You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The different scope layers. (See visit_scopes). It should be clear how shadowing works. I saw this list once, which is likely incorrect, but a starting point:
local variables
items in unnamed blocks
items in the current module
crate names in the "extern prelude"
standard library prelude
language prelude (built-in types)
I think all prelude kinds should be documented and explicitly named. Currently the reference mentions "the prelude" which is ambiguous, and the extern prelude. There are other preludes like the language prelude, the macro_use prelude, the "tool prelude" (I think), etc. DONE Start documenting name resolution. #937
Name resolution should be documented. This is a large topic. A few pieces I can think of:
macro_useandmacro_export.Enum::<Type, Params>::Variantallowed since 1.33 rust#69356 for an unusual example.macro_useprelude, the "tool prelude" (I think), etc. DONE Start documenting name resolution. #937no_implicit_preludeshould clarify which preludes are not included. DONE Start documenting name resolution. #937usehandle something that is available in multiple namespaces (such as a module and a type). Add details on how names are introduced. #1052