On 9/17/05, Jon A. Lambert <jlsysinc / alltel.net> wrote:
> Jon A. Lambert wrote:
> > Anyone know what the difference is, if any?
> 
> Dear Jon,
> 
> If you had bothered to read the source code you would have found a
> bunch of slick character encoding tables in regex.c and know that
> the lengths of characters in strings are dependent on the encoding
> options you be running on.   As long as you be using usacii then
> you'll be alright, but if you start messing with kanji you'll be bitten on
> the ass as StringScanner will suddenly be popping and hopping
> through 1,2, or n bytes at a time with getch.  So I'd recommend
> using getbyte.
> 
> There are enough hints about such things dropped in the very first
> chapters of the "Coding Ruby: The Canonical Coder's Guide".
> Pay attention and do some research before wasting our time.

It's necessary now to read C source code to figure out the API for
StringScanner?