OwningRef
is included in the compiler despite known soundness problems.
#109974
Labels
C-discussion
Category: Discussion or questions that doesn't represent real issues.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
The
OwningRef
module in rustc_data_structures, which seems to be a copy of this crate (perhaps with small additions?), has known soundness issues.I wrote an article about the soundness problems here.
It's used in rustc in
MetadataRef
and related things. (I don't know if it's used anywhere else).I don't know of any actual unsafe use of this crate in rustc, but I haven't actually tried to look for any.
IMO, in order to keep the code safe, either
owning_ref
should be replaced with something else, or otherwise, it should be updated to contain the known fixes to these soundness problems (here).The text was updated successfully, but these errors were encountered: