Browse Source

Remove unnecessary breaks in Tokenizer

split-manual
Dustin Wilson 6 years ago
parent
commit
2f0426946f
  1. 3
      lib/Tokenizer.php

3
lib/Tokenizer.php

@ -3105,18 +3105,15 @@ class Tokenizer {
if ($peek === ']]>') { if ($peek === ']]>') {
$this->data->consume(3); $this->data->consume(3);
return new CharacterToken($char); return new CharacterToken($char);
break;
} elseif ($peek === '') { } elseif ($peek === '') {
# If the end of the file was reached, reconsume the EOF character. # If the end of the file was reached, reconsume the EOF character.
$this->data->unconsume(); $this->data->unconsume();
return new CharacterToken($char); return new CharacterToken($char);
break;
} elseif ($peeklen < 3) { } elseif ($peeklen < 3) {
$char .= $this->data->consume($peeklen); $char .= $this->data->consume($peeklen);
# If the end of the file was reached, reconsume the EOF character. # If the end of the file was reached, reconsume the EOF character.
$this->data->unconsume(); $this->data->unconsume();
return new CharacterToken($char); return new CharacterToken($char);
break;
} else { } else {
$char .= $this->data->consume(); $char .= $this->data->consume();
} }

Loading…
Cancel
Save