1
Fork 0

Fix even more clippy warnings

This commit is contained in:
Joshua Nelson 2020-10-26 21:02:48 -04:00
parent bfecb18771
commit 57c6ed0c07
53 changed files with 276 additions and 520 deletions

View file

@ -397,10 +397,8 @@ impl StaticMethods for CodegenCx<'ll, 'tcx> {
// As an optimization, all shared statics which do not have interior
// mutability are placed into read-only memory.
if !is_mutable {
if self.type_is_freeze(ty) {
llvm::LLVMSetGlobalConstant(g, llvm::True);
}
if !is_mutable && self.type_is_freeze(ty) {
llvm::LLVMSetGlobalConstant(g, llvm::True);
}
debuginfo::create_global_var_metadata(&self, def_id, g);