4 ms·
> But that just means it's a black box and I can't do anything meaningful to it other than copying it around. It means you need some out-of-band context about
by chimeracoder 11y ago
> But that just means it's a black box and I can't do anything meaningful to it other than copying it around.
It means you need some out-of-band context about the domain. The things I can expect do with text if I know I'm parsing C source code is very different from the things I can expect to do with text if I'm parsing Twitter data (especially if the tweets are geotagged to a region that doesn't speak English). Or, if I'm parsing SMS message data (which are likely to contain lots of Unicode emoji).
And quite frankly, pretty much any task involving processing arbitrary input text already has so many complicating factors that have nothing to do with Unicode. There's already pretty much nothing interesting you can do to arbitrary text besides copy it around if all you know is the character encoding. Every real-life problem space has more concrete assumptions about the data you're dealing with, so including assumptions about the character encoding and characters used in that set is not terribly burdensome.
- jstimpfle 11y agoAbsolutely. And my go-to context is ASCII whenever it's convenient. This is the only context where I have a clear idea what's inside it.