4 ms·
> the tag for the character set (as you rightly think necessary) takes up space too Java recently (JEP 254) moved to internal flag for Strings (ISO-8859-1 or U
by ucho 11y ago
> the tag for the character set (as you rightly think necessary) takes up space too
Java recently (JEP 254) moved to internal flag for Strings (ISO-8859-1 or UTF16) as most memory was used by strings without any special characters. It was decided that additional complexity was worth it. I guess that getting rid of UTF-16 would be even better as it is the worst Unicode encoding.