mirror of
https://github.com/rust-lang/rust.git
synced 2025-05-07 15:37:39 +00:00
![]() Remove global `next_disambiguator` state and handle it with a `DisambiguatorState` type This removes `Definitions.next_disambiguator` as it doesn't guarantee deterministic def paths when `create_def` is called in parallel. Instead a new `DisambiguatorState` type is passed as a mutable reference to `create_def` to help create unique def paths. `create_def` calls with distinct `DisambiguatorState` instances must ensure that that the def paths are unique without its help. Anon associated types did rely on this global state for uniqueness and are changed to use (method they're defined in + their position in the method return type) as the `DefPathData` to ensure uniqueness. This also means that the method they're defined in appears in error messages, which is nicer. `DefPathData::NestedStatic` is added to use for nested data inside statics instead of reusing `DefPathData::AnonConst` to avoid conflicts with those. cc `@oli-obk` |
||
---|---|---|
.. | ||
impl-trait | ||
rfc-0000-never_patterns | ||
rfc-0107-bind-by-move-pattern-guards | ||
rfc-1014-stdout-existential-crisis | ||
rfc-1445-restrict-constants-in-patterns | ||
rfc-1623-static | ||
rfc-1717-dllimport | ||
rfc-1789-as-cell | ||
rfc-1857-stabilize-drop-order | ||
rfc-1937-termination-trait | ||
rfc-2005-default-binding-mode | ||
rfc-2008-non-exhaustive | ||
rfc-2091-track-caller | ||
rfc-2093-infer-outlives | ||
rfc-2126-crate-paths | ||
rfc-2126-extern-absolute-paths | ||
rfc-2151-raw-identifiers | ||
rfc-2175-or-if-while-let | ||
rfc-2294-if-let-guard | ||
rfc-2302-self-struct-ctor | ||
rfc-2306-convert-id | ||
rfc-2361-dbg-macro | ||
rfc-2396-target_feature-11 | ||
rfc-2421-unreserve-pure-offsetof-sizeof-alignof | ||
rfc-2457-non-ascii-idents | ||
rfc-2497-if-let-chains | ||
rfc-2528-type-changing-struct-update | ||
rfc-2565-param-attrs | ||
rfc-3348-c-string-literals | ||
rfc-3467-unsafe-pinned | ||
type-alias-impl-trait | ||
rfc-3391-result-ffi-guarantees.rs |