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

Break string percent formatting like black #6505

Closed
Tracked by #6069
konstin opened this issue Aug 11, 2023 · 4 comments
Closed
Tracked by #6069

Break string percent formatting like black #6505

konstin opened this issue Aug 11, 2023 · 4 comments
Assignees
Labels
formatter Related to the formatter

Comments

@konstin
Copy link
Member

konstin commented Aug 11, 2023

black:

template_params["lhs"] = "%s, %s" % (
    template_params,
    lookup_band_lhs,
)

template_params__lhs__ = "%s, %s" % (
    template_params,
    lookup_band_lhs,
)

ours:

template_params["lhs"] = (
    "%s, %s"
    % (
        template_params,
        lookup_band_lhs,
    )
)

template_params__lhs__ = "%s, %s" % (
    template_params,
    lookup_band_lhs,
)
@konstin konstin added the formatter Related to the formatter label Aug 11, 2023
@evanrittenhouse
Copy link
Contributor

@konstin Feel free to assign this to me. May take a bit as I have to get up to speed with the formatter, though.

@MichaReiser
Copy link
Member

MichaReiser commented Aug 12, 2023

I'm not sure if this is a good first formatter issue. Feel free to have a look but I expect that this fix requires good knowledge of the IR

You could coordinate with @dhruvmanila and implement a match case formatting.

@MichaReiser MichaReiser added this to the Formatter: Alpha milestone Aug 16, 2023
@konstin konstin self-assigned this Aug 23, 2023
@konstin
Copy link
Member Author

konstin commented Aug 24, 2023

Fixed by #6815

@konstin konstin closed this as completed Aug 24, 2023
@MichaReiser
Copy link
Member

Fixed by #6815

Uh interesting, that's not what I expected would fix this

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

No branches or pull requests

3 participants