GabrielDosReis / ipr

Compiler-neutral Internal Program Representation for C++
BSD 3-Clause "New" or "Revised" License
222 stars 23 forks source link

Miscellaneous cleanup 5/n #175

Closed GabrielDosReis closed 3 years ago

GabrielDosReis commented 3 years ago

Back in the 2000s, we didn't have constexpr to enforce static initialization of global objects of class types with constructors, so we 'manually' constructed many commonly used objects at startup; these include allocating some statically known String objects. This patch makes such String objects statically allocated. In the process, it also removed uses of const char* and std::string as interface for trucking character strings. A follow up patch will switch to consistent uses of UTF-8 encoded character strings for the internal representation.