[LLVMbugs] [Bug 19779] no zero initialization in value initialization
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Sun May 18 11:34:48 PDT 2014
http://llvm.org/bugs/show_bug.cgi?id=19779
Richard Smith <richard-llvm at metafoo.co.uk> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
CC| |richard-llvm at metafoo.co.uk
Resolution|--- |INVALID
--- Comment #1 from Richard Smith <richard-llvm at metafoo.co.uk> ---
B is an aggregate, so B{} is aggregate initialization, which initializes the A
subobject from empty braces. That performs value-initialization of an A object,
which does *not* perform zero-initialization first. Replacing 'B{}' with 'B()'
gives 0 as the value of b.a.i, as it should.
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20140518/b41e55b2/attachment.html>
More information about the llvm-bugs
mailing list