diff options
Diffstat (limited to 'crates/hir_expand')
-rw-r--r-- | crates/hir_expand/src/db.rs | 1 | ||||
-rw-r--r-- | crates/hir_expand/src/name.rs | 36 |
2 files changed, 37 insertions, 0 deletions
diff --git a/crates/hir_expand/src/db.rs b/crates/hir_expand/src/db.rs index b591130ca..ade57ac1b 100644 --- a/crates/hir_expand/src/db.rs +++ b/crates/hir_expand/src/db.rs | |||
@@ -389,6 +389,7 @@ fn to_fragment_kind(db: &dyn AstDatabase, id: MacroCallId) -> FragmentKind { | |||
389 | CALL_EXPR => FragmentKind::Expr, | 389 | CALL_EXPR => FragmentKind::Expr, |
390 | INDEX_EXPR => FragmentKind::Expr, | 390 | INDEX_EXPR => FragmentKind::Expr, |
391 | METHOD_CALL_EXPR => FragmentKind::Expr, | 391 | METHOD_CALL_EXPR => FragmentKind::Expr, |
392 | FIELD_EXPR => FragmentKind::Expr, | ||
392 | AWAIT_EXPR => FragmentKind::Expr, | 393 | AWAIT_EXPR => FragmentKind::Expr, |
393 | CAST_EXPR => FragmentKind::Expr, | 394 | CAST_EXPR => FragmentKind::Expr, |
394 | REF_EXPR => FragmentKind::Expr, | 395 | REF_EXPR => FragmentKind::Expr, |
diff --git a/crates/hir_expand/src/name.rs b/crates/hir_expand/src/name.rs index 63f828707..b26ffa1ef 100644 --- a/crates/hir_expand/src/name.rs +++ b/crates/hir_expand/src/name.rs | |||
@@ -208,6 +208,42 @@ pub mod known { | |||
208 | PartialOrd, | 208 | PartialOrd, |
209 | Eq, | 209 | Eq, |
210 | PartialEq, | 210 | PartialEq, |
211 | // Safe intrinsics | ||
212 | abort, | ||
213 | size_of, | ||
214 | min_align_of, | ||
215 | needs_drop, | ||
216 | caller_location, | ||
217 | size_of_val, | ||
218 | min_align_of_val, | ||
219 | add_with_overflow, | ||
220 | sub_with_overflow, | ||
221 | mul_with_overflow, | ||
222 | wrapping_add, | ||
223 | wrapping_sub, | ||
224 | wrapping_mul, | ||
225 | saturating_add, | ||
226 | saturating_sub, | ||
227 | rotate_left, | ||
228 | rotate_right, | ||
229 | ctpop, | ||
230 | ctlz, | ||
231 | cttz, | ||
232 | bswap, | ||
233 | bitreverse, | ||
234 | discriminant_value, | ||
235 | type_id, | ||
236 | likely, | ||
237 | unlikely, | ||
238 | ptr_guaranteed_eq, | ||
239 | ptr_guaranteed_ne, | ||
240 | minnumf32, | ||
241 | minnumf64, | ||
242 | maxnumf32, | ||
243 | rustc_peek, | ||
244 | maxnumf64, | ||
245 | type_name, | ||
246 | variant_count, | ||
211 | ); | 247 | ); |
212 | 248 | ||
213 | // self/Self cannot be used as an identifier | 249 | // self/Self cannot be used as an identifier |