| Register | FAQ | Calendar | Search | Today's Posts | Mark Forums Read |
|
#1
| |||
| |||
| but once the sample2 code is compiled, i believe that there shud be no difference in execution speed. does not the bytecode perform the necessary adjustments ?? |
|
#2
| |||
| |||
| codism wrote: > but once the sample2 code is compiled, i believe that there shud be no difference in execution speed. does not the bytecode perform the necessary adjustments ?? Pretty much, or if there is a difference it is very tiny and would not really compensate for hard to read and maintain code. The following does not really apply to the example you provided, but using <cfoutput>...</cfoutput> block somewhat like your second example can be explained as a form of whitespace management. If one uses the <cfsetting enableCFoutputOnly="true"> tag, then only content inside of <cfoutput>...</cfoutput> blocks will be sent in the response. This can be used to control whitespace something like this. <cfsetting enableCFoutputOnly="true"> <!--- A bunch of cf processing ---> <cfloop this...> <cfloop that...> <cfquery something ...> <!---output the results---> <cfouput>What needs to be seen</cfouput> <!---More cf processing ---> <cfset something equals somethingElse> <cfif this or that> <cfswitch experssion="#justForFun#"> <!---again output the results---> <cfoutput>Only this will be seen</cfoutput> |
![]() |
| Thread Tools | |
| Display Modes | |
In an effort to better serve ads to our visitors, cookies are used on objectmix.com. For more information, check out our Privacy Policy.