cvs: ZendEngine2(PHP_5_3) / zend_language_scanner.c zend_language_scanner.l
[email protected] ("Ilia Alshanetsky")
| Newsgroups | php.zend-engine.cvs |
|---|---|
| Message-ID | <cvsiliaa1230840987@cvsserver> |
iliaa Thu Jan 1 20:16:27 2009 UTC
Modified files: (Branch: PHP_5_3)
/ZendEngine2 zend_language_scanner.l zend_language_scanner.c
Log:
Fixed bug #46844 (php scripts or included files with first line starting
with # have the 1st line missed from the output).
http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_language_scanner.l?r1=1.131.2.11.2.13.2.32&r2=1.131.2.11.2.13.2.33&diff_format=u
Index: ZendEngine2/zend_language_scanner.l
diff -u ZendEngine2/zend_language_scanner.l:1.131.2.11.2.13.2.32 ZendEngine2/zend_language_scanner.l:1.131.2.11.2.13.2.33
--- ZendEngine2/zend_language_scanner.l:1.131.2.11.2.13.2.32 Tue Nov 4 15:58:51 2008
+++ ZendEngine2/zend_language_scanner.l Thu Jan 1 20:16:24 2009
@@ -21,7 +21,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_language_scanner.l,v 1.131.2.11.2.13.2.32 2008/11/04 15:58:51 helly Exp $ */
+/* $Id: zend_language_scanner.l,v 1.131.2.11.2.13.2.33 2009/01/01 20:16:24 iliaa Exp $ */
#if 0
# define YYDEBUG(s, c) printf("state: %d char: %c\n", s, c)
@@ -843,8 +843,8 @@
return 0;
}
- /* ignore first line when it's started with a # */
- if (YYCURSOR == SCNG(yy_start) && *YYCURSOR == '#') {
+ /* ignore first line when it's started with a #! */
+ if (YYCURSOR == SCNG(yy_start) && *YYCURSOR == '#' && *(YYCURSOR + 1) == '!') {
while (++YYCURSOR < YYLIMIT) {
if (*YYCURSOR == '\n') {
++YYCURSOR;
http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_language_scanner.c?r1=1.1.2.28&r2=1.1.2.29&diff_format=u
Index: ZendEngine2/zend_language_scanner.c
diff -u ZendEngine2/zend_language_scanner.c:1.1.2.28 ZendEngine2/zend_language_scanner.c:1.1.2.29
--- ZendEngine2/zend_language_scanner.c:1.1.2.28 Tue Nov 4 15:58:50 2008
+++ ZendEngine2/zend_language_scanner.c Thu Jan 1 20:16:24 2009
@@ -1,4 +1,4 @@
-/* Generated by re2c 0.13.6.dev on Tue Nov 4 01:40:34 2008 */
+/* Generated by re2c 0.13.5 on Thu Jan 1 15:13:42 2009 */
#line 1 "Zend/zend_language_scanner.l"
/*
+----------------------------------------------------------------------+
@@ -23,7 +23,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_language_scanner.c,v 1.1.2.28 2008/11/04 15:58:50 helly Exp $ */
+/* $Id: zend_language_scanner.c,v 1.1.2.29 2009/01/01 20:16:24 iliaa Exp $ */
#if 0
# define YYDEBUG(s, c) printf("state: %d char: %c\n", s, c)
@@ -845,8 +845,8 @@
return 0;
}
- /* ignore first line when it's started with a # */
- if (YYCURSOR == SCNG(yy_start) && *YYCURSOR == '#') {
+ /* ignore first line when it's started with a #! */
+ if (YYCURSOR == SCNG(yy_start) && *YYCURSOR == '#' && *(YYCURSOR + 1) == '!') {
while (++YYCURSOR < YYLIMIT) {
if (*YYCURSOR == '\n') {
++YYCURSOR;