File tree Expand file tree Collapse file tree 3 files changed +4
-12
lines changed Expand file tree Collapse file tree 3 files changed +4
-12
lines changed Original file line number Diff line number Diff line change 1
1
---
2
2
refs/heads/master: 2d28d645422c1617be58c8ca7ad9a457264ca850
3
3
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4
- refs/heads/snap-stage3: b04c40bb1c96202409f663480076977619a1da30
4
+ refs/heads/snap-stage3: d7e1f08b2115b3f5dd1497e993fb5b3029e70346
5
5
refs/heads/try: 7b78b52e602bb3ea8174f9b2006bff3315f03ef9
6
6
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
7
7
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -1694,16 +1694,13 @@ pub fn create_llargs_for_fn_args(cx: fn_ctxt,
1694
1694
let arg = & args[ i] ;
1695
1695
let llarg = llvm:: LLVMGetParam ( cx. llfn , arg_n as c_uint ) ;
1696
1696
1697
- // Mark `&mut T` as no-alias, as the borrowck pass ensures it's true
1698
1697
match arg. ty . node {
1699
- ast:: ty_rptr( _, mt) => {
1700
- if mt. mutbl == ast:: m_mutbl {
1701
- llvm:: LLVMAddAttribute ( llarg, lib:: llvm:: NoAliasAttribute as c_uint ) ;
1702
- }
1703
- }
1698
+ // `~` pointers never alias other parameters, because ownership was transferred
1704
1699
ast:: ty_uniq( _) => {
1705
1700
llvm:: LLVMAddAttribute ( llarg, lib:: llvm:: NoAliasAttribute as c_uint ) ;
1706
1701
}
1702
+ // FIXME: #6785: `&mut` can only alias `&const` and `@mut`, we should check for
1703
+ // those in the other parameters and then mark it as `noalias` if there aren't any
1707
1704
_ => { }
1708
1705
}
1709
1706
You can’t perform that action at this time.
0 commit comments