Progress changes break VMMaker

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Progress changes break VMMaker

Eliot Miranda-2
Hi All,  Hi Chris,

    something in the changes to ProcessInitiationException done in ToolBuilder-Kernel-cmm.48/49/52 breaks the VMMaker.  i.e. the following prints nil 5 times to the Transcript instead of printing #caught 5 times.

['Progressing' displayProgressFrom: 1 to: 5 during:
[:bar|
1 to: 5 do:
[:i|
Transcript cr; print: (Notification new tag: #getVMMaker; signal); flush.
bar value: i]]]
on: Notification
do:[:ex|
ex tag == #getVMMaker
ifTrue: [ex resume: #caught]
ifFalse: [ex pass]]

Any help in fixing this appreciated!

Interestingly in the following count is 1

| count |
count := 0.
['Progressing' displayProgressFrom: 1 to: 5 during:
[:bar|
1 to: 5 do:
[:i|
Transcript cr; print: (Notification new tag: #getVMMaker; signal); flush.
bar value: i]]]
on: Notification
do:[:ex|
count := count + 1.
ex tag == #getVMMaker
ifTrue: [ex resume: #caught]
ifFalse: [ex pass]].
count 1

--
best,
Eliot



Reply | Threaded
Open this post in threaded view
|

Re: [Vm-dev] Progress changes break VMMaker

Eliot Miranda-2


On Sat, Jun 23, 2012 at 10:13 AM, Balázs Kósi <[hidden email]> wrote:

I poked around a bit more, and found a method to handle these kind of
situations: #rearmHandlerDuring:
You could rewrite the exception handling block to something like this:

[ :ex |
  ex tag == #getVMMaker
     ifTrue: [ ex resume: #caught ]
     ifFalse: [ ex rearmHandlerDuring: [ ex pass ] ] ]

and get five #cought on the Transcript

So is this a hack that points to a bug in the exception handling system or what?  I don't have time to think about this carefully right now, but it looks like this is covering up a serious bug in the exception system.  Thoughts? 



--
best,
Eliot