Comment Comment by UncleMeat ???You can absolutely write a type like this. class Foo { public: Foo() {} // never initialized x int x; } And then using it like this Foo f; bar(foo.x); // oops "But my types are well designed" is the usual response to "why the heck does the language allow you to quietly expose yourself to UB in this way?" parent UncleMeat 2 years ago
You can absolutely write a type like this.
And then using it like this "But my types are well designed" is the usual response to "why the heck does the language allow you to quietly expose yourself to UB in this way?"