zero_init()1int zero_init() { return 0; } 2 int badGlobal = zero_init(); readBadGlobal()3int readBadGlobal() { return badGlobal; } 4 5 namespace badNamespace { 6 class BadClass { 7 public: BadClass()8 BadClass() { value = 0; } 9 int value; 10 }; 11 // Global object with non-trivial constructor. 12 BadClass bad_object; 13 } // namespace badNamespace 14 accessBadObject()15int accessBadObject() { return badNamespace::bad_object.value; } 16