Debugger highlighting bug

William O. Dargel wDargel at shoshana.com
Thu Apr 16 00:27:09 UTC 1998


I noticed that the debugger's highlight of the current message is a bit
off when the message argument is a literal string. This can be seen by
executing:
    self halt: 'test'
going into the debugger and selecting UndefinedObject>>DoIt. The
highlight will cover "halt: 'tes" but not the final "t'".

I've been using the FileContentsBrowser (thanks Andreas!) to check out
some downloads that I grabbed from somewhere last December. I found the
following changes that sure seem to fix the problem. They were in a
Delta Debug 2 file and also a much larger set of changes in FastDebug
that look like they were going to make the Debugger run faster. I guess
this particular bug fix was never advertised separately from the rest of
that project, and so hasn't made it into the core image yet. BTW, anyone
know who "SN" is?

Anyway, they fixes are:

'From Squeak 1.31 of Feb 4, 1998 on 15 April 1998 at 6:26:23 pm'!

!Parser methodsFor: 'scanning' stamp: 'sn 9/19/97 19:32'!
advance

    | this |
    prevMark _ hereMark.
    prevToken _ "Now means prev size"
        self previousTokenSize.
    this _ here.
    here _ token.
    hereType _ tokenType.
    hereMark _ mark.
    self scanToken.
    ^this! !

!Parser methodsFor: 'private' stamp: 'sn 9/19/97 19:31'!
previousTokenSize
    "Answer the size of the previous token. Bugfix for Strings."

    hereType == #number ifTrue: [^mark - prevMark].
    hereType == #string ifTrue: [^here size + 2].    "One for each
single quote"
    ^here size! !

-------------------------------------------
Bill Dargel            wdargel at shoshana.com
Shoshana Technologies
100 West Joy Road, Ann Arbor, MI 48105  USA





More information about the Squeak-dev mailing list