Merge branch 'PHP-5.4' into PHP-5.5

* PHP-5.4:
  Fixed compiler reenterability
  Fixed compiler reenterability

Conflicts:
	Zend/zend_language_scanner.c
	Zend/zend_language_scanner_defs.h
This commit is contained in:
Dmitry Stogov 2012-11-14 18:03:38 +04:00
commit ba8a06fd95
4 changed files with 351 additions and 346 deletions

View File

@ -219,6 +219,7 @@ ZEND_API void file_handle_dtor(zend_file_handle *fh) /* {{{ */
void init_compiler(TSRMLS_D) /* {{{ */
{
CG(active_op_array) = NULL;
memset(&CG(context), 0, sizeof(CG(context)));
zend_init_compiler_data_structures(TSRMLS_C);
zend_init_rsrc_list(TSRMLS_C);
zend_hash_init(&CG(filenames_table), 5, NULL, (dtor_func_t) free_estring, 0);

File diff suppressed because it is too large Load Diff

View File

@ -580,6 +580,7 @@ ZEND_API zend_op_array *compile_file(zend_file_handle *file_handle, int type TSR
init_op_array(op_array, ZEND_USER_FUNCTION, INITIAL_OP_ARRAY_SIZE TSRMLS_CC);
CG(in_compilation) = 1;
CG(active_op_array) = op_array;
zend_stack_push(&CG(context_stack), (void *) &CG(context), sizeof(CG(context)));
zend_init_compiler_context(TSRMLS_C);
compiler_result = zendparse(TSRMLS_C);
zend_do_return(&retval_znode, 0 TSRMLS_CC);
@ -749,6 +750,7 @@ zend_op_array *compile_string(zval *source_string, char *filename TSRMLS_DC)
init_op_array(op_array, ZEND_EVAL_CODE, INITIAL_OP_ARRAY_SIZE TSRMLS_CC);
CG(interactive) = orig_interactive;
CG(active_op_array) = op_array;
zend_stack_push(&CG(context_stack), (void *) &CG(context), sizeof(CG(context)));
zend_init_compiler_context(TSRMLS_C);
BEGIN(ST_IN_SCRIPTING);
compiler_result = zendparse(TSRMLS_C);

View File

@ -1,4 +1,4 @@
/* Generated by re2c 0.13.5 on Mon Aug 20 13:34:50 2012 */
/* Generated by re2c 0.13.5 on Wed Nov 14 17:50:16 2012 */
#line 3 "Zend/zend_language_scanner_defs.h"
enum YYCONDTYPE {