Skip to content

Commit 8bc84fd

Browse files
committed
Auto merge of rust-lang#106371 - RalfJung:no-ret-position-noalias, r=nikic
do not add noalias in return position `noalias` as a return attribute in LLVM indicates that the returned pointer does not alias anything else that is reachable from the caller, *including things reachable before this function call*. This is clearly not the case with a function like `fn id(Box<T>) -> Box<T>`, so we cannot use this attribute. Fixes rust-lang/unsafe-code-guidelines#385 (including an actual miscompilation that `@comex` managed to produce).
2 parents 3cf246c + 9f6039a commit 8bc84fd

File tree

0 file changed

+0
-0
lines changed

    0 file changed

    +0
    -0
    lines changed

    0 commit comments

    Comments
     (0)