This one was met with a round of applause last night in Dallas. In Scorpio you can now use the following in CFML expressions:
++ -- % += -= *= /= %= && || !
In addition, in
== != >=
This one was met with a round of applause last night in Dallas. In Scorpio you can now use the following in CFML expressions:
++ -- % += -= *= /= %= && || !
In addition, in
== != >=
I may have clapped the loudest for this, lol. Love the idea, finally a ++, and a % for CF!
And bravo for figuring out the validation nightmare that must have been "if(a<b) || (a>c)". It sure looks like it should validate as a tag, but grats for figuring it out and including it! Well done!
Do we call it CF++ now? 🙂
Yay, finally! Good one 🙂
Ben, say are there by any chance plans to give developers the oppertunity to write cfc’s *completely* on a script basis, too? Like defining a component with a class (~component) keyword rather than using the tag syntay? Also, will there be mechanisms like interfaces or abstract classes in CF++? 😉
Cheers, Thomas
Give them an inch and they want a mile. 😉
Thomas, interfaces are in Scorpio, but no plans for for class creation in script. And, without starting a big debate on the subject, I would be very opposed to this idea myself. If you want components defined as classes, well, use Java, it does it really well. But, ya never know.
— Ben
Great to have you in DFW! A question came to mind about the CFIMAGE tag. Currently we have an image server which we use some of the same functionality you talked about with CFIMAGE. Will there be any caching available of images (or is that me just dreaming to big)? Can you manipulate the DPI? We keep hi-res JPEGs (300 dpi) for print and then our image server renders them as 72 dpi for display.
I am so very, very excited and can’t wait for the release of CF8. Thanks for your wonderful presentation last night!
That is awesome, I’m very excited about the new operators. I have a question though. I’ve been told IIF is very slow. Is the following going to work?
a = (b == true) ? c : d;
Ben said:
Give them an inch and they want a mile.
True Ben, but please realize that we’re REALLY grateful for the inch! 🙂
Steven
Steven said:
True Ben, but please realize that we’re REALLY grateful for the inch! 🙂
hell, we are 😀
Cheers, Thomas
#ERROR!
that’s pretty cool!
This is AWESOME!!! It is so irritating not having the incremental operators. That will be awesome. It only makes sense, getting closer to ECMAScript.
Now, to go for the mile.. 😉 I agree with Kevin that it would be awesome to have support for ? as in:
a = (b == true) ? c : d;
IIF() was slower than CFIF in earlier versions of ColdFusion but in MX they compile down to the exact same code.
a = (b == true) ? c : d; is called a ternary operator. 😉
pretty awesome Ben!
I hate doing
<cfset foo = foo + 1>
Now I can do
<cfset foo++>
Now if you can add a &= operator.
<cfset foo = foo & "some string">
becomes
<cfset foo &= "some string">
Rick,
I’m willing to be that with CF being dynamic and all that this will work for you:
<cfset foo += "some string" />
Finnnnnnnnnnnally! This is a feature that has been missing for a long time. 😉
Rick,
Not sure why, it’s not in the list.
But, you can do &= for string concatination.
(The tour just came through PDX on Monday).
Awsome stuff.
I’m excited to be a CF developer.
>> Can you manipulate the DPI? We keep hi-res JPEGs (300 dpi)
>>for print and then our image server renders them as 72 dpi for display.
Kevin, no, this is not supported at this time.
— Ben
One thing I’ve missed is the ability to effectively loop a query in script. Something like this would be awesome:
forin(query||struct[,item]){}
sooo! wicked! definitely past due
Leave a Reply