On 10 déc. 07, at 11:19, Toon Verwaest wrote:
Stéphane Ducasse wrote:
I shoud say that I do not really understand the
goal of what you are
doing.
Using Famix for code generation? representing parser results?
I have the impression that when you have a boolean and the parser
give you nil
then you know that this is not the value but unknown.
May be this is what you do not like doru (I got confused).
But the isKnown was the solution to this problem at that ancient
time :)
Stef
Mmmmh... I can't say that I really like the "isKnown" solution.
without a metamodel it was good enough.
The idea of our talk (at least my side) is that if
default values -
are-
primitive values; we might as well include them in the FAMIX.fm3.mse
specification.
But how can you make sure that these default values are the same in
all the languages.
Is it the importer that will do the mapping?
I did that in CDIF converting idiot -TRUE- into true and this is
boring and slowing everything.
So mse will be slower or mse will favor a language (if this is
Smalltalk this is ok too).
now if the default value is a boolean, will I get true or nil if in
the model it was not set?
This would allow code generation in different
platforms
to actually write the correct initialization for those values.
I know I did that in 2000 for the DomainGenerator we never used.
But this was fun to do that just to learn that old MOF way of
representing relationship was crap
and created overly complex queries for code generation.
And then famix-files would be allowed to omit values
which are the
default ones.
As we saw for famix specified in fm3 where we specified default values
(Adrian got a bit mixed up and reused these default values also for
other metamodels); this shortens the length of some files quite a lot.
(and reduces the time needed for parsing and initializing
obviously...)
Toon
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev