Special characters in strings

Started by Sandman, November 26, 2007, 07:58:20 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Sandman

I'd like to suggest special characters (\r, \n, \0, \\, etc) in strings.

"Hello.\n" would be the same as "Hello."+chr(10)

This brings a different way of string interpretation, as character escaping would also be useful, so it won't be fully compatible with Fenix code (the '\' char in Fenix is just a '\'). Perhaps have it as a bgdc.exe parameter again.

Another thing to consider is the way \n behaves. It's also possible to have its meaning depending on the OS (so on Windows it's CR+LF and on Unix it's only LF).

Well just an idea, but perhaps it's more work than it's worth.
-- Sandman

SplinterGU

Download Lastest BennuGD Release: http://www.bennugd.org/node/2

JaViS

Working on Anarkade. A couch multiplayer 2D shooter.