AnUnknownClass subclass: #Adaptor1Example
instanceVariableNames: 'customers accountID address name phoneNumber'
classVariableNames: ''
poolDictionaries: ''
category: 'Examples-Cookbook'
executes the default action for OCUndeclaredVariableWarning, which is
On 04 Dec 2013, at 20:02, Stéphane Ducasse stephane.duca...@inria.fr wrote:
AnUnknownClass subclass: #Adaptor1Example
instanceVariableNames: 'customers accountID address name phoneNumber'
classVariableNames: ''
poolDictionaries: ''
category:
As a clear example, this is just bad that each time we want to change the UI
message we have to change the compiler exception.
ugly at wish.
I have no cycle to fix that now. I will check if I can get something in
UndefinedObject so that I can continue to work on my task.
The whole
On 04 Dec 2013, at 20:34, Stéphane Ducasse stephane.duca...@inria.fr wrote:
As a clear example, this is just bad that each time we want to change the
UI message we have to change the compiler exception.
ugly at wish.
I have no cycle to fix that now. I will check if I can get something
Ok I will check something on UndefinedObject to start with.
Then it would be fun to prototype a kind of strategy hiearchy on the side
(extracted from also) behavior of OCSemanticsError
It was nice to see it and since now I'm ok to have a look at the compiler
code it was interesting.
Steph, each time you want to evaluate something, do you agree that this
involves
- a parse phase of the expression you want to evaluate to create an AST
- a code generation phase from AST - bytecodes to generate a CompiledMethod
- the evaluation phase itself which evaluates above CompiledMethod
I forgot to add that the OCUndeclaredVariableWarning was already handled at
semantic analysis.
Do you suggest that default behavior should be to handle and retry instead
of handle and return?
One way to achieve what you are asking would be to initialize the
Undeclared entry to some kind of
2013/12/4 Nicolas Cellier nicolas.cellier.aka.n...@gmail.com
I forgot to add that the OCUndeclaredVariableWarning was already handled
at semantic analysis.
This is not the case. The OCUndeclaredVariableWarning is handled in the
default action. Therefore anyone can catch it.
In this case for
On Dec 4, 2013, at 10:02 PM, Clément Bera bera.clem...@gmail.com wrote:
It didn't halt on your machine because you didn't copy and paste the code
that halts (i guess I wrote too much code in the mail so it was not clear).
You copied the code that I explicitly said that doesn't halt because
Hi nicolas
I forgot to add that the OCUndeclaredVariableWarning was already handled at
semantic analysis.
Do you suggest that default behavior should be to handle and retry instead of
handle and return?
I suggest that we can define what is the behavior of handling an exceptional
cases.
Well if the class does not exists it calls the method on UndefinedObject
(UndeclaredBinding). And you have:
UndefinedObjectsubclass: nameOfClass
instanceVariableNames: instVarNames
classVariableNames: classVarNames
poolDictionaries: poolDictnames
category: category
Calling this method is now
Then for your project replace ProtoObject by StubRootClass in
UndefinedObjectsubclass:instanceVariableNames:classVariableNames:
poolDictionaries:category: it will work.
An alternative is to catch OCSemanticWarning or its subclass
OCUndeclaredVariableWarning while loading the new classes and
On Dec 3, 2013, at 11:20 AM, Clément Bera bera.clem...@gmail.com wrote:
Then for your project replace ProtoObject by StubRootClass in
UndefinedObjectsubclass:instanceVariableNames:classVariableNames:poolDictionaries:category:
it will work.
yes but this is ugly because I do not want
*do you know if the OCUndeclaredVariable is raised for unknown superclass?*
this code:
AnUnknownClass subclass: #Adaptor1Example
instanceVariableNames: 'customers accountID address name
phoneNumber'
classVariableNames: ''
poolDictionaries: ''
category:
thanks for your analysis I will have a look at it.
I was thinking to check if I should redefine UndefinedObjectsubclass:
to raise an error
Stef
On Dec 3, 2013, at 3:17 PM, Clément Bera bera.clem...@gmail.com wrote:
do you know if the OCUndeclaredVariable is raised for unknown superclass?
Hi
when I load a class whose superclass is not in the image I have the impression
that the system create a subclass from ProtoObject
and I would like to be able to control the superclass.
ProtoObject subclass: #Adaptor1Example
instanceVariableNames: 'customers accountID address name
16 matches
Mail list logo