Is it merely a stylistic difference between
cfset myvar = What do you think of #this#? /
and
cfset myvar = What do you think of this ? /
Or is there a speed advantage to the latter which cancels out any increased
readability in the former?
Thanks!
Is it merely a stylistic difference between
cfset myvar = What do you think of #this#? /
and
cfset myvar = What do you think of this ? /
Or is there a speed advantage to the latter which cancels out any
increased readability in the former?
The former would be faster in some situations
www.coldfusionmuse.com
www.necfug.com
-Original Message-
From: Shannon Rhodes [mailto:shan...@rhodesedge.com]
Sent: Monday, January 03, 2011 8:10 AM
To: cf-talk
Subject: Concantenate vs Pound Signs within Quotes
Is it merely a stylistic difference between
cfset myvar = What do you think
Is it merely a stylistic difference between
cfset myvar = What do you think of #this#? /
and
cfset myvar = What do you think of this ? /
Or is there a speed advantage to the latter which cancels out any
increased readability in the former?
The former would be faster in some
: Concantenate vs Pound Signs within Quotes
Is it merely a stylistic difference between
cfset myvar = What do you think of #this#? /
and
cfset myvar = What do you think of this ? /
Or is there a speed advantage to the latter which cancels out any increased
readability in the former?
Thanks
Marginally valid test for giggles...(on CF8)...
cfset myvar = arrayNew(1)
cfset starttick = getTickCount()
cfloop index=i from=1 to=100
cfset myvar[i] = What do you think of #i#? /
/cfloop
cfoutput#Evaluate(getTickCount() - starttick)#/cfoutput
...produced 1119.
cfset myvar = arrayNew(1)
Thanks guys, that's about what I expected. As a stylistic difference, I would
not advocate changing existing code to eliminate pound signs, whereas there are
those who argue the speed advantage of moving to concantenation only. While I
like concantenation, I see no problem with choosing ease
I try to use pound signs as little as possible. It's a bit of a hang over
from the old cf4.x days but I personally find it a) easier to read and b)
more akin to other languages.
On Mon, Jan 3, 2011 at 9:27 AM, Shannon Rhodes shan...@rhodesedge.comwrote:
Thanks guys, that's about what I
8 matches
Mail list logo