Op Sat, 18 Apr 2009 12:25:55 +0200 schreef Danny Wilson
<blueze...@gmail.com>:
Op Fri, 17 Apr 2009 22:31:04 +0200 schreef Nick Sabalausky <a...@a.a>:
so far, opDotExp's benefits are trivial at best. I don't want to have to
keep track of "ok, is this class using opDotExp or not, because if it
is,
then I need to be more careful", just for the sake of a feature that
provides such a tiny and questionable benefit.
So what exactly are you afraid of?!
What I was really trying to say is: sure you have to keep track of which
class uses opDotExp but you won't be thinking about it.
You'll be thinking "How do I access this json 'object'?" and then remember
you can just access it. With quoted identifiers you'll think exactly the
same: "How do i access?" use: ["object"].
In both cases you'll get a runtime exception of some sort and have to take
a look at the code if you made typos.
HaXe (and Actionscript a little) are great examples of
statically-dynamically-typed languages :-) I use static typing pretty
much all the time. Just in a few cases I use Dynamic (or this opDotExp
like thing) and then I'll know where to look for simple errors like typos.
Null pointers are a far more common bug for me but that's beside the point.