rust-analyzer/crates
bors[bot] efa72c899d
Merge #3591
3591: Support local macro_rules r=matklad a=edwin0cheng

This PR implement local `macro_rules` in function body, by adding following things:

1. While lowering, add a `MacroDefId` in body's `ItemScope` as a textual legacy macro. 
2. Make `Expander::enter_expand` search with given `ItemScope`.
3. Make `Resolver::resolve_path_as_macro` search with `LocalItemScope`.

Fix #2181

Co-authored-by: Edwin Cheng <edwin0cheng@gmail.com>
2020-03-15 12:15:09 +00:00
..
ra_arena Switch to variant-granularity field type inference 2019-11-25 00:12:36 +03:00
ra_assists Simplify 2020-03-13 18:02:04 +01:00
ra_cargo_watch Handle diagnostics with multiple primary spans 2020-03-12 15:24:20 +01:00
ra_cfg Update versions 2020-02-18 16:12:40 +02:00
ra_db Add extern source 2020-03-11 11:04:02 +08:00
ra_fmt When joining lines, unwrap trivial diverging blocks 2020-02-24 17:17:05 +01:00
ra_hir Fix completion of HashMap::new 2020-03-13 13:04:32 +01:00
ra_hir_def Merge #3591 2020-03-15 12:15:09 +00:00
ra_hir_expand Update comment 2020-03-12 02:00:56 +08:00
ra_hir_ty Support local macro_rules 2020-03-14 14:25:51 +08:00
ra_ide Merge #3591 2020-03-15 12:15:09 +00:00
ra_ide_db Remove some TextUnit->usize escapees 2020-03-12 22:33:27 -04:00
ra_mbe Merge #3513 2020-03-09 08:56:58 +00:00
ra_parser Parse variadics correctly 2020-03-13 13:54:14 +01:00
ra_prof Allow specifying additional info on call to profile 2020-03-06 17:36:51 +01:00
ra_project_model Switch from Vec<InlayKind> to object with props 2020-03-11 20:14:39 -07:00
ra_syntax Parse variadics correctly 2020-03-13 13:54:14 +01:00
ra_text_edit Remove some TextUnit->usize escapees 2020-03-12 22:33:27 -04:00
ra_tt Update versions 2020-02-18 16:12:40 +02:00
rust-analyzer Merge #3561 #3577 2020-03-13 14:01:29 +00:00
test_utils Move verbose tests out of line 2020-03-13 12:20:42 +01:00