diff --git a/Zend/zend.c b/Zend/zend.c
index 06cb9cbc78954..8a6e09ea04f68 100644
--- a/Zend/zend.c
+++ b/Zend/zend.c
@@ -372,11 +372,9 @@ static FILE *zend_fopen_wrapper(const char *filename, char **opened_path TSRMLS_
/* }}} */
#ifdef ZTS
-static zend_bool asp_tags_default = 0;
-static zend_bool short_tags_default = 1;
+static zend_bool short_tags_default = 1;
static uint32_t compiler_options_default = ZEND_COMPILE_DEFAULT;
#else
-# define asp_tags_default 0
# define short_tags_default 1
# define compiler_options_default ZEND_COMPILE_DEFAULT
#endif
@@ -384,7 +382,6 @@ static uint32_t compiler_options_default = ZEND_COMPILE_DEFAULT;
static void zend_set_default_compile_time_values(TSRMLS_D) /* {{{ */
{
/* default compile-time values */
- CG(asp_tags) = asp_tags_default;
CG(short_tags) = short_tags_default;
CG(compiler_options) = compiler_options_default;
}
@@ -721,7 +718,6 @@ void zend_post_startup(TSRMLS_D) /* {{{ */
*GLOBAL_CLASS_TABLE = *compiler_globals->class_table;
*GLOBAL_CONSTANTS_TABLE = *executor_globals->zend_constants;
- asp_tags_default = CG(asp_tags);
short_tags_default = CG(short_tags);
compiler_options_default = CG(compiler_options);
diff --git a/Zend/zend_globals.h b/Zend/zend_globals.h
index 69e1cf9e68271..4a59b653efb4f 100644
--- a/Zend/zend_globals.h
+++ b/Zend/zend_globals.h
@@ -91,7 +91,6 @@ struct _zend_compiler_globals {
zend_bool parse_error;
zend_bool in_compilation;
zend_bool short_tags;
- zend_bool asp_tags;
zend_declarables declarables;
diff --git a/Zend/zend_language_scanner.c b/Zend/zend_language_scanner.c
index 5bd2798cde83b..fd1693554a0ef 100644
--- a/Zend/zend_language_scanner.c
+++ b/Zend/zend_language_scanner.c
@@ -991,10 +991,8 @@ int lex_scan(zval *zendlval TSRMLS_DC)
restart:
SCNG(yy_text) = YYCURSOR;
-yymore_restart:
-
-#line 998 "Zend/zend_language_scanner.c"
+#line 996 "Zend/zend_language_scanner.c"
{
YYCTYPE yych;
unsigned int yyaccept = 0;
@@ -1037,64 +1035,19 @@ int lex_scan(zval *zendlval TSRMLS_DC)
}
/* *********************************** */
yyc_INITIAL:
- {
- static const unsigned char yybm[] = {
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 128, 128, 0, 0, 128, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 128, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
- };
- YYDEBUG(0, *YYCURSOR);
- YYFILL(8);
- yych = *YYCURSOR;
- if (yych != '<') goto yy4;
- YYDEBUG(2, *YYCURSOR);
- yyaccept = 0;
- yych = *(YYMARKER = ++YYCURSOR);
- if (yych <= '?') {
- if (yych == '%') goto yy7;
- if (yych >= '?') goto yy5;
- } else {
- if (yych <= 'S') {
- if (yych >= 'S') goto yy9;
- } else {
- if (yych == 's') goto yy9;
- }
- }
+ YYDEBUG(0, *YYCURSOR);
+ YYFILL(7);
+ yych = *YYCURSOR;
+ if (yych != '<') goto yy4;
+ YYDEBUG(2, *YYCURSOR);
+ ++YYCURSOR;
+ if ((yych = *YYCURSOR) == '?') goto yy5;
yy3:
- YYDEBUG(3, *YYCURSOR);
- yyleng = YYCURSOR - SCNG(yy_text);
-#line 1663 "Zend/zend_language_scanner.l"
- {
+ YYDEBUG(3, *YYCURSOR);
+ yyleng = YYCURSOR - SCNG(yy_text);
+#line 1627 "Zend/zend_language_scanner.l"
+ {
if (YYCURSOR > YYLIMIT) {
return 0;
}
@@ -1106,35 +1059,19 @@ int lex_scan(zval *zendlval TSRMLS_DC)
YYCURSOR = ptr ? ptr + 1 : YYLIMIT;
- if (YYCURSOR < YYLIMIT) {
- switch (*YYCURSOR) {
- case '?':
- if (CG(short_tags) || !strncasecmp((char*)YYCURSOR + 1, "php", 3) || (*(YYCURSOR + 1) == '=')) { /* Assume [ \t\n\r] follows "php" */
- break;
- }
- continue;
- case '%':
- if (CG(asp_tags)) {
- break;
- }
- continue;
- case 's':
- case 'S':
- /* Probably NOT an opening PHP "){NEWLINE}? {
+"?>"{NEWLINE}? {
BEGIN(INITIAL);
return T_CLOSE_TAG; /* implicit ';' at php-end tag */
}
-"%>"{NEWLINE}? {
- if (CG(asp_tags)) {
- BEGIN(INITIAL);
- return T_CLOSE_TAG; /* implicit ';' at php-end tag */
- } else {
- yyless(1);
- return yytext[0];
- }
-}
-
-
b?['] {
register char *s, *t;
char *end;
diff --git a/ext/readline/readline_cli.c b/ext/readline/readline_cli.c
index ff0671ce9fa77..48ab488763fcb 100644
--- a/ext/readline/readline_cli.c
+++ b/ext/readline/readline_cli.c
@@ -270,12 +270,6 @@ static int cli_is_valid_code(char *code, int len, zend_string **prompt TSRMLS_DC
}
valid_end = 0;
break;
- case '%':
- if (!CG(asp_tags)) {
- valid_end = 0;
- break;
- }
- /* no break */
case '?':
if (code[i+1] == '>') {
i++;
@@ -360,7 +354,6 @@ static int cli_is_valid_code(char *code, int len, zend_string **prompt TSRMLS_DC
break;
case outside:
if ((CG(short_tags) && !strncmp(code+i-1, "", 2))
- || (CG(asp_tags) && !strncmp(code+i-1, "<%", 2))
|| (i > 3 && !strncmp(code+i-4, " tags.
-; http://php.net/asp-tags
-asp_tags = Off
-
; The number of significant digits displayed in floating point numbers.
; http://php.net/precision
precision = 14
diff --git a/php.ini-production b/php.ini-production
index c07ed21c38703..a455b825b5a99 100644
--- a/php.ini-production
+++ b/php.ini-production
@@ -201,10 +201,6 @@ engine = On
; http://php.net/short-open-tag
short_open_tag = Off
-; Allow ASP-style <% %> tags.
-; http://php.net/asp-tags
-asp_tags = Off
-
; The number of significant digits displayed in floating point numbers.
; http://php.net/precision
precision = 14
diff --git a/tests/lang/script_tag.phpt b/tests/lang/script_tag.phpt
deleted file mode 100644
index 1b5c69629576a..0000000000000
--- a/tests/lang/script_tag.phpt
+++ /dev/null
@@ -1,17 +0,0 @@
---TEST--
-
-
-
-texto