[BUG]Integer class(Object)>>error:

Boris Gaertner Boris.Gaertner at gmx.net
Thu Apr 1 14:47:28 UTC 2004


"Frank Shearar" <frank.shearar at rnid.org.uk> wrote:

When I posted an answer to Alexanders bug report, I got newest
mails and saw that you posted exactly the fix that I posted, too.


<snip>
> Update 5844 (5844ANSICompatibility) introduces support for reading in
float
> literals. These take the form <mantissa><exponentLetter><exponent>.
> exponentLetter can be $e, $d or $q.
>
> Therefore, when you view Preference's class comment RunArray>>scanFrom:
gets
> given '(220 29 81 35 812)f1,f1dPreferences
> openFactoredPanel;;,f1,f1dPreferences giveHelpWithPreferences;;,f1'.
>
> The substring 'f1dPreferences' thus gets interpreted as a float literal
and
> Number class tries to interpret the substring 'Preferences' as a sequence
of
> digits.
</snip>

<snip>
> I suppose the solution is to change RunArray>>scanFrom: to
> Integer>>readFrom? Otherwise we'd have to not use $d in RunArray, which
> means we'd have to change the .changes file, wouldn't we?
>
> I've attached a changeset which alters RunArray>>scanFrom: to use
> Integer>>readFrom: instead of Number>>readFrom:. The three RunArray
thingies
> that the changeset affects are TextDoIt ($d), TextAlignment ($a) and
> TextFontReference ($F).
>
> The changeset does require someone more knowledgeable than I to review
it -
> I know next to nothing about how RunArray works.
</snip>

I agree both with your fix and with your explanation to your fix.
I revoke my fix and review yours.

Greetings, Boris




More information about the Squeak-dev mailing list