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
Hi,
The main use case in Magritte for the nil initial value is that you
want to distinguish between something that is specifically set and
something that is not. The same use case we would have for
distinguishing between the case when a parser could not say about a
class that it isAbstract and another case when it could say that it is
not.
The other use case is when we could not compute some metric for some
reason.
I think, these are good use cases.
On the other hand, I do not like that a Boolean can have 3 values
because this hinders later on the queries and proliferates guard
conditions (which is a pain). So, if we take this road, then I would
like to have an ExtendedBoolean and an ExtendedNumber that deal with
the special cases.
But, somehow I would rather go for the simplest case when we do not
allow such undecided values, because this puts more pressure on the
parsers to produce better results.
Doru
On Dec 8, 2007, at 5:03 PM, Lukas Renggli wrote:
Currently
FM3 does not allow other default, question is if we really
need that, as we have no usecase yet. @Lukas, how is it in Magritte?
In Magritte default values are nil by default, also for numbers and
booleans. Attributes can have a different default value. As Toon
explained I have examples where the default value for a boolean is
true or the one for a number is 17 ;-)
Cheers,
Lukas
--
Lukas Renggli
http://www.lukas-renggli.ch
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
--
www.tudorgirba.com
www.tudorgirba.com/blog
"It's not what we do that matters most, it's how we do it."
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev