# weird behaviour with ext/tokenizer and heredoc

- Thread: https://externals.io/message/3827
- Original archive: https://news-web.php.net/php.internals/3827
- Started by Patrick Preuster on 2003-08-08T12:35:14+00:00
- Messages: 1
- Reply by email to internals@lists.php.net
- More for agents: search with https://externals.io/search.md?q={query} · JSON API at https://externals.io/api · documentation at https://externals.io/llms.txt

---

## #3827 — Patrick Preuster — 2003-08-08T12:35:14+00:00

URL: https://externals.io/message/3827#3827

Hello,

when playing around with ext/tokenizer, I found a weird behaviour with
the `T_END_HEREDOC` token. I got "FOO;;" instead of the expected "FOO"
as token. As a consequence I wrote a patch for the Zend Engine that
should fix ext/tokenizer and makes the special stuff for `T_END_HEREDOC` 
in zend_highlight.c unnecessary.

I tested my changes all over but as I'm not really sure if I didn't 
break something, I did a second patch for ext/tokenizer to fix 
 `T_END_HEREDOC` and leave the Zend Engine untouched.

-- 
Patrick Preuster
sica-php@baldur.org, sica@FreeNode

"Heaven doesn't want us and Hell is afraid we'll take over!"
