-
-
Notifications
You must be signed in to change notification settings - Fork 37
Open
Labels
Description
Channel
C++Weekly
Topics
value initialization
aggregate initialization
zero initialization
Length
Should this be bite-sized (5-10 minutes) or more long form (10-20 minutes)?
Unsure.
I was 99% confident that if I have
struct X
{
float a[2];
float b;
};
X x[3]{};
that x will be zero initialized (i.e. all of those floats will be zero). I wanted to be 100% sure so I looked up the various relevant pages on cppreference and now I'm 95% sure.
Nobody1707, bsolomenco, amanbh, mehdi-fakihani, reedhedges and 3 more
Metadata
Metadata
Assignees
Labels
Projects
Status
No status