tracker issue : CF-3346435

select a category, or use search below
(searches all categories and all time range)
Title:

Anonymous function blocks

| View in Tracker

Status/Resolution/Reason: Closed/Fixed/Fixed

Reporter/Name(from Bugbase): Adam Cameron / Adam Cameron (Adam Cameron)

Created: 10/15/2012

Components: Language

Versions: 10.0

Failure Type: Enhancement Request

Found In Build/Fixed In Build: Final / latest build

Priority/Frequency: Trivial / Unknown

Locale/System: English / Platforms All

Vote Count: 10

G'day
It'd be good of CF could have anonymous function blocks as per Javascript, eg:

{code:java}
(
    function(message){
        var uppered = message.toUpperCase();
        document.write("Inside: "+ uppered + "<br />");
    }
)("Hello World");
{code}


See blog article for more discussion: http://adamcameroncoldfusion.blogspot.co.uk/2012/09/callbacks-function-expressions.html

Cheers.

-- 
Adam

----------------------------- Additional Watson Details -----------------------------

Watson Bug ID:	3346435

External Customer Info:
External Company:  
External Customer Name: Adam Cameron.
External Customer Email:  
External Test Config: My Hardware and Environment details:

Attachments:

Comments:

will be considered for the next release.
Comment by Rupesh K.
17553 | September 06, 2013 02:46:10 AM GMT
Please explain in 25 characters or more how this feature impacts productivity and why you are adding a vote.
Vote by External U.
17559 | September 18, 2014 12:09:08 AM GMT
There's actually another ticket which also covers this same E/R: https://bugbase.adobe.com/index.cfm?event=bug&id=CF-3135080
Comment by External U.
17554 | September 27, 2014 07:36:08 PM GMT
+1 - thought I'd already voted, now I know I have :)
Vote by External U.
17560 | November 24, 2014 04:08:07 AM GMT
Deferred until when? CF12? Thanks!, -Aaron
Comment by External U.
17555 | May 14, 2015 06:03:08 PM GMT
I cannot believe this is being deffered. WIthout further explanation. This is an essential tool to have with closure support.
Vote by External U.
17561 | June 01, 2015 09:37:15 AM GMT
Will this be considered for CF12 or CF11 patch. I would hope that it could be available to CF11 as well as a patch.
Comment by External U.
17556 | June 01, 2015 09:37:44 AM GMT
I agree it would be nice to have this
Vote by External U.
17562 | June 29, 2015 03:11:01 PM GMT
+1................................
Vote by External U.
17563 | June 29, 2015 08:55:42 PM GMT
+1 - improves closure support
Vote by External U.
17564 | June 30, 2015 04:59:34 AM GMT
@Adobe, do you see the two questions from your clients there? Do you not think it's a bit rubbish to simply ignore them? FWIW, I have the same question... what's the story here? Whe're you gonna make time?
Comment by Adam C.
17557 | June 01, 2017 09:03:29 AM GMT
Opening it up for evaluation.
Comment by Vamseekrishna N.
17558 | June 01, 2017 10:06:30 AM GMT
Was this considered for 2018?
Comment by Bradley W.
29281 | July 11, 2018 04:44:00 AM GMT
Relates to: https://tracker.adobe.com/#/view/CF-3950736 and https://tracker.adobe.com/#/view/CF-3041263
Comment by Bradley W.
29282 | July 11, 2018 05:25:50 AM GMT
Was just trying to build an IIFE and found AC's blog and eventually this ticket. Would love this feature.
Vote by Bernhard D.
29825 | October 23, 2018 10:45:16 AM GMT
Just a Note, Lucee 5 now supports this as you can see here: https://trycf.com/gist/3693d9d5f99abdfcc62d182a2a441c7c/lucee5?theme=monokai
Comment by Bradley W.
29830 | October 23, 2018 09:36:37 PM GMT