Open CAD97 opened 1 year ago
-Zmiri-retag-fields=scalar is roughly explained as retagging where rustc emits noalias attributes.
That's a motivation for the choice of behavior, but not a spec.
I don't think it makes sense to tie retag-fields and box-noalias together in any way. However we could consider making Miri respect box-noalias, completely independent of retag-fields.
Note however that retagging justifies both the noalias
and dereferenceable
attributes. For Box this is fine though since we already don't add dereferenceable
.
-Zmiri-retag-fields=scalar
is roughly explained as retagging where rustc emitsnoalias
attributes. For this to be accurate,Box
shouldn't cause retagging when-Zbox-noalias=no
, since setting this (experimental) rustc flag disables emittingnoalias
forBox
.