Skip to content

Commit

Permalink
Add a Preview feature
Browse files Browse the repository at this point in the history
  • Loading branch information
JelleZijlstra committed Oct 16, 2023
1 parent b4647fb commit ba2cc11
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/black/linegen.py
Expand Up @@ -566,7 +566,7 @@ def transform_line(
# split the line. Default to line_str, if no power operator are present on the line.
line_str_hugging_power_ops = (
(_hugging_power_ops_line_to_string(line, features, mode) or line_str)
if mode.preview
if Preview.fix_power_op_line_length in mode
else line_str
)

Expand Down
1 change: 1 addition & 0 deletions src/black/mode.py
Expand Up @@ -188,6 +188,7 @@ class Preview(Enum):
dummy_implementations = auto()
walrus_subscript = auto()
module_docstring_newlines = auto()
fix_power_op_line_length = auto()


class Deprecated(UserWarning):
Expand Down

0 comments on commit ba2cc11

Please sign in to comment.