BartVandewoestyne / Design-Patterns-GoF

Working code for the Design Patterns book from the Gang of Four.
278 stars 123 forks source link

Initialize _registry variable correctly in Registry of Singletons example #5

Open BartVandewoestyne opened 1 year ago

BartVandewoestyne commented 1 year ago

The _registry variable in Creational_Patterns/Singleton/registry_of_singletons/Singleton.cpp is not yet correctly initialized (see also the TODO in that file). We should initialize it to something feasible so that we don't get a crash when running the example.