[haXe] Request: ? : operators

Ralf Bokelberg ralf.bokelberg at gmail.com
Sat Dec 16 08:51:54 CET 2006


The question is: Why has this wheel been invented in the first place
when you already have a perfectly good one ;) ("if" that is)
Btw. its not just "if", other statements, like "switch" can be used as
an expression too.
Cheers,
Ralf

On 12/16/06, Jim Kremens <kremens at gmail.com> wrote:
> But I guess I'm with Sebastian... if it doesn't do anyything new, why
> not use the really standard thing?  Ternary conditionals have been
> around for a long time...  In other words, why reinvent a perfectly
> good wheel?
>
> If it does in fact add functionality, then please chime in...
>
> Thanks,
>
> Jim Kremens
>
> On 12/15/06, Aaron Gray <ang.haxe at googlemail.com> wrote:
> > Like it nice one :)
> >
> > Thanks, not quite as neat as ?: but the same syntax and semantics anyway.
> >
> > Aaron
> >
> > On 12/15/06, Danny Wilson <danny at decube.net> wrote:
> > > Hey,
> > >
> > > If you've read the language reference, you would know haXe has a more
> > > powerfull if statement, that can be used the same way.
> > >
> > > Quote: "var y : Int = if( flag ) 1 else 2;"
> > >
> > > On Fri, 2006-12-15 at 20:30 +0000, Aaron Gray wrote:
> > > > Hi,
> > > >
> > > > Heres a request for C like ? and : operators as they can reduce code
> > > > down from multiple if..else statement down to a single line of code.
> > > >
> > > > Aaron
> > > >
> > > > --
> > > > haXe - an open source web programming language
> > > > http://haxe.org
> > >
> > >
> > > --
> > > haXe - an open source web programming language
> > > http://haxe.org
> > >
> >
> >
> > --
> > haXe - an open source web programming language
> > http://haxe.org
> >
> >
>
>
> --
> Jim Kremens
>
> --
> haXe - an open source web programming language
> http://haxe.org
>


-- 
Ralf Bokelberg <ralf.bokelberg at gmail.com>
Flex & Flash Consultant based in Cologne/Germany



More information about the Haxe mailing list