-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Macro error with futures::try_join! #6835
Comments
Same here. |
Maybe related to #6811 |
@Victor-Savu @peku33 Please check this again with the next nightly or current master. |
Unfortunately I can still reproduce the problem. Here is a minimal reproduction:
[package]
name = "rust-analyzer-error"
version = "0.1.0"
edition = "2018"
[dependencies]
tokio = { version = "0.2", features = ["macros"] }
futures = "0.3"
#[tokio::main]
async fn main() {
futures::join!(
async {
println!("Hello, world!");
},
async {
println!("Hello, world!");
}
);
} I used
|
|
So this is a problem with rust-analyzer or futures? |
Any error that rust-analyzer produces in code that compiles is a problem in rust-analyzer. You can disable the diagnostic by adding |
Triage: this still happens even after #7145. |
Ah, it's a |
still getting this, any easy way to disable it temporarily? |
@bionicles if you are using VSCode, create a file {
"rust-analyzer.diagnostics.disabled": [
"macro-error"
]
} |
It's annoying that with |
Doesn't work for me with futures::select!. Any other way i can disable this? |
The diagnostic is now called |
This also occurs with Yew's |
This occurs with fstrings's macros (seemably all?). |
If the problem is
|
I'd rather keep it open. It will probably take years until the ecosystem uses futures 0.4 |
I will backport that patch to 0.3, so no need to wait for futures 0.4. (See the label of the PR that fixed the issue) |
Released futures 0.3.15 which includes the fix for this issue. |
I recently started getting the same error with Should I open a separate issue or is this reasonably related? |
Doesn't sound like the same issue |
I've just ran into this issue recently with pyo3. |
I am experiencing the same thing, for now I just disabled |
Me too, I am also disabling it. |
I got the problem in ifmt. |
I've ran into this issue with |
@alexdevteam |
Got this error with |
In my particular case, I was getting the problem with Yew's macros. Other macros from other libraries like Embassy seemed to work. To work-around my issue, my settings.json looks like:
|
This also worked for me, but I was using a VS Workspace, for which |
For anyone using CoC with neovim:
|
I'll close this issue, a lot of comments in here are about very different issues making it difficult to figure out what the problem even is at this point. So we gain more from people opening new specific issues instead. |
Same as @jeromegn , I am still getting the error on the nightly version of rust-analyzer, in my case in a call to
futures::try_join!
.Originally posted by @Victor-Savu in #6716 (comment)
The text was updated successfully, but these errors were encountered: