Il 01/11/2012 21:54, Rick Flower ha scritto:
> On 01.11.2012 09:42, Rick Flower wrote:
> 
>> Ok.. So I've got 3.2.4 install but I also saw this issue with 3.2 as
>> well..
>>
>> I have defined an exception class as follows :
>>
>> Error subclass: MissingRequiredXMLDescriptorFile [
>> MissingRequiredXMLDescriptorFile class >> signal: aMessage [
>> ^self new signal: aMessage
>> ]
>> ]
>>
>> I then have some code elsewhere that throws the exception :
>>
>> areXMLDescriptionFilesPresent [
>> MissingRequiredXMLDescriptorFile signal: 'Foo!!!'
>> ]
>>
>> and try to catch it with the following :
>>
>> [ sdf areXMLDescriptionFilesPresent ]
>> on: MissingRequiredXMLDescriptorFile
>> do: [:ex | Transcript show: ex messageText. ObjectMemory quit: 1].
> 
> Fixed my problem!! I changed the above code snippet to :
> 
> [ sdf areXMLDescriptionFilesPresent ]
> on: Error
> do: [:ex | Transcript show: ex messageText. ObjectMemory quit: 1].
> 
> Now it works as expected!!  I guess it wanted to see the more generic
> base class Error as being caught instead of my nicely named derived
> class..

It seems that the MissingRequiredXMLDescriptorFile exception is not
visible where you're trying to catch it.

Perhaps it's in a different namespace?

Paolo

> Consider this issue closed and I'm good for now -- although I suspect
> my Solaris build issues may need addressing at some point for those of
> us using older build systems (gcc versions below 4.2).


_______________________________________________
help-smalltalk mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/help-smalltalk

Reply via email to