Skip to content

Commit b52f6f4

Browse files
committed
Elaborate on why we don't look at frozenness
1 parent 870a6dc commit b52f6f4

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/librustc_mir/interpret/intern.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,8 @@ for
168168
// We do not have any `frozen` logic here, because it's essentially equivalent to
169169
// the mutability except for the outermost item. Only `UnsafeCell` can "unfreeze",
170170
// and we check that in `visit_aggregate`.
171+
// This is not an inherent limitation, but one that we know to be true, because
172+
// const qualification enforces it. We can lift it in the future.
171173
match (self.mode, mutability) {
172174
// all is "good and well" in the unsoundness of `static mut`
173175
(InternMode::StaticMut, _) => {},

0 commit comments

Comments
 (0)