-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Don't require semicolon after macro usage with brackets #225
Comments
Note that similar logic already works for macros in item position: this function basically returns "does this macro use |
DJMcNab
added a commit
to DJMcNab/rust-analyzer
that referenced
this issue
Dec 18, 2018
DJMcNab
added a commit
to DJMcNab/rust-analyzer
that referenced
this issue
Dec 19, 2018
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The following code expects a semicolon at the cursor position:
This might be caused by the fact that the macro call is being treated as a non-block expression, though I don't know for sure (I am not very familiar with the parser):
https://github.com/rust-analyzer/rust-analyzer/blob/477de790b0211196256a772befe4f577d1a8ba14/crates/ra_syntax/src/grammar/expressions/mod.rs#L204-L209
The problem is that some macros should be treated as blocks and other shouldn't, so determining whether the element is a block based on
SyntaxKind
is insufficient in this case (unless we introduce a special syntax kind for block-like macro calls)The text was updated successfully, but these errors were encountered: