Add ImmutableString to encapsulate some compiler strings The new ImmutableString class is intended to be used instead of plain const char pointers to pool-allocated or static memory. It has the following advantages over using plain const char pointers: 1. It makes it clear when a string is guaranteed to be safe to pass around inside the compiler. 2. It can be compared with a comparison operator rather than using strcmp, which is easier to read. 3. It records the length of the stored string, which enables faster copies and comparisons in some cases. 4. ImmutableStrings could be implicitly converted from std::strings when a pool-allocated string is required. This is robust and convenient. C++17 has a similar class std::string_view, but our code style doesn't allow it yet. We also couldn't use it as is if we require properties 1 and 4 from above, but would rather need to inherit or wrap it in a custom class. Eventually all current usage of TString could be replaced with ImmutableString. For now, use it for unmangled built-in names. TEST=angle_unittests BUG=angleproject:2267 Change-Id: Id60c7b544032e06460e1b99837e429bc84dc4367 Reviewed-on: https://chromium-review.googlesource.com/881020 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>