abs icon indicating copy to clipboard operation
abs copied to clipboard

Add Syntax to Enter Arbitrary Bytes in String Literals

Open tyingq opened this issue 3 years ago • 0 comments

I see that string literals support \t, \r, and \n. But they don't seem to support other commonly seen syntax like \xff, \0, and so on. So there's not an obvious way to get arbitrary values into a string, other than maybe reading from stdin().

I'm new to ABS, so I don't know what the limitations might be. I'm assuming a string can have null characters in it, but don't know that for sure.

Also, I see you can use unicode in string literals. I assume that means there's a default assumed encoding (utf8?), which perhaps clashes with the idea of putting in arbitrary bytes. If that's the case, I assume that has to eventually be addressed (new type, or ability to specify encoding) if you want to be able to send/receive arbitrary data over sockets or in/out of files.

tyingq avatar Aug 31 '21 16:08 tyingq