Skip to content
This repository was archived by the owner on Feb 15, 2023. It is now read-only.

Commit f064c9e

Browse files
committed
Delete two comments that are no longer accurate.
1 parent aa8db31 commit f064c9e

File tree

2 files changed

+3
-8
lines changed

2 files changed

+3
-8
lines changed

src/char_ref.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23034,7 +23034,8 @@ static bool consume_named_ref(
2303423034

2303523035
#line 2490 "char_ref.rl"
2303623036

23037-
if (output->first != kGumboNoChar) {
23037+
if (false) {
23038+
assert(output->first != kGumboNoChar);
2303823039
char last_char = *(te - 1);
2303923040
int len = te - start;
2304023041
// Consume the match outside of the if-statement below;

src/char_ref.rl

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2482,18 +2482,12 @@ static bool consume_named_ref(
24822482
(void) ts;
24832483

24842484
start = p;
2485-
// Note that the state machine operates on raw character buffers, so it's not
2486-
// consuming any characters. As a result, we don't need to do any mark/reset
2487-
// calls, but we do need to call utf8iterator_maybe_consume_match on success
2488-
// to consume the characters we just looked at.
24892485
%% write exec;
24902486

24912487
if (output->first != kGumboNoChar) {
2488+
assert(output->first != kGumboNoChar);
24922489
char last_char = *(te - 1);
24932490
int len = te - start;
2494-
// Consume the match outside of the if-statement below;
2495-
// is_legal_attribute_char_next depends upon the iterator having been
2496-
// advanced past it.
24972491
if (last_char == ';') {
24982492
bool matched = utf8iterator_maybe_consume_match(input, start, len, true);
24992493
assert(matched);

0 commit comments

Comments
 (0)