Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

macro block with ${} #215

Closed
Gama11 opened this issue Aug 21, 2018 · 0 comments
Closed

macro block with ${} #215

Gama11 opened this issue Aug 21, 2018 · 0 comments
Labels
bug Something isn't working unstable output changes with multiple formatting passes
Milestone

Comments

@Gama11
Copy link
Member

Gama11 commented Aug 21, 2018

class Main {
	public static function main() {
		macro { $e0; ${loop(el)}};
	}
}

There's two problems when formatting the above snippet:

  • it takes two formattings to arrive at the final result
  • the final formatting doesn't look correct:
class Main {
	public static function main() {
		macro {
			$e0;
			${loop(el)}};
	}
}

Instead, I would expect:

class Main {
	public static function main() {
		macro {
			$e0;
			${loop(el)}
		};
	}
}
@Gama11 Gama11 added bug Something isn't working unstable output changes with multiple formatting passes labels Aug 21, 2018
@Gama11 Gama11 added this to the haxe milestone Aug 21, 2018
AlexHaxe added a commit to AlexHaxe/haxe-formatter that referenced this issue Sep 15, 2018
fixed unstable comments after typedef without semicolon, fixes HaxeCheckstyle#216
changed default rules for function signature wrapping, HaxeCheckstyle#231
added testcase for keys value iterator, fixes HaxeCheckstyle#232
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working unstable output changes with multiple formatting passes
Projects
None yet
Development

No branches or pull requests

1 participant