Skip to content

ComplexType reification + ternary operator #638

Closed
@kevinresol

Description

@kevinresol

When ComplexType reification is used with the ternary operator, spaces and line breaks are messed up.

Input file

function main() {
	final type = true ? macro:String : macro:Int;
}

Broken output

function main() {
	final type = true ? macro : String
	:macro:Int;
}

Expected output

function main() {
	final type = true ? macro:String : macro:Int;
}

(not very sure about the spaces in the complex type, but at least I think the whole thing should be on the same line)

Metadata

Metadata

Assignees

No one assigned

    Labels

    lineendsline end handlingtokentreerequires fix in tokentreewhitespacemissing or incorrect space around token

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions