Mantis - Squeak
Viewing Issue Advanced Details
6842 Kernel minor always 01-08-08 23:11 01-22-08 21:46
0006842: Non-breaking spaces break code
When code is copied from the web or other sources, non-breaking spaces may be used to format it properly. Although they look normal to the eye, they fail to compile properly.
It's an easy fix. The second line of Scanner class>>initialize simply needs to include character 160, the non-breaking space, along with the others.

    newTable atAll: #(9 10 12 13 32 160) put: #xDelimiter. "tab lf ff cr space nbspace"

Then, the fix is installed once you execute:

        Scanner initialize

01-08-08 23:33   
In my opinion this amounts to a change to the language and should be considered carefully. It may be a good change, I don't know. I'm just suggesting that some discussion occur before 'officializing' this 'easy fix'.
nicolas cellier   
01-22-08 21:46   
Yes these errors are annoying: how would our eyes distinguish a non breaking space from a regular space (except near end of lines)?

I would vote for the change.

Only problem i see is that it might get viral: methods saved with non breaking spaces in Monticello repositories can only be loaded in images with this change...

Maybe it would be good for backward and cross-dialect compatibility to replace with a regular space when saving the changes in the change file or Monticello... (But maybe not inside literal strings nor comments!)