Status/Resolution/Reason: To Fix//EnhancementRequired
Reporter/Name(from Bugbase): Adam Cameron / Adam Cameron ()
Created: 10/11/2017
Components: Language
Versions: 2016
Failure Type: Enhancement Request
Found In Build/Fixed In Build: 2016 /
Priority/Frequency: Normal / Very few users will encounter
Locale/System: / Platforms All
Vote Count: 2
This should work
{code:java}
<cfscript>
myFunction = evaluate("function(){}");
writeDump(variables);
</cfscript>
{code}
it doesn't:
Invalid CFML construct found on line 1 at column 11.
ColdFusion was looking at the following text:
{
The error occurred in C:/apps/adobe/ColdFusion/2016/express/cfusion/wwwroot/CF2018/src/misc/evaluateFunctionExpressionRepro.cfm: line 2
1 : <cfscript>
2 : myFunction = evaluate("function(){}");
3 : writeDump(variables);
4 : </cfscript>
It's a contrived repro case of a more complex situation wherein it was legit to be evaluating the function expression as it had dynamic code in it (don't ask... I'm under NDA so I can't say anyhow ;-)
Attachments:
Comments: