<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
<meta name="Generator" content="Microsoft Exchange Server">
<!-- converted from text --><style><!-- .EmailQuote { margin-left: 1pt; padding-left: 4pt; border-left: #800000 2px solid; } --></style>
</head>
<body>
<meta content="text/html; charset=UTF-8">
<style type="text/css" style="">
<!--
p
        {margin-top:0;
        margin-bottom:0}
-->
</style>
<div dir="ltr">
<div id="x_divtagdefaultwrapper" dir="ltr" style="font-size:12pt; color:#000000; font-family:Calibri,Helvetica,sans-serif">
<p>Hi Tobias,</p>
<p><br>
</p>
<p>> <span style="font-size:12pt">true false nil are special. :)</span></p>
<div>> The ObjectTracer on whatever cannot be ever true.</div>
<div><br>
</div>
<div>I know they don't work like usual objects because many boolean/nil selectors are inlined ATM.</div>
<div>However, this only affects specific selectors.</div>
<div>The following worked - if ObjectTracer would not cause a recursion:</div>
<div><span>(ObjectTracer on: true) xor: (ObjectTracer on: false)</span><br>
</div>
<div><span><br>
</span></div>
<div><span>IMHO, everything in Smalltalk should be an object and should also behave like an object, especially in terms of message dispatching. Is there any other reason to deviate from these rules besides performance?</span></div>
<div><span><br>
</span></div>
<div><span>Best,</span></div>
<div><span>Christoph</span></div>
<div><span><br>
</span></div>
<div><span>PS: You cannot suppress the debuggers spawn by an ObjectTracer ... Should we maybe use some kind of notification for this? IWLT do the following:</span></div>
<div><span>[<span style="font-family:Calibri,Helvetica,sans-serif,EmojiFont,"Apple Color Emoji","Segoe UI Emoji",NotoColorEmoji,"Segoe UI Symbol","Android Emoji",EmojiSymbols; font-size:16px">(ObjectTracer on: true) xor: (ObjectTracer on: false)] on: WarningOrSo
 do: #resume.</span></span></div>
<p></p>
<div id="x_Signature">
<div id="x_divtagdefaultwrapper" dir="ltr" style="font-size:12pt; color:rgb(0,0,0); font-family:Calibri,Helvetica,sans-serif,EmojiFont,"Apple Color Emoji","Segoe UI Emoji",NotoColorEmoji,"Segoe UI Symbol","Android Emoji",EmojiSymbols">
<div name="x_divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<div><font size="2" color="#808080"></font></div>
</div>
</div>
</div>
</div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="x_divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>Von:</b> Squeak-dev <squeak-dev-bounces@lists.squeakfoundation.org> im Auftrag von Tobias Pape <Das.Linux@gmx.de><br>
<b>Gesendet:</b> Mittwoch, 25. März 2020 21:57:43<br>
<b>An:</b> The general-purpose Squeak developers list<br>
<b>Betreff:</b> Re: [squeak-dev] [Simulation errors] ObjectTracer on: true</font>
<div> </div>
</div>
</div>
<font size="2"><span style="font-size:10pt;">
<div class="PlainText"><br>
> On 25.03.2020, at 21:35, Thiede, Christoph <Christoph.Thiede@student.hpi.uni-potsdam.de> wrote:<br>
> <br>
> Hi all!<br>
> <br>
> I rarely discovered that much errors with one single command :-)<br>
> <br>
> Steps to reproduce<br>
> <br>
> Print it:<br>
> <br>
> (ObjectTracer on: true) ifTrue: [1]<br>
> Expected behavior<br>
> <br>
> It is printed: 1<br>
> <br>
<br>
No :D<br>
true false nil are special. :)<br>
The ObjectTracer on whatever cannot be ever true.<br>
<br>
-t<br>
<br>
> Actual behavior<br>
> <br>
> The following tracer notifications appear (proceed them all):<br>
> <br>
>        • (3x) #printStringLimitedTo:, #longPrintOn:limitedTo:indent: and again #printStringLimitedTo:, caused by SmalltalkImage >> #logSqueakError:inContext:<br>
>        • #mustBeBoolean<br>
>        • (3 more print message called by #logSqueakError:inContext: again, see the next error)<br>
>        • Error: Where's the jump?<br>
> Caused by #mustBeBooleanIn:, #skipBackBeforeJump<br>
> If you still keep proceeding:<br>
> <br>
>        • (3 more print message called by #logSqueakError:inContext: again, see the next error)<br>
>        • Finally, the NonBooleanReceiver error from 2.<br>
>        • VM crashes.<br>
> Summarizing the bugs<br>
> <br>
> ObjectTracer traces too much<br>
> <br>
> The amount of messages printed by the ObjectTracer is an unintended side effect of the way it signals calls via the debugger. The debugger logs this error, including the stack trace. How can we avoid this? Should we suppress all further notifications from
 one ObjectTracer instance during the first one is debugged?<br>
> <br>
> #mustBeBoolean is sent to boolean proxy<br>
> <br>
> This is caused by the simulation of the inlined #ifTrue: call.<br>
> I don't know whether this is worth to be fixed before Scorch?<br>
> If yes, I think we would need to disable inlining for this particular selector or make inlining opt-out-able as proposed here (this would probably be way too slow).<br>
> <br>
> #mustBoBoolean depends on caller chain<br>
> <br>
> It turns out that #mustBeBoolean relies on being called from a context that just did a jump. This makes it impossible to forward this message as usual via a transparent proxy/decorator.<br>
> <br>
> We use this pattern in other methods as well. How can we enable transparent wrappers not to collide with method contexts depending on their sender?<br>
> <br>
> Best,<br>
> Christoph<br>
<br>
<br>
<br>
</div>
</span></font>
</body>
</html>