mirror of
https://github.com/ytdl-org/youtube-dl.git
synced 2025-08-22 22:34:01 -07:00
[jsinterp] This isn't C, we don't need semicolons
This commit is contained in:
parent
3c8b56e3aa
commit
10e59b6c7f
1 changed files with 4 additions and 4 deletions
|
@ -256,7 +256,7 @@ class JSInterpreter(object):
|
||||||
in_quote, escaping, skipping = None, False, 0
|
in_quote, escaping, skipping = None, False, 0
|
||||||
in_comment_block, in_comment_line, finishing_comment = False, False, False
|
in_comment_block, in_comment_line, finishing_comment = False, False, False
|
||||||
after_op, in_regex_char_group, skip_re = True, False, 0
|
after_op, in_regex_char_group, skip_re = True, False, 0
|
||||||
start_comment = None;
|
start_comment = None
|
||||||
comment_spans = []
|
comment_spans = []
|
||||||
|
|
||||||
for idx, char in enumerate(expr):
|
for idx, char in enumerate(expr):
|
||||||
|
@ -287,15 +287,15 @@ class JSInterpreter(object):
|
||||||
if in_comment_line:
|
if in_comment_line:
|
||||||
if char == '\n':
|
if char == '\n':
|
||||||
in_comment_line = False
|
in_comment_line = False
|
||||||
comment_spans.append((start_comment, idx));
|
comment_spans.append((start_comment, idx))
|
||||||
start_comment = None
|
start_comment = None
|
||||||
continue
|
continue
|
||||||
if finishing_comment:
|
if finishing_comment:
|
||||||
# Eat the final '/' of a '/* ... */' comment.
|
# Eat the final '/' of a '/* ... */' comment.
|
||||||
finishing_comment = False
|
finishing_comment = False
|
||||||
comment_spans.append((start_comment, idx));
|
comment_spans.append((start_comment, idx))
|
||||||
start_comment = None
|
start_comment = None
|
||||||
continue;
|
continue
|
||||||
if not in_quote:
|
if not in_quote:
|
||||||
if char in _MATCHING_PARENS:
|
if char in _MATCHING_PARENS:
|
||||||
counters[_MATCHING_PARENS[char]] += 1
|
counters[_MATCHING_PARENS[char]] += 1
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue