cfmlparser icon indicating copy to clipboard operation
cfmlparser copied to clipboard

Incorrect script parse with `for` and `while`

Open jcberquist opened this issue 5 years ago • 0 comments

It looks like the script parser does not currently look explicitly for while and for keywords, and the result seems to be that it doesn't handle script with those keywords when there are nested braces:

component {

    function test() {
        for ( x in y ) {
            if ( true ) {
            }
        }
    }

    // comment
}

With the above component, the parser identifies the end of the component and the function blocks one } too early.

jcberquist avatar Jul 11 '19 16:07 jcberquist