diff options
Diffstat (limited to 'crates/ra_hir_def')
-rw-r--r-- | crates/ra_hir_def/src/nameres.rs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/crates/ra_hir_def/src/nameres.rs b/crates/ra_hir_def/src/nameres.rs index 0c18df1a9..b279bdeef 100644 --- a/crates/ra_hir_def/src/nameres.rs +++ b/crates/ra_hir_def/src/nameres.rs | |||
@@ -137,7 +137,10 @@ impl ModuleOrigin { | |||
137 | } | 137 | } |
138 | 138 | ||
139 | pub fn is_inline(&self) -> bool { | 139 | pub fn is_inline(&self) -> bool { |
140 | matches!(self, ModuleOrigin::Inline { .. }) | 140 | match self { |
141 | ModuleOrigin::Inline { .. } => true, | ||
142 | ModuleOrigin::CrateRoot { .. } | ModuleOrigin::File { .. } => false, | ||
143 | } | ||
141 | } | 144 | } |
142 | 145 | ||
143 | /// Returns a node which defines this module. | 146 | /// Returns a node which defines this module. |