From: hauntsaninja Date: Tue, 13 Nov 2018 23:02:27 +0000 (-0800) Subject: Fix two types to be Optional (#607) X-Git-Url: https://git.madduck.net/etc/vim.git/commitdiff_plain/5bc62a4a82a4e59ad3bb8e9078b9992396ebfd2f?ds=sidebyside;hp=fbf59b60d750ace9792a78736f19a4e81a156333 Fix two types to be Optional (#607) --- diff --git a/black.py b/black.py index 9ac16c0..74cf650 100644 --- a/black.py +++ b/black.py @@ -1892,7 +1892,7 @@ def container_of(leaf: Leaf) -> LN: return container -def is_split_after_delimiter(leaf: Leaf, previous: Leaf = None) -> int: +def is_split_after_delimiter(leaf: Leaf, previous: Optional[Leaf] = None) -> int: """Return the priority of the `leaf` delimiter, given a line break after it. The delimiter priorities returned here are from those delimiters that would @@ -1906,7 +1906,7 @@ def is_split_after_delimiter(leaf: Leaf, previous: Leaf = None) -> int: return 0 -def is_split_before_delimiter(leaf: Leaf, previous: Leaf = None) -> int: +def is_split_before_delimiter(leaf: Leaf, previous: Optional[Leaf] = None) -> int: """Return the priority of the `leaf` delimiter, given a line break before it. The delimiter priorities returned here are from those delimiters that would