In general (but it often does not work :)) having a lot of conditions in OOP
means that you are missing class to dispatch on then.
> But then which is the equivalence to #and:and:and: when I have many
> conditions?
a and: [b] and: [c]
if a and c do not have side effect that may change the condition are equivalent
to
a and: [ b and: [c]]
so you have express what you want
> Perhaps I will say a stupidity... but , not is valid the implementation of
> #&& and #|| messages instead of #and:... #or: .....?
& and | are executing all their arguments while
true & error -> error
true and: [error] -> true but it is more costly
>
> ( aCondition1 && aCondition2 && aCondition3 ) ifTrue: [ <something> ]
>
>
> Regards
> --
> View this message in context:
> http://forum.world.st/and-and-and-deprecated-on-1-1-why-tp2230786p2231486.html
> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>
> _______________________________________________
> Pharo-project mailing list
> [email protected]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
_______________________________________________
Pharo-project mailing list
[email protected]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project