summaryrefslogtreecommitdiff
path: root/Zend/zend_ini_scanner.l
diff options
context:
space:
mode:
authorAnatol Belski <ab@php.net>2014-12-13 23:06:14 +0100
committerAnatol Belski <ab@php.net>2014-12-13 23:06:14 +0100
commitbdeb220f48825642f84cdbf3ff23a30613c92e86 (patch)
tree1a6cf34d20420e4815b4becb21311a4457d84103 /Zend/zend_ini_scanner.l
parentbb66f385d09e7e55390e9f57fcbca08f6b43ff91 (diff)
downloadphp-git-bdeb220f48825642f84cdbf3ff23a30613c92e86.tar.gz
first shot remove TSRMLS_* things
Diffstat (limited to 'Zend/zend_ini_scanner.l')
-rw-r--r--Zend/zend_ini_scanner.l56
1 files changed, 28 insertions, 28 deletions
diff --git a/Zend/zend_ini_scanner.l b/Zend/zend_ini_scanner.l
index 79d82764b1..005c216c23 100644
--- a/Zend/zend_ini_scanner.l
+++ b/Zend/zend_ini_scanner.l
@@ -187,7 +187,7 @@ static void zend_ini_copy_typed_value(zval *retval, const int type, const char *
}
}
-static void _yy_push_state(int new_state TSRMLS_DC)
+static void _yy_push_state(int new_state)
{
zend_stack_push(&SCNG(state_stack), (void *) &YYGETCONDITION());
YYSETCONDITION(new_state);
@@ -195,14 +195,14 @@ static void _yy_push_state(int new_state TSRMLS_DC)
#define yy_push_state(state_and_tsrm) _yy_push_state(yyc##state_and_tsrm)
-static void yy_pop_state(TSRMLS_D)
+static void yy_pop_state(void)
{
int *stack_state = zend_stack_top(&SCNG(state_stack));
YYSETCONDITION(*stack_state);
zend_stack_del_top(&SCNG(state_stack));
}
-static void yy_scan_buffer(char *str, unsigned int len TSRMLS_DC)
+static void yy_scan_buffer(char *str, unsigned int len)
{
YYCURSOR = (YYCTYPE*)str;
SCNG(yy_start) = YYCURSOR;
@@ -213,7 +213,7 @@ static void yy_scan_buffer(char *str, unsigned int len TSRMLS_DC)
/* {{{ init_ini_scanner()
*/
-static int init_ini_scanner(int scanner_mode, zend_file_handle *fh TSRMLS_DC)
+static int init_ini_scanner(int scanner_mode, zend_file_handle *fh)
{
/* Sanity check */
if (scanner_mode != ZEND_INI_SCANNER_NORMAL && scanner_mode != ZEND_INI_SCANNER_RAW && scanner_mode != ZEND_INI_SCANNER_TYPED) {
@@ -240,7 +240,7 @@ static int init_ini_scanner(int scanner_mode, zend_file_handle *fh TSRMLS_DC)
/* {{{ shutdown_ini_scanner()
*/
-void shutdown_ini_scanner(TSRMLS_D)
+void shutdown_ini_scanner(void)
{
zend_stack_destroy(&SCNG(state_stack));
if (ini_filename) {
@@ -251,7 +251,7 @@ void shutdown_ini_scanner(TSRMLS_D)
/* {{{ zend_ini_scanner_get_lineno()
*/
-int zend_ini_scanner_get_lineno(TSRMLS_D)
+int zend_ini_scanner_get_lineno(void)
{
return SCNG(lineno);
}
@@ -259,7 +259,7 @@ int zend_ini_scanner_get_lineno(TSRMLS_D)
/* {{{ zend_ini_scanner_get_filename()
*/
-char *zend_ini_scanner_get_filename(TSRMLS_D)
+char *zend_ini_scanner_get_filename(void)
{
return ini_filename ? ini_filename : "Unknown";
}
@@ -267,21 +267,21 @@ char *zend_ini_scanner_get_filename(TSRMLS_D)
/* {{{ zend_ini_open_file_for_scanning()
*/
-int zend_ini_open_file_for_scanning(zend_file_handle *fh, int scanner_mode TSRMLS_DC)
+int zend_ini_open_file_for_scanning(zend_file_handle *fh, int scanner_mode)
{
char *buf;
size_t size;
- if (zend_stream_fixup(fh, &buf, &size TSRMLS_CC) == FAILURE) {
+ if (zend_stream_fixup(fh, &buf, &size) == FAILURE) {
return FAILURE;
}
- if (init_ini_scanner(scanner_mode, fh TSRMLS_CC) == FAILURE) {
- zend_file_handle_dtor(fh TSRMLS_CC);
+ if (init_ini_scanner(scanner_mode, fh) == FAILURE) {
+ zend_file_handle_dtor(fh);
return FAILURE;
}
- yy_scan_buffer(buf, (unsigned int)size TSRMLS_CC);
+ yy_scan_buffer(buf, (unsigned int)size);
return SUCCESS;
}
@@ -289,15 +289,15 @@ int zend_ini_open_file_for_scanning(zend_file_handle *fh, int scanner_mode TSRML
/* {{{ zend_ini_prepare_string_for_scanning()
*/
-int zend_ini_prepare_string_for_scanning(char *str, int scanner_mode TSRMLS_DC)
+int zend_ini_prepare_string_for_scanning(char *str, int scanner_mode)
{
int len = (int)strlen(str);
- if (init_ini_scanner(scanner_mode, NULL TSRMLS_CC) == FAILURE) {
+ if (init_ini_scanner(scanner_mode, NULL) == FAILURE) {
return FAILURE;
}
- yy_scan_buffer(str, len TSRMLS_CC);
+ yy_scan_buffer(str, len);
return SUCCESS;
}
@@ -305,7 +305,7 @@ int zend_ini_prepare_string_for_scanning(char *str, int scanner_mode TSRMLS_DC)
/* {{{ zend_ini_escape_string()
*/
-static void zend_ini_escape_string(zval *lval, char *str, int len, char quote_type TSRMLS_DC)
+static void zend_ini_escape_string(zval *lval, char *str, int len, char quote_type)
{
register char *s, *t;
char *end;
@@ -352,7 +352,7 @@ static void zend_ini_escape_string(zval *lval, char *str, int len, char quote_ty
}
/* }}} */
-int ini_lex(zval *ini_lval TSRMLS_DC)
+int ini_lex(zval *ini_lval)
{
restart:
SCNG(yy_text) = YYCURSOR;
@@ -402,9 +402,9 @@ SECTION_VALUE_CHARS ([^$\n\r;"'\]\\]|("\\"{ANY_CHAR})|{LITERAL_DOLLAR})
<INITIAL>"[" { /* Section start */
/* Enter section data lookup state */
if (SCNG(scanner_mode) == ZEND_INI_SCANNER_RAW) {
- yy_push_state(ST_SECTION_RAW TSRMLS_CC);
+ yy_push_state(ST_SECTION_RAW);
} else {
- yy_push_state(ST_SECTION_VALUE TSRMLS_CC);
+ yy_push_state(ST_SECTION_VALUE);
}
return TC_SECTION;
}
@@ -432,7 +432,7 @@ SECTION_VALUE_CHARS ([^$\n\r;"'\]\\]|("\\"{ANY_CHAR})|{LITERAL_DOLLAR})
EAT_TRAILING_WHITESPACE_EX('[');
/* Enter offset lookup state */
- yy_push_state(ST_OFFSET TSRMLS_CC);
+ yy_push_state(ST_OFFSET);
RETURN_TOKEN(TC_OFFSET, yytext, yyleng);
}
@@ -443,7 +443,7 @@ SECTION_VALUE_CHARS ([^$\n\r;"'\]\\]|("\\"{ANY_CHAR})|{LITERAL_DOLLAR})
}
<ST_DOUBLE_QUOTES,ST_SECTION_VALUE,ST_VALUE,ST_OFFSET>{DOLLAR_CURLY} { /* Variable start */
- yy_push_state(ST_VARNAME TSRMLS_CC);
+ yy_push_state(ST_VARNAME);
return TC_DOLLAR_CURLY;
}
@@ -458,7 +458,7 @@ SECTION_VALUE_CHARS ([^$\n\r;"'\]\\]|("\\"{ANY_CHAR})|{LITERAL_DOLLAR})
}
<ST_VARNAME>"}" { /* Variable end */
- yy_pop_state(TSRMLS_C);
+ yy_pop_state();
return '}';
}
@@ -486,9 +486,9 @@ SECTION_VALUE_CHARS ([^$\n\r;"'\]\\]|("\\"{ANY_CHAR})|{LITERAL_DOLLAR})
<INITIAL>{TABS_AND_SPACES}*[=]{TABS_AND_SPACES}* { /* Start option value */
if (SCNG(scanner_mode) == ZEND_INI_SCANNER_RAW) {
- yy_push_state(ST_RAW TSRMLS_CC);
+ yy_push_state(ST_RAW);
} else {
- yy_push_state(ST_VALUE TSRMLS_CC);
+ yy_push_state(ST_VALUE);
}
return '=';
}
@@ -571,12 +571,12 @@ end_raw_value_chars:
}
<ST_SECTION_VALUE,ST_VALUE,ST_OFFSET>{TABS_AND_SPACES}*["] { /* Double quoted '"' string start */
- yy_push_state(ST_DOUBLE_QUOTES TSRMLS_CC);
+ yy_push_state(ST_DOUBLE_QUOTES);
return '"';
}
<ST_DOUBLE_QUOTES>["]{TABS_AND_SPACES}* { /* Double quoted '"' string ends */
- yy_pop_state(TSRMLS_C);
+ yy_pop_state();
return '"';
}
@@ -612,7 +612,7 @@ end_raw_value_chars:
yyleng = YYCURSOR - SCNG(yy_text);
- zend_ini_escape_string(ini_lval, yytext, yyleng, '"' TSRMLS_CC);
+ zend_ini_escape_string(ini_lval, yytext, yyleng, '"');
return TC_QUOTED_STRING;
}
@@ -637,7 +637,7 @@ end_raw_value_chars:
}
<INITIAL>{TABS_AND_SPACES}*[#][^\r\n]*{NEWLINE} { /* #Comment */
- zend_error(E_DEPRECATED, "Comments starting with '#' are deprecated in %s on line %d", zend_ini_scanner_get_filename(TSRMLS_C), SCNG(lineno));
+ zend_error(E_DEPRECATED, "Comments starting with '#' are deprecated in %s on line %d", zend_ini_scanner_get_filename(), SCNG(lineno));
BEGIN(INITIAL);
SCNG(lineno)++;
return END_OF_LINE;