Skip to content

Commit

Permalink
mark non-immediate by-value parameters as non-null
Browse files Browse the repository at this point in the history
  • Loading branch information
thestinger committed May 26, 2014
1 parent 20a4151 commit 0c51149
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/librustc/middle/trans/base.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1766,6 +1766,7 @@ pub fn get_fn_llvm_attributes(ccx: &CrateContext, fn_ty: ty::t) -> Vec<(uint, u6
if !type_is_immediate(ccx, t) {
attrs.push((idx, lib::llvm::NoAliasAttribute as u64));
attrs.push((idx, lib::llvm::NoCaptureAttribute as u64));
attrs.push((idx, lib::llvm::NonNullAttribute as u64));
}
}
}
Expand Down

0 comments on commit 0c51149

Please sign in to comment.