Skip to content

macros: render more comprehensible documentation for select!#6468

Merged
Darksonn merged 2 commits intotokio-rs:masterfrom
dtolnay-contrib:selectdoc
Apr 6, 2024
Merged

macros: render more comprehensible documentation for select!#6468
Darksonn merged 2 commits intotokio-rs:masterfrom
dtolnay-contrib:selectdoc

Conversation

@dtolnay
Copy link
Copy Markdown
Contributor

@dtolnay dtolnay commented Apr 6, 2024

Motivation

Screenshot from 2024-04-06 15-16-57

Solution

Screenshot from 2024-04-06 15-17-10

@Darksonn Darksonn added T-docs Topic: documentation A-tokio Area: The main tokio crate M-macros Module: macros in the main Tokio crate labels Apr 6, 2024
@Darksonn
Copy link
Copy Markdown
Member

Darksonn commented Apr 6, 2024

Looks sensible. Thanks! Does this hide docs from ide tooltips?

Rendered docs.

Comment thread tokio/src/macros/select.rs Outdated
@dtolnay
Copy link
Copy Markdown
Contributor Author

dtolnay commented Apr 6, 2024

Does this hide docs from ide tooltips?

Yes, seems it does. Good call.

I found a way to fix it.

Copy link
Copy Markdown
Member

@Darksonn Darksonn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the doc improvement! Looks good to me.

The extra indentation is unfortunate, but oh well.

@Darksonn Darksonn enabled auto-merge (squash) April 6, 2024 22:45
auto-merge was automatically disabled April 6, 2024 22:45

Head branch was pushed to by a user without write access

@dtolnay
Copy link
Copy Markdown
Contributor Author

dtolnay commented Apr 6, 2024

In fact the extra indentation wrecked the docs, too.

image

I pushed a different approach without indentation, that rustfmt is still okay with.

@Darksonn Darksonn enabled auto-merge (squash) April 6, 2024 22:48
@Darksonn
Copy link
Copy Markdown
Member

Darksonn commented Apr 6, 2024

Good catch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-tokio Area: The main tokio crate M-macros Module: macros in the main Tokio crate T-docs Topic: documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants