X-Git-Url: https://git.madduck.net/etc/vim.git/blobdiff_plain/ad5c315ddad26a3c41f22d3b73c493fb7d7b86b8..e0a780a5056f1039edcf12c7a44198be902afbbc:/src/black/linegen.py?ds=sidebyside diff --git a/src/black/linegen.py b/src/black/linegen.py index 1f132b7..8e8d41e 100644 --- a/src/black/linegen.py +++ b/src/black/linegen.py @@ -220,7 +220,9 @@ class LineGenerator(Visitor[Line]): for child in children: yield from self.visit(child) - if child.type == token.ASYNC: + if child.type == token.ASYNC or child.type == STANDALONE_COMMENT: + # STANDALONE_COMMENT happens when `# fmt: skip` is applied on the async + # line. break internal_stmt = next(children)