aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir_expand/src
diff options
context:
space:
mode:
authorFlorian Diebold <[email protected]>2019-12-06 20:21:39 +0000
committerFlorian Diebold <[email protected]>2019-12-06 20:25:22 +0000
commit4a99ef5c39e670162ea3c35d53ccd75b81281865 (patch)
tree0b2434749b1700489633630f2e1ff49bf79eb12e /crates/ra_hir_expand/src
parenta565072ddeac519eea3b415a57e9fd208e20e562 (diff)
Builtin macros only use caller tokens
Diffstat (limited to 'crates/ra_hir_expand/src')
-rw-r--r--crates/ra_hir_expand/src/db.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/ra_hir_expand/src/db.rs b/crates/ra_hir_expand/src/db.rs
index 99dabf3fb..013a6c8ba 100644
--- a/crates/ra_hir_expand/src/db.rs
+++ b/crates/ra_hir_expand/src/db.rs
@@ -45,8 +45,8 @@ impl TokenExpander {
45 pub fn map_id_up(&self, id: tt::TokenId) -> (tt::TokenId, mbe::Origin) { 45 pub fn map_id_up(&self, id: tt::TokenId) -> (tt::TokenId, mbe::Origin) {
46 match self { 46 match self {
47 TokenExpander::MacroRules(it) => it.map_id_up(id), 47 TokenExpander::MacroRules(it) => it.map_id_up(id),
48 TokenExpander::Builtin(..) => (id, mbe::Origin::Def), 48 TokenExpander::Builtin(..) => (id, mbe::Origin::Call),
49 TokenExpander::BuiltinDerive(..) => (id, mbe::Origin::Def), 49 TokenExpander::BuiltinDerive(..) => (id, mbe::Origin::Call),
50 } 50 }
51 } 51 }
52} 52}