aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_def/src
Commit message (Collapse)AuthorAgeFilesLines
...
* | Remove unused test fixturesEdwin Cheng2021-03-281-4/+0
| |
* | Basic Support Macro 2.0Edwin Cheng2021-03-272-39/+85
|/
* Fix recursive macro statement expansionEdwin Cheng2021-03-254-52/+37
|
* Merge #7907bors[bot]2021-03-242-1/+38
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7907: Autoderef with visibility r=cynecx a=cynecx Fixes https://github.com/rust-analyzer/rust-analyzer/issues/7841. I am not sure about the general approach here. Right now this simply tries to check whether the autoderef candidate is reachable from the current module. ~~However this doesn't exactly work with traits (see the `tests::macros::infer_derive_clone_in_core` test, which fails right now).~~ see comment below Refs: - `rustc_typeck` checking fields: https://github.com/rust-lang/rust/blob/66ec64ccf31883cd2c28d045912a76179c0c6ed2/compiler/rustc_typeck/src/check/expr.rs#L1610 r? @flodiebold Co-authored-by: cynecx <[email protected]>
| * hir_def: move visibility queries from hir_ty to hir_defcynecx2021-03-242-1/+38
| |
* | Merge bang-macros and derives in name resolutionJonas Schievink2021-03-231-86/+79
| |
* | resolver: manually traverse nested block scopesJonas Schievink2021-03-223-5/+32
| |
* | Code review fixesKirill Bulatov2021-03-221-0/+2
| |
* | Do not revisit recursively imported modulesKirill Bulatov2021-03-211-7/+47
| |
* | Merge #8134bors[bot]2021-03-211-4/+9
|\ \ | | | | | | | | | | | | | | | | | | | | | 8134: Correct the paths of submodules from the include! macro r=edwin0cheng a=sticnarf This PR should fix #7846. It mostly follows the instructions from @edwin0cheng in that issue. Co-authored-by: Yilin Chen <[email protected]>
| * | check is_include_macro only when attr_path is not specifiedYilin Chen2021-03-211-4/+3
| | | | | | | | | | | | Signed-off-by: Yilin Chen <[email protected]>
| * | use the included file as the source of expanded include macroYilin Chen2021-03-211-2/+8
| | | | | | | | | | | | Signed-off-by: Yilin Chen <[email protected]>
* | | Merge #8135bors[bot]2021-03-212-2/+2
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8135: more clippy::{perf, complexity, style} fixes r=Veykril a=matthiaskrgr Co-authored-by: Matthias Krüger <[email protected]>
| * | | clippy::complexity simplifications related to IteratorsMatthias Krüger2021-03-211-1/+1
| | | |
| * | | remove more redundant clones (clippy::redundant_clone())Matthias Krüger2021-03-211-1/+1
| |/ /
* | | Merge #8128bors[bot]2021-03-212-6/+28
|\ \ \ | |/ / |/| | | | | | | | | | | | | | | | | | | | | | | 8128: Expand legacy-scoped macro during collection r=jonas-schievink a=jonas-schievink Fixes https://github.com/rust-analyzer/rust-analyzer/issues/8120 Co-authored-by: Jonas Schievink <[email protected]>
| * | Expand legacy-scoped macro during collectionJonas Schievink2021-03-212-6/+28
| |/
* | Fix incorrect scoping in while expressionsLukas Wirth2021-03-211-1/+1
| |
* | Track labels in scopesLukas Wirth2021-03-212-11/+52
|/
* Add `AttrsWithOwner` and clean up `source_map`Jonas Schievink2021-03-192-126/+192
|
* Return `Either` from `MacroDefId::ast_id`Jonas Schievink2021-03-191-3/+4
|
* Fix handling of `#![cfg]` in outline module fileJonas Schievink2021-03-192-21/+48
|
* Add builtin macro-like attributesJonas Schievink2021-03-191-2/+5
|
* Rename derive-specific APIsJonas Schievink2021-03-193-8/+8
|
* Merge #8097bors[bot]2021-03-191-1/+1
|\ | | | | | | | | | | | | | | 8097: Parse extended_key_value_attributes r=jonas-schievink a=Veykril Companion PR https://github.com/rust-analyzer/ungrammar/pull/31 Co-authored-by: Lukas Wirth <[email protected]>
| * Parse extended_key_value_attributesLukas Wirth2021-03-191-1/+1
| |
* | Document fields of `ModuleId`Jonas Schievink2021-03-181-1/+5
| |
* | Merge #8083bors[bot]2021-03-181-16/+48
|\ \ | | | | | | | | | | | | | | | | | | | | | 8083: Track source file IDs in source mapping of Attrs r=jonas-schievink a=Veykril Fixes the panics/incorrect injection highlighting of outline module declarations until we figure out a nicer source mapping strategy for attributes. Co-authored-by: Lukas Wirth <[email protected]>
| * | Track source file IDs in source mapping of AttrsLukas Wirth2021-03-181-16/+48
| | |
* | | Add testJonas Schievink2021-03-181-0/+26
| | |
* | | Record custom derive helpers in `DefMap`Jonas Schievink2021-03-183-25/+91
| | | | | | | | | | | | Also clean up proc macro attribute parsing a bit
* | | Store an `AstId` for procedural macrosJonas Schievink2021-03-182-7/+8
| | |
* | | Make MacroDefId's `AstId` mandatory when possibleJonas Schievink2021-03-184-15/+12
| |/ |/|
* | Merge #8082bors[bot]2021-03-182-0/+12
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | 8082: Proper handle inner recursive macro rules cases r=edwin0cheng a=edwin0cheng Fixes #7645 cc @jonas-schievink bors r+ Co-authored-by: Edwin Cheng <[email protected]>
| * Handle inner recursive macro rules casesEdwin Cheng2021-03-182-0/+12
| |
* | Rename `item_tree` query to `file_item_tree`Jonas Schievink2021-03-185-11/+11
| |
* | Make `ItemTreeId` its own typeJonas Schievink2021-03-187-36/+76
| |
* | Avoid cloning `CfgOptions`Jonas Schievink2021-03-181-2/+3
| |
* | Support `#[cfg]` on all associated itemsJonas Schievink2021-03-181-5/+5
| |
* | Merge #8075bors[bot]2021-03-172-16/+37
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | 8075: Fix `use crate as <name>;` imports r=jonas-schievink a=jonas-schievink Fixes https://github.com/rust-analyzer/rust-analyzer/issues/4644 bors r+ Co-authored-by: Jonas Schievink <[email protected]>
| * | Fix `use crate as <name>;` importsJonas Schievink2021-03-172-16/+37
| | |
* | | Improve diagnostic when including nonexistent fileJonas Schievink2021-03-172-2/+2
|/ /
* | Use first early expansion error during nameresJonas Schievink2021-03-172-1/+20
| |
* | Apply `#[cfg]`s when computing function signaturesJonas Schievink2021-03-172-4/+17
| |
* | ItemTree: lower attributes on fn parametersJonas Schievink2021-03-173-23/+54
| |
* | Merge #8065bors[bot]2021-03-171-49/+56
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | 8065: Better handling of block doc comments r=Veykril a=Veykril Moves doc string processing to `Attrs::docs`, as we need the indent info from all comments before being able to know how much to strip Closes #7774 Co-authored-by: Lukas Wirth <[email protected]>
| * | Fix incorrect newline emission in Attrs::docsLukas Wirth2021-03-171-14/+14
| | |
| * | Better handling of block doc commentsLukas Wirth2021-03-171-38/+45
| | |
* | | Handle `#[cfg]` on call argumentsJonas Schievink2021-03-171-11/+16
|/ /
* | Merge #8059bors[bot]2021-03-171-6/+39
|\ \ | |/ |/| | | | | | | | | | | 8059: Move doc-comment highlight injection from AST to HIR r=matklad,jonas-schievink a=Veykril Fixes #5016 Co-authored-by: Lukas Wirth <[email protected]>