Skip to content

Add a warning to Delimiter::None that rustc currently does not respect it.#455

Merged
dtolnay merged 1 commit intodtolnay:masterfrom
CensoredUsername:master
May 25, 2024
Merged

Add a warning to Delimiter::None that rustc currently does not respect it.#455
dtolnay merged 1 commit intodtolnay:masterfrom
CensoredUsername:master

Conversation

@CensoredUsername
Copy link
Copy Markdown
Contributor

Currently when used to implement a proc_macro, Delimiter::None simply doesn't do what it is documented to do.

While this is a rustc bug (rust-lang/rust#67062), it is a long standing one, and hard to discover.
This pull request adds a warning to inform users of this issue, with a link to the relevant issue, and a version number of the last known affected rustc version.

Copy link
Copy Markdown
Owner

@dtolnay dtolnay left a comment

Choose a reason for hiding this comment

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

Could you please add this in proc_macro's documentation to begin with? Then we can mirror it here. I am not interested in the documentation being out of sync.

@CensoredUsername
Copy link
Copy Markdown
Contributor Author

Of course. I wasn't aware that it was a mirror of that.

I'll follow up here if/when that's done.

…t it.

It does not provide the behaviour it is indicated to provide when used in
a proc_macro context.

This is a port of rust-lang/rust/124389.
@CensoredUsername
Copy link
Copy Markdown
Contributor Author

This is now a port of the accepted rust-lang/rust/pull/124389

Copy link
Copy Markdown
Owner

@dtolnay dtolnay left a comment

Choose a reason for hiding this comment

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

Thank you!

@dtolnay dtolnay merged commit d850da5 into dtolnay:master May 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants