Re:JEP254: proposal to represent Java Strings as ISO-8859-1
by TheLoneWolfling on Saturday May 16, 2015 @11:33AM
(#9556450)
Agreed. The copy-on-substring behavior is a real pain, and I don't know if there's any workaround.
[ Parent
| on HN ]
Re:JEP254: proposal to represent Java Strings as ISO-8859-1
by needusername on Sunday May 17, 2015 @12:53PM
(#9560701)
Not using String, eg. using CharBuffer (and #slice) or building your own. It's annoying and not always an option.
Re:JEP254: proposal to represent Java Strings as ISO-8859-1
by TheLoneWolfling on Wednesday May 20, 2015 @12:07AM
(#9574600)
Yep, as you said, not always an option. No way to pass them to external things expecting strings, for one. Wouldn't be an issue, except that you can't extend strings.