this post was submitted on 11 Apr 2024
7 points (100.0% liked)
C++
1782 readers
1 users here now
The center for all discussion and news regarding C++.
Rules
- Respect instance rules.
- Don't be a jerk.
- Please keep all posts related to C++.
founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
Aww, was hoping for some insight on global variable initialization order. It's something I've been curious about how different vendors order things with linking.
"Essentially at random, and it may change with build flags, compiler version updates, static v. dynamic linking, and who knows what else?" Can't rely on it, I'm afraid. What you can rely on is static init of local variables:
My
C
brain does not likestatic auto