[Cuis-dev] I think i found a bug in the debugger

Hernan Wilkinson hernan.wilkinson at 10pines.com
Sat Aug 7 04:35:53 PDT 2021


Hi Nicola,
 I'm sorry! I misunderstood your email! I read the subject with the word
"bug" and then went directly to the image you pasted and I thought "it is
not a bug, it is how it is intended to work" :-)
 I agree that on this example, it would be better to see 'nil' than just
nil because it is confusing but for sure there is a reason not to do it
that way... I mean, Smalltalk is a mature system and for sure there is a
reason for showing strings that way, sadly I do not know/recall that reason.
 Anyway, it is not a bug. It would be interesting to see the behavior of
the change Gerald suggested... maybe the reason for that "if" was only
"performance" (why create a new string if we already have one) and if so,
changing that behaviour would be an improvement from the UI point of view
as you suggested.

 Cheers!
 Hernan

On Sat, Aug 7, 2021 at 5:01 AM Nicola Mingotti <nmingotti at gmail.com> wrote:

>
> Hi Hernan,
>
> Speaking of representation if easy to slip talking into aesthetic
> preferences, which is not my aim. ;)
>
> That representation made me mistake, I thought a bit about it, and here is
> what i
> guess is the explanation.
>
> ----- Workspace "Print It" interactions --------------
> nil.     "=>  nil "
> 123.   "=>  123 "
> '123'. "=>  '123' "
> 'nil'.   "=>  'nil' "
> ----------------------------------------------------
>
> This is what I expect to see also in the debugger, the programmer view of
> the object.
> Instead I see kind of a simplified 'user' view, something that can in ok
> in Transcript for example.
> But not in the debugger, where it is fundamental to distinguish 123 from
> '123' and nil from 'nil'.
>
> Bye
> Nicola
>
>
>
>
>
>
>
>
> On 8/6/21 7:56 PM, Hernan Wilkinson wrote:
>
> Hi Nicola,
>  I do not see a problem... the debugger is showing the string nil and the
> inspector too. aStringRep is referencing a string, that string is 'nil' ...
>
> On Fri, Aug 6, 2021 at 1:14 PM Nicola Mingotti via Cuis-dev <
> cuis-dev at lists.cuis.st> wrote:
>
>>
>> Hi guys,
>>
>> I hit a stupid bug today ... to find it was nasty, i think because
>> the debugger does not show what (at least I) would expect.
>>
>> Please see the attached picture here:
>> https://pasteboard.co/KeEwgAy.png
>>
>> If you look at the debugger bottom right pane you think
>> that 'aStringRepr' is nil, right? Well, it is not so,
>> If you inspect it, see inspector in the middle of the screen,
>> you see it actually is 'nil', that is a String containing a 3 letter
>> value.
>>
>> This happens also for numbers, if they are inside Strings the debugger
>> does not show eg: '123', but 123. That is some kind of "print
>> representation".
>>
>> I think this is very much undesirable and an unexpected behavior,
>> at least for a beginner;)
>>
>> bye
>> Nicola
>>
>>
>>
>> --
>> Cuis-dev mailing list
>> Cuis-dev at lists.cuis.st
>> https://lists.cuis.st/mailman/listinfo/cuis-dev
>>
>
>
> --
> <https://10pines.com/> Hernán Wilkinson Software Developer, Teacher &
> Coach
>
> Alem 896, Floor 6, Buenos Aires, Argentina
>
> +54 11 6091 3125
>
> @HernanWilkinson
>
>
>

-- 
<https://10pines.com/>Hernán WilkinsonSoftware Developer, Teacher & Coach

Alem 896, Floor 6, Buenos Aires, Argentina

+54 11 6091 3125

@HernanWilkinson
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20210807/55dc033f/attachment.htm>


More information about the Cuis-dev mailing list