-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Request to make a temporary doc change to satisfy the IntelliJ-Rust parser #882
Comments
I don't think it's reasonable to remove important parts of the docs to work around an IDE issue. I just tried one way of simplifying the implementation that might have fixed it if it worked, but it didn't work. |
Yep I agree. I don't wanna remove docs due to IDE bugs. You're welcome to suggest alternate workarounds. |
For the record, what I tried is moving the docs out of the inner macro invocation. This didn't work for two reasons:
|
That's okay. This is not high priority.
Is the second option possible? I know that adding a new dependency for something so trivial isn't ideal, but would it be acceptable? |
I'm not aware of what |
It's not a crate, just a macro that's being copy-pasted around. I'm pretty sure it's going to break IntelliJ in the same way. Here's the one I added to Ruma a while ago: macro_rules! doc_concat {
( $( #[doc = $doc:expr] $( $thing:tt )* )* ) => ( $( #[doc = $doc] $( $thing )* )* );
} The issue I referenced in a comment above it, rust-lang/rust#52607, was apparently closed by rust-lang/rust#78837 but I'm still seeing issues without the macro, not sure what to make of that. There's a small chance it was just my own editor integration (rust-analyzer) that broke, but regardless of that I don't see how we could fix the first issue I mentioned. |
Why does rust-analyzer work then? |
I don't understand what you mean. Why wouldn't rust-analyzer work? |
Is this bit of code
absolutely necessary? If not, intellij-rust/intellij-rust#8589 can be worked around by removing this line (
#[doc = concat!("Route `", stringify!($method) ,"` requests to the given handler.")]
) from all the*_handler_fn
macros, until intellij-rust is fixed. Please consider doing so.The text was updated successfully, but these errors were encountered: