tracker issue : CF-4203408

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

Nested structure

| View in Tracker

Status/Resolution/Reason: Closed/Fixed/Fixed

Reporter/Name(from Bugbase): Dave Levin / ()

Created: 10/25/2018

Components: Language, Functions

Versions: 2016,11.0,2018

Failure Type: Non Functioning

Found In Build/Fixed In Build: latest / CF2016U12,CF2018U5

Priority/Frequency: Normal / All users will encounter

Locale/System: ALL / Windows 10 64 bit

Vote Count: 6

Problem Description:
Referencing a variable in a nested structure generates an exception error:
Steps to Reproduce:
https://trycf.com/gist/044ee4daf84fe98fbaa5aed6fc3e6b65/acf2018?theme=monokai

OR

<cfoutput>
    <cfloop array="#['apples', 'oranges', 'bananas']#" item="a">

    #renderView(
        view = "location/myView",
        args = {
            fruit = a
        }
    )#

</cfloop>
    
    <cfscript>
        function renderView() {
            writeDump( arguments );
        }
    </cfscript>
    
</cfoutput>
Actual Result:
"Variable A is undefined. on line 7"
Expected Result:
It should be able to know what A is.
Any Workarounds:
Assemble the nested structure first.

Attachments:

Comments:

This is really basic stuff and should just work. Tested in Lucee and it works fine there.
Comment by Bradley W.
29849 | October 25, 2018 06:28:27 PM GMT
Pretty sure I ran into this in some TDD mocks. Had to duplicate test data and then return. The code provided should work.
Vote by Chris P.
29979 | November 28, 2018 01:11:58 AM GMT
It should be noted that this bug also impacts ColdFusion version 2016 (latest)
Comment by Dave L.
30224 | February 11, 2019 09:59:02 PM GMT
I see this bug has been fixed in build 2020.0.0.314525, however what about the other currently supported versions of CF? This issue still plagues version 2016 and I have many customers still relying on that version receiving updates and fixes.
Comment by Dave L.
30922 | June 14, 2019 02:30:16 PM GMT