PureBasic News

Not needed. Leaving here.

LOL, I didn’t even see the traffic – I ignored them ages ago. :rofl:

Why PureBasic chose to use UCS2 strings instead of UTF-8? I think UTF-8 makes more sense today.

It uses USC2 internally due to native compatibility with Windows, but automatically reads/writes UTF8, so you more or less never notice this. In fact, I had to look this up because I’ve never had any issue and was assuming it was just UTF-8 throughout. Unicode

It also offers string handling functions and flags to work across UTF-8, ASCII, and PB_Unicode, which is apparently UCS. I’ve actually found this easier than dealing with Encodings in Xojo, though clearly it doesn’t support an arbitrary encoding.

That said, the next version (6.4alpha) was just announced yesterday, and Fred discussed the rewrite of the string manager toward increasing performance. It’s supposed to be “99%” backward compatible, so I expect that this same relationship with UTF-8 will continue.

1 Like