| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Signed-off-by: Benjamin Coenen <[email protected]>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
We treat macro calls as expressions (there's appropriate Into impl),
which causes problem if there's expresison and non-expression macro in
the same node (like in the match arm).
We fix this problem by nesting macor patterns into another node (the
same way we nest path into PathExpr or PathPat). Ideally, we probably
should add a similar nesting for macro expressions, but that needs
some careful thinking about macros in blocks: `{ am_i_expression!() }`.
|
| |
|
| |
|
| |
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| | |
3062: Implement slice pattern AST > HIR lowering r=jplatte a=jplatte
WIP. The necessary changes for parsing are implemented, but actual inference is not yet. Just wanted to upload what I've got so far so it doesn't get duplicated :)
Will fix #3043
Co-authored-by: Jonas Platte <[email protected]>
|
| | |
|
| | |
|
|/ |
|
|
|
|
|
| |
- Handle const generics type args
- Fix issue with const generic as first parameter in trait impl
|
| |
|
| |
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
2641: Parse const generics r=matklad a=roblabla
Adds very primitive support for parsing const generics (`const IDENT: TY`) so that rust-analyzer stops complaining about the syntax being invalid.
Fixes #1574
Fixes #2281
Co-authored-by: roblabla <[email protected]>
|
| |
| |
| |
| |
| | |
Fixes #1574
Fixes #2281
|
|/
|
|
| |
Fixes #2547.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Although structs and unions have the same syntax and differ only in
the keyword, re-using the single syntax node for both of them leads to
confusion in practice, and propagates further down the hir in an
upleasent way.
Moreover, static and consts also share syntax, but we use different
nodes for them.
|
| |
|
|
|
|
|
|
| |
The default impl should have the same behaviour, and it can be generated
by codegen.
See also `ModuleItem` and `NominalDef`
|
| |
|
|\
| |
| |
| |
| | |
# Conflicts:
# crates/ra_assists/src/ast_editor.rs
|
| | |
|
| | |
|
|/
|
|
| |
#1856
|
| |
|
|
|
|
| |
This is modeled on `PlaceholderPat`.
|
| |
|
| |
|
|\
| |
| |
| |
| |
| |
| |
| | |
1743: Support `#[macro_use]` on `extern crate` r=matklad a=uHOOCCOOHu
Unfortunately, #1688 is still an issue. My guess is wrong :(
Co-authored-by: uHOOCCOOHu <[email protected]>
|
| | |
|
| | |
|
| | |
|
|/ |
|
| |
|
| |
|
|
|
|
| |
With the new owned trees, we don't need an indirection here
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
1208: [WIP] Goto for Macro's r=matklad a=Lapz
Adds goto definition for macros. Currently only works for macros in the current crate ~~otherwise it panics~~. Proper macro resolution needs to be added for it to resolve macros in other crates.
Todo
- [X] Allow goto from macro calls
- [X] Fix panics
- [x] Add tests
![Screen Recording 2019-04-25 at 18 00 24](https://user-images.githubusercontent.com/19998186/56754499-1dd01c00-6785-11e9-9e9a-1e36de70cfa3.gif)
Co-authored-by: Lenard Pratt <[email protected]>
|
| | |
|
|/ |
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
1154: Initial support for lang items (and str completion) r=flodiebold a=marcogroppo
This PR adds partial support for lang items.
For now, the only supported lang items are the ones that target an impl block.
Lang items are now resolved during type inference - this means that `str` completion now works.
Fixes #1139.
(thanks Florian Diebold for the help!)
Co-authored-by: Marco Groppo <[email protected]>
|
| | |
|