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

Format giving wrong results #769

Closed
sathvikbhagavan opened this issue Oct 18, 2023 · 3 comments
Closed

Format giving wrong results #769

sathvikbhagavan opened this issue Oct 18, 2023 · 3 comments

Comments

@sathvikbhagavan
Copy link

I have a file (test.jl) where I have this line of code:

@assert x isa Tuple "x is not a Tuple"

If I format it using format("test.jl"), I get:

@assert xisaTuple "x is not a Tuple"

which is wrong

Version:

[98e50ef6] JuliaFormatter v1.0.39
@domluna
Copy link
Owner

domluna commented Oct 19, 2023

can you post your .JuliaFormatter.toml file with the defaults it formats fine

@sathvikbhagavan
Copy link
Author

Yes, it is SciML style

style = "sciml"

If I also try:

format("test.jl", style = SciMLStyle())

I get the same error

@hyrodium
Copy link
Contributor

MWE without an external file:

julia> using JuliaFormatter

julia> text = "@assert x isa Tuple \"msg\""
"@assert x isa Tuple \"msg\""

julia> format_text(text, style=SciMLStyle())
"@assert xisaTuple \"msg\""

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants