ruff/crates/ruff_python_formatter/src
Micha Reiser df2efe81c8
Respect magic trailing comma for set expression (#5782)
<!--
Thank you for contributing to Ruff! To help us out with reviewing,
please consider the following:

- Does this pull request include a summary of the change? (See below.)
- Does this pull request include a descriptive title?
- Does this pull request include references to any relevant issues?
-->

## Summary

This PR uses the `join_comma_separated` builder for formatting set
expressions
to ensure the formatting preserves magic commas, if the setting is
enabled.
<!-- What's the purpose of the change? What does it do, and why? -->

## Test Plan
See the fixed black tests

<!-- How was it tested? -->
2023-07-15 16:40:38 +00:00
..
comments Parenthesize with statements (#5758) 2023-07-15 16:03:09 +01:00
expression Respect magic trailing comma for set expression (#5782) 2023-07-15 16:40:38 +00:00
module Format `ModExpression` (#5689) 2023-07-11 16:41:10 +02:00
other Parenthesize with statements (#5758) 2023-07-15 16:03:09 +01:00
pattern Use dedicated structs in `comparable.rs` (#5042) 2023-06-13 03:57:34 +00:00
snapshots formatter: multi char tokens in SimpleTokenizer (#5610) 2023-07-10 09:00:59 +01:00
statement Parenthesize with statements (#5758) 2023-07-15 16:03:09 +01:00
builders.rs Parenthesize with statements (#5758) 2023-07-15 16:03:09 +01:00
cli.rs Create `PyFormatOptions` 2023-06-26 14:02:17 +02:00
context.rs Cover Black's `is_aritmetic_like` formatting (#5738) 2023-07-14 17:54:58 +02:00
generated.rs Run nightly Clippy over the Ruff repo (#5670) 2023-07-10 23:44:38 -04:00
lib.rs Parenthesize with statements (#5758) 2023-07-15 16:03:09 +01:00
main.rs Add a formatter CLI for debugging (#4809) 2023-06-05 07:33:33 +00:00
options.rs Prefer the configured quote style 2023-06-26 14:24:25 +02:00
prelude.rs Accept any `Into<AnyNodeRef>` as `Comments` arguments (#5205) 2023-06-20 16:49:21 +00:00
trivia.rs Parenthesize with statements (#5758) 2023-07-15 16:03:09 +01:00