Skip to content
This repository has been archived by the owner on Apr 1, 2024. It is now read-only.

Commit

Permalink
Fix HEREDOC bug
Browse files Browse the repository at this point in the history
Summary:
Heredocs weren't scanning properly in XHP 1.2.1. This fixes that

Test Plan:
$foo = <<<HERE
HERE;

Reviewed By: epriestley

Revert: OK
  • Loading branch information
Marcel Laverdet committed Sep 29, 2009
1 parent c577a2d commit 8e72216
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion ext.hpp
Expand Up @@ -4,7 +4,7 @@
#endif
#include "php.h"

#define PHP_XHP_VERSION "1.2.1"
#define PHP_XHP_VERSION "1.2.2"
#define PHP_XHP_EXTNAME "xhp"

extern zend_module_entry xhp_module_entry;
Expand Down
1 change: 1 addition & 0 deletions xhp/scanner.l
Expand Up @@ -444,6 +444,7 @@ NEWLINE ("\r\n"|"\n"|"\r")
}
++yyextra->lineno;
yyextra->heredoc_yyleng = yyleng;
yymore();
}
[^\r\n]+ {
set_state(PHP_HEREDOC_DATA);
Expand Down

0 comments on commit 8e72216

Please sign in to comment.