<br><br><div class="gmail_quote">On Wed, Jan 28, 2009 at 2:03 PM, John M McIntosh <span dir="ltr"><<a href="mailto:johnmci@smalltalkconsulting.com">johnmci@smalltalkconsulting.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
That was the original Squeak code to deal with the interrupt key.<br>
<br>
I you pressed the interrupt key, then the VM would see that and set the interruptPending flag which later in checkForInterrrupts would grab the TheInterruptSemaphore<br>
which was a semaphore that the Smalltalk interrupt handler was waiting on to let the image know the interrupt key was pressed<br>
<br>
Obviously there was a problem in determining what an interrupt key was across all platforms, and what if you wanted to changed it?<br>
That led to the code being moved out of the VM into EventSensor>>processEvent: -> "Check if the event is a user interrupt"<br>
were we look for the magic keystrokes versus doing that in the VM.<br>
<br>
However the TheInterruptSemaphore logic in the VM still exists to handle images from before the EventSensor work, and is set via InputSensor>>installInterruptWatcher<br>
EventSensor>>primInterruptSemaphore: records the semaphore so it can use it directly.<br>
<br>
<br>
In *theory* *cough* you should be able to take a current mac vm and open a squeak image from 1995, if any one cares to try, please let me know if it works.</blockquote><div><br></div><div>It certainly _won't_ work unless TheInterruptSemaphore is defined as the correct index in the specialObjectsArray, which is what I'm asking for. Right now TheInterruptSemaphore is defined as null:</div>
<div><br></div><div><span class="Apple-style-span" style="font-family: 'courier new', monospace;">#define TheInterruptSemaphore null</span></div><div><br></div><div>so if one opens up the 1995 image and it tries to set the input semaphore it'll simply overwrite nil, which won't make the system very happy. So once again,</div>
<div><br></div><div>anyone know what the correct value for TheInputSemaphore should be in a circa 1995 VM/image?</div><div><br></div><div>TIA</div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div><div></div><div class="Wj3C7c"><br>
<br>
<br>
On 28-Jan-09, at 1:22 PM, Eliot Miranda wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi All,<br>
<br>
just noptied that in our current VM there's an undefined constant TheInputSemaphore. This is (or rather isn't) used in Interpreter>>primitiveInputSemaphore. I can find no clue in my current images as to what its correct old value. Anyone have the old value (in the Interpreter and/or in Smalltalk>>specialObjectsArray)? TIA<br>
<br>
Eliot<br>
<br>
</blockquote>
<br></div></div><font color="#888888">
--<br>
===========================================================================<br>
John M. McIntosh <<a href="mailto:johnmci@smalltalkconsulting.com" target="_blank">johnmci@smalltalkconsulting.com</a>><br>
Corporate Smalltalk Consulting Ltd. <a href="http://www.smalltalkconsulting.com" target="_blank">http://www.smalltalkconsulting.com</a><br>
===========================================================================<br>
<br>
<br>
<br>
<br>
</font></blockquote></div><br>