Loading black.py +1 −1 Changes for black.py: 1 added line, 1 removed line. Original line number Diff line number Diff line Loading @@ -1741,7 +1741,7 @@ def is_split_before_delimiter(leaf: Leaf, previous: Leaf = None) -> int: leaf.type == token.DOT and leaf.parent and leaf.parent.type not in {syms.import_from, syms.dotted_name} and (previous is None or previous.type != token.NAME) and (previous is None or previous.type in CLOSING_BRACKETS) ): return DOT_PRIORITY Loading tests/comments2.py +39 −0 Changes for tests/comments2.py: 39 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -23,6 +23,25 @@ 'Generator', ] not_shareables = [ # singletons True, False, NotImplemented, ..., # builtin types and objects type, object, object(), Exception(), 42, 100.0, "spam", # user-defined types and objects Cheese, Cheese("Wensleydale"), SubBytes(b"spam"), ] if 'PYTHON' in os.environ: add_compiler(compiler_from_env()) else: Loading Loading @@ -152,6 +171,26 @@ def inline_comments_in_brackets_ruin_everything(): "Generator", ] not_shareables = [ # singletons True, False, NotImplemented, ..., # builtin types and objects type, object, object(), Exception(), 42, 100.0, "spam", # user-defined types and objects Cheese, Cheese("Wensleydale"), SubBytes(b"spam"), ] if "PYTHON" in os.environ: add_compiler(compiler_from_env()) else: Loading Loading
black.py +1 −1 Changes for black.py: 1 added line, 1 removed line. Original line number Diff line number Diff line Loading @@ -1741,7 +1741,7 @@ def is_split_before_delimiter(leaf: Leaf, previous: Leaf = None) -> int: leaf.type == token.DOT and leaf.parent and leaf.parent.type not in {syms.import_from, syms.dotted_name} and (previous is None or previous.type != token.NAME) and (previous is None or previous.type in CLOSING_BRACKETS) ): return DOT_PRIORITY Loading
tests/comments2.py +39 −0 Changes for tests/comments2.py: 39 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -23,6 +23,25 @@ 'Generator', ] not_shareables = [ # singletons True, False, NotImplemented, ..., # builtin types and objects type, object, object(), Exception(), 42, 100.0, "spam", # user-defined types and objects Cheese, Cheese("Wensleydale"), SubBytes(b"spam"), ] if 'PYTHON' in os.environ: add_compiler(compiler_from_env()) else: Loading Loading @@ -152,6 +171,26 @@ def inline_comments_in_brackets_ruin_everything(): "Generator", ] not_shareables = [ # singletons True, False, NotImplemented, ..., # builtin types and objects type, object, object(), Exception(), 42, 100.0, "spam", # user-defined types and objects Cheese, Cheese("Wensleydale"), SubBytes(b"spam"), ] if "PYTHON" in os.environ: add_compiler(compiler_from_env()) else: Loading