| @@ 421-433 (lines=13) @@ | ||
| 418 | Parse error. Switch to the data state. */ |
|
| 419 | $this->state = 'data'; |
|
| 420 | ||
| 421 | } elseif($this->char === $this->EOF) { |
|
| 422 | /* EOF |
|
| 423 | Parse error. Emit a U+003C LESS-THAN SIGN character token and a U+002F |
|
| 424 | SOLIDUS character token. Reconsume the EOF character in the data state. */ |
|
| 425 | $this->emitToken(array( |
|
| 426 | 'type' => self::CHARACTR, |
|
| 427 | 'data' => '</' |
|
| 428 | )); |
|
| 429 | ||
| 430 | $this->char--; |
|
| 431 | $this->state = 'data'; |
|
| 432 | ||
| 433 | } else { |
|
| 434 | /* Parse error. Switch to the bogus comment state. */ |
|
| 435 | $this->state = 'bogusComment'; |
|
| 436 | } |
|
| @@ 977-987 (lines=11) @@ | ||
| 974 | ||
| 975 | $this->state = 'data'; |
|
| 976 | ||
| 977 | } elseif($this->char === $this->EOF) { |
|
| 978 | $this->emitToken(array( |
|
| 979 | 'name' => null, |
|
| 980 | 'type' => self::DOCTYPE, |
|
| 981 | 'error' => true |
|
| 982 | )); |
|
| 983 | ||
| 984 | $this->char--; |
|
| 985 | $this->state = 'data'; |
|
| 986 | ||
| 987 | } else { |
|
| 988 | $this->token = array( |
|
| 989 | 'name' => $char, |
|
| 990 | 'type' => self::DOCTYPE, |
|