BlackToppStudios / Mezz_Foundation

Foundational Data types that enforce no opinions on how to build games and provide many facilities that complex games need. This largely avoids graphics and physics, but provides tools like the SortedVector, CountedPtr and HashedString classes.
GNU General Public License v3.0
3 stars 0 forks source link

Add Support to stringtools for detecting BOM #72

Open Sqeaky opened 4 years ago

Sqeaky commented 4 years ago

Some Unicode text files have a Byte Order Mark at the beginning of the file. This is usually 4 bytes that indicate if the file was made on a big or little endian machines. The JagatiIndex.cmake file has one that can be used as an Example. Having at least 4 functions on the StringTools seems like a good idea: IsBigEndianBOM(String), isLittleEndingBOM(String), IsBom(String), IsBOMDigit(Character).