diff options
| author | Alan Egerton <eggyal@gmail.com> | 2024-06-12 13:01:22 +0100 |
|---|---|---|
| committer | Alan Egerton <eggyal@gmail.com> | 2024-06-12 13:01:22 +0100 |
| commit | 114dd2061e0bfa6bc1353d0265389cfaa04d8858 (patch) | |
| tree | 4878585dc756c16cb2a5ff9ee82ac01d717ee158 /compiler/rustc_query_system/src | |
| parent | 02c7a5921e3de5c2b3ecb2e0082c1dafce0729a1 (diff) | |
Un-unsafe the `StableOrd` trait
Whilst incorrect implementations of this trait can cause miscompilation, they cannot cause memory unsafety in rustc.
Diffstat (limited to 'compiler/rustc_query_system/src')
| -rw-r--r-- | compiler/rustc_query_system/src/dep_graph/dep_node.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_query_system/src/dep_graph/dep_node.rs b/compiler/rustc_query_system/src/dep_graph/dep_node.rs index 5f1a03502a7..3fb59ad26f6 100644 --- a/compiler/rustc_query_system/src/dep_graph/dep_node.rs +++ b/compiler/rustc_query_system/src/dep_graph/dep_node.rs @@ -301,7 +301,7 @@ impl<HCX> ToStableHashKey<HCX> for WorkProductId { self.hash } } -unsafe impl StableOrd for WorkProductId { +impl StableOrd for WorkProductId { // Fingerprint can use unstable (just a tuple of `u64`s), so WorkProductId can as well const CAN_USE_UNSTABLE_SORT: bool = true; } |
