[PATCH] D17983: Eliminate many benign instances of "potentially uninitialized local variable" warnings

Teresa Johnson via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 9 08:11:41 PST 2016


tejohnson added a subscriber: tejohnson.
tejohnson added a comment.

Thanks for doing this!

I will fix these 3, which one of my changes would have provoked. It is a benign case since we do have an assert at the use site checking the same condition that the inits are guarded with, but there is no reason not to 0 init these to avoid the bogus warning.

Warning	C4701	potentially uninitialized local variable 'FnEntry8BitAbbrev' used	LLVMBitWriter	c:\llvm\llvm\lib\bitcode\writer\bitcodewriter.cpp	2353
Warning	C4701	potentially uninitialized local variable 'FnEntry7BitAbbrev' used	LLVMBitWriter	c:\llvm\llvm\lib\bitcode\writer\bitcodewriter.cpp	2357
Warning	C4701	potentially uninitialized local variable 'FnEntry6BitAbbrev' used	LLVMBitWriter	c:\llvm\llvm\lib\bitcode\writer\bitcodewriter.cpp	2355


http://reviews.llvm.org/D17983





More information about the llvm-commits mailing list