Commit Graph

10 Commits

Author SHA1 Message Date
Micha Reiser dd0d1afb66
Create `PyFormatOptions`
<!--
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 adds a new `PyFormatOptions` struct that stores the python formatter options. 
The new options aren't used yet, with the exception of magical trailing commas and the options passed to the printer. 
I'll follow up with more PRs that use the new options (e.g. `QuoteStyle`).

<!-- What's the purpose of the change? What does it do, and why? -->

## Test Plan

`cargo test` I'll follow up with a new PR that adds support for overriding the options in our fixture tests.
2023-06-26 14:02:17 +02:00
Micha Reiser 33434fcb9c
Add Formatter benchmark (#4860) 2023-06-05 21:05:42 +02:00
Micha Reiser 6c1ff6a85f
Upgrade RustPython (#4747) 2023-05-31 08:26:35 +00:00
Charlie Marsh 19c4b7bee6
Rename ruff_python_semantic's `Context` struct to `SemanticModel` (#4565) 2023-05-22 02:35:03 +00:00
Charlie Marsh fd34797d0f
Add a specialized `StatementVisitor` (#4349) 2023-05-10 12:42:20 -04:00
Micha Reiser 8969ad5879
Always generate fixes (#4239) 2023-05-10 07:06:14 +00:00
Micha Reiser 280dffb5e1
Add parser benchmark (#3990) 2023-04-17 16:43:59 +02:00
Micha Reiser a5494b8541
Bitflag based RuleSet (#3606) 2023-03-19 17:09:06 +01:00
Micha Reiser 87fab4a2e1
Benchmark all rules (#3570) 2023-03-17 19:29:39 +01:00
Micha Reiser d5700d7c69
Add Micro Benchmark (#3466) 2023-03-14 08:35:07 +01:00