Skip to content

Fromatter: Nested if and elseif with wrong intent  #37

@GoogleCodeExporter

Description

@GoogleCodeExporter
The following code:

#if($bar)
Hello,
#if($foo)
small
#end
World!
#elseif($bar2)
Hello again,
#if($foo)
small
#end
World!
#else
Bye!,
#if($foo)
small
#end
World!
#end

is formated as:

#if($bar)
    Hello,
    #if($foo)
        small
    #end
    World!
    #elseif($bar2)
        Hello again,
        #if($foo)
            small
        #end
        World!
        #else
            Bye!,
            #if($foo)
                small
            #end
            World!
#end

but correct would be:

#if($bar)
    Hello,
    #if($foo)
        small
    #end
    World!
#elseif($bar2)
    Hello again,
    #if($foo)
        small
    #end
    World!
#else
    Bye!,
    #if($foo)
        small
    #end
    World!
#end

Original issue reported on code.google.com by [email protected] on 15 Jun 2011 at 2:36

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions