diff --git a/.gitignore b/.gitignore index a57365df537..eb2e7016874 100644 --- a/.gitignore +++ b/.gitignore @@ -199,3 +199,4 @@ ext/phalcon/annotations/lemon.dSYM/ ext/phalcon/annotations/parser.out ext/phalcon/mvc/model/query/lemon ext/phalcon/mvc/model/query/parser.out +vendor/ diff --git a/CHANGELOG.md b/CHANGELOG.md index f1af035e6ef..c46f87d6fd4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,27 @@ +# [2.0.7](https://github.com/phalcon/cphalcon/releases/tag/phalcon-v2.0.7) (2015-08-17) +- `Image\Adapter\Gd::save()` no longer fails if the method or the instance is created with a filename without an extension +- Fixed segfault in `Image\Adapter\Imagick::text()` +- Exceptions thrown in Volt compiler are now `Phalcon\Mvc\View\Engine\Exception` +- Now you can import macros from other files using `{% include "file.volt" %}` +- Undefined function calls fall back to macro calls in Volt +- Automatic bound parameters in `Mvc\Model\Criteria` now uses a different prefix +than `Mvc\Model\Query\Builder` to avoid collissions +- Added `Cache\Multiple::flush()` to flush the cache backends added to the multiple system +- Fixed `Session\Bag::remove()` +- `Session\Bag::destroy()` eliminates any temporary data in the variables bag +- `afterCreate`/`afterUpdate` are only called if saving related records was successful +- Added an optional parameter removeData to `Session\Adapter::remove()` to remove any data in `$_SESSION` that +belongs to the uniqueId or the whole session data +- Now session variables making use of unique prefixes use `#` as internal separator +- Added parameter the changing operator for conditions in method `Mvc\Model\Criteria::fromImput()` [#10749](https://github.com/phalcon/cphalcon/issues/10749) +- Added `\Phalcon\Queue\Beanstalk::listTubes()` to get list of a tubes +- Added a fix to avoid that a table present in many sub-queries causes invalid SQL generation +- Add `CookieInterface`, update `Cookie` and `Cookies` to use this interface - Decoupling `Cookies` and `Cookie` - Check `Session` state before using it in `Cookie`. [#10789](https://github.com/phalcon/cphalcon/issues/10789) +- Fixed merge of `Phalcon\Config` instances containing objects different than `Phalcon\Config` compatible instances +- When creating tables in Postgres, inline PRIMARY keys are now escaped properly[#10797](https://github.com/phalcon/cphalcon/pull/10797) +- Fixed incorrect generation of `SELECT COUNT(\*)` causing unexpected exceptions when `phqlLiterals` is disabled +- Added `Phalcon\Security\Random` - secure random number generator class. Provides secure random number generator which is suitable for generating session key in HTTP cookies, etc + # [2.0.6](https://github.com/phalcon/cphalcon/releases/tag/phalcon-v2.0.6) (2015-07-21) - Builds in TravisCI now uses Docker to perform faster builds - Added `Http\Response::setCache()` to easily set cache headers. @@ -8,7 +32,7 @@ - Errors generated in `Cache\Backend\Memcached` now shows the result code to easily debug problems - Fixed `LIMIT/OFFSET` SQL generation in `Mvc\Model\Query\Builder` - Fixed Logger\Formatter\Line to match 1.3.x behavior -- Fixed warning when castOnHydrate' is true [#10648](https://github.com/phalcon/cphalcon/pull/10648) +- Fixed warning when 'castOnHydrate' is true [#10648](https://github.com/phalcon/cphalcon/pull/10648) - Added name before int/float/numeric/string/bool/null/other variables in Debug\Dump::output - Now `Validation\Validator\Identical` allows both 'accepted' and 'value' as value to keep backwards compatibility - Added `\Phalcon\Mvc\Model\MetaData\Redis` adapter. diff --git a/build/32bits/phalcon.zep.c b/build/32bits/phalcon.zep.c index f03e012a1f9..e17ef2cdf8d 100644 --- a/build/32bits/phalcon.zep.c +++ b/build/32bits/phalcon.zep.c @@ -248,23 +248,23 @@ PHP includes the Zend Engine, freely available at #define PHQL_IDENTIFIER 30 #define PHQL_DOT 31 #define PHQL_AS 32 -#define PHQL_WITH 33 -#define PHQL_INNER 34 -#define PHQL_JOIN 35 -#define PHQL_CROSS 36 -#define PHQL_LEFT 37 -#define PHQL_OUTER 38 -#define PHQL_RIGHT 39 -#define PHQL_FULL 40 -#define PHQL_ON 41 -#define PHQL_INSERT 42 -#define PHQL_INTO 43 -#define PHQL_VALUES 44 -#define PHQL_PARENTHESES_OPEN 45 -#define PHQL_PARENTHESES_CLOSE 46 -#define PHQL_UPDATE 47 -#define PHQL_SET 48 -#define PHQL_DELETE 49 +#define PHQL_INNER 33 +#define PHQL_JOIN 34 +#define PHQL_CROSS 35 +#define PHQL_LEFT 36 +#define PHQL_OUTER 37 +#define PHQL_RIGHT 38 +#define PHQL_FULL 39 +#define PHQL_ON 40 +#define PHQL_INSERT 41 +#define PHQL_INTO 42 +#define PHQL_VALUES 43 +#define PHQL_PARENTHESES_OPEN 44 +#define PHQL_PARENTHESES_CLOSE 45 +#define PHQL_UPDATE 46 +#define PHQL_SET 47 +#define PHQL_DELETE 48 +#define PHQL_WITH 49 #define PHQL_WHERE 50 #define PHQL_ORDER 51 #define PHQL_BY 52 @@ -3765,10 +3765,19 @@ static void zephir_concat_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) #include #include +double zephir_sin(zval *op1 TSRMLS_DC); +double zephir_asin(zval *op1 TSRMLS_DC); +double zephir_tan(zval *op1 TSRMLS_DC); +double zephir_cos(zval *op1 TSRMLS_DC); +double zephir_acos(zval *op1 TSRMLS_DC); +double zephir_sqrt(zval *op1 TSRMLS_DC); + double zephir_floor(zval *op1 TSRMLS_DC); double zephir_ceil(zval *op1 TSRMLS_DC); + static void zephir_round(zval *return_value, zval *op1, zval *op2, zval *op3 TSRMLS_DC); static void zephir_pow(zval *return_value, zval *op1, zval *op2 TSRMLS_DC); + long zephir_mt_rand(long min, long max TSRMLS_DC); #endif @@ -16302,6 +16311,96 @@ double zephir_floor(zval *op1 TSRMLS_DC) return floor(zephir_get_numberval(op1)); } +double zephir_sin(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return sin(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return sin(zephir_get_numberval(op1)); +} + +double zephir_asin(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return asin(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return asin(zephir_get_numberval(op1)); +} + +double zephir_cos(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return cos(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return cos(zephir_get_numberval(op1)); +} + +double zephir_acos(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return acos(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return acos(zephir_get_numberval(op1)); +} + +double zephir_sqrt(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return sqrt(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return sqrt(zephir_get_numberval(op1)); +} + +double zephir_tan(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return tan(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return tan(zephir_get_numberval(op1)); +} + double zephir_ceil(zval *op1 TSRMLS_DC) { @@ -16397,6 +16496,8 @@ static void zephir_pow_function_ex(zval *return_value, zval *zbase, zval *zexp T } #endif + + long zephir_mt_rand(long min, long max TSRMLS_DC) { long number; @@ -17626,7 +17727,7 @@ static PHP_METHOD(phalcon_0__closure, __invoke) { zephir_array_fetch_long(&_0, matches, 1, PH_NOISY | PH_READONLY, "phalcon/text.zep", 272 TSRMLS_CC); ZEPHIR_INIT_VAR(words); zephir_fast_explode_str(words, SL("|"), _0, LONG_MAX TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 442, words); + ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 441, words); zephir_check_call_status(); zephir_array_fetch(&_1, words, _2, PH_NOISY | PH_READONLY, "phalcon/text.zep", 273 TSRMLS_CC); RETURN_CTOR(_1); @@ -17729,7 +17830,7 @@ static PHP_METHOD(Phalcon_Config, offsetExists) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); RETURN_MM_BOOL(zephir_isset_property_zval(this_ptr, index TSRMLS_CC)); @@ -17750,7 +17851,7 @@ static PHP_METHOD(Phalcon_Config, get) { } - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); if (zephir_isset_property_zval(this_ptr, index TSRMLS_CC)) { @@ -17774,7 +17875,7 @@ static PHP_METHOD(Phalcon_Config, offsetGet) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); ZEPHIR_OBS_VAR(_1); @@ -17794,13 +17895,13 @@ static PHP_METHOD(Phalcon_Config, offsetSet) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); if (Z_TYPE_P(value) == IS_ARRAY) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_config_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 21, value); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 22, value); zephir_check_call_status(); zephir_update_property_zval_zval(this_ptr, index, _1 TSRMLS_CC); } else { @@ -17821,7 +17922,7 @@ static PHP_METHOD(Phalcon_Config, offsetUnset) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); zephir_update_property_zval_zval(this_ptr, index, ZEPHIR_GLOBAL(global_null) TSRMLS_CC); @@ -17839,7 +17940,7 @@ static PHP_METHOD(Phalcon_Config, merge) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_merge", NULL, 22, config); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_merge", NULL, 23, config); zephir_check_call_status(); RETURN_MM(); @@ -17856,7 +17957,7 @@ static PHP_METHOD(Phalcon_Config, toArray) { ZEPHIR_INIT_VAR(arrayConfig); array_init(arrayConfig); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, this_ptr); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/config.zep", 180); for ( @@ -17888,7 +17989,7 @@ static PHP_METHOD(Phalcon_Config, count) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, this_ptr); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM_LONG(zephir_fast_count_int(_0 TSRMLS_CC)); @@ -17908,7 +18009,7 @@ static PHP_METHOD(Phalcon_Config, __set_state) { object_init_ex(return_value, phalcon_config_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 21, data); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 22, data); zephir_check_call_status(); RETURN_MM(); @@ -17916,12 +18017,12 @@ static PHP_METHOD(Phalcon_Config, __set_state) { static PHP_METHOD(Phalcon_Config, _merge) { - zephir_fcall_cache_entry *_8 = NULL, *_9 = NULL; + zephir_fcall_cache_entry *_6 = NULL, *_7 = NULL; zend_bool _4, _5; HashTable *_2; HashPosition _1; int ZEPHIR_LAST_CALL_STATUS; - zval *config, *instance = NULL, *key = NULL, *value = NULL, *number = NULL, *_0 = NULL, **_3, *_6 = NULL, *_7 = NULL; + zval *config, *instance = NULL, *key = NULL, *value = NULL, *number = NULL, *localObject = NULL, *_0 = NULL, **_3; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 1, 1, &config, &instance); @@ -17938,39 +18039,40 @@ static PHP_METHOD(Phalcon_Config, _merge) { } ZEPHIR_CALL_METHOD(&number, instance, "count", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, config); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, config); zephir_check_call_status(); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/config.zep", 239); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/config.zep", 245); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) ) { ZEPHIR_GET_HMKEY(key, _2, _1); ZEPHIR_GET_HVALUE(value, _3); - _4 = zephir_isset_property_zval(instance, key TSRMLS_CC); - if (_4) { - _4 = Z_TYPE_P(value) == IS_OBJECT; - } - _5 = _4; - if (_5) { - ZEPHIR_OBS_NVAR(_6); - zephir_read_property_zval(&_6, instance, key, PH_NOISY_CC); - _5 = Z_TYPE_P(_6) == IS_OBJECT; + ZEPHIR_OBS_NVAR(localObject); + if (zephir_fetch_property_zval(&localObject, instance, key, PH_SILENT_CC)) { + _4 = Z_TYPE_P(localObject) == IS_OBJECT; + if (_4) { + _4 = Z_TYPE_P(value) == IS_OBJECT; + } + if (_4) { + _5 = zephir_instance_of_ev(localObject, phalcon_config_ce TSRMLS_CC); + if (_5) { + _5 = zephir_instance_of_ev(value, phalcon_config_ce TSRMLS_CC); + } + if (_5) { + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_merge", &_6, 23, value, localObject); + zephir_check_call_status(); + continue; + } + } } - if (_5) { - ZEPHIR_OBS_NVAR(_7); - zephir_read_property_zval(&_7, instance, key, PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_merge", &_8, 22, value, _7); + if (Z_TYPE_P(key) == IS_LONG) { + ZEPHIR_CALL_FUNCTION(&key, "strval", &_7, 21, number); zephir_check_call_status(); - } else { - if (Z_TYPE_P(key) == IS_LONG) { - ZEPHIR_CALL_FUNCTION(&key, "strval", &_9, 20, number); - zephir_check_call_status(); - ZEPHIR_SEPARATE(number); - zephir_increment(number); - } - zephir_update_property_zval_zval(instance, key, value TSRMLS_CC); + ZEPHIR_SEPARATE(number); + zephir_increment(number); } + zephir_update_property_zval_zval(instance, key, value TSRMLS_CC); } RETVAL_ZVAL(instance, 1, 0); RETURN_MM(); @@ -18196,15 +18298,15 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 1) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (paddingSize - 1)); - ZEPHIR_CALL_FUNCTION(&_4, "str_repeat", &_5, 129, _2, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "str_repeat", &_5, 131, _2, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(padding); ZEPHIR_CONCAT_VV(padding, _4, _6); @@ -18213,11 +18315,11 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 2) { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 129, _2, &_1); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 131, _2, &_1); zephir_check_call_status(); break; } @@ -18238,16 +18340,16 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { _7 = 1; } i = _8; - ZEPHIR_CALL_FUNCTION(&_2, "rand", &_10, 107); + ZEPHIR_CALL_FUNCTION(&_2, "rand", &_10, 109); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 128, _2); + ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 130, _2); zephir_check_call_status(); zephir_concat_self(&padding, _4 TSRMLS_CC); } } ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 130, &_1); zephir_check_call_status(); zephir_concat_self(&padding, _6 TSRMLS_CC); break; @@ -18255,15 +18357,15 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 4) { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 0x80); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (paddingSize - 1)); - ZEPHIR_CALL_FUNCTION(&_6, "str_repeat", &_5, 129, _4, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "str_repeat", &_5, 131, _4, &_1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(padding); ZEPHIR_CONCAT_VV(padding, _2, _6); @@ -18272,11 +18374,11 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 5) { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 129, _2, &_1); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 131, _2, &_1); zephir_check_call_status(); break; } @@ -18285,7 +18387,7 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { ZVAL_STRING(&_1, " ", 0); ZEPHIR_SINIT_VAR(_11); ZVAL_LONG(&_11, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 129, &_1, &_11); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 131, &_1, &_11); zephir_check_call_status(); break; } @@ -18373,18 +18475,18 @@ static PHP_METHOD(Phalcon_Crypt, _cryptUnpadText) { ZVAL_LONG(&_4, 1); ZEPHIR_INIT_VAR(last); zephir_substr(last, text, zephir_get_intval(&_3), 1 , 0); - ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 130, last); + ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 132, last); zephir_check_call_status(); ord = zephir_get_intval(_5); if (ord <= blockSize) { paddingSize = ord; ZEPHIR_SINIT_VAR(_7); ZVAL_LONG(&_7, 0); - ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 128, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 130, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, (paddingSize - 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, _8, &_7); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, _8, &_7); zephir_check_call_status(); ZEPHIR_INIT_VAR(padding); ZEPHIR_CONCAT_VV(padding, _10, last); @@ -18405,18 +18507,18 @@ static PHP_METHOD(Phalcon_Crypt, _cryptUnpadText) { ZVAL_LONG(&_4, 1); ZEPHIR_INIT_NVAR(last); zephir_substr(last, text, zephir_get_intval(&_3), 1 , 0); - ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 130, last); + ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 132, last); zephir_check_call_status(); ord = zephir_get_intval(_5); if (ord <= blockSize) { paddingSize = ord; ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, paddingSize); - ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 128, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 130, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_11, 129, _8, &_7); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_11, 131, _8, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, (length - paddingSize)); @@ -18435,7 +18537,7 @@ static PHP_METHOD(Phalcon_Crypt, _cryptUnpadText) { ZVAL_LONG(&_4, 1); ZEPHIR_INIT_NVAR(last); zephir_substr(last, text, zephir_get_intval(&_3), 1 , 0); - ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 130, last); + ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 132, last); zephir_check_call_status(); paddingSize = zephir_get_intval(_5); break; @@ -18591,7 +18693,7 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) { zephir_read_property_this(&cipher, this_ptr, SL("_cipher"), PH_NOISY_CC); ZEPHIR_OBS_VAR(mode); zephir_read_property_this(&mode, this_ptr, SL("_mode"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 131, cipher, mode); + ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 133, cipher, mode); zephir_check_call_status(); if (ZEPHIR_LT_LONG(ivSize, zephir_fast_strlen_ev(encryptKey))) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 320); @@ -18599,14 +18701,14 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) { } ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 2); - ZEPHIR_CALL_FUNCTION(&iv, "mcrypt_create_iv", NULL, 132, ivSize, &_0); + ZEPHIR_CALL_FUNCTION(&iv, "mcrypt_create_iv", NULL, 134, ivSize, &_0); zephir_check_call_status(); if (Z_TYPE_P(iv) != IS_STRING) { - ZEPHIR_CALL_FUNCTION(&_1, "strval", NULL, 20, iv); + ZEPHIR_CALL_FUNCTION(&_1, "strval", NULL, 21, iv); zephir_check_call_status(); ZEPHIR_CPY_WRT(iv, _1); } - ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 133, cipher, mode); + ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 135, cipher, mode); zephir_check_call_status(); if (Z_TYPE_P(blockSize) != IS_LONG) { _2 = zephir_get_intval(blockSize); @@ -18629,7 +18731,7 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) { } else { ZEPHIR_CPY_WRT(padded, text); } - ZEPHIR_CALL_FUNCTION(&_1, "mcrypt_encrypt", NULL, 134, cipher, encryptKey, padded, mode, iv); + ZEPHIR_CALL_FUNCTION(&_1, "mcrypt_encrypt", NULL, 136, cipher, encryptKey, padded, mode, iv); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, iv, _1); RETURN_MM(); @@ -18680,7 +18782,7 @@ static PHP_METHOD(Phalcon_Crypt, decrypt) { zephir_read_property_this(&cipher, this_ptr, SL("_cipher"), PH_NOISY_CC); ZEPHIR_OBS_VAR(mode); zephir_read_property_this(&mode, this_ptr, SL("_mode"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 131, cipher, mode); + ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 133, cipher, mode); zephir_check_call_status(); ZEPHIR_INIT_VAR(keySize); ZVAL_LONG(keySize, zephir_fast_strlen_ev(decryptKey)); @@ -18700,9 +18802,9 @@ static PHP_METHOD(Phalcon_Crypt, decrypt) { ZVAL_LONG(&_1, 0); ZEPHIR_INIT_VAR(_2); zephir_substr(_2, text, 0 , zephir_get_intval(ivSize), 0); - ZEPHIR_CALL_FUNCTION(&decrypted, "mcrypt_decrypt", NULL, 135, cipher, decryptKey, _0, mode, _2); + ZEPHIR_CALL_FUNCTION(&decrypted, "mcrypt_decrypt", NULL, 137, cipher, decryptKey, _0, mode, _2); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 133, cipher, mode); + ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 135, cipher, mode); zephir_check_call_status(); ZEPHIR_OBS_VAR(paddingType); zephir_read_property_this(&paddingType, this_ptr, SL("_padding"), PH_NOISY_CC); @@ -18759,19 +18861,19 @@ static PHP_METHOD(Phalcon_Crypt, encryptBase64) { if (safe == 1) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "encrypt", &_1, 0, text, key); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_2, "base64_encode", &_3, 112, _0); + ZEPHIR_CALL_FUNCTION(&_2, "base64_encode", &_3, 114, _0); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "+/", 0); ZEPHIR_SINIT_VAR(_5); ZVAL_STRING(&_5, "-_", 0); - ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 53, _2, &_4, &_5); + ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 54, _2, &_4, &_5); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_CALL_METHOD(&_0, this_ptr, "encrypt", &_1, 0, text, key); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", &_3, 112, _0); + ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", &_3, 114, _0); zephir_check_call_status(); RETURN_MM(); @@ -18819,15 +18921,15 @@ static PHP_METHOD(Phalcon_Crypt, decryptBase64) { ZVAL_STRING(&_0, "-_", 0); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "+/", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, text, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, text, &_0, &_1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_3, "base64_decode", &_4, 113, _2); + ZEPHIR_CALL_FUNCTION(&_3, "base64_decode", &_4, 115, _2); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "decrypt", &_5, 0, _3, key); zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_CALL_FUNCTION(&_2, "base64_decode", &_4, 113, text); + ZEPHIR_CALL_FUNCTION(&_2, "base64_decode", &_4, 115, text); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "decrypt", &_5, 0, _2, key); zephir_check_call_status(); @@ -18841,7 +18943,7 @@ static PHP_METHOD(Phalcon_Crypt, getAvailableCiphers) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_algorithms", NULL, 136); + ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_algorithms", NULL, 138); zephir_check_call_status(); RETURN_MM(); @@ -18853,7 +18955,7 @@ static PHP_METHOD(Phalcon_Crypt, getAvailableModes) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_modes", NULL, 137); + ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_modes", NULL, 139); zephir_check_call_status(); RETURN_MM(); @@ -19139,7 +19241,7 @@ static PHP_METHOD(Phalcon_Debug, listenExceptions) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "onUncaughtException", 1); zephir_array_fast_append(_0, _1); - ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _0); + ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 149, _0); zephir_check_call_status(); RETURN_THIS(); @@ -19159,7 +19261,7 @@ static PHP_METHOD(Phalcon_Debug, listenLowSeverity) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "onUncaughtLowSeverity", 1); zephir_array_fast_append(_0, _1); - ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 149, _0); + ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 150, _0); zephir_check_call_status(); ZEPHIR_INIT_VAR(_2); zephir_create_array(_2, 2, 0 TSRMLS_CC); @@ -19167,7 +19269,7 @@ static PHP_METHOD(Phalcon_Debug, listenLowSeverity) { ZEPHIR_INIT_NVAR(_1); ZVAL_STRING(_1, "onUncaughtException", 1); zephir_array_fast_append(_2, _1); - ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _2); + ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 149, _2); zephir_check_call_status(); RETURN_THIS(); @@ -19202,7 +19304,7 @@ static PHP_METHOD(Phalcon_Debug, debugVar) { ZEPHIR_INIT_VAR(_0); zephir_create_array(_0, 3, 0 TSRMLS_CC); zephir_array_fast_append(_0, varz); - ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 150); + ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 151); zephir_check_call_status(); zephir_array_fast_append(_0, _1); ZEPHIR_INIT_VAR(_2); @@ -19242,7 +19344,7 @@ static PHP_METHOD(Phalcon_Debug, _escapeString) { ZVAL_LONG(&_3, 2); ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "utf-8", 0); - ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 151, _0, &_3, &_4); + ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 152, _0, &_3, &_4); zephir_check_call_status(); RETURN_MM(); } @@ -19293,7 +19395,7 @@ static PHP_METHOD(Phalcon_Debug, _getArrayDump) { ) { ZEPHIR_GET_HMKEY(k, _2, _1); ZEPHIR_GET_HVALUE(v, _3); - ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 152, v); + ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 153, v); zephir_check_call_status(); if (zephir_is_true(_4)) { ZEPHIR_INIT_NVAR(varDump); @@ -19310,7 +19412,7 @@ static PHP_METHOD(Phalcon_Debug, _getArrayDump) { if (Z_TYPE_P(v) == IS_ARRAY) { ZEPHIR_INIT_NVAR(_8); ZVAL_LONG(_8, (zephir_get_numberval(n) + 1)); - ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 153, v, _8); + ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 154, v, _8); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVSVS(_10, "[", k, "] => Array(", _6, ")"); @@ -19351,7 +19453,7 @@ static PHP_METHOD(Phalcon_Debug, _getVarDump) { - ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 152, variable); + ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 153, variable); zephir_check_call_status(); if (zephir_is_true(_0)) { if (Z_TYPE_P(variable) == IS_BOOL) { @@ -19385,7 +19487,7 @@ static PHP_METHOD(Phalcon_Debug, _getVarDump) { } } if (Z_TYPE_P(variable) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 153, variable); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 154, variable); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "Array(", _1, ")"); RETURN_MM(); @@ -19406,7 +19508,7 @@ static PHP_METHOD(Phalcon_Debug, getMajorVersion) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 154); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 155); zephir_check_call_status(); ZEPHIR_INIT_VAR(parts); zephir_fast_explode_str(parts, SL(" "), _0, LONG_MAX TSRMLS_CC); @@ -19425,7 +19527,7 @@ static PHP_METHOD(Phalcon_Debug, getVersion) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmajorversion", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 154); + ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 155); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "
Phalcon Framework ", _1, "
"); RETURN_MM(); @@ -19517,9 +19619,9 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) { } else { ZEPHIR_INIT_VAR(classReflection); object_init_ex(classReflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, classReflection, "__construct", NULL, 62, className); + ZEPHIR_CALL_METHOD(NULL, classReflection, "__construct", NULL, 64, className); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 155); + ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 156); zephir_check_call_status(); if (zephir_is_true(_8)) { ZEPHIR_INIT_VAR(_9); @@ -19552,9 +19654,9 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) { if ((zephir_function_exists(functionName TSRMLS_CC) == SUCCESS)) { ZEPHIR_INIT_VAR(functionReflection); object_init_ex(functionReflection, zephir_get_internal_ce(SS("reflectionfunction") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 156, functionName); + ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 157, functionName); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 157); + ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 158); zephir_check_call_status(); if (zephir_is_true(_8)) { ZEPHIR_SINIT_NVAR(_4); @@ -19615,7 +19717,7 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) { ZEPHIR_OBS_VAR(showFiles); zephir_read_property_this(&showFiles, this_ptr, SL("_showFiles"), PH_NOISY_CC); if (zephir_is_true(showFiles)) { - ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 158, filez); + ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 159, filez); zephir_check_call_status(); ZEPHIR_INIT_VAR(numberLines); ZVAL_LONG(numberLines, zephir_fast_count_int(lines TSRMLS_CC)); @@ -19698,7 +19800,7 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) { ZVAL_LONG(&_23, 2); ZEPHIR_SINIT_NVAR(_25); ZVAL_STRING(&_25, "UTF-8", 0); - ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_26, 151, _21, &_23, &_25); + ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_26, 152, _21, &_23, &_25); zephir_check_call_status(); zephir_concat_self(&html, _8 TSRMLS_CC); } @@ -19722,7 +19824,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) { - ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 159); + ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 160); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_1); zephir_bitwise_and_function(&_1, _0, severity TSRMLS_CC); @@ -19731,7 +19833,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) { object_init_ex(_2, zephir_get_internal_ce(SS("errorexception") TSRMLS_CC)); ZEPHIR_INIT_VAR(_3); ZVAL_LONG(_3, 0); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 160, message, _3, severity, file, line); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 161, message, _3, severity, file, line); zephir_check_call_status(); zephir_throw_exception_debug(_2, "phalcon/debug.zep", 566 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -19756,10 +19858,10 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) { - ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 161); + ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 162); zephir_check_call_status(); if (ZEPHIR_GT_LONG(obLevel, 0)) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); } _0 = zephir_fetch_static_property_ce(phalcon_debug_ce, SL("_isActive") TSRMLS_CC); @@ -19823,7 +19925,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) { ) { ZEPHIR_GET_HMKEY(n, _11, _10); ZEPHIR_GET_HVALUE(traceItem, _12); - ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 162, n, traceItem); + ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 163, n, traceItem); zephir_check_call_status(); zephir_concat_self(&html, _13 TSRMLS_CC); } @@ -19842,7 +19944,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) { ZEPHIR_CONCAT_SVSVS(_18, "", keyRequest, "", value, ""); zephir_concat_self(&html, _18 TSRMLS_CC); } else { - ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 163, value, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 164, value, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_18); ZEPHIR_CONCAT_SVSVS(_18, "", keyRequest, "", _13, ""); @@ -19868,7 +19970,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) { zephir_concat_self_str(&html, SL("") TSRMLS_CC); zephir_concat_self_str(&html, SL("
") TSRMLS_CC); zephir_concat_self_str(&html, SL("") TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 164); + ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 165); zephir_check_call_status(); zephir_is_iterable(_13, &_25, &_24, 0, 0, "phalcon/debug.zep", 694); for ( @@ -19883,7 +19985,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) { } zephir_concat_self_str(&html, SL("
#Path
") TSRMLS_CC); zephir_concat_self_str(&html, SL("
") TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 165, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 166, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_27); ZEPHIR_CONCAT_SVS(_27, ""); @@ -20018,7 +20120,7 @@ static PHP_METHOD(Phalcon_Di, set) { ZEPHIR_INIT_VAR(service); object_init_ex(service, phalcon_di_service_ce); - ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 61, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 63, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_services"), name, service TSRMLS_CC); RETURN_CCTOR(service); @@ -20051,7 +20153,7 @@ static PHP_METHOD(Phalcon_Di, setShared) { object_init_ex(service, phalcon_di_service_ce); ZEPHIR_SINIT_VAR(_0); ZVAL_BOOL(&_0, 1); - ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 61, name, definition, &_0); + ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 63, name, definition, &_0); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_services"), name, service TSRMLS_CC); RETURN_CCTOR(service); @@ -20119,7 +20221,7 @@ static PHP_METHOD(Phalcon_Di, attempt) { if (!(zephir_array_isset(_0, name))) { ZEPHIR_INIT_VAR(service); object_init_ex(service, phalcon_di_service_ce); - ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 61, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 63, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_services"), name, service TSRMLS_CC); RETURN_CCTOR(service); @@ -20287,7 +20389,7 @@ static PHP_METHOD(Phalcon_Di, get) { ZEPHIR_CONCAT_SVS(_3, "Service '", name, "' wasn't found in the dependency injection container"); ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/di.zep", 229 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/di.zep", 230 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -20296,9 +20398,9 @@ static PHP_METHOD(Phalcon_Di, get) { if (zephir_is_php_version(50600)) { ZEPHIR_INIT_VAR(reflection); object_init_ex(reflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 62, name); + ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 64, name); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&instance, reflection, "newinstanceargs", NULL, 63, parameters); + ZEPHIR_CALL_METHOD(&instance, reflection, "newinstanceargs", NULL, 65, parameters); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(instance); @@ -20309,9 +20411,9 @@ static PHP_METHOD(Phalcon_Di, get) { if (zephir_is_php_version(50600)) { ZEPHIR_INIT_NVAR(reflection); object_init_ex(reflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 62, name); + ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 64, name); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 64); + ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 66); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(instance); @@ -20323,9 +20425,9 @@ static PHP_METHOD(Phalcon_Di, get) { if (zephir_is_php_version(50600)) { ZEPHIR_INIT_NVAR(reflection); object_init_ex(reflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 62, name); + ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 64, name); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 64); + ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 66); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(instance); @@ -20577,7 +20679,7 @@ static PHP_METHOD(Phalcon_Di, __call) { ZVAL_LONG(&_0, 3); ZEPHIR_INIT_VAR(_1); zephir_substr(_1, method, 3 , 0, ZEPHIR_SUBSTR_NO_LENGTH); - ZEPHIR_CALL_FUNCTION(&possibleService, "lcfirst", &_2, 65, _1); + ZEPHIR_CALL_FUNCTION(&possibleService, "lcfirst", &_2, 67, _1); zephir_check_call_status(); if (zephir_array_isset(services, possibleService)) { if (zephir_fast_count_int(arguments TSRMLS_CC)) { @@ -20597,7 +20699,7 @@ static PHP_METHOD(Phalcon_Di, __call) { ZVAL_LONG(&_0, 3); ZEPHIR_INIT_NVAR(_1); zephir_substr(_1, method, 3 , 0, ZEPHIR_SUBSTR_NO_LENGTH); - ZEPHIR_CALL_FUNCTION(&_4, "lcfirst", &_2, 65, _1); + ZEPHIR_CALL_FUNCTION(&_4, "lcfirst", &_2, 67, _1); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, this_ptr, "set", NULL, 0, _4, definition); zephir_check_call_status(); @@ -20610,7 +20712,7 @@ static PHP_METHOD(Phalcon_Di, __call) { ZEPHIR_CONCAT_SVS(_5, "Call to undefined method or service '", method, "'"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _5); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/di.zep", 427 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/di.zep", 428 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -21646,13 +21748,13 @@ static PHP_METHOD(Phalcon_Escaper, detectEncoding) { ; zephir_hash_move_forward_ex(_3, &_2) ) { ZEPHIR_GET_HVALUE(charset, _4); - ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 178, str, charset, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 179, str, charset, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); if (zephir_is_true(_5)) { RETURN_CCTOR(charset); } } - ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 178, str); + ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 179, str); zephir_check_call_status(); RETURN_MM(); @@ -21674,11 +21776,11 @@ static PHP_METHOD(Phalcon_Escaper, normalizeEncoding) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_escaper_exception_ce, "Extension 'mbstring' is required", "phalcon/escaper.zep", 128); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 179, str); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 180, str); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "UTF-32", 0); - ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, str, &_1, _0); + ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 181, str, &_1, _0); zephir_check_call_status(); RETURN_MM(); @@ -21698,7 +21800,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeHtml) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_htmlQuoteType"), PH_NOISY_CC); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC); - ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, text, _0, _1); + ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 182, text, _0, _1); zephir_check_call_status(); RETURN_MM(); @@ -21719,7 +21821,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeHtmlAttr) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 3); - ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, attribute, &_1, _0); + ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 182, attribute, &_1, _0); zephir_check_call_status(); RETURN_MM(); @@ -21737,7 +21839,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeCss) { zephir_get_strval(css, css_param); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, css); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 183, css); zephir_check_call_status(); zephir_escape_css(return_value, _0); RETURN_MM(); @@ -21756,7 +21858,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeJs) { zephir_get_strval(js, js_param); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, js); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 183, js); zephir_check_call_status(); zephir_escape_js(return_value, _0); RETURN_MM(); @@ -21775,7 +21877,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeUrl) { zephir_get_strval(url, url_param); - ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 183, url); + ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 184, url); zephir_check_call_status(); RETURN_MM(); @@ -22054,16 +22156,16 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { if (ZEPHIR_IS_STRING(filter, "email")) { ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "FILTER_SANITIZE_EMAIL", 0); - ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 191, &_3); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, _4); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, _4); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "int")) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 519); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, &_3); zephir_check_call_status(); RETURN_MM(); } @@ -22073,14 +22175,14 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { if (ZEPHIR_IS_STRING(filter, "absint")) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, zephir_get_intval(value)); - ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 192, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 193, &_3); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "string")) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 513); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, &_3); zephir_check_call_status(); RETURN_MM(); } @@ -22090,7 +22192,7 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { add_assoc_long_ex(_2, SS("flags"), 4096); ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 520); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3, _2); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, &_3, _2); zephir_check_call_status(); RETURN_MM(); } @@ -22102,7 +22204,7 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { ZVAL_STRING(_6, "/[^A-Za-z0-9]/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_FUNCTION("preg_replace", NULL, 28, _6, _7, value); + ZEPHIR_RETURN_CALL_FUNCTION("preg_replace", NULL, 29, _6, _7, value); zephir_check_temp_parameter(_6); zephir_check_temp_parameter(_7); zephir_check_call_status(); @@ -22113,13 +22215,13 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "striptags")) { - ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 193, value); + ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 194, value); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "lower")) { if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, value); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 195, value); zephir_check_call_status(); RETURN_MM(); } @@ -22128,7 +22230,7 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { } if (ZEPHIR_IS_STRING(filter, "upper")) { if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, value); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 196, value); zephir_check_call_status(); RETURN_MM(); } @@ -22909,7 +23011,7 @@ static PHP_METHOD(Phalcon_Loader, register) { ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "autoLoad", 1); zephir_array_fast_append(_1, _2); - ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 293, _1); + ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 286, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_registered"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } @@ -22933,7 +23035,7 @@ static PHP_METHOD(Phalcon_Loader, unregister) { ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "autoLoad", 1); zephir_array_fast_append(_1, _2); - ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 294, _1); + ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 287, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_registered"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } @@ -23041,7 +23143,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) { zephir_check_temp_parameter(_9); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath); + ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 288, filePath); zephir_check_call_status(); if (zephir_is_true(_11)) { if (Z_TYPE_P(eventsManager) == IS_OBJECT) { @@ -23112,7 +23214,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) { zephir_check_temp_parameter(_9); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath); + ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 288, filePath); zephir_check_call_status(); if (zephir_is_true(_11)) { if (Z_TYPE_P(eventsManager) == IS_OBJECT) { @@ -23170,7 +23272,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) { zephir_check_temp_parameter(_9); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath); + ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 288, filePath); zephir_check_call_status(); if (zephir_is_true(_11)) { if (Z_TYPE_P(eventsManager) == IS_OBJECT) { @@ -23423,7 +23525,7 @@ static PHP_METHOD(Phalcon_Registry, next) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 399, _0); + ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 392, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -23439,7 +23541,7 @@ static PHP_METHOD(Phalcon_Registry, key) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 400, _0); + ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 393, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); RETURN_MM(); @@ -23455,7 +23557,7 @@ static PHP_METHOD(Phalcon_Registry, rewind) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 401, _0); + ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 394, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -23471,7 +23573,7 @@ static PHP_METHOD(Phalcon_Registry, valid) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 400, _0); + ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 393, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); RETURN_MM_BOOL(Z_TYPE_P(_1) != IS_NULL); @@ -23487,7 +23589,7 @@ static PHP_METHOD(Phalcon_Registry, current) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 402, _0); + ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 395, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); RETURN_MM(); @@ -23516,7 +23618,7 @@ static PHP_METHOD(Phalcon_Registry, __set) { } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 403, key, value); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 396, key, value); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -23544,7 +23646,7 @@ static PHP_METHOD(Phalcon_Registry, __get) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 404, key); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 397, key); zephir_check_call_status(); RETURN_MM(); @@ -23572,7 +23674,7 @@ static PHP_METHOD(Phalcon_Registry, __isset) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 405, key); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 398, key); zephir_check_call_status(); RETURN_MM(); @@ -23600,7 +23702,7 @@ static PHP_METHOD(Phalcon_Registry, __unset) { } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 406, key); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 399, key); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -23756,9 +23858,9 @@ static PHP_METHOD(Phalcon_Security, getSaltBytes) { ZEPHIR_INIT_NVAR(safeBytes); ZEPHIR_INIT_NVAR(_1); ZVAL_LONG(_1, numberBytes); - ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 407, _1); + ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 400, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "base64_encode", &_5, 112, _2); + ZEPHIR_CALL_FUNCTION(&_4, "base64_encode", &_5, 114, _2); zephir_check_call_status(); zephir_filter_alphanum(safeBytes, _4); if (!(zephir_is_true(safeBytes))) { @@ -23848,7 +23950,7 @@ static PHP_METHOD(Phalcon_Security, hash) { } ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SVSV(_3, "$", variant, "$", saltBytes); - ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3); + ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 401, password, _3); zephir_check_call_status(); RETURN_MM(); } @@ -23871,11 +23973,11 @@ static PHP_METHOD(Phalcon_Security, hash) { ZVAL_STRING(&_5, "%02s", 0); ZEPHIR_SINIT_VAR(_6); ZVAL_LONG(&_6, workFactor); - ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 187, &_5, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 188, &_5, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVSVSV(_3, "$2", variant, "$", _7, "$", saltBytes); - ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3); + ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 401, password, _3); zephir_check_call_status(); RETURN_MM(); } while(0); @@ -23915,7 +24017,7 @@ static PHP_METHOD(Phalcon_Security, checkHash) { RETURN_MM_BOOL(0); } } - ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 408, password, passwordHash); + ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 401, password, passwordHash); zephir_check_call_status(); zephir_get_strval(_2, _1); ZEPHIR_CPY_WRT(cryptedHash, _2); @@ -23979,9 +24081,9 @@ static PHP_METHOD(Phalcon_Security, getTokenKey) { ZEPHIR_INIT_VAR(safeBytes); ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, numberBytes); - ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 407, _1); + ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 400, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_3, "base64_encode", NULL, 112, _2); + ZEPHIR_CALL_FUNCTION(&_3, "base64_encode", NULL, 114, _2); zephir_check_call_status(); zephir_filter_alphanum(safeBytes, _3); ZEPHIR_INIT_NVAR(_1); @@ -24021,9 +24123,9 @@ static PHP_METHOD(Phalcon_Security, getToken) { } ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, numberBytes); - ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 407, _0); + ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 400, _0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "base64_encode", NULL, 112, token); + ZEPHIR_CALL_FUNCTION(&_1, "base64_encode", NULL, 114, token); zephir_check_call_status(); ZEPHIR_CPY_WRT(token, _1); ZEPHIR_INIT_NVAR(_0); @@ -24194,7 +24296,7 @@ static PHP_METHOD(Phalcon_Security, computeHmac) { } - ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 409, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 402, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); if (!(zephir_is_true(hmac))) { ZEPHIR_INIT_VAR(_0); @@ -24985,7 +25087,7 @@ static PHP_METHOD(Phalcon_Tag, colorField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "color", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25005,7 +25107,7 @@ static PHP_METHOD(Phalcon_Tag, textField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "text", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25025,7 +25127,7 @@ static PHP_METHOD(Phalcon_Tag, numericField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "number", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25045,7 +25147,7 @@ static PHP_METHOD(Phalcon_Tag, rangeField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "range", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25065,7 +25167,7 @@ static PHP_METHOD(Phalcon_Tag, emailField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "email", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25085,7 +25187,7 @@ static PHP_METHOD(Phalcon_Tag, dateField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "date", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25105,7 +25207,7 @@ static PHP_METHOD(Phalcon_Tag, dateTimeField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "datetime", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25125,7 +25227,7 @@ static PHP_METHOD(Phalcon_Tag, dateTimeLocalField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "datetime-local", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25145,7 +25247,7 @@ static PHP_METHOD(Phalcon_Tag, monthField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "month", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25165,7 +25267,7 @@ static PHP_METHOD(Phalcon_Tag, timeField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "time", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25185,7 +25287,7 @@ static PHP_METHOD(Phalcon_Tag, weekField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "week", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25205,7 +25307,7 @@ static PHP_METHOD(Phalcon_Tag, passwordField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "password", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25225,7 +25327,7 @@ static PHP_METHOD(Phalcon_Tag, hiddenField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "hidden", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25245,7 +25347,7 @@ static PHP_METHOD(Phalcon_Tag, fileField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "file", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25265,7 +25367,7 @@ static PHP_METHOD(Phalcon_Tag, searchField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "search", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25285,7 +25387,7 @@ static PHP_METHOD(Phalcon_Tag, telField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "tel", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25305,7 +25407,7 @@ static PHP_METHOD(Phalcon_Tag, urlField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "url", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25325,7 +25427,7 @@ static PHP_METHOD(Phalcon_Tag, checkField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "checkbox", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 413, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25345,7 +25447,7 @@ static PHP_METHOD(Phalcon_Tag, radioField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "radio", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 413, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25367,7 +25469,7 @@ static PHP_METHOD(Phalcon_Tag, imageInput) { ZVAL_STRING(_1, "image", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters, _2); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25389,7 +25491,7 @@ static PHP_METHOD(Phalcon_Tag, submitButton) { ZVAL_STRING(_1, "submit", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters, _2); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25410,7 +25512,7 @@ static PHP_METHOD(Phalcon_Tag, selectStatic) { } - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 207, parameters, data); zephir_check_call_status(); RETURN_MM(); @@ -25430,7 +25532,7 @@ static PHP_METHOD(Phalcon_Tag, select) { } - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 207, parameters, data); zephir_check_call_status(); RETURN_MM(); @@ -25934,20 +26036,20 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) { ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "iconv", 0); - ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", &_2, 126, &_0); + ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", &_2, 128, &_0); zephir_check_call_status(); if (zephir_is_true(_1)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "en_US.UTF-8", 0); - ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 415, &_0, &_3); + ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 414, &_0, &_3); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "UTF-8", 0); ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "ASCII//TRANSLIT", 0); - ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 378, &_0, &_3, text); + ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 371, &_0, &_3, text); zephir_check_call_status(); zephir_get_strval(text, _5); } @@ -25985,7 +26087,7 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) { ZVAL_STRING(_11, "/[^a-zA-Z0-9\\/_|+ -]/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_12); ZVAL_STRING(_12, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&friendly, "preg_replace", &_13, 28, _11, _12, text); + ZEPHIR_CALL_FUNCTION(&friendly, "preg_replace", &_13, 29, _11, _12, text); zephir_check_temp_parameter(_11); zephir_check_temp_parameter(_12); zephir_check_call_status(); @@ -25996,7 +26098,7 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) { } ZEPHIR_INIT_NVAR(_11); ZVAL_STRING(_11, "/[\\/_|+ -]+/", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_5, "preg_replace", &_13, 28, _11, separator, friendly); + ZEPHIR_CALL_FUNCTION(&_5, "preg_replace", &_13, 29, _11, separator, friendly); zephir_check_temp_parameter(_11); zephir_check_call_status(); ZEPHIR_CPY_WRT(friendly, _5); @@ -26005,12 +26107,12 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) { ZEPHIR_CPY_WRT(friendly, _11); ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "iconv", 0); - ZEPHIR_CALL_FUNCTION(&_5, "extension_loaded", &_2, 126, &_3); + ZEPHIR_CALL_FUNCTION(&_5, "extension_loaded", &_2, 128, &_3); zephir_check_call_status(); if (zephir_is_true(_5)) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 0); - ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 415, &_3, locale); + ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 414, &_3, locale); zephir_check_call_status(); } RETURN_CCTOR(friendly); @@ -26378,13 +26480,13 @@ static PHP_METHOD(Phalcon_Text, random) { ZVAL_STRING(&_0, "a", 0); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "z", 0); - ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "A", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "Z", 0); - ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_INIT_VAR(pool); zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC); @@ -26395,13 +26497,13 @@ static PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "a", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "f", 0); - ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(pool); zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC); @@ -26412,7 +26514,7 @@ static PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); break; } @@ -26421,7 +26523,7 @@ static PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 1); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); break; } @@ -26429,21 +26531,21 @@ static PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "a", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "z", 0); - ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "A", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "Z", 0); - ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 419, _2, _4, _5); + ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 418, _2, _4, _5); zephir_check_call_status(); break; } while(0); @@ -26547,7 +26649,7 @@ static PHP_METHOD(Phalcon_Text, lower) { if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, str, encoding); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 195, str, encoding); zephir_check_call_status(); RETURN_MM(); } @@ -26595,7 +26697,7 @@ static PHP_METHOD(Phalcon_Text, upper) { if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, str, encoding); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 196, str, encoding); zephir_check_call_status(); RETURN_MM(); } @@ -26620,7 +26722,7 @@ static PHP_METHOD(Phalcon_Text, reduceSlashes) { ZVAL_STRING(_0, "#(?funcs->dtor(_0 TSRMLS_CC); @@ -36378,7 +36504,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_File, __construct) { return; } } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_file_ce, this_ptr, "__construct", &_5, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_file_ce, this_ptr, "__construct", &_5, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -36570,7 +36696,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_File, delete) { ZEPHIR_INIT_VAR(cacheFile); ZEPHIR_CONCAT_VVV(cacheFile, cacheDir, _1, _2); if ((zephir_file_exists(cacheFile TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("unlink", NULL, 104, cacheFile); + ZEPHIR_RETURN_CALL_FUNCTION("unlink", NULL, 106, cacheFile); zephir_check_call_status(); RETURN_MM(); } @@ -36603,7 +36729,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_File, queryKeys) { } ZEPHIR_INIT_VAR(_2); object_init_ex(_2, spl_ce_DirectoryIterator); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 105, cacheDir); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 107, cacheDir); zephir_check_call_status(); _1 = zephir_get_iterator(_2 TSRMLS_CC); _1->funcs->rewind(_1 TSRMLS_CC); @@ -36859,7 +36985,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_File, flush) { } ZEPHIR_INIT_VAR(_2); object_init_ex(_2, spl_ce_DirectoryIterator); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 105, cacheDir); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 107, cacheDir); zephir_check_call_status(); _1 = zephir_get_iterator(_2 TSRMLS_CC); _1->funcs->rewind(_1 TSRMLS_CC); @@ -36881,7 +37007,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_File, flush) { _4 = zephir_start_with(key, prefix, NULL); } if (_4) { - ZEPHIR_CALL_FUNCTION(&_5, "unlink", &_6, 104, cacheFile); + ZEPHIR_CALL_FUNCTION(&_5, "unlink", &_6, 106, cacheFile); zephir_check_call_status(); if (!(zephir_is_true(_5))) { RETURN_MM_BOOL(0); @@ -36989,7 +37115,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Libmemcached, __construct) { ZVAL_STRING(_1, "_PHCM", 1); zephir_array_update_string(&options, SL("statsKey"), &_1, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_libmemcached_ce, this_ptr, "__construct", &_2, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_libmemcached_ce, this_ptr, "__construct", &_2, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -37553,7 +37679,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Memcache, __construct) { ZVAL_STRING(_0, "_PHCM", 1); zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_memcache_ce, this_ptr, "__construct", &_1, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_memcache_ce, this_ptr, "__construct", &_1, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -38374,7 +38500,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Memory, serialize) { ZEPHIR_OBS_VAR(_1); zephir_read_property_this(&_1, this_ptr, SL("_frontend"), PH_NOISY_CC); zephir_array_update_string(&_0, SL("frontend"), &_1, PH_COPY | PH_SEPARATE); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -38390,7 +38516,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Memory, unserialize) { - ZEPHIR_CALL_FUNCTION(&unserialized, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&unserialized, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(unserialized) != IS_ARRAY) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(zend_exception_get_default(TSRMLS_C), "Unserialized data must be an array", "phalcon/cache/backend/memory.zep", 295); @@ -38455,7 +38581,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, __construct) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "The parameter 'collection' is required", "phalcon/cache/backend/mongo.zep", 79); return; } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_mongo_ce, this_ptr, "__construct", &_0, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_mongo_ce, this_ptr, "__construct", &_0, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -38555,7 +38681,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, get) { zephir_time(_2); zephir_array_update_string(&_1, SL("$gt"), &_2, PH_COPY | PH_SEPARATE); zephir_array_update_string(&conditions, SL("time"), &_1, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&document, _3, "findone", NULL, 0, conditions); zephir_check_call_status(); @@ -38644,7 +38770,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, save) { } else { ZEPHIR_CPY_WRT(ttl, lifetime); } - ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_0); zephir_time(_0); @@ -38703,7 +38829,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, delete) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 1, 0 TSRMLS_CC); @@ -38713,7 +38839,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, delete) { zephir_array_update_string(&_1, SL("key"), &_3, PH_COPY | PH_SEPARATE); ZEPHIR_CALL_METHOD(NULL, _0, "remove", NULL, 0, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "rand", NULL, 107); + ZEPHIR_CALL_FUNCTION(&_4, "rand", NULL, 109); zephir_check_call_status(); if (zephir_safe_mod_long_long(zephir_get_intval(_4), 100 TSRMLS_CC) == 0) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "gc", NULL, 0); @@ -38759,7 +38885,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, queryKeys) { zephir_time(_0); zephir_array_update_string(&_2, SL("$gt"), &_0, PH_COPY | PH_SEPARATE); zephir_array_update_string(&conditions, SL("time"), &_2, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 1, 0 TSRMLS_CC); @@ -38817,7 +38943,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, exists) { ZEPHIR_CONCAT_VV(lastKey, _0, keyName); } if (zephir_is_true(lastKey)) { - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 2, 0 TSRMLS_CC); @@ -38844,7 +38970,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, gc) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 1, 0 TSRMLS_CC); @@ -38879,7 +39005,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, increment) { ZEPHIR_INIT_VAR(prefixedKey); ZEPHIR_CONCAT_VV(prefixedKey, _0, keyName); zephir_update_property_this(this_ptr, SL("_lastKey"), prefixedKey TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_2); zephir_create_array(_2, 1, 0 TSRMLS_CC); @@ -38930,7 +39056,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, decrement) { ZEPHIR_INIT_VAR(prefixedKey); ZEPHIR_CONCAT_VV(prefixedKey, _0, keyName); zephir_update_property_this(this_ptr, SL("_lastKey"), prefixedKey TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_2); zephir_create_array(_2, 1, 0 TSRMLS_CC); @@ -38969,11 +39095,11 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, flush) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _0, "remove", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "rand", NULL, 107); + ZEPHIR_CALL_FUNCTION(&_1, "rand", NULL, 109); zephir_check_call_status(); if (zephir_safe_mod_long_long(zephir_get_intval(_1), 100 TSRMLS_CC) == 0) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "gc", NULL, 0); @@ -39057,7 +39183,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Redis, __construct) { ZVAL_STRING(_0, "_PHCR", 1); zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_redis_ce, this_ptr, "__construct", &_3, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_redis_ce, this_ptr, "__construct", &_3, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -39075,8 +39201,10 @@ static PHP_METHOD(Phalcon_Cache_Backend_Redis, _connect) { zephir_read_property_this(&options, this_ptr, SL("_options"), PH_NOISY_CC); ZEPHIR_INIT_VAR(redis); object_init_ex(redis, zephir_get_internal_ce(SS("redis") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, redis, "__construct", NULL, 0); - zephir_check_call_status(); + if (zephir_has_constructor(redis TSRMLS_CC)) { + ZEPHIR_CALL_METHOD(NULL, redis, "__construct", NULL, 0); + zephir_check_call_status(); + } ZEPHIR_OBS_VAR(host); _0 = !(zephir_array_isset_string_fetch(&host, options, SS("host"), 0 TSRMLS_CC)); if (!(_0)) { @@ -39615,7 +39743,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, __construct) { ZVAL_STRING(_0, "_PHCX", 1); zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_xcache_ce, this_ptr, "__construct", &_1, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_xcache_ce, this_ptr, "__construct", &_1, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -39640,7 +39768,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, get) { ZEPHIR_INIT_VAR(prefixedKey); ZEPHIR_CONCAT_SVV(prefixedKey, "_PHCX", _0, keyName); zephir_update_property_this(this_ptr, SL("_lastKey"), prefixedKey TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&cachedContent, "xcache_get", NULL, 81, prefixedKey); + ZEPHIR_CALL_FUNCTION(&cachedContent, "xcache_get", NULL, 83, prefixedKey); zephir_check_call_status(); if (!(zephir_is_true(cachedContent))) { RETURN_MM_NULL(); @@ -39718,10 +39846,10 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, save) { ZEPHIR_CPY_WRT(tt1, lifetime); } if (zephir_is_numeric(cachedContent)) { - ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 82, lastKey, cachedContent, tt1); + ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 84, lastKey, cachedContent, tt1); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 82, lastKey, preparedContent, tt1); + ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 84, lastKey, preparedContent, tt1); zephir_check_call_status(); } ZEPHIR_CALL_METHOD(&isBuffering, frontend, "isbuffering", NULL, 0); @@ -39743,14 +39871,14 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, save) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Unexpected inconsistency in options", "phalcon/cache/backend/xcache.zep", 169); return; } - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) != IS_ARRAY) { ZEPHIR_INIT_NVAR(keys); array_init(keys); } zephir_array_update_zval(&keys, lastKey, &tt1, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", &_1, 82, specialKey, keys); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", &_1, 84, specialKey, keys); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -39776,14 +39904,14 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, delete) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Unexpected inconsistency in options", "phalcon/cache/backend/xcache.zep", 199); return; } - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) != IS_ARRAY) { ZEPHIR_INIT_NVAR(keys); array_init(keys); } zephir_array_unset(&keys, prefixedKey, PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, specialKey, keys); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, specialKey, keys); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -39820,7 +39948,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, queryKeys) { } ZEPHIR_INIT_VAR(retval); array_init(retval); - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) == IS_ARRAY) { ZEPHIR_INIT_VAR(_1); @@ -39869,7 +39997,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, exists) { ZEPHIR_CONCAT_SVV(lastKey, "_PHCX", _0, keyName); } if (zephir_is_true(lastKey)) { - ZEPHIR_RETURN_CALL_FUNCTION("xcache_isset", NULL, 108, lastKey); + ZEPHIR_RETURN_CALL_FUNCTION("xcache_isset", NULL, 110, lastKey); zephir_check_call_status(); RETURN_MM(); } @@ -39908,14 +40036,14 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, increment) { if ((zephir_function_exists_ex(SS("xcache_inc") TSRMLS_CC) == SUCCESS)) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, value); - ZEPHIR_CALL_FUNCTION(&newVal, "xcache_inc", NULL, 109, lastKey, &_1); + ZEPHIR_CALL_FUNCTION(&newVal, "xcache_inc", NULL, 111, lastKey, &_1); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 81, lastKey); + ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 83, lastKey); zephir_check_call_status(); ZEPHIR_INIT_NVAR(newVal); ZVAL_LONG(newVal, (zephir_get_numberval(origVal) - value)); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, lastKey, newVal); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, lastKey, newVal); zephir_check_call_status(); } RETURN_CCTOR(newVal); @@ -39953,14 +40081,14 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, decrement) { if ((zephir_function_exists_ex(SS("xcache_dec") TSRMLS_CC) == SUCCESS)) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, value); - ZEPHIR_CALL_FUNCTION(&newVal, "xcache_dec", NULL, 110, lastKey, &_1); + ZEPHIR_CALL_FUNCTION(&newVal, "xcache_dec", NULL, 112, lastKey, &_1); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 81, lastKey); + ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 83, lastKey); zephir_check_call_status(); ZEPHIR_INIT_NVAR(newVal); ZVAL_LONG(newVal, (zephir_get_numberval(origVal) - value)); - ZEPHIR_CALL_FUNCTION(&success, "xcache_set", NULL, 82, lastKey, newVal); + ZEPHIR_CALL_FUNCTION(&success, "xcache_set", NULL, 84, lastKey, newVal); zephir_check_call_status(); } RETURN_CCTOR(newVal); @@ -39985,7 +40113,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, flush) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Unexpected inconsistency in options", "phalcon/cache/backend/xcache.zep", 350); return; } - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) == IS_ARRAY) { ZEPHIR_INIT_VAR(_1); @@ -39997,10 +40125,10 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, flush) { ZEPHIR_GET_HMKEY(key, _3, _2); ZEPHIR_GET_HVALUE(_1, _4); zephir_array_unset(&keys, key, PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_unset", &_5, 111, key); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_unset", &_5, 113, key); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, specialKey, keys); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, specialKey, keys); zephir_check_call_status(); } RETURN_MM_BOOL(1); @@ -40098,7 +40226,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Base64, beforeStore) { - ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", NULL, 112, data); + ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", NULL, 114, data); zephir_check_call_status(); RETURN_MM(); @@ -40114,7 +40242,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Base64, afterRetrieve) { - ZEPHIR_RETURN_CALL_FUNCTION("base64_decode", NULL, 113, data); + ZEPHIR_RETURN_CALL_FUNCTION("base64_decode", NULL, 115, data); zephir_check_call_status(); RETURN_MM(); @@ -40211,7 +40339,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Data, beforeStore) { - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, data); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, data); zephir_check_call_status(); RETURN_MM(); @@ -40227,7 +40355,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Data, afterRetrieve) { - ZEPHIR_RETURN_CALL_FUNCTION("unserialize", NULL, 72, data); + ZEPHIR_RETURN_CALL_FUNCTION("unserialize", NULL, 74, data); zephir_check_call_status(); RETURN_MM(); @@ -40322,7 +40450,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Igbinary, beforeStore) { - ZEPHIR_RETURN_CALL_FUNCTION("igbinary_serialize", NULL, 114, data); + ZEPHIR_RETURN_CALL_FUNCTION("igbinary_serialize", NULL, 116, data); zephir_check_call_status(); RETURN_MM(); @@ -40338,7 +40466,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Igbinary, afterRetrieve) { - ZEPHIR_RETURN_CALL_FUNCTION("igbinary_unserialize", NULL, 115, data); + ZEPHIR_RETURN_CALL_FUNCTION("igbinary_unserialize", NULL, 117, data); zephir_check_call_status(); RETURN_MM(); @@ -40603,7 +40731,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Output, start) { ZEPHIR_MM_GROW(); zephir_update_property_this(this_ptr, SL("_buffering"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -40618,7 +40746,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Output, getContent) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_buffering"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_contents", NULL, 117); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_contents", NULL, 119); zephir_check_call_status(); RETURN_MM(); } @@ -40635,7 +40763,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Output, stop) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_buffering"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); } zephir_update_property_this(this_ptr, SL("_buffering"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); @@ -41025,7 +41153,7 @@ static PHP_METHOD(Phalcon_Cli_Console, setArgument) { } if (_0) { Z_SET_ISREF_P(arguments); - ZEPHIR_CALL_FUNCTION(NULL, "array_shift", &_1, 119, arguments); + ZEPHIR_CALL_FUNCTION(NULL, "array_shift", &_1, 121, arguments); Z_UNSET_ISREF_P(arguments); zephir_check_call_status(); } @@ -41040,7 +41168,7 @@ static PHP_METHOD(Phalcon_Cli_Console, setArgument) { ZVAL_STRING(&_5, "--", 0); ZEPHIR_SINIT_NVAR(_6); ZVAL_LONG(&_6, 2); - ZEPHIR_CALL_FUNCTION(&_7, "strncmp", &_8, 120, arg, &_5, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "strncmp", &_8, 122, arg, &_5, &_6); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_7, 0)) { ZEPHIR_SINIT_NVAR(_5); @@ -41077,7 +41205,7 @@ static PHP_METHOD(Phalcon_Cli_Console, setArgument) { ZVAL_STRING(&_12, "-", 0); ZEPHIR_SINIT_NVAR(_13); ZVAL_LONG(&_13, 1); - ZEPHIR_CALL_FUNCTION(&_15, "strncmp", &_8, 120, arg, &_12, &_13); + ZEPHIR_CALL_FUNCTION(&_15, "strncmp", &_8, 122, arg, &_12, &_13); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_15, 0)) { ZEPHIR_SINIT_NVAR(_12); @@ -41095,21 +41223,21 @@ static PHP_METHOD(Phalcon_Cli_Console, setArgument) { } if (str) { ZEPHIR_INIT_NVAR(_9); - ZEPHIR_CALL_CE_STATIC(&_7, phalcon_cli_router_route_ce, "getdelimiter", &_16, 121); + ZEPHIR_CALL_CE_STATIC(&_7, phalcon_cli_router_route_ce, "getdelimiter", &_16, 123); zephir_check_call_status(); zephir_fast_join(_9, _7, args TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_arguments"), _9 TSRMLS_CC); } else { if (zephir_fast_count_int(args TSRMLS_CC)) { Z_SET_ISREF_P(args); - ZEPHIR_CALL_FUNCTION(&_15, "array_shift", &_1, 119, args); + ZEPHIR_CALL_FUNCTION(&_15, "array_shift", &_1, 121, args); Z_UNSET_ISREF_P(args); zephir_check_call_status(); zephir_array_update_string(&handleArgs, SL("task"), &_15, PH_COPY | PH_SEPARATE); } if (zephir_fast_count_int(args TSRMLS_CC)) { Z_SET_ISREF_P(args); - ZEPHIR_CALL_FUNCTION(&_7, "array_shift", &_1, 119, args); + ZEPHIR_CALL_FUNCTION(&_7, "array_shift", &_1, 121, args); Z_UNSET_ISREF_P(args); zephir_check_call_status(); zephir_array_update_string(&handleArgs, SL("action"), &_7, PH_COPY | PH_SEPARATE); @@ -41167,7 +41295,7 @@ static PHP_METHOD(Phalcon_Cli_Dispatcher, __construct) { ZEPHIR_INIT_VAR(_0); array_init(_0); zephir_update_property_this(this_ptr, SL("_options"), _0 TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_cli_dispatcher_ce, this_ptr, "__construct", &_1, 122); + ZEPHIR_CALL_PARENT(NULL, phalcon_cli_dispatcher_ce, this_ptr, "__construct", &_1, 124); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -41402,7 +41530,7 @@ static PHP_METHOD(Phalcon_Cli_Router, __construct) { add_assoc_long_ex(_1, SS("task"), 1); ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "#^(?::delimiter)?([a-zA-Z0-9\\_\\-]+)[:delimiter]{0,1}$#", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 123, _2, _1); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 125, _2, _1); zephir_check_temp_parameter(_2); zephir_check_call_status(); zephir_array_append(&routes, _0, PH_SEPARATE, "phalcon/cli/router.zep", 90); @@ -41415,7 +41543,7 @@ static PHP_METHOD(Phalcon_Cli_Router, __construct) { add_assoc_long_ex(_4, SS("params"), 3); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "#^(?::delimiter)?([a-zA-Z0-9\\_\\-]+):delimiter([a-zA-Z0-9\\.\\_]+)(:delimiter.*)*$#", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 123, _5, _4); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 125, _5, _4); zephir_check_temp_parameter(_5); zephir_check_call_status(); zephir_array_append(&routes, _2, PH_SEPARATE, "phalcon/cli/router.zep", 96); @@ -41702,7 +41830,7 @@ static PHP_METHOD(Phalcon_Cli_Router, handle) { ZEPHIR_INIT_VAR(strParams); zephir_substr(strParams, _15, 1 , 0, ZEPHIR_SUBSTR_NO_LENGTH); if (zephir_is_true(strParams)) { - ZEPHIR_CALL_CE_STATIC(&_17, phalcon_cli_router_route_ce, "getdelimiter", &_18, 121); + ZEPHIR_CALL_CE_STATIC(&_17, phalcon_cli_router_route_ce, "getdelimiter", &_18, 123); zephir_check_call_status(); ZEPHIR_INIT_NVAR(params); zephir_fast_explode(params, _17, strParams, LONG_MAX TSRMLS_CC); @@ -41758,7 +41886,7 @@ static PHP_METHOD(Phalcon_Cli_Router, add) { ZEPHIR_INIT_VAR(route); object_init_ex(route, phalcon_cli_router_route_ce); - ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 123, pattern, paths); + ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 125, pattern, paths); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_routes"), route TSRMLS_CC); RETURN_CCTOR(route); @@ -42788,7 +42916,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Ini, __construct) { } - ZEPHIR_CALL_FUNCTION(&iniConfig, "parse_ini_file", NULL, 124, filePath, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&iniConfig, "parse_ini_file", NULL, 126, filePath, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(iniConfig)) { ZEPHIR_INIT_VAR(_0); @@ -42838,7 +42966,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Ini, __construct) { zephir_array_update_zval(&config, section, &directives, PH_COPY | PH_SEPARATE); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_ini_ce, this_ptr, "__construct", &_12, 21, config); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_ini_ce, this_ptr, "__construct", &_12, 22, config); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -42885,7 +43013,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Ini, _parseIniString) { zephir_substr(_3, path, zephir_get_intval(&_2), 0, ZEPHIR_SUBSTR_NO_LENGTH); zephir_get_strval(path, _3); zephir_create_array(return_value, 1, 0 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "_parseinistring", NULL, 125, path, value); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "_parseinistring", NULL, 127, path, value); zephir_check_call_status(); zephir_array_update_zval(&return_value, key, &_4, PH_COPY); RETURN_MM(); @@ -42941,7 +43069,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Json, __construct) { ZEPHIR_INIT_VAR(_2); zephir_file_get_contents(_2, filePath TSRMLS_CC); zephir_json_decode(_1, &(_1), _2, zephir_get_intval(ZEPHIR_GLOBAL(global_true)) TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_json_ce, this_ptr, "__construct", &_0, 21, _1); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_json_ce, this_ptr, "__construct", &_0, 22, _1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -42996,7 +43124,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Php, __construct) { if (zephir_require_zval_ret(&_1, filePath TSRMLS_CC) == FAILURE) { RETURN_MM_NULL(); } - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_php_ce, this_ptr, "__construct", &_0, 21, _1); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_php_ce, this_ptr, "__construct", &_0, 22, _1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -43057,7 +43185,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Yaml, __construct) { ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "yaml", 0); - ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", NULL, 126, &_0); + ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", NULL, 128, &_0); zephir_check_call_status(); if (!(zephir_is_true(_1))) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_config_exception_ce, "Yaml extension not loaded", "phalcon/config/adapter/yaml.zep", 62); @@ -43069,11 +43197,11 @@ static PHP_METHOD(Phalcon_Config_Adapter_Yaml, __construct) { ZEPHIR_INIT_VAR(_3); ZVAL_LONG(_3, ndocs); Z_SET_ISREF_P(_3); - ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 127, filePath, _2, _3, callbacks); + ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 129, filePath, _2, _3, callbacks); Z_UNSET_ISREF_P(_3); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 127, filePath); + ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 129, filePath); zephir_check_call_status(); } if (ZEPHIR_IS_FALSE_IDENTICAL(yamlConfig)) { @@ -43089,7 +43217,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Yaml, __construct) { ZEPHIR_MM_RESTORE(); return; } - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_yaml_ce, this_ptr, "__construct", &_6, 21, yamlConfig); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_yaml_ce, this_ptr, "__construct", &_6, 22, yamlConfig); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -45708,7 +45836,7 @@ static PHP_METHOD(Phalcon_Db_Column, __set_state) { zephir_array_update_string(&definition, SL("bindType"), &bindType, PH_COPY | PH_SEPARATE); } object_init_ex(return_value, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 140, columnName, definition); zephir_check_call_status(); RETURN_MM(); @@ -46036,7 +46164,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getColumnList) { ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(column, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlcolumn", &_4, 29, column, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlcolumn", &_4, 30, column, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_append(&columns, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 158); } @@ -46164,17 +46292,17 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpression) { } do { if (ZEPHIR_IS_STRING(type, "scalar")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionscalar", NULL, 30, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionscalar", NULL, 31, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "object")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionobject", NULL, 31, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionobject", NULL, 32, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "qualified")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionqualified", NULL, 32, expression, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionqualified", NULL, 33, expression, escapeChar); zephir_check_call_status(); RETURN_MM(); } @@ -46223,34 +46351,34 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpression) { RETURN_CTOR(_0); } if (ZEPHIR_IS_STRING(type, "binary-op")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionbinaryoperations", NULL, 33, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionbinaryoperations", NULL, 34, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "unary-op")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionunaryoperations", NULL, 34, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionunaryoperations", NULL, 35, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "parentheses")) { zephir_array_fetch_string(&_0, expression, SL("left"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 305 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_6, this_ptr, "getsqlexpression", NULL, 35, _0, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_6, this_ptr, "getsqlexpression", NULL, 36, _0, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "(", _6, ")"); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "functionCall")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionfunctioncall", NULL, 36, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionfunctioncall", NULL, 37, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "list")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionlist", NULL, 37, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionlist", NULL, 38, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "all")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionall", NULL, 38, expression, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionall", NULL, 39, expression, escapeChar); zephir_check_call_status(); RETURN_MM(); } @@ -46262,17 +46390,17 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpression) { RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "cast")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncastvalue", NULL, 39, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncastvalue", NULL, 40, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "convert")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionconvertvalue", NULL, 40, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionconvertvalue", NULL, 41, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "case")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncase", NULL, 41, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncase", NULL, 42, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } @@ -46318,7 +46446,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlTable) { zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", NULL, 42, table, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", NULL, 43, table, escapeChar); zephir_check_call_status(); RETURN_MM(); @@ -46364,12 +46492,12 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { zephir_array_isset_string_fetch(&bindCounts, definition, SS("bindCounts"), 0 TSRMLS_CC); ZEPHIR_OBS_VAR(escapeChar); zephir_read_property_this(&escapeChar, this_ptr, SL("_escapeChar"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 43, columns, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 44, columns, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SV(_1, " ", _0); zephir_concat_self(&sql, _1 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "getsqlexpressionfrom", NULL, 44, tables, escapeChar); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "getsqlexpressionfrom", NULL, 45, tables, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SV(_3, " ", _2); @@ -46381,7 +46509,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { } if (_4) { zephir_array_fetch_string(&_6, definition, SL("joins"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 429 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionjoins", NULL, 45, _6, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionjoins", NULL, 46, _6, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -46393,7 +46521,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { _8 = zephir_is_true(where); } if (_8) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionwhere", NULL, 46, where, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionwhere", NULL, 47, where, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -46405,7 +46533,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { _9 = zephir_is_true(groupBy); } if (_9) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressiongroupby", NULL, 47, groupBy, escapeChar); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressiongroupby", NULL, 48, groupBy, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -46417,7 +46545,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { _10 = zephir_is_true(having); } if (_10) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionhaving", NULL, 48, having, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionhaving", NULL, 49, having, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -46429,7 +46557,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { _11 = zephir_is_true(orderBy); } if (_11) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionorderby", NULL, 49, orderBy, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionorderby", NULL, 50, orderBy, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -46445,7 +46573,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { zephir_create_array(_13, 2, 0 TSRMLS_CC); zephir_array_update_string(&_13, SL("sql"), &sql, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_13, SL("value"), &limit, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&sql, this_ptr, "getsqlexpressionlimit", NULL, 50, _13, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&sql, this_ptr, "getsqlexpressionlimit", NULL, 51, _13, escapeChar, bindCounts); zephir_check_call_status(); } _14 = zephir_array_isset_string_fetch(&forUpdate, definition, SS("forUpdate"), 1 TSRMLS_CC); @@ -46581,7 +46709,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionScalar) { if (zephir_array_isset_string(expression, SS("column"))) { zephir_array_fetch_string(&_0, expression, SL("column"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 525 TSRMLS_CC); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlcolumn", NULL, 29, _0); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlcolumn", NULL, 30, _0); zephir_check_call_status(); RETURN_MM(); } @@ -46708,7 +46836,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionBinaryOperations) { ZEPHIR_CALL_METHOD(&left, this_ptr, "getsqlexpression", &_1, 0, _0, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_2, expression, SL("right"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 583 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 35, _2, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 36, _2, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_3, expression, SL("op"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 585 TSRMLS_CC); ZEPHIR_CONCAT_VSVSV(return_value, left, " ", _3, " ", right); @@ -46751,7 +46879,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionUnaryOperations) { ZEPHIR_OBS_VAR(right); if (zephir_array_isset_string_fetch(&right, expression, SS("right"), 0 TSRMLS_CC)) { zephir_array_fetch_string(&_2, expression, SL("op"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 606 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getsqlexpression", &_1, 35, right, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getsqlexpression", &_1, 36, right, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_VSV(return_value, _2, " ", _0); RETURN_MM(); @@ -46955,7 +47083,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionCastValue) { ZEPHIR_CALL_METHOD(&left, this_ptr, "getsqlexpression", &_1, 0, _0, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_2, expression, SL("right"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 693 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 35, _2, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 36, _2, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "CAST(", left, " AS ", right, ")"); RETURN_MM(); @@ -46990,7 +47118,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionConvertValue) { ZEPHIR_CALL_METHOD(&left, this_ptr, "getsqlexpression", &_1, 0, _0, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_2, expression, SL("right"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 706 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 35, _2, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 36, _2, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "CONVERT(", left, " USING ", right, ")"); RETURN_MM(); @@ -47038,17 +47166,17 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionCase) { zephir_array_fetch_string(&_7, whenClause, SL("type"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 721 TSRMLS_CC); if (ZEPHIR_IS_STRING(_7, "when")) { zephir_array_fetch_string(&_9, whenClause, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 723 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 35, _9, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 36, _9, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_11, whenClause, SL("then"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 725 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_10, this_ptr, "getsqlexpression", &_2, 35, _11, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "getsqlexpression", &_2, 36, _11, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SVSV(_12, " WHEN ", _8, " THEN ", _10); zephir_concat_self(&sql, _12 TSRMLS_CC); } else { zephir_array_fetch_string(&_9, whenClause, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 727 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 35, _9, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 36, _9, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SV(_12, " ELSE ", _8); @@ -47089,7 +47217,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionFrom) { ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(table, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqltable", &_4, 51, table, escapeChar); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqltable", &_4, 52, table, escapeChar); zephir_check_call_status(); zephir_array_append(&tables, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 746); } @@ -47156,7 +47284,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionJoins) { ; zephir_hash_move_forward_ex(_6, &_5) ) { ZEPHIR_GET_HVALUE(condition, _7); - ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_4, 35, condition, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_4, 36, condition, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_append(&joinCondition, _8, PH_SEPARATE, "phalcon/db/dialect.zep", 779); } @@ -47177,7 +47305,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionJoins) { zephir_concat_self_str(&joinType, SL(" ") TSRMLS_CC); } zephir_array_fetch_string(&_11, join, SL("source"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 792 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&joinTable, this_ptr, "getsqltable", &_12, 51, _11, escapeChar); + ZEPHIR_CALL_METHOD(&joinTable, this_ptr, "getsqltable", &_12, 52, _11, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_13); ZEPHIR_CONCAT_SVSVSV(_13, " ", joinType, "JOIN ", joinTable, " ON ", joinCondition); @@ -47415,7 +47543,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionLimit) { _3 = Z_TYPE_P(offset) == IS_ARRAY; } if (_3) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getsqlexpression", &_2, 35, offset, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getsqlexpression", &_2, 36, offset, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CPY_WRT(offset, _4); } @@ -47467,7 +47595,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, prepareColumnAlias) { if (!ZEPHIR_IS_STRING(alias, "")) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", NULL, 42, alias, escapeChar); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", NULL, 43, alias, escapeChar); zephir_check_call_status(); ZEPHIR_CONCAT_VSV(return_value, qualified, " AS ", _0); RETURN_MM(); @@ -47517,18 +47645,18 @@ static PHP_METHOD(Phalcon_Db_Dialect, prepareTable) { } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", &_1, 42, table, escapeChar); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", &_1, 43, table, escapeChar); zephir_check_call_status(); zephir_get_strval(table, _0); if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 42, schema, escapeChar); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 43, schema, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_VSV(_3, _2, ".", table); zephir_get_strval(table, _3); } if (!ZEPHIR_IS_STRING(alias, "")) { - ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 42, alias, escapeChar); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 43, alias, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_VSV(_3, table, " AS ", _2); @@ -47576,11 +47704,11 @@ static PHP_METHOD(Phalcon_Db_Dialect, prepareQualified) { if (!ZEPHIR_IS_STRING(domain, "")) { ZEPHIR_INIT_VAR(_0); ZEPHIR_CONCAT_VSV(_0, domain, ".", column); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 42, _0, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 43, _0, escapeChar); zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 42, column, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 43, column, escapeChar); zephir_check_call_status(); RETURN_MM(); @@ -47890,19 +48018,19 @@ static PHP_METHOD(Phalcon_Db_Profiler, startProfile) { ZEPHIR_CALL_METHOD(NULL, activeProfile, "__construct", NULL, 0); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 144, sqlStatement); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 145, sqlStatement); zephir_check_call_status(); if (Z_TYPE_P(sqlVariables) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 145, sqlVariables); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 146, sqlVariables); zephir_check_call_status(); } if (Z_TYPE_P(sqlBindTypes) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 146, sqlBindTypes); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 147, sqlBindTypes); zephir_check_call_status(); } ZEPHIR_INIT_VAR(_0); zephir_microtime(_0, ZEPHIR_GLOBAL(global_true) TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 147, _0); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 148, _0); zephir_check_call_status(); if ((zephir_method_exists_ex(this_ptr, SS("beforestartprofile") TSRMLS_CC) == SUCCESS)) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "beforestartprofile", NULL, 0, activeProfile); @@ -48397,7 +48525,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo, __construct) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "connect", NULL, 0, descriptor); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_ce, this_ptr, "__construct", &_0, 24, descriptor); + ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_ce, this_ptr, "__construct", &_0, 25, descriptor); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -48571,7 +48699,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo, executePrepared) { if (ZEPHIR_IS_LONG(type, 1)) { ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 10); - ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_5, 25, value, &_4); + ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_5, 26, value, &_4); zephir_check_call_status(); break; } @@ -48723,7 +48851,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo, query) { zephir_check_call_status(); } object_init_ex(return_value, phalcon_db_result_pdo_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 26, this_ptr, statement, sqlStatement, bindParams, bindTypes); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 27, this_ptr, statement, sqlStatement, bindParams, bindTypes); zephir_check_call_status(); RETURN_MM(); } @@ -48904,7 +49032,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo, convertBoundParams) { ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, setOrder); Z_SET_ISREF_P(matches); - ZEPHIR_CALL_FUNCTION(&_1, "preg_match_all", NULL, 27, bindPattern, sql, matches, _0); + ZEPHIR_CALL_FUNCTION(&_1, "preg_match_all", NULL, 28, bindPattern, sql, matches, _0); Z_UNSET_ISREF_P(matches); zephir_check_call_status(); if (zephir_is_true(_1)) { @@ -48933,7 +49061,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo, convertBoundParams) { } ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "?", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&boundSql, "preg_replace", NULL, 28, bindPattern, _0, sql); + ZEPHIR_CALL_FUNCTION(&boundSql, "preg_replace", NULL, 29, bindPattern, _0, sql); zephir_check_temp_parameter(_0); zephir_check_call_status(); } else { @@ -49521,7 +49649,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Mysql, describeColumns) { zephir_array_fetch_long(&columnName, field, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/mysql.zep", 324 TSRMLS_CC); ZEPHIR_INIT_NVAR(_7); object_init_ex(_7, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_15, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_15, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter/pdo/mysql.zep", 325); ZEPHIR_CPY_WRT(oldColumn, columnName); @@ -49579,7 +49707,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Oracle, connect) { ZEPHIR_OBS_NVAR(descriptor); zephir_read_property_this(&descriptor, this_ptr, SL("_descriptor"), PH_NOISY_CC); } - ZEPHIR_CALL_PARENT(&status, phalcon_db_adapter_pdo_oracle_ce, this_ptr, "connect", &_0, 139, descriptor); + ZEPHIR_CALL_PARENT(&status, phalcon_db_adapter_pdo_oracle_ce, this_ptr, "connect", &_0, 141, descriptor); zephir_check_call_status(); ZEPHIR_OBS_VAR(startup); if (zephir_array_isset_string_fetch(&startup, descriptor, SS("startup"), 0 TSRMLS_CC)) { @@ -49753,7 +49881,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Oracle, describeColumns) { zephir_array_fetch_long(&columnName, field, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/oracle.zep", 194 TSRMLS_CC); ZEPHIR_INIT_NVAR(_8); object_init_ex(_8, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _8, "__construct", &_11, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _8, "__construct", &_11, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _8, PH_SEPARATE, "phalcon/db/adapter/pdo/oracle.zep", 199); ZEPHIR_CPY_WRT(oldColumn, columnName); @@ -49888,7 +50016,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, connect) { zephir_array_update_string(&descriptor, SL("password"), &ZEPHIR_GLOBAL(global_null), PH_COPY | PH_SEPARATE); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_postgresql_ce, this_ptr, "connect", &_3, 139, descriptor); + ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_postgresql_ce, this_ptr, "connect", &_3, 141, descriptor); zephir_check_call_status(); if (!(ZEPHIR_IS_EMPTY(schema))) { ZEPHIR_INIT_VAR(sql); @@ -50108,7 +50236,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, describeColumns) { ZVAL_STRING(_8, "/^'|'?::[[:alnum:][:space:]]+$/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_9); ZVAL_STRING(_9, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_15, "preg_replace", &_16, 28, _8, _9, _14); + ZEPHIR_CALL_FUNCTION(&_15, "preg_replace", &_16, 29, _8, _9, _14); zephir_check_temp_parameter(_8); zephir_check_temp_parameter(_9); zephir_check_call_status(); @@ -50116,7 +50244,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, describeColumns) { zephir_array_fetch_string(&_17, definition, SL("default"), PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/postgresql.zep", 305 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_18); ZVAL_STRING(&_18, "null", 0); - ZEPHIR_CALL_FUNCTION(&_19, "strcasecmp", &_20, 140, _17, &_18); + ZEPHIR_CALL_FUNCTION(&_19, "strcasecmp", &_20, 19, _17, &_18); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_19, 0)) { zephir_array_update_string(&definition, SL("default"), &ZEPHIR_GLOBAL(global_null), PH_COPY | PH_SEPARATE); @@ -50125,7 +50253,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, describeColumns) { zephir_array_fetch_long(&columnName, field, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/postgresql.zep", 313 TSRMLS_CC); ZEPHIR_INIT_NVAR(_7); object_init_ex(_7, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter/pdo/postgresql.zep", 314); ZEPHIR_CPY_WRT(oldColumn, columnName); @@ -50418,7 +50546,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, connect) { return; } zephir_array_update_string(&descriptor, SL("dsn"), &dbname, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_sqlite_ce, this_ptr, "connect", &_0, 139, descriptor); + ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_sqlite_ce, this_ptr, "connect", &_0, 141, descriptor); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -50616,7 +50744,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, describeColumns) { zephir_array_fetch_long(&_13, field, 4, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/sqlite.zep", 279 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "null", 0); - ZEPHIR_CALL_FUNCTION(&_15, "strcasecmp", &_16, 140, _13, &_14); + ZEPHIR_CALL_FUNCTION(&_15, "strcasecmp", &_16, 19, _13, &_14); zephir_check_call_status(); _9 = !ZEPHIR_IS_LONG(_15, 0); if (_9) { @@ -50629,7 +50757,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, describeColumns) { ZVAL_STRING(_7, "/^'|'$/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_8); ZVAL_STRING(_8, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_19, "preg_replace", &_20, 28, _7, _8, _18); + ZEPHIR_CALL_FUNCTION(&_19, "preg_replace", &_20, 29, _7, _8, _18); zephir_check_temp_parameter(_7); zephir_check_temp_parameter(_8); zephir_check_call_status(); @@ -50638,7 +50766,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, describeColumns) { zephir_array_fetch_long(&columnName, field, 1, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/sqlite.zep", 286 TSRMLS_CC); ZEPHIR_INIT_NVAR(_7); object_init_ex(_7, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter/pdo/sqlite.zep", 287); ZEPHIR_CPY_WRT(oldColumn, columnName); @@ -51093,7 +51221,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) { ZEPHIR_GET_HVALUE(value, _7); ZEPHIR_SINIT_NVAR(_8); ZVAL_STRING(&_8, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_9, 141, value, &_8); + ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_9, 142, value, &_8); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "\"", _0, "\", "); @@ -51111,7 +51239,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) { } else { ZEPHIR_SINIT_NVAR(_10); ZVAL_STRING(&_10, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_9, 141, typeValues, &_10); + ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_9, 142, typeValues, &_10); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, "(\"", _2, "\")"); @@ -51170,7 +51298,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 142, defaultValue, &_3); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\""); @@ -51247,7 +51375,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 142, defaultValue, &_3); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\""); @@ -51363,7 +51491,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 43, _4); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 44, _4); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSVS(_1, "`", _2, "` (", _3, ")"); @@ -51460,7 +51588,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addPrimaryKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 44, _2); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD PRIMARY KEY (", _1, ")"); RETURN_MM(); @@ -51546,7 +51674,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 43, _3); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 44, _3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_5, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); @@ -51556,7 +51684,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_8, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 43, _8); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 44, _8); zephir_check_call_status(); ZEPHIR_INIT_VAR(sql); ZEPHIR_CONCAT_SVSVSVSVSVS(sql, "ALTER TABLE ", _0, " ADD FOREIGN KEY `", _1, "`(", _2, ") REFERENCES ", _4, "(", _7, ")"); @@ -51707,7 +51835,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_NVAR(_6); ZVAL_STRING(&_6, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 142, defaultValue, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\""); @@ -51745,7 +51873,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) { ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_13, 43, _4); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_13, 44, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(indexSql); ZEPHIR_CONCAT_SVS(indexSql, "PRIMARY KEY (", _3, ")"); @@ -51754,13 +51882,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { if (!(ZEPHIR_IS_EMPTY(indexType))) { ZEPHIR_CALL_METHOD(&_14, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_13, 43, _14); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_13, 44, _14); zephir_check_call_status(); ZEPHIR_CONCAT_VSVSVS(indexSql, indexType, " KEY `", indexName, "` (", _7, ")"); } else { ZEPHIR_CALL_METHOD(&_15, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_14, this_ptr, "getcolumnlist", &_13, 43, _15); + ZEPHIR_CALL_METHOD(&_14, this_ptr, "getcolumnlist", &_13, 44, _15); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(indexSql, "KEY `", indexName, "` (", _14, ")"); } @@ -51780,13 +51908,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_13, 43, _7); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_13, 44, _7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_14, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_13, 43, _19); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_13, 44, _19); zephir_check_call_status(); ZEPHIR_INIT_NVAR(referenceSql); ZEPHIR_CONCAT_SVSVSSVSVS(referenceSql, "CONSTRAINT `", _3, "` FOREIGN KEY (", _4, ")", " REFERENCES `", _14, "`(", _15, ")"); @@ -53016,14 +53144,14 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, viewExists) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, viewName); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_VIEWS WHERE VIEW_NAME='", _0, "' AND OWNER='", _2, "'"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, viewName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_VIEWS WHERE VIEW_NAME='", _0, "'"); RETURN_MM(); @@ -53049,7 +53177,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, listViews) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT VIEW_NAME FROM ALL_VIEWS WHERE OWNER='", _0, "' ORDER BY VIEW_NAME"); RETURN_MM(); @@ -53088,14 +53216,14 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, tableExists) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, tableName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, tableName); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_TABLES WHERE TABLE_NAME='", _0, "' AND OWNER = '", _2, "'"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, tableName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, tableName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_TABLES WHERE TABLE_NAME='", _0, "'"); RETURN_MM(); @@ -53132,14 +53260,14 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeColumns) { if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schema); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT TC.COLUMN_NAME, TC.DATA_TYPE, TC.DATA_LENGTH, TC.DATA_PRECISION, TC.DATA_SCALE, TC.NULLABLE, C.CONSTRAINT_TYPE, TC.DATA_DEFAULT, CC.POSITION FROM ALL_TAB_COLUMNS TC LEFT JOIN (ALL_CONS_COLUMNS CC JOIN ALL_CONSTRAINTS C ON (CC.CONSTRAINT_NAME = C.CONSTRAINT_NAME AND CC.TABLE_NAME = C.TABLE_NAME AND CC.OWNER = C.OWNER AND C.CONSTRAINT_TYPE = 'P')) ON TC.TABLE_NAME = CC.TABLE_NAME AND TC.COLUMN_NAME = CC.COLUMN_NAME WHERE TC.TABLE_NAME = '", _0, "' AND TC.OWNER = '", _2, "' ORDER BY TC.COLUMN_ID"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT TC.COLUMN_NAME, TC.DATA_TYPE, TC.DATA_LENGTH, TC.DATA_PRECISION, TC.DATA_SCALE, TC.NULLABLE, C.CONSTRAINT_TYPE, TC.DATA_DEFAULT, CC.POSITION FROM ALL_TAB_COLUMNS TC LEFT JOIN (ALL_CONS_COLUMNS CC JOIN ALL_CONSTRAINTS C ON (CC.CONSTRAINT_NAME = C.CONSTRAINT_NAME AND CC.TABLE_NAME = C.TABLE_NAME AND CC.OWNER = C.OWNER AND C.CONSTRAINT_TYPE = 'P')) ON TC.TABLE_NAME = CC.TABLE_NAME AND TC.COLUMN_NAME = CC.COLUMN_NAME WHERE TC.TABLE_NAME = '", _0, "' ORDER BY TC.COLUMN_ID"); RETURN_MM(); @@ -53165,7 +53293,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, listTables) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT TABLE_NAME, OWNER FROM ALL_TABLES WHERE OWNER='", _0, "' ORDER BY OWNER, TABLE_NAME"); RETURN_MM(); @@ -53204,14 +53332,14 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeIndexes) { if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schema); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT I.TABLE_NAME, 0 AS C0, I.INDEX_NAME, IC.COLUMN_POSITION, IC.COLUMN_NAME FROM ALL_INDEXES I JOIN ALL_IND_COLUMNS IC ON I.INDEX_NAME = IC.INDEX_NAME WHERE I.TABLE_NAME = '", _0, "' AND IC.INDEX_OWNER = '", _2, "'"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT I.TABLE_NAME, 0 AS C0, I.INDEX_NAME, IC.COLUMN_POSITION, IC.COLUMN_NAME FROM ALL_INDEXES I JOIN ALL_IND_COLUMNS IC ON I.INDEX_NAME = IC.INDEX_NAME WHERE I.TABLE_NAME = '", _0, "'"); RETURN_MM(); @@ -53250,15 +53378,15 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeReferences) { ZEPHIR_INIT_VAR(sql); ZVAL_STRING(sql, "SELECT AC.TABLE_NAME, CC.COLUMN_NAME, AC.CONSTRAINT_NAME, AC.R_OWNER, RCC.TABLE_NAME R_TABLE_NAME, RCC.COLUMN_NAME R_COLUMN_NAME FROM ALL_CONSTRAINTS AC JOIN ALL_CONS_COLUMNS CC ON AC.CONSTRAINT_NAME = CC.CONSTRAINT_NAME JOIN ALL_CONS_COLUMNS RCC ON AC.R_OWNER = RCC.OWNER AND AC.R_CONSTRAINT_NAME = RCC.CONSTRAINT_NAME WHERE AC.CONSTRAINT_TYPE='R' ", 1); if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, schema); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SVSVS(_3, "AND AC.OWNER='", _0, "' AND AC.TABLE_NAME = '", _2, "'"); zephir_concat_self(&sql, _3 TSRMLS_CC); } else { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVS(_3, "AND AC.TABLE_NAME = '", _0, "'"); @@ -53354,11 +53482,11 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, prepareTable) { } - ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 142, table); + ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 143, table); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_3, phalcon_text_ce, "upper", &_2, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_3, phalcon_text_ce, "upper", &_2, 143, schema); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_PARENT(phalcon_db_dialect_oracle_ce, this_ptr, "preparetable", &_0, 143, _1, _3, alias, escapeChar); + ZEPHIR_RETURN_CALL_PARENT(phalcon_db_dialect_oracle_ce, this_ptr, "preparetable", &_0, 144, _1, _3, alias, escapeChar); zephir_check_call_status(); RETURN_MM(); @@ -53527,7 +53655,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, getColumnDefinition) { ZEPHIR_GET_HVALUE(value, _4); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_6, 141, value, &_5); + ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_6, 142, value, &_5); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "\"", _0, "\", "); @@ -53545,7 +53673,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, getColumnDefinition) { } else { ZEPHIR_SINIT_NVAR(_7); ZVAL_STRING(&_7, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_10, "addcslashes", &_6, 141, typeValues, &_7); + ZEPHIR_CALL_FUNCTION(&_10, "addcslashes", &_6, 142, typeValues, &_7); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, "(\"", _10, "\")"); @@ -53607,7 +53735,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 142, defaultValue, &_4); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\""); @@ -53739,7 +53867,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) { zephir_check_call_status(); ZEPHIR_SINIT_VAR(_11); ZVAL_STRING(&_11, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_12, "addcslashes", NULL, 141, defaultValue, &_11); + ZEPHIR_CALL_FUNCTION(&_12, "addcslashes", NULL, 142, defaultValue, &_11); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_VSVSVS(_9, sqlAlterTable, " ALTER COLUMN \"", _8, "\" SET DEFAULT \"", _12, "\""); @@ -53859,7 +53987,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addIndex) { zephir_concat_self(&sql, _1 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 43, _5); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 44, _5); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZEPHIR_CONCAT_SVS(_6, " (", _4, ")"); @@ -53953,7 +54081,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 44, _2); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _1, ")"); RETURN_MM(); @@ -54039,13 +54167,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 43, _3); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 44, _3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_4, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_6, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", NULL, 43, _6); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", NULL, 44, _6); zephir_check_call_status(); ZEPHIR_INIT_VAR(sql); ZEPHIR_CONCAT_SVSVSVSSVSVS(sql, "ALTER TABLE ", _0, " ADD CONSTRAINT \"", _1, "\" FOREIGN KEY (", _2, ")", " REFERENCES \"", _4, "\" (", _5, ")"); @@ -54120,12 +54248,12 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropForeignKey) { static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { - zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_16 = NULL; - HashTable *_1, *_14, *_23; - HashPosition _0, _13, _22; + zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL; + HashTable *_1, *_13, *_21; + HashPosition _0, _12, _20; int ZEPHIR_LAST_CALL_STATUS; zval *definition = NULL; - zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, *_10 = NULL, *_11 = NULL, *_12 = NULL, **_15, *_17 = NULL, *_18 = NULL, *_19 = NULL, *_20 = NULL, *_21 = NULL, **_24, *_25 = NULL; + zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, *_10 = NULL, *_11 = NULL, **_14, *_15 = NULL, *_16 = NULL, *_17 = NULL, *_18 = NULL, *_19 = NULL, **_22, *_23, *_24 = NULL; zval *tableName = NULL, *schemaName = NULL; ZEPHIR_MM_GROW(); @@ -54198,7 +54326,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_NVAR(_6); ZVAL_STRING(&_6, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 142, defaultValue, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\""); @@ -54223,22 +54351,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 381); } if (!(ZEPHIR_IS_EMPTY(primaryColumns))) { - ZEPHIR_INIT_VAR(_12); - zephir_fast_join_str(_12, SL(","), primaryColumns TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 44, primaryColumns); + zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); - ZEPHIR_CONCAT_SVS(_9, "PRIMARY KEY (", _12, ")"); + ZEPHIR_CONCAT_SVS(_9, "PRIMARY KEY (", _3, ")"); zephir_array_append(&createLines, _9, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 384); } ZEPHIR_INIT_VAR(indexSqlAfterCreate); ZVAL_STRING(indexSqlAfterCreate, "", 1); ZEPHIR_OBS_VAR(indexes); if (zephir_array_isset_string_fetch(&indexes, definition, SS("indexes"), 0 TSRMLS_CC)) { - zephir_is_iterable(indexes, &_14, &_13, 0, 0, "phalcon/db/dialect/postgresql.zep", 418); + zephir_is_iterable(indexes, &_13, &_12, 0, 0, "phalcon/db/dialect/postgresql.zep", 418); for ( - ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS - ; zephir_hash_move_forward_ex(_14, &_13) + ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS + ; zephir_hash_move_forward_ex(_13, &_12) ) { - ZEPHIR_GET_HVALUE(index, _15); + ZEPHIR_GET_HVALUE(index, _14); ZEPHIR_CALL_METHOD(&indexName, index, "getname", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0); @@ -54248,7 +54376,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) { ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_16, 43, _4); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 44, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(indexSql); ZEPHIR_CONCAT_SVS(indexSql, "CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _3, ")"); @@ -54256,25 +54384,25 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { if (!(ZEPHIR_IS_EMPTY(indexType))) { ZEPHIR_CALL_METHOD(&_10, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_16, 43, _10); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 44, _10); zephir_check_call_status(); ZEPHIR_INIT_NVAR(indexSql); ZEPHIR_CONCAT_SVSVSVS(indexSql, "CONSTRAINT \"", indexName, "\" ", indexType, " (", _7, ")"); } else { ZEPHIR_CALL_METHOD(&_11, index, "getname", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_17, this_ptr, "preparetable", NULL, 143, tableName, schemaName); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "preparetable", NULL, 144, tableName, schemaName); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_18); - ZEPHIR_CONCAT_SVSV(_18, "CREATE INDEX \"", _11, "\" ON ", _17); - zephir_concat_self(&indexSqlAfterCreate, _18 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_20, index, "getcolumns", NULL, 0); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SVSV(_16, "CREATE INDEX \"", _11, "\" ON ", _15); + zephir_concat_self(&indexSqlAfterCreate, _16 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_18, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_19, this_ptr, "getcolumnlist", &_16, 43, _20); + ZEPHIR_CALL_METHOD(&_17, this_ptr, "getcolumnlist", NULL, 44, _18); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_21); - ZEPHIR_CONCAT_SVS(_21, " (", _19, ");"); - zephir_concat_self(&indexSqlAfterCreate, _21 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_19); + ZEPHIR_CONCAT_SVS(_19, " (", _17, ");"); + zephir_concat_self(&indexSqlAfterCreate, _19 TSRMLS_CC); } } if (!(ZEPHIR_IS_EMPTY(indexSql))) { @@ -54284,64 +54412,64 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { } ZEPHIR_OBS_VAR(references); if (zephir_array_isset_string_fetch(&references, definition, SS("references"), 0 TSRMLS_CC)) { - zephir_is_iterable(references, &_23, &_22, 0, 0, "phalcon/db/dialect/postgresql.zep", 443); + zephir_is_iterable(references, &_21, &_20, 0, 0, "phalcon/db/dialect/postgresql.zep", 443); for ( - ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS - ; zephir_hash_move_forward_ex(_23, &_22) + ; zephir_hash_get_current_data_ex(_21, (void**) &_22, &_20) == SUCCESS + ; zephir_hash_move_forward_ex(_21, &_20) ) { - ZEPHIR_GET_HVALUE(reference, _24); + ZEPHIR_GET_HVALUE(reference, _22); ZEPHIR_CALL_METHOD(&_3, reference, "getname", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_16, 43, _7); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 44, _7); zephir_check_call_status(); ZEPHIR_INIT_NVAR(referenceSql); ZEPHIR_CONCAT_SVSVS(referenceSql, "CONSTRAINT \"", _3, "\" FOREIGN KEY (", _4, ") REFERENCES "); ZEPHIR_CALL_METHOD(&_11, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_10, this_ptr, "preparetable", NULL, 143, _11, schemaName); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "preparetable", NULL, 144, _11, schemaName); zephir_check_call_status(); zephir_concat_self(&referenceSql, _10 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0); + ZEPHIR_CALL_METHOD(&_17, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_17, this_ptr, "getcolumnlist", &_16, 43, _19); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", NULL, 44, _17); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); - ZEPHIR_CONCAT_SVS(_9, " (", _17, ")"); + ZEPHIR_CONCAT_SVS(_9, " (", _15, ")"); zephir_concat_self(&referenceSql, _9 TSRMLS_CC); ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0); zephir_check_call_status(); if (!(ZEPHIR_IS_EMPTY(onDelete))) { - ZEPHIR_INIT_LNVAR(_18); - ZEPHIR_CONCAT_SV(_18, " ON DELETE ", onDelete); - zephir_concat_self(&referenceSql, _18 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SV(_16, " ON DELETE ", onDelete); + zephir_concat_self(&referenceSql, _16 TSRMLS_CC); } ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0); zephir_check_call_status(); if (!(ZEPHIR_IS_EMPTY(onUpdate))) { - ZEPHIR_INIT_LNVAR(_21); - ZEPHIR_CONCAT_SV(_21, " ON UPDATE ", onUpdate); - zephir_concat_self(&referenceSql, _21 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_19); + ZEPHIR_CONCAT_SV(_19, " ON UPDATE ", onUpdate); + zephir_concat_self(&referenceSql, _19 TSRMLS_CC); } zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 441); } } - ZEPHIR_INIT_NVAR(_12); - zephir_fast_join_str(_12, SL(",\n\t"), createLines TSRMLS_CC); + ZEPHIR_INIT_VAR(_23); + zephir_fast_join_str(_23, SL(",\n\t"), createLines TSRMLS_CC); ZEPHIR_INIT_LNVAR(_9); - ZEPHIR_CONCAT_VS(_9, _12, "\n)"); + ZEPHIR_CONCAT_VS(_9, _23, "\n)"); zephir_concat_self(&sql, _9 TSRMLS_CC); if (zephir_array_isset_string(definition, SS("options"))) { ZEPHIR_CALL_METHOD(&_3, this_ptr, "_gettableoptions", NULL, 0, definition); zephir_check_call_status(); - ZEPHIR_INIT_VAR(_25); - ZEPHIR_CONCAT_SV(_25, " ", _3); - zephir_concat_self(&sql, _25 TSRMLS_CC); + ZEPHIR_INIT_VAR(_24); + ZEPHIR_CONCAT_SV(_24, " ", _3); + zephir_concat_self(&sql, _24 TSRMLS_CC); } - ZEPHIR_INIT_LNVAR(_25); - ZEPHIR_CONCAT_SV(_25, ";", indexSqlAfterCreate); - zephir_concat_self(&sql, _25 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_24); + ZEPHIR_CONCAT_SV(_24, ";", indexSqlAfterCreate); + zephir_concat_self(&sql, _24 TSRMLS_CC); RETURN_CCTOR(sql); } @@ -54892,7 +55020,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, getColumnDefinition) { ZEPHIR_GET_HVALUE(value, _5); ZEPHIR_SINIT_NVAR(_6); ZVAL_STRING(&_6, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_7, 141, value, &_6); + ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_7, 142, value, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "\"", _0, "\", "); @@ -54910,7 +55038,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, getColumnDefinition) { } else { ZEPHIR_SINIT_NVAR(_8); ZVAL_STRING(&_8, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_7, 141, typeValues, &_8); + ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_7, 142, typeValues, &_8); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVS(_10, "(\"", _2, "\")"); @@ -54972,7 +55100,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 142, defaultValue, &_4); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\""); @@ -55136,7 +55264,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addIndex) { } ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 43, _2); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 44, _2); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_VS(_1, _0, ")"); @@ -55841,13 +55969,17 @@ ZEPHIR_INIT_CLASS(Phalcon_Db_Profiler_Item) { static PHP_METHOD(Phalcon_Db_Profiler_Item, setSqlStatement) { - zval *sqlStatement; + zval *sqlStatement_param = NULL; + zval *sqlStatement = NULL; - zephir_fetch_params(0, 1, 0, &sqlStatement); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &sqlStatement_param); + zephir_get_strval(sqlStatement, sqlStatement_param); zephir_update_property_this(this_ptr, SL("_sqlStatement"), sqlStatement TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -55860,13 +55992,17 @@ static PHP_METHOD(Phalcon_Db_Profiler_Item, getSqlStatement) { static PHP_METHOD(Phalcon_Db_Profiler_Item, setSqlVariables) { - zval *sqlVariables; + zval *sqlVariables_param = NULL; + zval *sqlVariables = NULL; - zephir_fetch_params(0, 1, 0, &sqlVariables); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &sqlVariables_param); + zephir_get_arrval(sqlVariables, sqlVariables_param); zephir_update_property_this(this_ptr, SL("_sqlVariables"), sqlVariables TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -55879,13 +56015,17 @@ static PHP_METHOD(Phalcon_Db_Profiler_Item, getSqlVariables) { static PHP_METHOD(Phalcon_Db_Profiler_Item, setSqlBindTypes) { - zval *sqlBindTypes; + zval *sqlBindTypes_param = NULL; + zval *sqlBindTypes = NULL; - zephir_fetch_params(0, 1, 0, &sqlBindTypes); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &sqlBindTypes_param); + zephir_get_arrval(sqlBindTypes, sqlBindTypes_param); zephir_update_property_this(this_ptr, SL("_sqlBindTypes"), sqlBindTypes TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -55898,13 +56038,17 @@ static PHP_METHOD(Phalcon_Db_Profiler_Item, getSqlBindTypes) { static PHP_METHOD(Phalcon_Db_Profiler_Item, setInitialTime) { - zval *initialTime; + zval *initialTime_param = NULL, *_0; + double initialTime; - zephir_fetch_params(0, 1, 0, &initialTime); + zephir_fetch_params(0, 1, 0, &initialTime_param); + initialTime = zephir_get_doubleval(initialTime_param); - zephir_update_property_this(this_ptr, SL("_initialTime"), initialTime TSRMLS_CC); + ZEPHIR_INIT_ZVAL_NREF(_0); + ZVAL_DOUBLE(_0, initialTime); + zephir_update_property_this(this_ptr, SL("_initialTime"), _0 TSRMLS_CC); } @@ -55917,13 +56061,17 @@ static PHP_METHOD(Phalcon_Db_Profiler_Item, getInitialTime) { static PHP_METHOD(Phalcon_Db_Profiler_Item, setFinalTime) { - zval *finalTime; + zval *finalTime_param = NULL, *_0; + double finalTime; - zephir_fetch_params(0, 1, 0, &finalTime); + zephir_fetch_params(0, 1, 0, &finalTime_param); + finalTime = zephir_get_doubleval(finalTime_param); - zephir_update_property_this(this_ptr, SL("_finalTime"), finalTime TSRMLS_CC); + ZEPHIR_INIT_ZVAL_NREF(_0); + ZVAL_DOUBLE(_0, finalTime); + zephir_update_property_this(this_ptr, SL("_finalTime"), _0 TSRMLS_CC); } @@ -56425,7 +56573,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, all) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "variables", 1); zephir_array_fast_append(_0, _1); - ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 166); + ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 167); zephir_check_call_status(); ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, _0, _2); zephir_check_call_status(); @@ -56576,7 +56724,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { add_assoc_long_ex(_1, SS(":count"), zephir_fast_count_int(variable TSRMLS_CC)); ZEPHIR_SINIT_VAR(_5); ZVAL_STRING(&_5, "Array (:count) (\n", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); zephir_concat_self(&output, _2 TSRMLS_CC); zephir_is_iterable(variable, &_8, &_7, 0, 0, "phalcon/debug/dump.zep", 154); @@ -56588,7 +56736,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZEPHIR_GET_HVALUE(value, _9); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -56601,7 +56749,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_12, SL(":key"), &key, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "[:key] => ", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _10, _13); @@ -56625,7 +56773,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 167, value, _3, &_5); + ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 168, value, _3, &_5); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); @@ -56635,7 +56783,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab - 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_CONCAT_VVS(return_value, output, _10, ")"); RETURN_MM(); @@ -56654,10 +56802,10 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":class"), &_3, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Object :class", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); zephir_concat_self(&output, _2 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 168, variable); + ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 169, variable); zephir_check_call_status(); if (zephir_is_true(_13)) { ZEPHIR_INIT_NVAR(_12); @@ -56668,19 +56816,19 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_check_temp_parameter(_3); zephir_check_call_status(); zephir_array_update_string(&_12, SL(":style"), &_18, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 168, variable); + ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 169, variable); zephir_check_call_status(); zephir_array_update_string(&_12, SL(":parent"), &_18, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, " extends :parent", 0); - ZEPHIR_CALL_FUNCTION(&_18, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_18, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); zephir_concat_self(&output, _18 TSRMLS_CC); } zephir_concat_self_str(&output, SL(" (\n") TSRMLS_CC); _22 = zephir_fetch_nproperty_this(this_ptr, SL("_detailed"), PH_NOISY_CC); if (!(zephir_is_true(_22))) { - ZEPHIR_CALL_FUNCTION(&_10, "get_object_vars", NULL, 23, variable); + ZEPHIR_CALL_FUNCTION(&_10, "get_object_vars", NULL, 24, variable); zephir_check_call_status(); zephir_is_iterable(_10, &_24, &_23, 0, 0, "phalcon/debug/dump.zep", 171); for ( @@ -56691,7 +56839,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZEPHIR_GET_HVALUE(value, _25); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_13, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_13, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 3, 0 TSRMLS_CC); @@ -56705,7 +56853,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { add_assoc_stringl_ex(_12, SS(":type"), SL("public"), 1); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:key (:type) = ", 0); - ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _13, _26); @@ -56714,7 +56862,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5); + ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 168, value, _3, &_5); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); @@ -56724,7 +56872,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } else { do { Z_SET_ISREF_P(variable); - ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 169, variable); + ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 170, variable); Z_UNSET_ISREF_P(variable); zephir_check_call_status(); if (!(zephir_is_true(attr))) { @@ -56740,9 +56888,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZEPHIR_INIT_NVAR(_3); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "\\x00", 0); - ZEPHIR_CALL_FUNCTION(&_10, "ord", &_29, 130, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "ord", &_29, 132, &_5); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_13, "chr", &_30, 128, _10); + ZEPHIR_CALL_FUNCTION(&_13, "chr", &_30, 130, _10); zephir_check_call_status(); zephir_fast_explode(_3, _13, key, LONG_MAX TSRMLS_CC); ZEPHIR_CPY_WRT(key, _3); @@ -56759,7 +56907,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 3, 0 TSRMLS_CC); @@ -56770,14 +56918,14 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_check_call_status(); zephir_array_update_string(&_12, SL(":style"), &_26, PH_COPY | PH_SEPARATE); Z_SET_ISREF_P(key); - ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 170, key); + ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 171, key); Z_UNSET_ISREF_P(key); zephir_check_call_status(); zephir_array_update_string(&_12, SL(":key"), &_26, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_12, SL(":type"), &type, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:key (:type) = ", 0); - ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _18, _26); @@ -56786,7 +56934,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5); + ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 168, value, _3, &_5); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); @@ -56794,11 +56942,11 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_concat_self(&output, _20 TSRMLS_CC); } while (zephir_is_true(attr)); } - ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 171, variable); + ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 172, variable); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 3, 0 TSRMLS_CC); @@ -56814,7 +56962,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { add_assoc_long_ex(_12, SS(":count"), zephir_fast_count_int(attr TSRMLS_CC)); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, ":class methods: (:count) (\n", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _10, _13); @@ -56825,7 +56973,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { if (zephir_fast_in_array(_3, _33 TSRMLS_CC)) { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); ZEPHIR_CONCAT_VS(_20, _18, "[already listed]\n"); @@ -56843,7 +56991,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { if (ZEPHIR_IS_STRING(value, "__construct")) { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -56856,7 +57004,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_12, SL(":method"), &value, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:method(); [constructor]\n", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _10, _13); @@ -56864,7 +57012,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } else { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_FUNCTION(&_26, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_26, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_38); zephir_create_array(_38, 2, 0 TSRMLS_CC); @@ -56877,7 +57025,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_38, SL(":method"), &value, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:method();\n", 0); - ZEPHIR_CALL_FUNCTION(&_27, "strtr", &_6, 53, &_5, _38); + ZEPHIR_CALL_FUNCTION(&_27, "strtr", &_6, 54, &_5, _38); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_39); ZEPHIR_CONCAT_VV(_39, _26, _27); @@ -56886,7 +57034,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); ZEPHIR_CONCAT_VS(_20, _18, ")\n"); @@ -56894,7 +57042,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab - 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_CONCAT_VVS(return_value, output, _10, ")"); RETURN_MM(); @@ -56911,12 +57059,12 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Integer (:var)", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); } - ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 172, variable); + ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 173, variable); zephir_check_call_status(); if (zephir_is_true(_2)) { ZEPHIR_INIT_NVAR(_1); @@ -56930,7 +57078,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Float (:var)", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _13); RETURN_MM(); @@ -56948,7 +57096,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Numeric string (:length) \":var\"", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -56967,14 +57115,14 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_LONG(&_5, 4); ZEPHIR_SINIT_VAR(_40); ZVAL_STRING(&_40, "utf-8", 0); - ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 151, variable, &_5, &_40); + ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 152, variable, &_5, &_40); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_26, "nl2br", NULL, 173, _2); + ZEPHIR_CALL_FUNCTION(&_26, "nl2br", NULL, 174, _2); zephir_check_call_status(); zephir_array_update_string(&_1, SL(":var"), &_26, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "String (:length) \":var\"", 0); - ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _26); RETURN_MM(); @@ -56999,7 +57147,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &_14, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Boolean (:var)", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -57015,7 +57163,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":style"), &_2, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "NULL", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -57031,7 +57179,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "(:var)", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -57069,7 +57217,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, variable) { zephir_array_update_string(&_0, SL(":output"), &_1, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "
:output
", 0); - ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 53, &_3, _0); + ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 54, &_3, _0); zephir_check_call_status(); RETURN_MM(); @@ -57087,7 +57235,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, variables) { ZEPHIR_INIT_VAR(output); ZVAL_STRING(output, "", 1); - ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 166); + ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 167); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/debug/dump.zep", 290); for ( @@ -57196,7 +57344,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_ce, this_ptr, "__construct", &_0, 73); + ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_ce, this_ptr, "__construct", &_0, 75); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 21, 0 TSRMLS_CC); @@ -57208,7 +57356,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Router", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_VAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57221,7 +57369,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Dispatcher", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57234,7 +57382,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Url", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57247,7 +57395,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57260,7 +57408,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\MetaData\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57273,7 +57421,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Http\\Response", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57286,7 +57434,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Http\\Response\\Cookies", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57299,7 +57447,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Http\\Request", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57312,7 +57460,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Filter", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57325,7 +57473,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Escaper", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57338,7 +57486,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Security", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57351,7 +57499,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Crypt", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57364,7 +57512,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Annotations\\Adapter\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57377,7 +57525,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Flash\\Direct", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57390,7 +57538,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Flash\\Session", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57403,7 +57551,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Tag", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57416,7 +57564,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Session\\Adapter\\Files", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57427,7 +57575,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_3, "sessionBag", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_4); ZVAL_STRING(_4, "Phalcon\\Session\\Bag", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57440,7 +57588,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Events\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57448,12 +57596,12 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZEPHIR_INIT_NVAR(_2); object_init_ex(_2, phalcon_di_service_ce); ZEPHIR_INIT_NVAR(_3); - ZVAL_STRING(_3, "transactions", ZEPHIR_TEMP_PARAM_COPY); + ZVAL_STRING(_3, "transactionManager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_4); ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Transaction\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57466,7 +57614,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Assets\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57846,7 +57994,7 @@ static PHP_METHOD(Phalcon_Di_Service, resolve) { ZEPHIR_CALL_METHOD(NULL, builder, "__construct", NULL, 0); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 175, dependencyInjector, definition, parameters); + ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 176, dependencyInjector, definition, parameters); zephir_check_call_status(); } else { found = 0; @@ -57969,7 +58117,7 @@ static PHP_METHOD(Phalcon_Di_Service, __set_state) { return; } object_init_ex(return_value, phalcon_di_service_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 61, name, definition, shared); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 63, name, definition, shared); zephir_check_call_status(); RETURN_MM(); @@ -58009,6 +58157,8 @@ ZEPHIR_DOC_METHOD(Phalcon_Di_ServiceInterface, getDefinition); ZEPHIR_DOC_METHOD(Phalcon_Di_ServiceInterface, resolve); +ZEPHIR_DOC_METHOD(Phalcon_Di_ServiceInterface, setParameter); + ZEPHIR_DOC_METHOD(Phalcon_Di_ServiceInterface, __set_state); @@ -58042,7 +58192,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 174); + ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 175); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 10, 0 TSRMLS_CC); @@ -58054,7 +58204,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\CLI\\Router", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_VAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58067,7 +58217,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\CLI\\Dispatcher", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58080,7 +58230,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58093,7 +58243,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\MetaData\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58106,7 +58256,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Filter", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58119,7 +58269,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Escaper", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58132,7 +58282,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Annotations\\Adapter\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58145,7 +58295,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Security", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58158,7 +58308,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Events\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58171,7 +58321,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Transaction\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58344,7 +58494,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, _buildParameters) { ) { ZEPHIR_GET_HMKEY(position, _1, _0); ZEPHIR_GET_HVALUE(argument, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 176, dependencyInjector, position, argument); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 177, dependencyInjector, position, argument); zephir_check_call_status(); zephir_array_append(&buildArguments, _3, PH_SEPARATE, "phalcon/di/service/builder.zep", 117); } @@ -58389,7 +58539,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { } else { ZEPHIR_OBS_VAR(arguments); if (zephir_array_isset_string_fetch(&arguments, definition, SS("arguments"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 178, dependencyInjector, arguments); zephir_check_call_status(); ZEPHIR_INIT_NVAR(instance); ZEPHIR_LAST_CALL_STATUS = zephir_create_instance_params(instance, className, _0 TSRMLS_CC); @@ -58410,7 +58560,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "Setter injection parameters must be an array", "phalcon/di/service/builder.zep", 181); return; } - zephir_is_iterable(paramCalls, &_3, &_2, 0, 0, "phalcon/di/service/builder.zep", 235); + zephir_is_iterable(paramCalls, &_3, &_2, 0, 0, "phalcon/di/service/builder.zep", 233); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -58459,7 +58609,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { } if (zephir_fast_count_int(arguments TSRMLS_CC)) { ZEPHIR_INIT_NVAR(_5); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 178, dependencyInjector, arguments); zephir_check_call_status(); ZEPHIR_CALL_USER_FUNC_ARRAY(_5, methodCall, _0); zephir_check_call_status(); @@ -58474,14 +58624,14 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_OBS_NVAR(paramCalls); if (zephir_array_isset_string_fetch(¶mCalls, definition, SS("properties"), 0 TSRMLS_CC)) { if (Z_TYPE_P(instance) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "The definition has properties injection parameters but the constructor didn't return an instance", "phalcon/di/service/builder.zep", 243); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "The definition has properties injection parameters but the constructor didn't return an instance", "phalcon/di/service/builder.zep", 241); return; } if (Z_TYPE_P(paramCalls) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "Setter injection parameters must be an array", "phalcon/di/service/builder.zep", 247); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "Setter injection parameters must be an array", "phalcon/di/service/builder.zep", 245); return; } - zephir_is_iterable(paramCalls, &_9, &_8, 0, 0, "phalcon/di/service/builder.zep", 282); + zephir_is_iterable(paramCalls, &_9, &_8, 0, 0, "phalcon/di/service/builder.zep", 279); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) @@ -58495,7 +58645,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_CONCAT_SV(_6, "Property must be an array on position ", propertyPosition); ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_11, "phalcon/di/service/builder.zep", 259 TSRMLS_CC); + zephir_throw_exception_debug(_11, "phalcon/di/service/builder.zep", 257 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -58507,7 +58657,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_CONCAT_SV(_6, "The property name is required on position ", propertyPosition); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 266 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 264 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -58519,11 +58669,11 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_CONCAT_SV(_6, "The property value is required on position ", propertyPosition); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 273 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 271 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 176, dependencyInjector, propertyPosition, propertyValue); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 177, dependencyInjector, propertyPosition, propertyValue); zephir_check_call_status(); zephir_update_property_zval_zval(instance, propertyName, _0 TSRMLS_CC); } @@ -58588,13 +58738,17 @@ ZEPHIR_INIT_CLASS(Phalcon_Events_Event) { static PHP_METHOD(Phalcon_Events_Event, setType) { - zval *type; + zval *type_param = NULL; + zval *type = NULL; - zephir_fetch_params(0, 1, 0, &type); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &type_param); + zephir_get_strval(type, type_param); zephir_update_property_this(this_ptr, SL("_type"), type TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -58827,7 +58981,7 @@ static PHP_METHOD(Phalcon_Events_Manager, attach) { } ZEPHIR_INIT_VAR(_2); ZVAL_LONG(_2, 1); - ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 184, _2); + ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 185, _2); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_events"), eventType, priorityQueue TSRMLS_CC); } else { @@ -58837,7 +58991,7 @@ static PHP_METHOD(Phalcon_Events_Manager, attach) { if (Z_TYPE_P(priorityQueue) == IS_OBJECT) { ZEPHIR_INIT_NVAR(_2); ZVAL_LONG(_2, priority); - ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 185, handler, _2); + ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 186, handler, _2); zephir_check_call_status(); } else { zephir_array_append(&priorityQueue, handler, PH_SEPARATE, "phalcon/events/manager.zep", 82); @@ -58886,7 +59040,7 @@ static PHP_METHOD(Phalcon_Events_Manager, detach) { } ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 1); - ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 184, _1); + ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 185, _1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_1); ZVAL_LONG(_1, 3); @@ -58908,13 +59062,13 @@ static PHP_METHOD(Phalcon_Events_Manager, detach) { if (!ZEPHIR_IS_IDENTICAL(_5, handler)) { zephir_array_fetch_string(&_6, data, SL("data"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC); zephir_array_fetch_string(&_7, data, SL("priority"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 185, _6, _7); + ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 186, _6, _7); zephir_check_call_status(); } } zephir_update_property_array(this_ptr, SL("_events"), eventType, newPriorityQueue TSRMLS_CC); } else { - ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 186, handler, priorityQueue, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 187, handler, priorityQueue, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); if (!ZEPHIR_IS_FALSE_IDENTICAL(key)) { zephir_array_unset(&priorityQueue, key, PH_SEPARATE); @@ -59070,7 +59224,7 @@ static PHP_METHOD(Phalcon_Events_Manager, fireQueue) { zephir_get_class(_1, queue, 0 TSRMLS_CC); ZEPHIR_SINIT_VAR(_2); ZVAL_STRING(&_2, "Unexpected value type: expected object of type SplPriorityQueue, %s given", 0); - ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 187, &_2, _1); + ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 188, &_2, _1); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); @@ -59283,9 +59437,9 @@ static PHP_METHOD(Phalcon_Events_Manager, fire) { if (_3) { ZEPHIR_INIT_NVAR(event); object_init_ex(event, phalcon_events_event_ce); - ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 189, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event); + ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 190, fireEvents, event); zephir_check_call_status(); } } @@ -59299,10 +59453,10 @@ static PHP_METHOD(Phalcon_Events_Manager, fire) { if (Z_TYPE_P(event) == IS_NULL) { ZEPHIR_INIT_NVAR(event); object_init_ex(event, phalcon_events_event_ce); - ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 189, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event); + ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 190, fireEvents, event); zephir_check_call_status(); } } @@ -59515,7 +59669,7 @@ static PHP_METHOD(Phalcon_Flash_Direct, output) { } } if (remove) { - ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 196); + ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 197); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -59788,7 +59942,7 @@ static PHP_METHOD(Phalcon_Flash_Session, output) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 196); + ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 197); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -59806,7 +59960,7 @@ static PHP_METHOD(Phalcon_Flash_Session, clear) { ZVAL_BOOL(_0, 1); ZEPHIR_CALL_METHOD(NULL, this_ptr, "_getsessionmessages", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 196); + ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 197); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -60932,7 +61086,7 @@ static PHP_METHOD(Phalcon_Forms_Form, isValid) { } else { ZEPHIR_INIT_NVAR(validation); object_init_ex(validation, phalcon_validation_ce); - ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 210, preparedValidators); + ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 211, preparedValidators); zephir_check_call_status(); } ZEPHIR_CALL_METHOD(&filters, element, "getfilters", NULL, 0); @@ -60940,10 +61094,10 @@ static PHP_METHOD(Phalcon_Forms_Form, isValid) { if (Z_TYPE_P(filters) == IS_ARRAY) { ZEPHIR_CALL_METHOD(&_2, element, "getname", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 211, _2, filters); + ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 212, _2, filters); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 212, data, entity); + ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 213, data, entity); zephir_check_call_status(); if (zephir_fast_count_int(elementMessages TSRMLS_CC)) { ZEPHIR_CALL_METHOD(&_14, element, "getname", NULL, 0); @@ -61006,7 +61160,7 @@ static PHP_METHOD(Phalcon_Forms_Form, getMessages) { ; zephir_hash_move_forward_ex(_2, &_1) ) { ZEPHIR_GET_HVALUE(elementMessages, _3); - ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 213, elementMessages); + ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 214, elementMessages); zephir_check_call_status(); } } @@ -61476,7 +61630,7 @@ static PHP_METHOD(Phalcon_Forms_Form, rewind) { ZVAL_LONG(_0, 0); zephir_update_property_this(this_ptr, SL("_position"), _0 TSRMLS_CC); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_elements"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 214, _0); + ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 215, _0); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_elementsIndexed"), _1 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -61568,7 +61722,7 @@ static PHP_METHOD(Phalcon_Forms_Manager, create) { } ZEPHIR_INIT_VAR(form); object_init_ex(form, phalcon_forms_form_ce); - ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 215, entity); + ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 216, entity); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_forms"), name, form TSRMLS_CC); RETURN_CCTOR(form); @@ -61677,7 +61831,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Check, render) { ZVAL_BOOL(_2, 1); ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 197, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 198, _1); zephir_check_call_status(); RETURN_MM(); @@ -61722,7 +61876,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Date, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 198, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 199, _1); zephir_check_call_status(); RETURN_MM(); @@ -61767,7 +61921,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Email, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 199, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 200, _1); zephir_check_call_status(); RETURN_MM(); @@ -61812,7 +61966,7 @@ static PHP_METHOD(Phalcon_Forms_Element_File, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 200, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 201, _1); zephir_check_call_status(); RETURN_MM(); @@ -61857,7 +62011,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Hidden, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 201, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 202, _1); zephir_check_call_status(); RETURN_MM(); @@ -61902,7 +62056,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Numeric, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 202, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 203, _1); zephir_check_call_status(); RETURN_MM(); @@ -61947,7 +62101,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Password, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 203, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 204, _1); zephir_check_call_status(); RETURN_MM(); @@ -61994,7 +62148,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Radio, render) { ZVAL_BOOL(_2, 1); ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 204, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 205, _1); zephir_check_call_status(); RETURN_MM(); @@ -62045,7 +62199,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Select, __construct) { zephir_update_property_this(this_ptr, SL("_optionsValues"), options TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 205, name, attributes); + ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 206, name, attributes); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -62073,14 +62227,29 @@ static PHP_METHOD(Phalcon_Forms_Element_Select, getOptions) { static PHP_METHOD(Phalcon_Forms_Element_Select, addOption) { - zval *option; + HashTable *_1; + HashPosition _0; + zval *option, *key = NULL, *value = NULL, **_2; - zephir_fetch_params(0, 1, 0, &option); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &option); - zephir_update_property_array_append(this_ptr, SL("_optionsValues"), option TSRMLS_CC); - RETURN_THISW(); + if (Z_TYPE_P(option) == IS_ARRAY) { + zephir_is_iterable(option, &_1, &_0, 0, 0, "phalcon/forms/element/select.zep", 85); + for ( + ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS + ; zephir_hash_move_forward_ex(_1, &_0) + ) { + ZEPHIR_GET_HMKEY(key, _1, _0); + ZEPHIR_GET_HVALUE(value, _2); + zephir_update_property_array(this_ptr, SL("_optionsValues"), key, value TSRMLS_CC); + } + } else { + zephir_update_property_array_append(this_ptr, SL("_optionsValues"), option TSRMLS_CC); + } + RETURN_THIS(); } @@ -62101,7 +62270,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Select, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); _2 = zephir_fetch_nproperty_this(this_ptr, SL("_optionsValues"), PH_NOISY_CC); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, _1, _2); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 207, _1, _2); zephir_check_call_status(); RETURN_MM(); @@ -62146,7 +62315,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Submit, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 207, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 208, _1); zephir_check_call_status(); RETURN_MM(); @@ -62191,7 +62360,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Text, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 208, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 209, _1); zephir_check_call_status(); RETURN_MM(); @@ -62236,7 +62405,7 @@ static PHP_METHOD(Phalcon_Forms_Element_TextArea, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 209, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 210, _1); zephir_check_call_status(); RETURN_MM(); @@ -62284,6 +62453,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Http_Cookie) { zend_declare_property_bool(phalcon_http_cookie_ce, SL("_httpOnly"), 1, ZEND_ACC_PROTECTED TSRMLS_CC); + zend_class_implements(phalcon_http_cookie_ce TSRMLS_CC, 1, phalcon_http_cookieinterface_ce); zend_class_implements(phalcon_http_cookie_ce TSRMLS_CC, 1, phalcon_di_injectionawareinterface_ce); return SUCCESS; @@ -62516,16 +62686,20 @@ static PHP_METHOD(Phalcon_Http_Cookie, send) { zephir_check_temp_parameter(_1); zephir_check_call_status(); ZEPHIR_CPY_WRT(session, _0); - ZEPHIR_INIT_VAR(_2); - ZEPHIR_CONCAT_SV(_2, "_PHCOOKIE_", name); - ZEPHIR_CALL_METHOD(NULL, session, "set", NULL, 0, _2, definition); + ZEPHIR_CALL_METHOD(&_0, session, "isstarted", NULL, 0); zephir_check_call_status(); + if (zephir_is_true(_0)) { + ZEPHIR_INIT_VAR(_2); + ZEPHIR_CONCAT_SV(_2, "_PHCOOKIE_", name); + ZEPHIR_CALL_METHOD(NULL, session, "set", NULL, 0, _2, definition); + zephir_check_call_status(); + } } _3 = zephir_fetch_nproperty_this(this_ptr, SL("_useEncryption"), PH_NOISY_CC); if (zephir_is_true(_3)) { if (!(ZEPHIR_IS_EMPTY(value))) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "A dependency injection object is required to access the 'filter' service", "phalcon/http/cookie.zep", 258); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "A dependency injection object is required to access the 'filter' service", "phalcon/http/cookie.zep", 260); return; } ZEPHIR_INIT_NVAR(_1); @@ -62543,7 +62717,7 @@ static PHP_METHOD(Phalcon_Http_Cookie, send) { } else { ZEPHIR_CPY_WRT(encryptValue, value); } - ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, encryptValue, expire, path, domain, secure, httpOnly); + ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 217, name, encryptValue, expire, path, domain, secure, httpOnly); zephir_check_call_status(); RETURN_THIS(); @@ -62552,7 +62726,7 @@ static PHP_METHOD(Phalcon_Http_Cookie, send) { static PHP_METHOD(Phalcon_Http_Cookie, restore) { int ZEPHIR_LAST_CALL_STATUS; - zval *dependencyInjector, *expire, *domain, *path, *secure, *httpOnly, *session = NULL, *definition = NULL, *_0, *_1, *_2, *_3; + zval *dependencyInjector, *expire, *domain, *path, *secure, *httpOnly, *session = NULL, *definition = NULL, *_0, *_1, *_2 = NULL, *_3, *_4; ZEPHIR_MM_GROW(); @@ -62566,26 +62740,30 @@ static PHP_METHOD(Phalcon_Http_Cookie, restore) { ZEPHIR_CALL_METHOD(&session, dependencyInjector, "getshared", NULL, 0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_3); - ZEPHIR_CONCAT_SV(_3, "_PHCOOKIE_", _2); - ZEPHIR_CALL_METHOD(&definition, session, "get", NULL, 0, _3); + ZEPHIR_CALL_METHOD(&_2, session, "isstarted", NULL, 0); zephir_check_call_status(); - if (Z_TYPE_P(definition) == IS_ARRAY) { - if (zephir_array_isset_string_fetch(&expire, definition, SS("expire"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_expire"), expire TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&domain, definition, SS("domain"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_domain"), domain TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&path, definition, SS("path"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_path"), path TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&secure, definition, SS("secure"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_secure"), secure TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&httpOnly, definition, SS("httpOnly"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_httpOnly"), httpOnly TSRMLS_CC); + if (zephir_is_true(_2)) { + _3 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); + ZEPHIR_INIT_VAR(_4); + ZEPHIR_CONCAT_SV(_4, "_PHCOOKIE_", _3); + ZEPHIR_CALL_METHOD(&definition, session, "get", NULL, 0, _4); + zephir_check_call_status(); + if (Z_TYPE_P(definition) == IS_ARRAY) { + if (zephir_array_isset_string_fetch(&expire, definition, SS("expire"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_expire"), expire TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&domain, definition, SS("domain"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_domain"), domain TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&path, definition, SS("path"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_path"), path TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&secure, definition, SS("secure"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_secure"), secure TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&httpOnly, definition, SS("httpOnly"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_httpOnly"), httpOnly TSRMLS_CC); + } } } } @@ -62621,17 +62799,21 @@ static PHP_METHOD(Phalcon_Http_Cookie, delete) { zephir_check_temp_parameter(_2); zephir_check_call_status(); ZEPHIR_CPY_WRT(session, _1); - ZEPHIR_INIT_VAR(_3); - ZEPHIR_CONCAT_SV(_3, "_PHCOOKIE_", name); - ZEPHIR_CALL_METHOD(NULL, session, "remove", NULL, 0, _3); + ZEPHIR_CALL_METHOD(&_1, session, "isstarted", NULL, 0); zephir_check_call_status(); + if (zephir_is_true(_1)) { + ZEPHIR_INIT_VAR(_3); + ZEPHIR_CONCAT_SV(_3, "_PHCOOKIE_", name); + ZEPHIR_CALL_METHOD(NULL, session, "remove", NULL, 0, _3); + zephir_check_call_status(); + } } zephir_update_property_this(this_ptr, SL("_value"), ZEPHIR_GLOBAL(global_null) TSRMLS_CC); ZEPHIR_INIT_NVAR(_2); zephir_time(_2); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, (zephir_get_numberval(_2) - 691200)); - ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly); + ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 217, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -62895,6 +63077,60 @@ static PHP_METHOD(Phalcon_Http_Cookie, __toString) { +#ifdef HAVE_CONFIG_H +#endif + +#include + +#include + + + +ZEPHIR_INIT_CLASS(Phalcon_Http_CookieInterface) { + + ZEPHIR_REGISTER_INTERFACE(Phalcon\\Http, CookieInterface, phalcon, http_cookieinterface, phalcon_http_cookieinterface_method_entry); + + return SUCCESS; + +} + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setValue); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getValue); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, send); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, delete); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, useEncryption); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, isUsingEncryption); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setExpiration); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getExpiration); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setPath); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getName); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getPath); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setDomain); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getDomain); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setSecure); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getSecure); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setHttpOnly); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getHttpOnly); + + + + #ifdef HAVE_CONFIG_H #endif @@ -62988,7 +63224,7 @@ static PHP_METHOD(Phalcon_Http_Request, get) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -63039,7 +63275,7 @@ static PHP_METHOD(Phalcon_Http_Request, getPost) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -63097,12 +63333,12 @@ static PHP_METHOD(Phalcon_Http_Request, getPut) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getrawbody", NULL, 0); zephir_check_call_status(); Z_SET_ISREF_P(put); - ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 218, _0, put); + ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 219, _0, put); Z_UNSET_ISREF_P(put); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_putCache"), put TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -63153,7 +63389,7 @@ static PHP_METHOD(Phalcon_Http_Request, getQuery) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -63435,7 +63671,7 @@ static PHP_METHOD(Phalcon_Http_Request, getHeader) { ZVAL_STRING(&_0, "-", 0); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "_", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, header, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, header, &_0, &_1); zephir_check_call_status(); ZEPHIR_INIT_VAR(name); zephir_fast_strtoupper(name, _2); @@ -63590,7 +63826,7 @@ static PHP_METHOD(Phalcon_Http_Request, getServerAddress) { } ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "localhost", 0); - ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 219, &_0); + ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 220, &_0); zephir_check_call_status(); RETURN_MM(); @@ -63781,7 +64017,7 @@ static PHP_METHOD(Phalcon_Http_Request, isMethod) { } - ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); if (Z_TYPE_P(methods) == IS_STRING) { _0 = strict; @@ -63853,7 +64089,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPost) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "POST")); @@ -63866,7 +64102,7 @@ static PHP_METHOD(Phalcon_Http_Request, isGet) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "GET")); @@ -63879,7 +64115,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPut) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PUT")); @@ -63892,7 +64128,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPatch) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PATCH")); @@ -63905,7 +64141,7 @@ static PHP_METHOD(Phalcon_Http_Request, isHead) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "HEAD")); @@ -63918,7 +64154,7 @@ static PHP_METHOD(Phalcon_Http_Request, isDelete) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "DELETE")); @@ -63931,7 +64167,7 @@ static PHP_METHOD(Phalcon_Http_Request, isOptions) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "OPTIONS")); @@ -63979,7 +64215,7 @@ static PHP_METHOD(Phalcon_Http_Request, hasFiles) { } } if (Z_TYPE_P(error) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 222, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); numberFiles += zephir_get_numberval(_4); } @@ -64023,7 +64259,7 @@ static PHP_METHOD(Phalcon_Http_Request, hasFileHelper) { } } if (Z_TYPE_P(value) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 222, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); numberFiles += zephir_get_numberval(_4); } @@ -64072,7 +64308,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) { zephir_array_fetch_string(&_6, input, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC); zephir_array_fetch_string(&_7, input, SL("size"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC); zephir_array_fetch_string(&_8, input, SL("error"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 222, _4, _5, _6, _7, _8, prefix); + ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 223, _4, _5, _6, _7, _8, prefix); zephir_check_call_status(); zephir_is_iterable(smoothInput, &_11, &_10, 0, 0, "phalcon/http/request.zep", 714); for ( @@ -64106,7 +64342,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) { ZEPHIR_INIT_NVAR(_16); object_init_ex(_16, phalcon_http_request_file_ce); zephir_array_fetch_string(&_17, file, SL("key"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 711 TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, dataFile, _17); + ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 224, dataFile, _17); zephir_check_call_status(); zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 711); } @@ -64120,7 +64356,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) { if (_13) { ZEPHIR_INIT_NVAR(_16); object_init_ex(_16, phalcon_http_request_file_ce); - ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, input, prefix); + ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 224, input, prefix); zephir_check_call_status(); zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 716); } @@ -64193,7 +64429,7 @@ static PHP_METHOD(Phalcon_Http_Request, smoothFiles) { zephir_array_fetch(&_7, tmp_names, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC); zephir_array_fetch(&_8, sizes, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC); zephir_array_fetch(&_9, errors, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 222, _5, _6, _7, _8, _9, p); + ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 223, _5, _6, _7, _8, _9, p); zephir_check_call_status(); zephir_is_iterable(parentFiles, &_12, &_11, 0, 0, "phalcon/http/request.zep", 755); for ( @@ -64247,7 +64483,7 @@ static PHP_METHOD(Phalcon_Http_Request, getHeaders) { ZVAL_STRING(&_8, " ", 0); zephir_fast_str_replace(&_4, &_7, &_8, _6 TSRMLS_CC); zephir_fast_strtolower(_3, _4); - ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3); + ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 225, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_10); ZEPHIR_SINIT_NVAR(_11); @@ -64266,7 +64502,7 @@ static PHP_METHOD(Phalcon_Http_Request, getHeaders) { ZVAL_STRING(&_7, " ", 0); zephir_fast_str_replace(&_4, &_5, &_7, name TSRMLS_CC); zephir_fast_strtolower(_3, _4); - ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3); + ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 225, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_6); ZEPHIR_SINIT_NVAR(_8); @@ -64341,7 +64577,7 @@ static PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) { ZVAL_LONG(&_2, -1); ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 1); - ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 225, &_1, _0, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 226, &_1, _0, &_2, &_3); zephir_check_call_status(); zephir_is_iterable(_4, &_7, &_6, 0, 0, "phalcon/http/request.zep", 827); for ( @@ -64359,7 +64595,7 @@ static PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) { ZVAL_LONG(&_2, -1); ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 1); - ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 225, &_1, _9, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 226, &_1, _9, &_2, &_3); zephir_check_call_status(); zephir_is_iterable(_10, &_12, &_11, 0, 0, "phalcon/http/request.zep", 824); for ( @@ -64490,7 +64726,7 @@ static PHP_METHOD(Phalcon_Http_Request, getAcceptableContent) { ZVAL_STRING(_0, "HTTP_ACCEPT", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 227, _0, _1); zephir_check_temp_parameter(_0); zephir_check_temp_parameter(_1); zephir_check_call_status(); @@ -64509,7 +64745,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestAccept) { zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 228, _0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -64527,7 +64763,7 @@ static PHP_METHOD(Phalcon_Http_Request, getClientCharsets) { ZVAL_STRING(_0, "HTTP_ACCEPT_CHARSET", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 227, _0, _1); zephir_check_temp_parameter(_0); zephir_check_temp_parameter(_1); zephir_check_call_status(); @@ -64546,7 +64782,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestCharset) { zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 228, _0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -64564,7 +64800,7 @@ static PHP_METHOD(Phalcon_Http_Request, getLanguages) { ZVAL_STRING(_0, "HTTP_ACCEPT_LANGUAGE", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 227, _0, _1); zephir_check_temp_parameter(_0); zephir_check_temp_parameter(_1); zephir_check_call_status(); @@ -64583,7 +64819,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestLanguage) { zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 228, _0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -64637,7 +64873,7 @@ static PHP_METHOD(Phalcon_Http_Request, getDigestAuth) { ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 2); Z_SET_ISREF_P(matches); - ZEPHIR_CALL_FUNCTION(&_2, "preg_match_all", NULL, 27, _0, digest, matches, _1); + ZEPHIR_CALL_FUNCTION(&_2, "preg_match_all", NULL, 28, _0, digest, matches, _1); zephir_check_temp_parameter(_0); Z_UNSET_ISREF_P(matches); zephir_check_call_status(); @@ -64903,7 +65139,7 @@ static PHP_METHOD(Phalcon_Http_Response, setStatusCode) { if (_4) { ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "HTTP/", 0); - ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 234, key, &_5); + ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 235, key, &_5); zephir_check_call_status(); _4 = zephir_is_true(_6); } @@ -65330,7 +65566,7 @@ static PHP_METHOD(Phalcon_Http_Response, redirect) { if (_0) { ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "://", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 234, location, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 235, location, &_1); zephir_check_call_status(); _0 = zephir_is_true(_2); } @@ -65550,7 +65786,7 @@ static PHP_METHOD(Phalcon_Http_Response, send) { _1 = (zephir_fast_strlen_ev(file)) ? 1 : 0; } if (_1) { - ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 235, file); + ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 236, file); zephir_check_call_status(); } } @@ -65790,12 +66026,12 @@ static PHP_METHOD(Phalcon_Http_Request_File, __construct) { zephir_update_property_this(this_ptr, SL("_name"), name TSRMLS_CC); ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "PATHINFO_EXTENSION", 0); - ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 228, &_0); + ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 229, &_0); zephir_check_call_status(); if (zephir_is_true(_1)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_LONG(&_0, 4); - ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 69, name, &_0); + ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 71, name, &_0); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_extension"), _2 TSRMLS_CC); } @@ -65856,15 +66092,15 @@ static PHP_METHOD(Phalcon_Http_Request_File, getRealType) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 16); - ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 229, &_0); + ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 230, &_0); zephir_check_call_status(); if (Z_TYPE_P(finfo) != IS_RESOURCE) { RETURN_MM_STRING("", 1); } _1 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, finfo, _1); + ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 231, finfo, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, finfo); + ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 232, finfo); zephir_check_call_status(); RETURN_CCTOR(mime); @@ -65882,7 +66118,7 @@ static PHP_METHOD(Phalcon_Http_Request_File, isUploadedFile) { zephir_check_call_status(); _0 = Z_TYPE_P(tmp) == IS_STRING; if (_0) { - ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 232, tmp); + ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 233, tmp); zephir_check_call_status(); _0 = zephir_is_true(_1); } @@ -65913,7 +66149,7 @@ static PHP_METHOD(Phalcon_Http_Request_File, moveTo) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC); - ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 233, _0, destination); + ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 234, _0, destination); zephir_check_call_status(); RETURN_MM(); @@ -66028,12 +66264,14 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, isUsingEncryption) { static PHP_METHOD(Phalcon_Http_Response_Cookies, set) { + zval *_3; + zend_bool secure, httpOnly; int expire, ZEPHIR_LAST_CALL_STATUS; - zval *name_param = NULL, *value = NULL, *expire_param = NULL, *path_param = NULL, *secure = NULL, *domain_param = NULL, *httpOnly = NULL, *cookie = NULL, *encryption, *dependencyInjector, *response = NULL, *_0, *_1 = NULL, *_2; + zval *name_param = NULL, *value = NULL, *expire_param = NULL, *path_param = NULL, *secure_param = NULL, *domain_param = NULL, *httpOnly_param = NULL, *cookie = NULL, *encryption, *dependencyInjector, *response = NULL, *_0, *_1, *_2 = NULL, *_4 = NULL, *_5; zval *name = NULL, *path = NULL, *domain = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 6, &name_param, &value, &expire_param, &path_param, &secure, &domain_param, &httpOnly); + zephir_fetch_params(1, 1, 6, &name_param, &value, &expire_param, &path_param, &secure_param, &domain_param, &httpOnly_param); if (unlikely(Z_TYPE_P(name_param) != IS_STRING && Z_TYPE_P(name_param) != IS_NULL)) { zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'name' must be a string") TSRMLS_CC); @@ -66060,8 +66298,10 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, set) { } else { zephir_get_strval(path, path_param); } - if (!secure) { - secure = ZEPHIR_GLOBAL(global_null); + if (!secure_param) { + secure = 0; + } else { + secure = zephir_get_boolval(secure_param); } if (!domain_param) { ZEPHIR_INIT_VAR(domain); @@ -66079,8 +66319,10 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, set) { ZVAL_EMPTY_STRING(domain); } } - if (!httpOnly) { - httpOnly = ZEPHIR_GLOBAL(global_null); + if (!httpOnly_param) { + httpOnly = 0; + } else { + httpOnly = zephir_get_boolval(httpOnly_param); } @@ -66089,48 +66331,64 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, set) { ZEPHIR_OBS_VAR(cookie); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_cookies"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&cookie, _0, name, 0 TSRMLS_CC))) { - ZEPHIR_INIT_NVAR(cookie); - object_init_ex(cookie, phalcon_http_cookie_ce); - ZEPHIR_INIT_VAR(_1); - ZVAL_LONG(_1, expire); - ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name, value, _1, path, secure, domain, httpOnly); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); + ZEPHIR_INIT_VAR(_3); + zephir_create_array(_3, 7, 0 TSRMLS_CC); + zephir_array_fast_append(_3, name); + zephir_array_fast_append(_3, value); + ZEPHIR_INIT_VAR(_4); + ZVAL_LONG(_4, expire); + zephir_array_fast_append(_3, _4); + zephir_array_fast_append(_3, path); + ZEPHIR_INIT_NVAR(_4); + ZVAL_BOOL(_4, secure); + zephir_array_fast_append(_3, _4); + zephir_array_fast_append(_3, domain); + ZEPHIR_INIT_NVAR(_4); + ZVAL_BOOL(_4, httpOnly); + zephir_array_fast_append(_3, _4); + ZEPHIR_INIT_NVAR(_4); + ZVAL_STRING(_4, "Phalcon\\Http\\Cookie", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&_2, _1, "get", NULL, 0, _4, _3); + zephir_check_temp_parameter(_4); zephir_check_call_status(); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, _2); + ZEPHIR_CPY_WRT(cookie, _2); + _5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 0, _5); zephir_check_call_status(); if (zephir_is_true(encryption)) { - ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption); + ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 0, encryption); zephir_check_call_status(); } zephir_update_property_array(this_ptr, SL("_cookies"), name, cookie TSRMLS_CC); } else { - ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 239, value); + ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 0, value); zephir_check_call_status(); - ZEPHIR_INIT_NVAR(_1); - ZVAL_LONG(_1, expire); - ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 240, _1); + ZEPHIR_INIT_NVAR(_4); + ZVAL_LONG(_4, expire); + ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 0, _4); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 241, path); + ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 0, path); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 242, secure); + ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 0, (secure ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 243, domain); + ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 0, domain); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 244, httpOnly); + ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 0, (httpOnly ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_registered"), PH_NOISY_CC); - if (ZEPHIR_IS_FALSE_IDENTICAL(_2)) { + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_registered"), PH_NOISY_CC); + if (ZEPHIR_IS_FALSE_IDENTICAL(_1)) { ZEPHIR_OBS_VAR(dependencyInjector); zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_cookie_exception_ce, "A dependency injection object is required to access the 'response' service", "phalcon/http/response/cookies.zep", 138); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_cookie_exception_ce, "A dependency injection object is required to access the 'response' service", "phalcon/http/response/cookies.zep", 130); return; } - ZEPHIR_INIT_NVAR(_1); - ZVAL_STRING(_1, "response", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&response, dependencyInjector, "getshared", NULL, 0, _1); - zephir_check_temp_parameter(_1); + ZEPHIR_INIT_NVAR(_4); + ZVAL_STRING(_4, "response", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&response, dependencyInjector, "getshared", NULL, 0, _4); + zephir_check_temp_parameter(_4); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, response, "setcookies", NULL, 0, this_ptr); zephir_check_call_status(); @@ -66142,7 +66400,8 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, set) { static PHP_METHOD(Phalcon_Http_Response_Cookies, get) { int ZEPHIR_LAST_CALL_STATUS; - zval *name_param = NULL, *dependencyInjector, *encryption, *cookie = NULL, *_0; + zval *_3; + zval *name_param = NULL, *dependencyInjector, *encryption, *cookie = NULL, *_0, *_1, *_2 = NULL, *_4; zval *name = NULL; ZEPHIR_MM_GROW(); @@ -66166,19 +66425,25 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, get) { if (zephir_array_isset_fetch(&cookie, _0, name, 0 TSRMLS_CC)) { RETURN_CCTOR(cookie); } - ZEPHIR_INIT_NVAR(cookie); - object_init_ex(cookie, phalcon_http_cookie_ce); - ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); + ZEPHIR_INIT_VAR(_3); + zephir_create_array(_3, 1, 0 TSRMLS_CC); + zephir_array_fast_append(_3, name); + ZEPHIR_INIT_VAR(_4); + ZVAL_STRING(_4, "Phalcon\\Http\\Cookie", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&_2, _1, "get", NULL, 0, _4, _3); + zephir_check_temp_parameter(_4); zephir_check_call_status(); + ZEPHIR_CPY_WRT(cookie, _2); ZEPHIR_OBS_VAR(dependencyInjector); zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) { - ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 0, dependencyInjector); zephir_check_call_status(); ZEPHIR_OBS_VAR(encryption); zephir_read_property_this(&encryption, this_ptr, SL("_useEncryption"), PH_NOISY_CC); if (zephir_is_true(encryption)) { - ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption); + ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 0, encryption); zephir_check_call_status(); } } @@ -66262,11 +66527,11 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, send) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 54); + ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 55); zephir_check_call_status(); if (!(zephir_is_true(_0))) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_cookies"), PH_NOISY_CC); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/cookies.zep", 243); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/cookies.zep", 236); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -66381,41 +66646,53 @@ ZEPHIR_INIT_CLASS(Phalcon_Http_Response_Headers) { static PHP_METHOD(Phalcon_Http_Response_Headers, set) { - zval *name, *value; + zval *name_param = NULL, *value_param = NULL; + zval *name = NULL, *value = NULL; - zephir_fetch_params(0, 2, 0, &name, &value); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 2, 0, &name_param, &value_param); + zephir_get_strval(name, name_param); + zephir_get_strval(value, value_param); zephir_update_property_array(this_ptr, SL("_headers"), name, value TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } static PHP_METHOD(Phalcon_Http_Response_Headers, get) { - zval *name, *headers, *headerValue; + zval *name_param = NULL, *headers, *headerValue; + zval *name = NULL; - zephir_fetch_params(0, 1, 0, &name); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &name_param); + zephir_get_strval(name, name_param); headers = zephir_fetch_nproperty_this(this_ptr, SL("_headers"), PH_NOISY_CC); if (zephir_array_isset_fetch(&headerValue, headers, name, 1 TSRMLS_CC)) { - RETURN_CTORW(headerValue); + RETURN_CTOR(headerValue); } - RETURN_BOOL(0); + RETURN_MM_BOOL(0); } static PHP_METHOD(Phalcon_Http_Response_Headers, setRaw) { - zval *header; + zval *header_param = NULL; + zval *header = NULL; - zephir_fetch_params(0, 1, 0, &header); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &header_param); + zephir_get_strval(header, header_param); zephir_update_property_array(this_ptr, SL("_headers"), header, ZEPHIR_GLOBAL(global_null) TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -66448,11 +66725,11 @@ static PHP_METHOD(Phalcon_Http_Response_Headers, send) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 54); + ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 55); zephir_check_call_status(); if (!(zephir_is_true(_0))) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_headers"), PH_NOISY_CC); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/headers.zep", 98); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/headers.zep", 90); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -66462,10 +66739,10 @@ static PHP_METHOD(Phalcon_Http_Response_Headers, send) { if (!(ZEPHIR_IS_EMPTY(value))) { ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_VSV(_5, header, ": ", value); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, _5, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 237, _5, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, header, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 237, header, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); } } @@ -66519,14 +66796,14 @@ static PHP_METHOD(Phalcon_Http_Response_Headers, __set_state) { } ZEPHIR_OBS_VAR(dataHeaders); if (zephir_array_isset_string_fetch(&dataHeaders, data, SS("_headers"), 0 TSRMLS_CC)) { - zephir_is_iterable(dataHeaders, &_1, &_0, 0, 0, "phalcon/http/response/headers.zep", 130); + zephir_is_iterable(dataHeaders, &_1, &_0, 0, 0, "phalcon/http/response/headers.zep", 122); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HMKEY(key, _1, _0); ZEPHIR_GET_HVALUE(value, _2); - ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 246, key, value); + ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 238, key, value); zephir_check_call_status(); } } @@ -66815,7 +67092,7 @@ static PHP_METHOD(Phalcon_Image_Adapter, resize) { zephir_round(_8, &_9, NULL, NULL TSRMLS_CC); ZEPHIR_INIT_VAR(_10); ZVAL_LONG(_10, 1); - ZEPHIR_CALL_FUNCTION(&_11, "max", &_12, 66, _8, _10); + ZEPHIR_CALL_FUNCTION(&_11, "max", &_12, 68, _8, _10); zephir_check_call_status(); width = zephir_get_intval(_11); ZEPHIR_INIT_NVAR(_10); @@ -66824,7 +67101,7 @@ static PHP_METHOD(Phalcon_Image_Adapter, resize) { zephir_round(_10, &_13, NULL, NULL TSRMLS_CC); ZEPHIR_INIT_VAR(_14); ZVAL_LONG(_14, 1); - ZEPHIR_CALL_FUNCTION(&_15, "max", &_12, 66, _10, _14); + ZEPHIR_CALL_FUNCTION(&_15, "max", &_12, 68, _10, _14); zephir_check_call_status(); height = zephir_get_intval(_15); ZEPHIR_INIT_NVAR(_14); @@ -67150,23 +67427,19 @@ static PHP_METHOD(Phalcon_Image_Adapter, watermark) { static PHP_METHOD(Phalcon_Image_Adapter, text) { zend_bool _0; - int offsetX, offsetY, opacity, size, ZEPHIR_LAST_CALL_STATUS; - zval *text_param = NULL, *offsetX_param = NULL, *offsetY_param = NULL, *opacity_param = NULL, *color_param = NULL, *size_param = NULL, *fontfile_param = NULL, *colors = NULL, _1, _2, *_3, _4 = zval_used_for_init, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8, *_9, *_10, *_11, *_12; + int opacity, size, ZEPHIR_LAST_CALL_STATUS; + zval *text_param = NULL, *offsetX = NULL, *offsetY = NULL, *opacity_param = NULL, *color_param = NULL, *size_param = NULL, *fontfile_param = NULL, *colors = NULL, _1, _2, *_3, _4 = zval_used_for_init, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8, *_9, *_10; zval *text = NULL, *color = NULL, *fontfile = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 6, &text_param, &offsetX_param, &offsetY_param, &opacity_param, &color_param, &size_param, &fontfile_param); + zephir_fetch_params(1, 1, 6, &text_param, &offsetX, &offsetY, &opacity_param, &color_param, &size_param, &fontfile_param); zephir_get_strval(text, text_param); - if (!offsetX_param) { - offsetX = 0; - } else { - offsetX = zephir_get_intval(offsetX_param); + if (!offsetX) { + offsetX = ZEPHIR_GLOBAL(global_false); } - if (!offsetY_param) { - offsetY = 0; - } else { - offsetY = zephir_get_intval(offsetY_param); + if (!offsetY) { + offsetY = ZEPHIR_GLOBAL(global_false); } if (!opacity_param) { opacity = 100; @@ -67194,8 +67467,10 @@ static PHP_METHOD(Phalcon_Image_Adapter, text) { if (opacity < 0) { opacity = 0; - } else if (opacity > 100) { - opacity = 100; + } else { + if (opacity > 100) { + opacity = 100; + } } _0 = zephir_fast_strlen_ev(color) > 1; if (_0) { @@ -67219,7 +67494,7 @@ static PHP_METHOD(Phalcon_Image_Adapter, text) { ZVAL_STRING(_5, "/./", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "$0$0", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 28, _5, _6, color); + ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 29, _5, _6, color); zephir_check_temp_parameter(_5); zephir_check_temp_parameter(_6); zephir_check_call_status(); @@ -67227,24 +67502,20 @@ static PHP_METHOD(Phalcon_Image_Adapter, text) { } ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 2); - ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 67, color, &_4); + ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 69, color, &_4); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_STRING(&_4, "hexdec", 0); - ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 68, &_4, _7); + ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 70, &_4, _7); zephir_check_call_status(); - zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 333 TSRMLS_CC); - zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 333 TSRMLS_CC); - zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 333 TSRMLS_CC); + zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 335 TSRMLS_CC); + zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 335 TSRMLS_CC); + zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 335 TSRMLS_CC); ZEPHIR_INIT_NVAR(_5); - ZVAL_LONG(_5, offsetX); + ZVAL_LONG(_5, opacity); ZEPHIR_INIT_NVAR(_6); - ZVAL_LONG(_6, offsetY); - ZEPHIR_INIT_VAR(_11); - ZVAL_LONG(_11, opacity); - ZEPHIR_INIT_VAR(_12); - ZVAL_LONG(_12, size); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_text", NULL, 0, text, _5, _6, _11, _8, _9, _10, _12, fontfile); + ZVAL_LONG(_6, size); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_text", NULL, 0, text, offsetX, offsetY, _5, _8, _9, _10, _6, fontfile); zephir_check_call_status(); RETURN_THIS(); @@ -67306,7 +67577,7 @@ static PHP_METHOD(Phalcon_Image_Adapter, background) { ZVAL_STRING(_5, "/./", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "$0$0", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 28, _5, _6, color); + ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 29, _5, _6, color); zephir_check_temp_parameter(_5); zephir_check_temp_parameter(_6); zephir_check_call_status(); @@ -67314,15 +67585,15 @@ static PHP_METHOD(Phalcon_Image_Adapter, background) { } ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 2); - ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 67, color, &_4); + ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 69, color, &_4); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_STRING(&_4, "hexdec", 0); - ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 68, &_4, _7); + ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 70, &_4, _7); zephir_check_call_status(); - zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 364 TSRMLS_CC); - zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 364 TSRMLS_CC); - zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 364 TSRMLS_CC); + zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 366 TSRMLS_CC); + zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 366 TSRMLS_CC); + zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 366 TSRMLS_CC); ZEPHIR_INIT_NVAR(_5); ZVAL_LONG(_5, opacity); ZEPHIR_CALL_METHOD(NULL, this_ptr, "_background", NULL, 0, _8, _9, _10, _5); @@ -67444,7 +67715,7 @@ static PHP_METHOD(Phalcon_Image_Adapter, render) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 4); - ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 69, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 71, _0, &_1); zephir_check_call_status(); zephir_get_strval(_3, _2); ZEPHIR_CPY_WRT(ext, _3); @@ -67580,13 +67851,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, check) { ZVAL_NULL(version); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "GD_VERSION", 0); - ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 228, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 229, &_1); zephir_check_call_status(); if (zephir_is_true(_2)) { ZEPHIR_INIT_NVAR(version); ZEPHIR_GET_CONSTANT(version, "GD_VERSION"); } else { - ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 247); + ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 239); zephir_check_call_status(); ZEPHIR_INIT_VAR(matches); ZVAL_NULL(matches); @@ -67604,7 +67875,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, check) { ZVAL_STRING(&_5, "2.0.1", 0); ZEPHIR_SINIT_VAR(_6); ZVAL_STRING(&_6, ">=", 0); - ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 248, version, &_5, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 240, version, &_5, &_6); zephir_check_call_status(); if (!(zephir_is_true(_7))) { ZEPHIR_INIT_NVAR(_3); @@ -67666,11 +67937,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); if ((zephir_file_exists(_1 TSRMLS_CC) == SUCCESS)) { _2 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_3, "realpath", NULL, 60, _2); + ZEPHIR_CALL_FUNCTION(&_3, "realpath", NULL, 62, _2); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_realpath"), _3 TSRMLS_CC); _4 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 249, _4); + ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 241, _4); zephir_check_call_status(); if (zephir_is_true(imageinfo)) { zephir_array_fetch_long(&_5, imageinfo, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 77 TSRMLS_CC); @@ -67686,35 +67957,35 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { do { if (ZEPHIR_IS_LONG(_9, 1)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 250, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 242, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 2)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 251, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 243, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 3)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 252, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 244, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 15)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 253, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 245, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 16)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 254, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 246, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; @@ -67739,7 +68010,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { } while(0); _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _10, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 247, _10, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); } else { _16 = !width; @@ -67762,14 +68033,14 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { ZVAL_LONG(&_17, width); ZEPHIR_SINIT_VAR(_18); ZVAL_LONG(&_18, height); - ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 256, &_17, &_18); + ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 248, &_17, &_18); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _3 TSRMLS_CC); _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _4, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, _4, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _9, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 247, _9, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); zephir_update_property_this(this_ptr, SL("_realpath"), _10 TSRMLS_CC); @@ -67808,7 +68079,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION"); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "5.5.0", 0); - ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 240, _0, &_1); zephir_check_call_status(); if (ZEPHIR_LT_LONG(_2, 0)) { ZEPHIR_OBS_VAR(pre_width); @@ -67856,11 +68127,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZVAL_LONG(&_14, 0); ZEPHIR_SINIT_VAR(_15); ZVAL_LONG(&_15, 0); - ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 258, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11); + ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 250, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11); zephir_check_call_status(); if (zephir_is_true(_16)) { _17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _17); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 251, _17); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); } @@ -67884,17 +68155,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZVAL_LONG(&_15, width); ZEPHIR_SINIT_VAR(_21); ZVAL_LONG(&_21, height); - ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 260, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height); + ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 252, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height); zephir_check_call_status(); if (zephir_is_true(_16)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _10); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 251, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 261, image); + ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _22 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 262, image); + ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _24 TSRMLS_CC); } @@ -67904,16 +68175,16 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZVAL_LONG(&_6, width); ZEPHIR_SINIT_NVAR(_12); ZVAL_LONG(&_12, height); - ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 263, _3, &_6, &_12); + ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 255, _3, &_6, &_12); zephir_check_call_status(); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _5); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 251, _5); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 261, image); + ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 262, image); + ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _22 TSRMLS_CC); } @@ -67940,7 +68211,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) { ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION"); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "5.5.0", 0); - ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 240, _0, &_1); zephir_check_call_status(); if (ZEPHIR_LT_LONG(_2, 0)) { ZEPHIR_INIT_VAR(_3); @@ -67966,17 +68237,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) { ZVAL_LONG(&_11, width); ZEPHIR_SINIT_VAR(_12); ZVAL_LONG(&_12, height); - ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 260, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12); + ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 252, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12); zephir_check_call_status(); if (zephir_is_true(_13)) { _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 251, _14); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 261, image); + ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 262, image); + ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _18 TSRMLS_CC); } @@ -67996,16 +68267,16 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) { ZVAL_LONG(_3, height); zephir_array_update_string(&rect, SL("height"), &_3, PH_COPY | PH_SEPARATE); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 264, _5, rect); + ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 256, _5, rect); zephir_check_call_status(); _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 251, _14); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 261, image); + ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _13 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 262, image); + ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _16 TSRMLS_CC); } @@ -68033,20 +68304,20 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) { ZVAL_LONG(&_3, 0); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, 127); - ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 265, _0, &_1, &_2, &_3, &_4); + ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 257, _0, &_1, &_2, &_3, &_4); zephir_check_call_status(); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (360 - degrees)); ZEPHIR_SINIT_NVAR(_2); ZVAL_LONG(&_2, 1); - ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 266, _5, &_1, transparent, &_2); + ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 258, _5, &_1, transparent, &_2); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 247, image, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 261, image); + ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 253, image); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 262, image); + ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 254, image); zephir_check_call_status(); _6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); @@ -68059,11 +68330,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) { ZVAL_LONG(&_4, 0); ZEPHIR_SINIT_VAR(_7); ZVAL_LONG(&_7, 100); - ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 267, _6, image, &_1, &_2, &_3, &_4, width, height, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 259, _6, image, &_1, &_2, &_3, &_4, width, height, &_7); zephir_check_call_status(); if (zephir_is_true(_8)) { _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _9); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _9); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_width"), width TSRMLS_CC); @@ -68089,7 +68360,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION"); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "5.5.0", 0); - ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 240, _0, &_1); zephir_check_call_status(); if (ZEPHIR_LT_LONG(_2, 0)) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); @@ -68117,7 +68388,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { ZVAL_LONG(&_11, 0); ZEPHIR_SINIT_NVAR(_12); ZVAL_LONG(&_12, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, &_12, _8); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, image, _6, &_1, &_9, &_10, &_11, &_12, _8); zephir_check_call_status(); } } else { @@ -68141,18 +68412,18 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { ZVAL_LONG(&_11, ((zephir_get_numberval(_7) - x) - 1)); ZEPHIR_SINIT_NVAR(_12); ZVAL_LONG(&_12, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, _8, &_12); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, image, _6, &_1, &_9, &_10, &_11, _8, &_12); zephir_check_call_status(); } } _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _5); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _5); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 261, image); + ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _14 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 262, image); + ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _15 TSRMLS_CC); } else { @@ -68160,13 +68431,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _3, &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 261, _3, &_1); zephir_check_call_status(); } else { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 2); - ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _4, &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 261, _4, &_1); zephir_check_call_status(); } } @@ -68189,7 +68460,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) { ZEPHIR_INIT_VAR(_0); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, (-18 + ((amount * 0.08)))); - ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 193, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 2); @@ -68238,15 +68509,15 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) { ZVAL_LONG(&_6, (amount - 8)); ZEPHIR_SINIT_VAR(_7); ZVAL_LONG(&_7, 0); - ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 270, _5, matrix, &_6, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 262, _5, matrix, &_6, &_7); zephir_check_call_status(); if (zephir_is_true(_8)) { _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 261, _9); + ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 253, _9); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _10 TSRMLS_CC); _11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 262, _11); + ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 254, _11); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _12 TSRMLS_CC); } @@ -68272,7 +68543,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZEPHIR_INIT_VAR(_0); ZEPHIR_SINIT_VAR(_1); ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127))); - ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 193, &_1); zephir_check_call_status(); zephir_round(_0, _2, NULL, NULL TSRMLS_CC); opacity = zephir_get_intval(_0); @@ -68298,7 +68569,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_11, 0); ZEPHIR_SINIT_VAR(_12); ZVAL_LONG(&_12, 0); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, _7, &_1, &_10, &_11, &_12, _8, _9); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, reflection, _7, &_1, &_10, &_11, &_12, _8, _9); zephir_check_call_status(); offset = 0; while (1) { @@ -68339,7 +68610,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_21, src_y); ZEPHIR_SINIT_NVAR(_22); ZVAL_LONG(&_22, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, line, _18, &_11, &_12, &_20, &_21, _19, &_22); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, line, _18, &_11, &_12, &_20, &_21, _19, &_22); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_11); ZVAL_LONG(&_11, 4); @@ -68351,7 +68622,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_21, 0); ZEPHIR_SINIT_NVAR(_22); ZVAL_LONG(&_22, dst_opacity); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 271, line, &_11, &_12, &_20, &_21, &_22); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 263, line, &_11, &_12, &_20, &_21, &_22); zephir_check_call_status(); _24 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_11); @@ -68364,18 +68635,18 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_21, 0); ZEPHIR_SINIT_NVAR(_22); ZVAL_LONG(&_22, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, line, &_11, &_12, &_20, &_21, _24, &_22); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, reflection, line, &_11, &_12, &_20, &_21, _24, &_22); zephir_check_call_status(); offset++; } _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _14); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), reflection TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 261, reflection); + ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 253, reflection); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _25 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 262, reflection); + ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 254, reflection); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _26 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -68397,21 +68668,21 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZEPHIR_CALL_METHOD(&_0, watermark, "render", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 272, _0); + ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 264, _0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, overlay, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 247, overlay, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, overlay); + ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 253, overlay); zephir_check_call_status(); width = zephir_get_intval(_1); - ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, overlay); + ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 254, overlay); zephir_check_call_status(); height = zephir_get_intval(_2); if (opacity < 100) { ZEPHIR_INIT_VAR(_3); ZEPHIR_SINIT_VAR(_4); ZVAL_DOUBLE(&_4, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127))); - ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 192, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 193, &_4); zephir_check_call_status(); zephir_round(_3, _5, NULL, NULL TSRMLS_CC); opacity = zephir_get_intval(_3); @@ -68423,11 +68694,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZVAL_LONG(&_7, 127); ZEPHIR_SINIT_VAR(_8); ZVAL_LONG(&_8, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, overlay, &_4, &_6, &_7, &_8); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 257, overlay, &_4, &_6, &_7, &_8); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 3); - ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 273, overlay, &_4); + ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 265, overlay, &_4); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 0); @@ -68437,11 +68708,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZVAL_LONG(&_7, width); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, height); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 274, overlay, &_4, &_6, &_7, &_8, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 266, overlay, &_4, &_6, &_7, &_8, color); zephir_check_call_status(); } _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _9, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, _9, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_4); @@ -68456,10 +68727,10 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZVAL_LONG(&_11, width); ZEPHIR_SINIT_VAR(_12); ZVAL_LONG(&_12, height); - ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 268, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12); + ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 260, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12); zephir_check_call_status(); if (zephir_is_true(_5)) { - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, overlay); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, overlay); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -68491,7 +68762,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZEPHIR_INIT_VAR(_0); ZEPHIR_SINIT_VAR(_1); ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127))); - ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 193, &_1); zephir_check_call_status(); zephir_round(_0, _2, NULL, NULL TSRMLS_CC); opacity = zephir_get_intval(_0); @@ -68500,7 +68771,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_1, size); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, 0); - ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 275, &_1, &_4, fontfile, text); + ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 267, &_1, &_4, fontfile, text); zephir_check_call_status(); if (zephir_array_isset_long(space, 0)) { ZEPHIR_OBS_VAR(_5); @@ -68534,12 +68805,12 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { } ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (s4 - s0)); - ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 193, &_1); zephir_check_call_status(); width = (zephir_get_numberval(_12) + 10); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (s5 - s1)); - ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 193, &_1); zephir_check_call_status(); height = (zephir_get_numberval(_13) + 10); if (offsetX < 0) { @@ -68559,7 +68830,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_15, b); ZEPHIR_SINIT_VAR(_16); ZVAL_LONG(&_16, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 257, _14, &_1, &_4, &_15, &_16); zephir_check_call_status(); angle = 0; _18 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -68571,17 +68842,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_15, offsetX); ZEPHIR_SINIT_NVAR(_16); ZVAL_LONG(&_16, offsetY); - ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 276, _18, &_1, &_4, &_15, &_16, color, fontfile, text); + ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 268, _18, &_1, &_4, &_15, &_16, color, fontfile, text); zephir_check_call_status(); } else { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, size); - ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 277, &_1); + ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 269, &_1); zephir_check_call_status(); width = (zephir_get_intval(_12) * zephir_fast_strlen_ev(text)); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, size); - ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 278, &_1); + ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 270, &_1); zephir_check_call_status(); height = zephir_get_intval(_13); if (offsetX < 0) { @@ -68601,7 +68872,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_15, b); ZEPHIR_SINIT_NVAR(_16); ZVAL_LONG(&_16, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 257, _14, &_1, &_4, &_15, &_16); zephir_check_call_status(); _19 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); @@ -68610,7 +68881,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_4, offsetX); ZEPHIR_SINIT_NVAR(_15); ZVAL_LONG(&_15, offsetY); - ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 279, _19, &_1, &_4, &_15, text, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 271, _19, &_1, &_4, &_15, text, color); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -68631,22 +68902,22 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZEPHIR_CALL_METHOD(&_0, mask, "render", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 272, _0); + ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 264, _0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, maskImage); + ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 253, maskImage); zephir_check_call_status(); mask_width = zephir_get_intval(_1); - ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, maskImage); + ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 254, maskImage); zephir_check_call_status(); mask_height = zephir_get_intval(_2); alpha = 127; - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, maskImage, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 247, maskImage, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _4 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); ZEPHIR_CALL_METHOD(&newimage, this_ptr, "_create", NULL, 0, _4, _5); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, newimage, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 247, newimage, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_6); ZVAL_LONG(&_6, 0); @@ -68656,13 +68927,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_8, 0); ZEPHIR_SINIT_VAR(_9); ZVAL_LONG(&_9, alpha); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, &_6, &_7, &_8, &_9); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 257, newimage, &_6, &_7, &_8, &_9); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_6); ZVAL_LONG(&_6, 0); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, 0); - ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 280, newimage, &_6, &_7, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 272, newimage, &_6, &_7, color); zephir_check_call_status(); _11 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _12 = !ZEPHIR_IS_LONG(_11, mask_width); @@ -68673,7 +68944,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { if (_12) { _14 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _15 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 256, _14, _15); + ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 248, _14, _15); zephir_check_call_status(); _16 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _17 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); @@ -68689,9 +68960,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_18, mask_width); ZEPHIR_SINIT_VAR(_19); ZVAL_LONG(&_19, mask_height); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 260, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 252, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 251, maskImage); zephir_check_call_status(); ZEPHIR_CPY_WRT(maskImage, tempImage); } @@ -68711,9 +68982,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_6, x); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, y); - ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, maskImage, &_6, &_7); + ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 273, maskImage, &_6, &_7); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, maskImage, index); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 274, maskImage, index); zephir_check_call_status(); if (zephir_array_isset_string(color, SS("red"))) { zephir_array_fetch_string(&_23, color, SL("red"), PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 431 TSRMLS_CC); @@ -68726,10 +68997,10 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_7, x); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, y); - ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, _16, &_7, &_8); + ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 273, _16, &_7, &_8); zephir_check_call_status(); _17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, _17, index); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 274, _17, index); zephir_check_call_status(); ZEPHIR_OBS_NVAR(r); zephir_array_fetch_string(&r, color, SL("red"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC); @@ -68739,22 +69010,22 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { zephir_array_fetch_string(&b, color, SL("blue"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, alpha); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, r, g, b, &_7); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 257, newimage, r, g, b, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, x); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, y); - ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 283, newimage, &_7, &_8, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 275, newimage, &_7, &_8, color); zephir_check_call_status(); y++; } x++; } _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 251, _14); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 251, maskImage); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), newimage TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -68788,9 +69059,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) { ZVAL_LONG(&_4, b); ZEPHIR_SINIT_VAR(_5); ZVAL_LONG(&_5, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, background, &_2, &_3, &_4, &_5); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 257, background, &_2, &_3, &_4, &_5); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, background, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, background, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); @@ -68803,11 +69074,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) { ZVAL_LONG(&_4, 0); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, 0); - ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 268, background, _6, &_2, &_3, &_4, &_5, _7, _8); + ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 260, background, _6, &_2, &_3, &_4, &_5, _7, _8); zephir_check_call_status(); if (zephir_is_true(_9)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _10); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), background TSRMLS_CC); } @@ -68835,7 +69106,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _blur) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 7); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 271, _0, &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 263, _0, &_1); zephir_check_call_status(); i++; } @@ -68874,7 +69145,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) { ZVAL_LONG(&_3, x1); ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, y1); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 281, _2, &_3, &_4); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 273, _2, &_3, &_4); zephir_check_call_status(); x2 = (x + amount); y2 = (y + amount); @@ -68887,7 +69158,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) { ZVAL_LONG(&_7, x2); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, y2); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 274, _6, &_3, &_4, &_7, &_8, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 266, _6, &_3, &_4, &_7, &_8, color); zephir_check_call_status(); y += amount; } @@ -68900,9 +69171,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) { static PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) { zend_bool _8; - zephir_fcall_cache_entry *_3 = NULL, *_6 = NULL; + zephir_fcall_cache_entry *_4 = NULL, *_6 = NULL; int quality, ZEPHIR_LAST_CALL_STATUS; - zval *file_param = NULL, *quality_param = NULL, *ext, _0 = zval_used_for_init, *_1 = NULL, *_2 = NULL, *_4, *_5 = NULL, *_7, *_9 = NULL, *_10 = NULL, *_11, *_12; + zval *file_param = NULL, *quality_param = NULL, *ext = NULL, _0 = zval_used_for_init, *_1, *_2 = NULL, *_3 = NULL, *_5 = NULL, *_7, *_9 = NULL, *_10 = NULL, *_11; zval *file = NULL; ZEPHIR_MM_GROW(); @@ -68914,112 +69185,118 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 4); - ZEPHIR_CALL_FUNCTION(&_1, "pathinfo", NULL, 69, file, &_0); + ZEPHIR_CALL_FUNCTION(&ext, "pathinfo", NULL, 71, file, &_0); zephir_check_call_status(); - ZEPHIR_INIT_VAR(ext); - zephir_fast_strtolower(ext, _1); + if (!(zephir_is_true(ext))) { + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&ext, "image_type_to_extension", NULL, 276, _1, ZEPHIR_GLOBAL(global_false)); + zephir_check_call_status(); + } + ZEPHIR_INIT_VAR(_2); + zephir_fast_strtolower(_2, ext); + ZEPHIR_CPY_WRT(ext, _2); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_3, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); - if (ZEPHIR_IS_LONG(_2, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 1); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 285, _4); + if (ZEPHIR_IS_LONG(_3, 0)) { + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 1); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _5 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 279, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); _8 = ZEPHIR_IS_LONG(_5, 0); if (!(_8)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); _8 = ZEPHIR_IS_LONG(_9, 0); } if (_8) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 2); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 2); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_LONG(&_0, quality); - ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _7, file, &_0); + ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 280, _7, file, &_0); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "png", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_5, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 3); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 3); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 281, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "wbmp", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_5, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 15); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 15); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 282, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "xbm", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_5, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 16); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 16); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 283, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } + ZEPHIR_INIT_NVAR(_2); + object_init_ex(_2, phalcon_image_exception_ce); ZEPHIR_INIT_VAR(_11); - object_init_ex(_11, phalcon_image_exception_ce); - ZEPHIR_INIT_VAR(_12); - ZEPHIR_CONCAT_SVS(_12, "Installed GD does not support '", ext, "' images"); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", NULL, 9, _12); + ZEPHIR_CONCAT_SVS(_11, "Installed GD does not support '", ext, "' images"); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _11); zephir_check_call_status(); - zephir_throw_exception_debug(_11, "phalcon/image/adapter/gd.zep", 537 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/image/adapter/gd.zep", 544 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -69043,29 +69320,29 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) { ZEPHIR_INIT_VAR(_0); zephir_fast_strtolower(_0, ext); zephir_get_strval(ext, _0); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_2, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _4); + ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 279, _4); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG(_6, 0); if (!(_7)) { ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG(_8, 0); } @@ -69073,45 +69350,45 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, quality); - ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _4, ZEPHIR_GLOBAL(global_null), &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 280, _4, ZEPHIR_GLOBAL(global_null), &_1); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "png", 0); - ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_9, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _4); + ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 281, _4); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "wbmp", 0); - ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_10, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _4); + ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 282, _4); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "xbm", 0); - ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_11, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _4, ZEPHIR_GLOBAL(global_null)); + ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 283, _4, ZEPHIR_GLOBAL(global_null)); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } @@ -69121,7 +69398,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) { ZEPHIR_CONCAT_SVS(_13, "Installed GD does not support '", ext, "' images"); ZEPHIR_CALL_METHOD(NULL, _12, "__construct", NULL, 9, _13); zephir_check_call_status(); - zephir_throw_exception_debug(_12, "phalcon/image/adapter/gd.zep", 565 TSRMLS_CC); + zephir_throw_exception_debug(_12, "phalcon/image/adapter/gd.zep", 572 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -69143,11 +69420,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _create) { ZVAL_LONG(&_0, width); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, height); - ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 256, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 248, &_0, &_1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, image, ZEPHIR_GLOBAL(global_false)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, image, ZEPHIR_GLOBAL(global_false)); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 247, image, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); RETURN_CCTOR(image); @@ -69163,7 +69440,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __destruct) { ZEPHIR_OBS_VAR(image); zephir_read_property_this(&image, this_ptr, SL("_image"), PH_NOISY_CC); if (Z_TYPE_P(image) == IS_RESOURCE) { - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, image); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, image); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -69216,12 +69493,12 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, check) { } ZEPHIR_SINIT_VAR(_2); ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0); - ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 228, &_2); + ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 229, &_2); zephir_check_call_status(); if (zephir_is_true(_3)) { ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0); - ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_2); + ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 191, &_2); zephir_check_call_status(); zephir_update_static_property_ce(phalcon_image_adapter_imagick_ce, SL("_version"), &_4 TSRMLS_CC); } @@ -69280,7 +69557,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, __construct) { _2 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); if ((zephir_file_exists(_2 TSRMLS_CC) == SUCCESS)) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_4, "realpath", NULL, 60, _3); + ZEPHIR_CALL_FUNCTION(&_4, "realpath", NULL, 62, _3); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_realpath"), _4 TSRMLS_CC); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -69306,7 +69583,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, __construct) { _12 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_13); ZVAL_STRING(&_13, "Imagick::ALPHACHANNEL_SET", 0); - ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 190, &_13); + ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 191, &_13); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _12, "setimagealphachannel", NULL, 0, _14); zephir_check_call_status(); @@ -69778,7 +70055,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { while (1) { ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::COMPOSITE_DSTOUT", 0); - ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, 0); @@ -69792,11 +70069,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { } ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::EVALUATE_MULTIPLY", 0); - ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::CHANNEL_ALPHA", 0); - ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, opacity); @@ -69839,7 +70116,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::ALPHACHANNEL_SET", 0); - ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, image, "setimagealphachannel", &_25, 0, _9); zephir_check_call_status(); @@ -69856,7 +70133,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { _30 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::COMPOSITE_SRC", 0); - ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, 0); @@ -69886,7 +70163,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { while (1) { ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::COMPOSITE_OVER", 0); - ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 191, &_14); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); ZEPHIR_INIT_NVAR(_3); @@ -69968,7 +70245,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _watermark) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_4); ZVAL_STRING(&_4, "Imagick::COMPOSITE_OVER", 0); - ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 190, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 191, &_4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_1); ZVAL_LONG(_1, offsetX); @@ -69997,17 +70274,18 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _watermark) { static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) { - zephir_fcall_cache_entry *_6 = NULL, *_8 = NULL; - int offsetX, offsetY, opacity, r, g, b, size, ZEPHIR_LAST_CALL_STATUS; - zval *text_param = NULL, *offsetX_param = NULL, *offsetY_param = NULL, *opacity_param = NULL, *r_param = NULL, *g_param = NULL, *b_param = NULL, *size_param = NULL, *fontfile_param = NULL, *draw, *color = NULL, *pixel, *gravity = NULL, _0 = zval_used_for_init, _1, _2, _3, *_4 = NULL, *_5 = NULL, *_7 = NULL, *_9, *_10, *_11 = NULL, *_12 = NULL, *_13; + zephir_fcall_cache_entry *_7 = NULL; + zend_bool _6; + int opacity, r, g, b, size, x, y, ZEPHIR_LAST_CALL_STATUS; + zval *text_param = NULL, *offsetX = NULL, *offsetY = NULL, *opacity_param = NULL, *r_param = NULL, *g_param = NULL, *b_param = NULL, *size_param = NULL, *fontfile_param = NULL, *draw, *color = NULL, *gravity = NULL, _0 = zval_used_for_init, _1, _2, _3, *_4, *_5 = NULL, *_8, *_9, *_10, *_11 = NULL; zval *text = NULL, *fontfile = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 9, 0, &text_param, &offsetX_param, &offsetY_param, &opacity_param, &r_param, &g_param, &b_param, &size_param, &fontfile_param); + zephir_fetch_params(1, 9, 0, &text_param, &offsetX, &offsetY, &opacity_param, &r_param, &g_param, &b_param, &size_param, &fontfile_param); zephir_get_strval(text, text_param); - offsetX = zephir_get_intval(offsetX_param); - offsetY = zephir_get_intval(offsetY_param); + ZEPHIR_SEPARATE_PARAM(offsetX); + ZEPHIR_SEPARATE_PARAM(offsetY); opacity = zephir_get_intval(opacity_param); r = zephir_get_intval(r_param); g = zephir_get_intval(g_param); @@ -70031,76 +70309,210 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) { ZVAL_LONG(&_2, g); ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, b); - ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 188, &_0, &_1, &_2, &_3); zephir_check_call_status(); - ZEPHIR_INIT_VAR(pixel); - object_init_ex(pixel, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC)); - if (zephir_has_constructor(pixel TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(NULL, pixel, "__construct", NULL, 0, color); + ZEPHIR_INIT_VAR(_4); + object_init_ex(_4, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC)); + if (zephir_has_constructor(_4 TSRMLS_CC)) { + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 0, color); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, draw, "setfillcolor", NULL, 0, pixel); + ZEPHIR_CALL_METHOD(NULL, draw, "setfillcolor", NULL, 0, _4); zephir_check_call_status(); if (fontfile && Z_STRLEN_P(fontfile)) { ZEPHIR_CALL_METHOD(NULL, draw, "setfont", NULL, 0, fontfile); zephir_check_call_status(); } if (size) { - ZEPHIR_INIT_VAR(_4); - ZVAL_LONG(_4, size); - ZEPHIR_CALL_METHOD(NULL, draw, "setfontsize", NULL, 0, _4); + ZEPHIR_INIT_VAR(_5); + ZVAL_LONG(_5, size); + ZEPHIR_CALL_METHOD(NULL, draw, "setfontsize", NULL, 0, _5); zephir_check_call_status(); } if (opacity) { - ZEPHIR_INIT_NVAR(_4); - ZVAL_LONG(_4, opacity); - ZEPHIR_CALL_METHOD(NULL, draw, "setfillopacity", NULL, 0, _4); - zephir_check_call_status(); - } - if (offsetX < 0) { - ZEPHIR_SINIT_NVAR(_0); - ZVAL_LONG(&_0, offsetX); - ZEPHIR_CALL_FUNCTION(&_5, "abs", &_6, 192, &_0); - zephir_check_call_status(); - offsetX = zephir_get_numberval(_5); - if (offsetY < 0) { - ZEPHIR_SINIT_NVAR(_0); - ZVAL_LONG(&_0, offsetY); - ZEPHIR_CALL_FUNCTION(&_7, "abs", &_6, 192, &_0); - zephir_check_call_status(); - offsetY = zephir_get_numberval(_7); - ZEPHIR_SINIT_NVAR(_0); - ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); - ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0); - zephir_check_call_status(); + ZEPHIR_INIT_NVAR(_5); + ZVAL_LONG(_5, opacity); + ZEPHIR_CALL_METHOD(NULL, draw, "setfillopacity", NULL, 0, _5); + zephir_check_call_status(); + } + ZEPHIR_INIT_VAR(gravity); + ZVAL_NULL(gravity); + if (Z_TYPE_P(offsetX) == IS_BOOL) { + if (Z_TYPE_P(offsetY) == IS_BOOL) { + ZEPHIR_INIT_NVAR(offsetX); + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, 0); + _6 = zephir_is_true(offsetX); + if (_6) { + _6 = zephir_is_true(offsetY); + } + if (_6) { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + if (zephir_is_true(offsetX)) { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_EAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + if (zephir_is_true(offsetY)) { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_CENTER", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } } else { - ZEPHIR_SINIT_NVAR(_0); - ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0); - ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0); - zephir_check_call_status(); + if (Z_TYPE_P(offsetY) == IS_LONG) { + y = zephir_get_intval(offsetY); + if (zephir_is_true(offsetX)) { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } else { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } + } + } else { + if (Z_TYPE_P(offsetX) == IS_LONG) { + x = zephir_get_intval(offsetX); + if (zephir_is_true(offsetX)) { + if (Z_TYPE_P(offsetY) == IS_BOOL) { + if (zephir_is_true(offsetY)) { + ZEPHIR_INIT_NVAR(offsetY); + if (x < 0) { + ZEPHIR_INIT_NVAR(offsetX); + ZVAL_LONG(offsetX, (x * -1)); + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } else { + ZEPHIR_INIT_NVAR(offsetY); + if (x < 0) { + ZEPHIR_INIT_NVAR(offsetX); + ZVAL_LONG(offsetX, (x * -1)); + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_EAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_WEST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } else { + if (Z_TYPE_P(offsetY) == IS_LONG) { + x = zephir_get_intval(offsetX); + y = zephir_get_intval(offsetY); + if (x < 0) { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, (x * -1)); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, (x * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } else { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHWEST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHWEST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } + } + } } } ZEPHIR_CALL_METHOD(NULL, draw, "setgravity", NULL, 0, gravity); zephir_check_call_status(); - _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_INIT_NVAR(_4); - ZVAL_LONG(_4, 0); - ZEPHIR_CALL_METHOD(NULL, _9, "setiteratorindex", NULL, 0, _4); + _8 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); + ZEPHIR_INIT_NVAR(_5); + ZVAL_LONG(_5, 0); + ZEPHIR_CALL_METHOD(NULL, _8, "setiteratorindex", NULL, 0, _5); zephir_check_call_status(); while (1) { - _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_INIT_NVAR(_4); - ZVAL_LONG(_4, offsetX); - ZEPHIR_INIT_NVAR(_11); - ZVAL_LONG(_11, offsetY); - ZEPHIR_INIT_NVAR(_12); - ZVAL_LONG(_12, 0); - ZEPHIR_CALL_METHOD(NULL, _10, "annotateimage", NULL, 0, draw, _4, _11, _12, text); + _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); + ZEPHIR_INIT_NVAR(_5); + ZVAL_LONG(_5, 0); + ZEPHIR_CALL_METHOD(NULL, _9, "annotateimage", NULL, 0, draw, offsetX, offsetY, _5, text); zephir_check_call_status(); - _13 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(&_5, _13, "nextimage", NULL, 0); + _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(&_11, _10, "nextimage", NULL, 0); zephir_check_call_status(); - if (ZEPHIR_IS_FALSE_IDENTICAL(_5)) { + if (ZEPHIR_IS_FALSE_IDENTICAL(_11)) { break; } } @@ -70145,7 +70557,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _mask) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Imagick::COMPOSITE_DSTIN", 0); - ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 190, &_5); + ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 191, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_2); ZVAL_LONG(_2, 0); @@ -70154,7 +70566,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _mask) { ZEPHIR_CALL_METHOD(&ret, _4, "compositeimage", NULL, 0, mask, _6, _2, _8); zephir_check_call_status(); if (!ZEPHIR_IS_TRUE_IDENTICAL(ret)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 453); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 531); return; } _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -70195,7 +70607,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { ZVAL_LONG(&_2, g); ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, b); - ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 188, &_0, &_1, &_2, &_3); zephir_check_call_status(); ZEPHIR_INIT_VAR(pixel1); object_init_ex(pixel1, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC)); @@ -70234,7 +70646,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { if (!(zephir_is_true(_9))) { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::ALPHACHANNEL_SET", 0); - ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, background, "setimagealphachannel", &_13, 0, _11); zephir_check_call_status(); @@ -70243,11 +70655,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::EVALUATE_MULTIPLY", 0); - ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::CHANNEL_ALPHA", 0); - ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_4); ZVAL_LONG(_4, opacity); @@ -70261,7 +70673,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { _20 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::COMPOSITE_DISSOLVE", 0); - ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_4); ZVAL_LONG(_4, 0); @@ -70270,7 +70682,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { ZEPHIR_CALL_METHOD(&ret, background, "compositeimage", &_23, 0, _20, _21, _4, _22); zephir_check_call_status(); if (!ZEPHIR_IS_TRUE_IDENTICAL(ret)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 492); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 570); return; } _24 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -70387,7 +70799,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 4); - ZEPHIR_CALL_FUNCTION(&ext, "pathinfo", NULL, 69, file, &_0); + ZEPHIR_CALL_FUNCTION(&ext, "pathinfo", NULL, 71, file, &_0); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_CALL_METHOD(NULL, _1, "setformat", NULL, 0, ext); @@ -70407,7 +70819,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { zephir_update_property_this(this_ptr, SL("_mime"), _7 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_9, 140, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_9, 19, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_8, 0)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -70415,7 +70827,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "w", 0); - ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 292, file, &_0); + ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 285, file, &_0); zephir_check_call_status(); _11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_CALL_METHOD(NULL, _11, "writeimagesfile", NULL, 0, fp); @@ -70425,13 +70837,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { } else { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_12, "strcasecmp", &_9, 140, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_12, "strcasecmp", &_9, 19, ext, &_0); zephir_check_call_status(); _13 = ZEPHIR_IS_LONG(_12, 0); if (!(_13)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_14, "strcasecmp", &_9, 140, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_14, "strcasecmp", &_9, 19, ext, &_0); zephir_check_call_status(); _13 = ZEPHIR_IS_LONG(_14, 0); } @@ -70439,7 +70851,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::COMPRESSION_JPEG", 0); - ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 191, &_0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _10, "setimagecompression", NULL, 0, _15); zephir_check_call_status(); @@ -70490,7 +70902,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _render) { zephir_update_property_this(this_ptr, SL("_mime"), _2 TSRMLS_CC); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_4, "strcasecmp", &_5, 140, extension, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "strcasecmp", &_5, 19, extension, &_3); zephir_check_call_status(); if (ZEPHIR_IS_LONG_IDENTICAL(_4, 0)) { ZEPHIR_CALL_METHOD(NULL, image, "optimizeimagelayers", NULL, 0); @@ -70498,20 +70910,20 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _render) { } else { ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_6, "strcasecmp", &_5, 140, extension, &_3); + ZEPHIR_CALL_FUNCTION(&_6, "strcasecmp", &_5, 19, extension, &_3); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG_IDENTICAL(_6, 0); if (!(_7)) { ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_5, 140, extension, &_3); + ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_5, 19, extension, &_3); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG_IDENTICAL(_8, 0); } if (_7) { ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "Imagick::COMPRESSION_JPEG", 0); - ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 190, &_3); + ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 191, &_3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, image, "setimagecompression", NULL, 0, _9); zephir_check_call_status(); @@ -71094,7 +71506,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter, log) { if (zephir_is_true(_3)) { ZEPHIR_INIT_VAR(_4); object_init_ex(_4, phalcon_logger_item_ce); - ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 52, toggledMessage, toggledType, timestamp, context); + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 53, toggledMessage, toggledType, timestamp, context); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_queue"), _4 TSRMLS_CC); } else { @@ -71285,7 +71697,7 @@ static PHP_METHOD(Phalcon_Logger_Formatter, interpolate) { ZEPHIR_CONCAT_SVS(_4, "{", key, "}"); zephir_array_update_zval(&replace, _4, &value, PH_COPY | PH_SEPARATE); } - ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 53, message, replace); + ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 54, message, replace); zephir_check_call_status(); RETURN_MM(); } @@ -71910,7 +72322,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, __construct) { ZEPHIR_INIT_NVAR(mode); ZVAL_STRING(mode, "ab", 1); } - ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 292, name, mode); + ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 285, name, mode); zephir_check_call_status(); if (Z_TYPE_P(handler) != IS_RESOURCE) { ZEPHIR_INIT_VAR(_0); @@ -71942,7 +72354,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, getFormatter) { if (Z_TYPE_P(_0) != IS_OBJECT) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_logger_formatter_line_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 289); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC); } @@ -72022,7 +72434,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, __wakeup) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_logger_exception_ce, "Logger must be opened in append or write mode", "phalcon/logger/adapter/file.zep", 152); return; } - ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 292, path, mode); + ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 285, path, mode); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_fileHandler"), _1 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -72107,15 +72519,15 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) { if (!ZEPHIR_IS_TRUE_IDENTICAL(_1)) { ZEPHIR_SINIT_VAR(_2); ZVAL_STRING(&_2, "X-Wf-Protocol-1: http://meta.wildfirehq.org/Protocol/JsonStream/0.2", 0); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, &_2); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "X-Wf-1-Plugin-1: http://meta.firephp.org/Wildfire/Plugin/FirePHP/Library-FirePHPCore/0.3", 0); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, &_2); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "X-Wf-Structure-1: http://meta.firephp.org/Wildfire/Structure/FirePHP/FirebugConsole/0.1", 0); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, &_2); zephir_check_call_status(); zephir_update_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_initialized"), &(ZEPHIR_GLOBAL(global_true)) TSRMLS_CC); } @@ -72129,7 +72541,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_LONG(&_2, 4500); - ZEPHIR_CALL_FUNCTION(&chunk, "str_split", NULL, 67, format, &_2); + ZEPHIR_CALL_FUNCTION(&chunk, "str_split", NULL, 69, format, &_2); zephir_check_call_status(); zephir_is_iterable(chunk, &_8, &_7, 0, 0, "phalcon/logger/adapter/firephp.zep", 102); for ( @@ -72145,7 +72557,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) { if (zephir_array_isset_long(chunk, (zephir_get_numberval(key) + 1))) { zephir_concat_self_str(&content, SL("|\\") TSRMLS_CC); } - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, content); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, content); zephir_check_call_status(); _10 = zephir_fetch_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_index") TSRMLS_CC); ZEPHIR_INIT_ZVAL_NREF(_11); @@ -72223,7 +72635,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Stream, __construct) { ZEPHIR_INIT_NVAR(mode); ZVAL_STRING(mode, "ab", 1); } - ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 292, name, mode); + ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 285, name, mode); zephir_check_call_status(); if (!(zephir_is_true(stream))) { ZEPHIR_INIT_VAR(_0); @@ -72253,7 +72665,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Stream, getFormatter) { if (Z_TYPE_P(_0) != IS_OBJECT) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_logger_formatter_line_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 289); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC); } @@ -72355,7 +72767,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, __construct) { ZEPHIR_INIT_NVAR(facility); ZVAL_LONG(facility, 8); } - ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 297, name, option, facility); + ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 290, name, option, facility); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_opened"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } @@ -72415,7 +72827,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, logInternal) { } zephir_array_fetch_long(&_3, appliedFormat, 0, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC); zephir_array_fetch_long(&_4, appliedFormat, 1, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 298, _3, _4); + ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 291, _3, _4); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -72430,7 +72842,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, close) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_opened"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 299); + ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 292); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -72587,15 +72999,15 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Firephp, format) { ZVAL_STRING(&_3, "5.3.6", 0); ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "<", 0); - ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 248, _1, &_3, &_4); + ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 240, _1, &_3, &_4); zephir_check_call_status(); if (!(zephir_is_true(_0))) { param = (2) ? 1 : 0; } - ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 150, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 151, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); Z_SET_ISREF_P(backtrace); - ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 170, backtrace); + ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 171, backtrace); Z_UNSET_ISREF_P(backtrace); zephir_check_call_status(); if (zephir_array_isset_string(lastTrace, SS("file"))) { @@ -72766,13 +73178,17 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, getDateFormat) { static PHP_METHOD(Phalcon_Logger_Formatter_Line, setDateFormat) { - zval *dateFormat; + zval *dateFormat_param = NULL; + zval *dateFormat = NULL; - zephir_fetch_params(0, 1, 0, &dateFormat); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &dateFormat_param); + zephir_get_strval(dateFormat, dateFormat_param); zephir_update_property_this(this_ptr, SL("_dateFormat"), dateFormat TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -72785,13 +73201,17 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, getFormat) { static PHP_METHOD(Phalcon_Logger_Formatter_Line, setFormat) { - zval *format; + zval *format_param = NULL; + zval *format = NULL; - zephir_fetch_params(0, 1, 0, &format); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &format_param); + zephir_get_strval(format, format_param); zephir_update_property_this(this_ptr, SL("_format"), format TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -72842,7 +73262,7 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, format) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dateFormat"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_2); ZVAL_LONG(&_2, timestamp); - ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 300, _1, &_2); + ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 293, _1, &_2); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "%date%", 0); @@ -73896,7 +74316,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, _getResultset) { } ZEPHIR_INIT_VAR(collections); array_init(collections); - ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 301, documentsCursor); + ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 294, documentsCursor); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/collection.zep", 440); for ( @@ -74359,7 +74779,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, save) { zephir_update_property_this(this_ptr, SL("_errorMessages"), _1 TSRMLS_CC); ZEPHIR_OBS_VAR(disableEvents); zephir_read_static_property_ce(&disableEvents, phalcon_mvc_collection_ce, SL("_disableEvents") TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 302, dependencyInjector, disableEvents, exists); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 295, dependencyInjector, disableEvents, exists); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(_2)) { RETURN_MM_BOOL(0); @@ -74388,7 +74808,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, save) { } else { success = 0; } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 303, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 296, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists); zephir_check_call_status(); RETURN_MM(); @@ -74806,7 +75226,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, toArray) { zephir_check_call_status(); ZEPHIR_INIT_VAR(data); array_init(data); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, this_ptr); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/collection.zep", 1244); for ( @@ -74838,7 +75258,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, serialize) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "toarray", NULL, 0); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -74869,7 +75289,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, unserialize) { } - ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(attributes) == IS_ARRAY) { ZEPHIR_CALL_CE_STATIC(&dependencyInjector, phalcon_di_ce, "getdefault", &_0, 1); @@ -75717,7 +76137,7 @@ static PHP_METHOD(Phalcon_Mvc_Micro, mount) { if (zephir_is_true(_0)) { ZEPHIR_INIT_VAR(lazyHandler); object_init_ex(lazyHandler, phalcon_mvc_micro_lazyloader_ce); - ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 304, mainHandler); + ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 297, mainHandler); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(lazyHandler, mainHandler); @@ -75866,11 +76286,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, setService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 305, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 298, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -75903,11 +76323,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, hasService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 306, serviceName); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 299, serviceName); zephir_check_call_status(); RETURN_MM(); @@ -75940,11 +76360,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, getService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 307, serviceName); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 300, serviceName); zephir_check_call_status(); RETURN_MM(); @@ -75965,11 +76385,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, getSharedService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 308, serviceName); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 301, serviceName); zephir_check_call_status(); RETURN_MM(); @@ -76533,7 +76953,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __construct) { zephir_check_call_status(); } if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 135); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 134); return; } zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); @@ -76545,7 +76965,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __construct) { zephir_check_call_status(); ZEPHIR_CPY_WRT(modelsManager, _1); if (Z_TYPE_P(modelsManager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 146); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 145); return; } } @@ -76623,7 +77043,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getModelsMetaData) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _0); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 215); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 214); return; } ZEPHIR_INIT_VAR(_2); @@ -76633,7 +77053,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getModelsMetaData) { zephir_check_call_status(); ZEPHIR_CPY_WRT(metaData, _1); if (Z_TYPE_P(metaData) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsMetadata' is not valid", "phalcon/mvc/model.zep", 223); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsMetadata' is not valid", "phalcon/mvc/model.zep", 222); return; } zephir_update_property_this(this_ptr, SL("_modelsMetaData"), metaData TSRMLS_CC); @@ -76947,7 +77367,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, assign) { if (Z_TYPE_P(dataColumnMap) == IS_ARRAY) { ZEPHIR_INIT_VAR(dataMapped); array_init(dataMapped); - zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 437); + zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 436); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -76976,7 +77396,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, assign) { } ZEPHIR_CALL_METHOD(&_3, metaData, "getattributes", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(_3, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 489); + zephir_is_iterable(_3, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 488); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -76992,7 +77412,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, assign) { ZEPHIR_CONCAT_SVS(_8, "Column '", attribute, "' doesn\\'t make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_9, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_7, "phalcon/mvc/model.zep", 459 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model.zep", 458 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -77060,7 +77480,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { ZVAL_LONG(_0, dirtyState); ZEPHIR_CALL_METHOD(NULL, instance, "setdirtystate", NULL, 0, _0); zephir_check_call_status(); - zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 589); + zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 588); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -77081,7 +77501,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model.zep", 532 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model.zep", 531 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -77097,12 +77517,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { _6 = Z_TYPE_P(value) != IS_NULL; } if (_6) { - zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 544 TSRMLS_CC); + zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 543 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_7, 0)) { ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, 10); - ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_9, 25, value, &_8); + ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_9, 26, value, &_8); zephir_check_call_status(); break; } @@ -77121,7 +77541,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { } while(0); } else { - zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 565 TSRMLS_CC); + zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 564 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_7, 0) || ZEPHIR_IS_LONG(_7, 9) || ZEPHIR_IS_LONG(_7, 3) || ZEPHIR_IS_LONG(_7, 7) || ZEPHIR_IS_LONG(_7, 8)) { ZEPHIR_INIT_NVAR(castValue); @@ -77134,7 +77554,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { } ZEPHIR_OBS_NVAR(attributeName); - zephir_array_fetch_long(&attributeName, attribute, 0, PH_NOISY, "phalcon/mvc/model.zep", 581 TSRMLS_CC); + zephir_array_fetch_long(&attributeName, attribute, 0, PH_NOISY, "phalcon/mvc/model.zep", 580 TSRMLS_CC); zephir_update_property_zval_zval(instance, attributeName, castValue TSRMLS_CC); } } @@ -77179,7 +77599,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMapHydrate) { ZEPHIR_INIT_VAR(hydrateObject); object_init(hydrateObject); } - zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 663); + zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 662); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -77197,7 +77617,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMapHydrate) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 642 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 641 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -77253,7 +77673,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResult) { ZVAL_LONG(_0, dirtyState); ZEPHIR_CALL_METHOD(NULL, instance, "setdirtystate", NULL, 0, _0); zephir_check_call_status(); - zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 710); + zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 709); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -77261,7 +77681,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResult) { ZEPHIR_GET_HMKEY(key, _2, _1); ZEPHIR_GET_HVALUE(value, _3); if (Z_TYPE_P(key) != IS_STRING) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid key in array data provided to dumpResult()", "phalcon/mvc/model.zep", 702); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid key in array data provided to dumpResult()", "phalcon/mvc/model.zep", 701); return; } zephir_update_property_zval_zval(instance, key, value TSRMLS_CC); @@ -77300,7 +77720,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, find) { ZEPHIR_INIT_VAR(params); array_init(params); if (Z_TYPE_P(parameters) != IS_NULL) { - zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 756); + zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 755); } } else { ZEPHIR_CPY_WRT(params, parameters); @@ -77375,7 +77795,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, findFirst) { ZEPHIR_INIT_VAR(params); array_init(params); if (Z_TYPE_P(parameters) != IS_NULL) { - zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 843); + zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 842); } } else { ZEPHIR_CPY_WRT(params, parameters); @@ -77459,12 +77879,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, query) { ZEPHIR_CALL_METHOD(NULL, criteria, "__construct", NULL, 0); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 309, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 302, dependencyInjector); zephir_check_call_status(); } ZEPHIR_INIT_NVAR(_2); zephir_get_called_class(_2 TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, _2); + ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 303, _2); zephir_check_call_status(); RETURN_CCTOR(criteria); @@ -77682,7 +78102,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _groupResult) { ZEPHIR_INIT_VAR(params); array_init(params); if (Z_TYPE_P(parameters) != IS_NULL) { - zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 1092); + zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 1093); } } else { ZEPHIR_CPY_WRT(params, parameters); @@ -77690,7 +78110,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _groupResult) { ZEPHIR_OBS_VAR(groupColumn); if (!(zephir_array_isset_string_fetch(&groupColumn, params, SS("column"), 0 TSRMLS_CC))) { ZEPHIR_INIT_NVAR(groupColumn); - ZVAL_LONG(groupColumn, '*'); + ZVAL_STRING(groupColumn, "*", 1); } ZEPHIR_OBS_VAR(distinctColumn); if (zephir_array_isset_string_fetch(&distinctColumn, params, SS("distinct"), 0 TSRMLS_CC)) { @@ -77998,7 +78418,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, validate) { if (ZEPHIR_IS_FALSE_IDENTICAL(_0)) { ZEPHIR_CALL_METHOD(&_1, validator, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1392); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1393); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -78050,7 +78470,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getMessages) { ZEPHIR_INIT_VAR(filtered); array_init(filtered); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_errorMessages"), PH_NOISY_CC); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1458); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1459); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -78059,7 +78479,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getMessages) { ZEPHIR_CALL_METHOD(&_5, message, "getfield", NULL, 0); zephir_check_call_status(); if (ZEPHIR_IS_EQUAL(_5, filter)) { - zephir_array_append(&filtered, message, PH_SEPARATE, "phalcon/mvc/model.zep", 1455); + zephir_array_append(&filtered, message, PH_SEPARATE, "phalcon/mvc/model.zep", 1456); } } RETURN_CCTOR(filtered); @@ -78086,7 +78506,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { zephir_check_call_status(); if (zephir_fast_count_int(belongsTo TSRMLS_CC)) { error = 0; - zephir_is_iterable(belongsTo, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1601); + zephir_is_iterable(belongsTo, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1602); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -78099,7 +78519,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { if (Z_TYPE_P(foreignKey) == IS_ARRAY) { if (zephir_array_isset_string(foreignKey, SS("action"))) { ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1502 TSRMLS_CC); + zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1503 TSRMLS_CC); action = zephir_get_intval(_4); } } @@ -78118,7 +78538,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { ZEPHIR_CALL_METHOD(&referencedFields, relation, "getreferencedfields", NULL, 0); zephir_check_call_status(); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1538); + zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1539); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) @@ -78127,11 +78547,11 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { ZEPHIR_GET_HVALUE(field, _9); ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, field, PH_SILENT_CC); - zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1531 TSRMLS_CC); + zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1532 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVSV(_11, "[", _10, "] = ?", position); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1531); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1532); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1532); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1533); if (Z_TYPE_P(value) == IS_NULL) { numberNull++; } @@ -78142,15 +78562,15 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { zephir_fetch_property_zval(&value, this_ptr, fields, PH_SILENT_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVS(_11, "[", referencedFields, "] = ?0"); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1543); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1544); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1544); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1545); if (Z_TYPE_P(value) == IS_NULL) { validateWithNulls = 1; } } ZEPHIR_OBS_NVAR(extraConditions); if (zephir_array_isset_string_fetch(&extraConditions, foreignKey, SS("conditions"), 0 TSRMLS_CC)) { - zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1555); + zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1556); } if (validateWithNulls) { ZEPHIR_OBS_NVAR(allowNulls); @@ -78232,7 +78652,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { ZEPHIR_CALL_METHOD(&relations, manager, "gethasoneandhasmany", NULL, 0, this_ptr); zephir_check_call_status(); if (zephir_fast_count_int(relations TSRMLS_CC)) { - zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1715); + zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1716); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -78245,7 +78665,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { if (Z_TYPE_P(foreignKey) == IS_ARRAY) { if (zephir_array_isset_string(foreignKey, SS("action"))) { ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1654 TSRMLS_CC); + zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1655 TSRMLS_CC); action = zephir_get_intval(_4); } } @@ -78263,7 +78683,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { ZEPHIR_INIT_NVAR(bindParams); array_init(bindParams); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1682); + zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1683); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) @@ -78272,23 +78692,23 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { ZEPHIR_GET_HVALUE(field, _9); ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, field, PH_SILENT_CC); - zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1679 TSRMLS_CC); + zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1680 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVSV(_11, "[", _10, "] = ?", position); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1679); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1680); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1680); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1681); } } else { ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, fields, PH_SILENT_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVS(_11, "[", referencedFields, "] = ?0"); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1684); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1685); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1685); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1686); } ZEPHIR_OBS_NVAR(extraConditions); if (zephir_array_isset_string_fetch(&extraConditions, foreignKey, SS("conditions"), 0 TSRMLS_CC)) { - zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1692); + zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1693); } ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -78329,7 +78749,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { zephir_check_call_status(); if (zephir_fast_count_int(relations TSRMLS_CC)) { error = 0; - zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1834); + zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1835); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -78342,7 +78762,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { if (Z_TYPE_P(foreignKey) == IS_ARRAY) { if (zephir_array_isset_string(foreignKey, SS("action"))) { ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1762 TSRMLS_CC); + zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1763 TSRMLS_CC); action = zephir_get_intval(_4); } } @@ -78360,7 +78780,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { ZEPHIR_INIT_NVAR(bindParams); array_init(bindParams); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/mvc/model.zep", 1794); + zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/mvc/model.zep", 1795); for ( ; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS ; zephir_hash_move_forward_ex(_7, &_6) @@ -78369,23 +78789,23 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { ZEPHIR_GET_HVALUE(field, _8); ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, field, PH_SILENT_CC); - zephir_array_fetch(&_9, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1790 TSRMLS_CC); + zephir_array_fetch(&_9, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1791 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVSV(_10, "[", _9, "] = ?", position); - zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1790); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1791); + zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1791); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1792); } } else { ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, fields, PH_SILENT_CC); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVS(_10, "[", referencedFields, "] = ?0"); - zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1796); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1797); + zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1797); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1798); } ZEPHIR_OBS_NVAR(extraConditions); if (zephir_array_isset_string_fetch(&extraConditions, foreignKey, SS("conditions"), 0 TSRMLS_CC)) { - zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1804); + zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1805); } ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -78509,7 +78929,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSave) { ZEPHIR_CALL_METHOD(&emptyStringValues, metaData, "getemptystringattributes", NULL, 0, this_ptr); zephir_check_call_status(); error = 0; - zephir_is_iterable(notNull, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 2000); + zephir_is_iterable(notNull, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 2001); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -78526,7 +78946,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSave) { ZEPHIR_CONCAT_SVS(_7, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 1936 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 1937 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -78746,7 +79166,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_INIT_NVAR(columnMap); ZVAL_NULL(columnMap); } - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 2184); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 2185); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -78762,7 +79182,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2138 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2139 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -78788,23 +79208,23 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Column '", field, "' have not defined a bind data type"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2162 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2163 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2165); - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2165); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2165); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2166); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2166); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2166); } else { if (zephir_array_isset(defaultValues, field)) { ZEPHIR_CALL_METHOD(&_8, connection, "getdefaultvalue", &_9, 0); zephir_check_call_status(); - zephir_array_append(&values, _8, PH_SEPARATE, "phalcon/mvc/model.zep", 2170); + zephir_array_append(&values, _8, PH_SEPARATE, "phalcon/mvc/model.zep", 2171); } else { - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2172); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2173); } - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2175); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2175); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2176); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2176); } } } @@ -78816,7 +79236,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { zephir_check_call_status(); useExplicitIdentity = zephir_get_boolval(_8); if (useExplicitIdentity) { - zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2193); + zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2194); } if (Z_TYPE_P(columnMap) == IS_ARRAY) { ZEPHIR_OBS_NVAR(attributeField); @@ -78827,7 +79247,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Identity column '", identityField, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2201 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2202 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -78842,12 +79262,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { } if (_6) { if (useExplicitIdentity) { - zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2214); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2214); + zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2215); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2215); } } else { if (!(useExplicitIdentity)) { - zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2222); + zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2223); } ZEPHIR_OBS_NVAR(bindType); if (!(zephir_array_isset_fetch(&bindType, bindDataTypes, identityField, 0 TSRMLS_CC))) { @@ -78857,17 +79277,17 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Identity column '", identityField, "' isn\\'t part of the table columns"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2229 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2230 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2232); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2232); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2233); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2233); } } else { if (useExplicitIdentity) { - zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2236); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2236); + zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2237); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2237); } } } @@ -78957,7 +79377,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_INIT_NVAR(columnMap); ZVAL_NULL(columnMap); } - zephir_is_iterable(nonPrimary, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 2436); + zephir_is_iterable(nonPrimary, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 2437); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -78972,7 +79392,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CONCAT_SVS(_6, "Column '", field, "' have not defined a bind data type"); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2335 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2336 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -78985,7 +79405,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CONCAT_SVS(_6, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2343 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2344 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -78995,9 +79415,9 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_OBS_NVAR(value); if (zephir_fetch_property_zval(&value, this_ptr, attributeField, PH_SILENT_CC)) { if (!(useDynamicUpdate)) { - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2359); - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2359); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2360); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2360); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2360); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2361); } else { ZEPHIR_OBS_NVAR(snapshotValue); if (!(zephir_array_isset_fetch(&snapshotValue, snapshot, attributeField, 0 TSRMLS_CC))) { @@ -79019,9 +79439,9 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { break; } if (ZEPHIR_IS_LONG(bindType, 3) || ZEPHIR_IS_LONG(bindType, 7)) { - ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 311, snapshotValue); + ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 304, snapshotValue); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 311, value); + ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 304, value); zephir_check_call_status(); changed = !ZEPHIR_IS_IDENTICAL(_1, _9); break; @@ -79039,15 +79459,15 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { } } if (changed) { - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2422); - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2422); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2423); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2423); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2423); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2424); } } } else { - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2428); - zephir_array_append(&values, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2428); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2428); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2429); + zephir_array_append(&values, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2429); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2429); } } } @@ -79064,12 +79484,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CALL_METHOD(&primaryKeys, metaData, "getprimarykeyattributes", NULL, 0, this_ptr); zephir_check_call_status(); if (!(zephir_fast_count_int(primaryKeys TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 2455); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 2456); return; } ZEPHIR_INIT_NVAR(uniqueParams); array_init(uniqueParams); - zephir_is_iterable(primaryKeys, &_13, &_12, 0, 0, "phalcon/mvc/model.zep", 2478); + zephir_is_iterable(primaryKeys, &_13, &_12, 0, 0, "phalcon/mvc/model.zep", 2479); for ( ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS ; zephir_hash_move_forward_ex(_13, &_12) @@ -79084,7 +79504,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CONCAT_SVS(_6, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2466 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2467 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79093,9 +79513,9 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { } ZEPHIR_OBS_NVAR(value); if (zephir_fetch_property_zval(&value, this_ptr, attributeField, PH_SILENT_CC)) { - zephir_array_append(&uniqueParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2473); + zephir_array_append(&uniqueParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2474); } else { - zephir_array_append(&uniqueParams, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2475); + zephir_array_append(&uniqueParams, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2476); } } } @@ -79132,7 +79552,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmodelsmanager", NULL, 0); zephir_check_call_status(); ZEPHIR_CPY_WRT(manager, _0); - zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2584); + zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2585); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -79149,7 +79569,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { if (Z_TYPE_P(record) != IS_OBJECT) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_5, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects can be stored as part of belongs-to relations", "phalcon/mvc/model.zep", 2533); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects can be stored as part of belongs-to relations", "phalcon/mvc/model.zep", 2534); return; } ZEPHIR_CALL_METHOD(&columns, relation, "getfields", NULL, 0); @@ -79161,7 +79581,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { if (Z_TYPE_P(columns) == IS_ARRAY) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_6, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2542); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2543); return; } ZEPHIR_CALL_METHOD(&_0, record, "save", NULL, 0); @@ -79169,7 +79589,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { if (!(zephir_is_true(_0))) { ZEPHIR_CALL_METHOD(&_7, record, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_7, &_9, &_8, 0, 0, "phalcon/mvc/model.zep", 2571); + zephir_is_iterable(_7, &_9, &_8, 0, 0, "phalcon/mvc/model.zep", 2572); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) @@ -79216,7 +79636,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmodelsmanager", NULL, 0); zephir_check_call_status(); ZEPHIR_CPY_WRT(manager, _0); - zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2772); + zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2773); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -79239,7 +79659,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (_5) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_6, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects/arrays can be stored as part of has-many/has-one/has-many-to-many relations", "phalcon/mvc/model.zep", 2623); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects/arrays can be stored as part of has-many/has-one/has-many-to-many relations", "phalcon/mvc/model.zep", 2624); return; } ZEPHIR_CALL_METHOD(&columns, relation, "getfields", NULL, 0); @@ -79251,7 +79671,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (Z_TYPE_P(columns) == IS_ARRAY) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_7, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2632); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2633); return; } if (Z_TYPE_P(record) == IS_OBJECT) { @@ -79271,7 +79691,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CONCAT_SVS(_10, "The column '", columns, "' needs to be present in the model"); ZEPHIR_CALL_METHOD(NULL, _9, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2646 TSRMLS_CC); + zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2647 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79286,7 +79706,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CALL_METHOD(&intermediateReferencedFields, relation, "getintermediatereferencedfields", NULL, 0); zephir_check_call_status(); } - zephir_is_iterable(relatedRecords, &_14, &_13, 0, 0, "phalcon/mvc/model.zep", 2761); + zephir_is_iterable(relatedRecords, &_14, &_13, 0, 0, "phalcon/mvc/model.zep", 2762); for ( ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS ; zephir_hash_move_forward_ex(_14, &_13) @@ -79301,7 +79721,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (!(zephir_is_true(_12))) { ZEPHIR_CALL_METHOD(&_16, recordAfter, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_16, &_18, &_17, 0, 0, "phalcon/mvc/model.zep", 2703); + zephir_is_iterable(_16, &_18, &_17, 0, 0, "phalcon/mvc/model.zep", 2704); for ( ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS ; zephir_hash_move_forward_ex(_18, &_17) @@ -79334,7 +79754,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (!(zephir_is_true(_16))) { ZEPHIR_CALL_METHOD(&_23, intermediateModel, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_23, &_25, &_24, 0, 0, "phalcon/mvc/model.zep", 2755); + zephir_is_iterable(_23, &_25, &_24, 0, 0, "phalcon/mvc/model.zep", 2756); for ( ; zephir_hash_get_current_data_ex(_25, (void**) &_26, &_24) == SUCCESS ; zephir_hash_move_forward_ex(_25, &_24) @@ -79363,7 +79783,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CONCAT_SVSVS(_10, "There are no defined relations for the model '", className, "' using alias '", name, "'"); ZEPHIR_CALL_METHOD(NULL, _9, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2764 TSRMLS_CC); + zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2765 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79458,9 +79878,9 @@ static PHP_METHOD(Phalcon_Mvc_Model, save) { ZEPHIR_INIT_NVAR(_4); object_init_ex(_4, phalcon_mvc_model_validationfailed_ce); _3 = zephir_fetch_nproperty_this(this_ptr, SL("_errorMessages"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 312, this_ptr, _3); + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 305, this_ptr, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 2877 TSRMLS_CC); + zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 2878 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79478,11 +79898,6 @@ static PHP_METHOD(Phalcon_Mvc_Model, save) { ZVAL_LONG(_3, 0); zephir_update_property_this(this_ptr, SL("_dirtyState"), _3 TSRMLS_CC); } - if (ZEPHIR_GLOBAL(orm).events) { - ZEPHIR_CALL_METHOD(&_2, this_ptr, "_postsave", NULL, 0, success, exists); - zephir_check_call_status(); - ZEPHIR_CPY_WRT(success, _2); - } if (Z_TYPE_P(related) == IS_ARRAY) { if (ZEPHIR_IS_FALSE_IDENTICAL(success)) { ZEPHIR_INIT_NVAR(_1); @@ -79494,6 +79909,11 @@ static PHP_METHOD(Phalcon_Mvc_Model, save) { zephir_check_call_status(); } } + if (ZEPHIR_GLOBAL(orm).events) { + ZEPHIR_CALL_METHOD(&_2, this_ptr, "_postsave", NULL, 0, success, exists); + zephir_check_call_status(); + ZEPHIR_CPY_WRT(success, _2); + } if (ZEPHIR_IS_FALSE_IDENTICAL(success)) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "_canceloperation", NULL, 0); zephir_check_call_status(); @@ -79652,10 +80072,10 @@ static PHP_METHOD(Phalcon_Mvc_Model, delete) { ZVAL_NULL(columnMap); } if (!(zephir_fast_count_int(primaryKeys TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 3061); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 3062); return; } - zephir_is_iterable(primaryKeys, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 3102); + zephir_is_iterable(primaryKeys, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 3103); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -79669,7 +80089,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, delete) { ZEPHIR_CONCAT_SVS(_7, "Column '", primaryKey, "' have not defined a bind data type"); ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3073 TSRMLS_CC); + zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3074 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79682,7 +80102,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, delete) { ZEPHIR_CONCAT_SVS(_7, "Column '", primaryKey, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3081 TSRMLS_CC); + zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3082 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79697,17 +80117,17 @@ static PHP_METHOD(Phalcon_Mvc_Model, delete) { ZEPHIR_CONCAT_SVS(_7, "Cannot delete the record because the primary key attribute: '", attributeField, "' wasn't set"); ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3091 TSRMLS_CC); + zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3092 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 3097); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 3098); ZEPHIR_CALL_METHOD(&_2, writeConnection, "escapeidentifier", &_9, 0, primaryKey); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_VS(_7, _2, " = ?"); - zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model.zep", 3098); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 3099); + zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model.zep", 3099); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 3100); } if (ZEPHIR_GLOBAL(orm).events) { zephir_update_property_this(this_ptr, SL("_skipped"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); @@ -79783,7 +80203,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, refresh) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC); if (!ZEPHIR_IS_LONG(_0, 0)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3177); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3178); return; } ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0); @@ -79808,7 +80228,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, refresh) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "_exists", NULL, 0, metaData, readConnection, table); zephir_check_call_status(); if (!(zephir_is_true(_1))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3199); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3200); return; } ZEPHIR_OBS_NVAR(uniqueKey); @@ -79817,14 +80237,14 @@ static PHP_METHOD(Phalcon_Mvc_Model, refresh) { ZEPHIR_OBS_VAR(uniqueParams); zephir_read_property_this(&uniqueParams, this_ptr, SL("_uniqueParams"), PH_NOISY_CC); if (Z_TYPE_P(uniqueParams) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3207); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3208); return; } ZEPHIR_INIT_VAR(fields); array_init(fields); ZEPHIR_CALL_METHOD(&_1, metaData, "getattributes", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3221); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3222); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -79833,7 +80253,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, refresh) { ZEPHIR_INIT_NVAR(_5); zephir_create_array(_5, 1, 0 TSRMLS_CC); zephir_array_fast_append(_5, attribute); - zephir_array_append(&fields, _5, PH_SEPARATE, "phalcon/mvc/model.zep", 3215); + zephir_array_append(&fields, _5, PH_SEPARATE, "phalcon/mvc/model.zep", 3216); } ZEPHIR_CALL_METHOD(&dialect, readConnection, "getdialect", NULL, 0); zephir_check_call_status(); @@ -79948,7 +80368,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, skipAttributes) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3302); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3303); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -79983,7 +80403,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, skipAttributesOnCreate) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3333); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3334); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -80016,7 +80436,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, skipAttributesOnUpdate) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3362); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3363); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -80049,7 +80469,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, allowEmptyStringValues) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3391); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3392); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -80262,7 +80682,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) { if (Z_TYPE_P(columnMap) == IS_ARRAY) { ZEPHIR_INIT_VAR(snapshot); array_init(snapshot); - zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3605); + zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3606); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -80281,7 +80701,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3586 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3587 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -80298,7 +80718,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3595 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3596 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -80351,12 +80771,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_OBS_VAR(snapshot); zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC); if (Z_TYPE_P(snapshot) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3644); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3645); return; } _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC); if (!ZEPHIR_IS_LONG(_0, 0)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3651); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3652); return; } ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0); @@ -80378,7 +80798,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3683 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3684 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80390,7 +80810,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3687 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3688 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80403,7 +80823,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not defined on the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3695 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3696 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80415,14 +80835,14 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_3, "The field '", fieldName, "' was not found in the snapshot"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3702 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3703 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } RETURN_MM_BOOL(!ZEPHIR_IS_EQUAL(value, originalValue)); } ZEPHIR_INIT_NVAR(_1); - zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3738); + zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3739); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -80457,12 +80877,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) { ZEPHIR_OBS_VAR(snapshot); zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC); if (Z_TYPE_P(snapshot) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3751); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3752); return; } _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC); if (!ZEPHIR_IS_LONG(_0, 0)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3758); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3759); return; } ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0); @@ -80478,7 +80898,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) { ZEPHIR_INIT_VAR(changed); array_init(changed); ZEPHIR_INIT_VAR(_1); - zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3812); + zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3813); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -80486,17 +80906,17 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) { ZEPHIR_GET_HMKEY(name, _3, _2); ZEPHIR_GET_HVALUE(_1, _4); if (!(zephir_array_isset(snapshot, name))) { - zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3791); + zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3792); continue; } ZEPHIR_OBS_NVAR(value); if (!(zephir_fetch_property_zval(&value, this_ptr, name, PH_SILENT_CC))) { - zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3799); + zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3800); continue; } - zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3806 TSRMLS_CC); + zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3807 TSRMLS_CC); if (!ZEPHIR_IS_EQUAL(value, _5)) { - zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3807); + zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3808); continue; } } @@ -80553,7 +80973,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getRelated) { ZEPHIR_CONCAT_SVSVS(_3, "There is no defined relations for the model '", className, "' using alias '", alias, "'"); ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3854 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3855 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80691,7 +81111,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __call) { ZEPHIR_CONCAT_SVSVS(_2, "The method '", method, "' doesn't exist on model '", modelName, "'"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3946 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3947 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -80702,16 +81122,13 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { zval *_6, *_7; zend_class_entry *_5, *_8; int ZEPHIR_LAST_CALL_STATUS; - zval *method_param = NULL, *arguments = NULL, *extraMethod = NULL, *type = NULL, *modelName, *value, *model, *attributes = NULL, *field = NULL, *extraMethodFirst = NULL, *metaData = NULL, _0 = zval_used_for_init, *_1 = NULL, *_2 = NULL, *_4 = NULL; + zval *method_param = NULL, *arguments, *extraMethod = NULL, *type = NULL, *modelName, *value, *model, *attributes = NULL, *field = NULL, *extraMethodFirst = NULL, *metaData = NULL, _0 = zval_used_for_init, *_1 = NULL, *_2 = NULL, *_4 = NULL; zval *method = NULL, *_3; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 1, &method_param, &arguments); + zephir_fetch_params(1, 2, 0, &method_param, &arguments); zephir_get_strval(method, method_param); - if (!arguments) { - arguments = ZEPHIR_GLOBAL(global_null); - } ZEPHIR_INIT_VAR(extraMethod); @@ -80753,7 +81170,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { ZEPHIR_CONCAT_SVSVS(_2, "The static method '", method, "' doesn't exist on model '", modelName, "'"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3997 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3998 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80765,7 +81182,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { ZEPHIR_CONCAT_SVS(_3, "The static method '", method, "' requires one argument"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4001 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4002 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80788,7 +81205,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { if (zephir_array_isset(attributes, extraMethod)) { ZEPHIR_CPY_WRT(field, extraMethod); } else { - ZEPHIR_CALL_FUNCTION(&extraMethodFirst, "lcfirst", NULL, 65, extraMethod); + ZEPHIR_CALL_FUNCTION(&extraMethodFirst, "lcfirst", NULL, 67, extraMethod); zephir_check_call_status(); if (zephir_array_isset(attributes, extraMethodFirst)) { ZEPHIR_CPY_WRT(field, extraMethodFirst); @@ -80802,7 +81219,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { ZEPHIR_CONCAT_SVS(_2, "Cannot resolve attribute '", extraMethod, "' in the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4035 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4036 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80861,7 +81278,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __set) { zephir_check_call_status(); ZEPHIR_INIT_VAR(related); array_init(related); - zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4099); + zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4100); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -80870,7 +81287,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __set) { ZEPHIR_GET_HVALUE(item, _3); if (Z_TYPE_P(item) == IS_OBJECT) { if (zephir_instance_of_ev(item, phalcon_mvc_modelinterface_ce TSRMLS_CC)) { - zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4086); + zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4087); } } else { ZEPHIR_INIT_NVAR(lowerKey); @@ -81020,7 +81437,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, serialize) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "toarray", NULL, 0); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -81051,13 +81468,13 @@ static PHP_METHOD(Phalcon_Mvc_Model, unserialize) { } - ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(attributes) == IS_ARRAY) { ZEPHIR_CALL_CE_STATIC(&dependencyInjector, phalcon_di_ce, "getdefault", &_0, 1); zephir_check_call_status(); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4223); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4224); return; } zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); @@ -81068,13 +81485,13 @@ static PHP_METHOD(Phalcon_Mvc_Model, unserialize) { zephir_check_call_status(); ZEPHIR_CPY_WRT(manager, _1); if (Z_TYPE_P(manager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4236); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4237); return; } zephir_update_property_this(this_ptr, SL("_modelsManager"), manager TSRMLS_CC); ZEPHIR_CALL_METHOD(NULL, manager, "initialize", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4255); + zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4256); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -81094,7 +81511,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, dump) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 23, this_ptr); + ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM(); @@ -81124,7 +81541,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, toArray) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_0, metaData, "getattributes", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4319); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4320); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -81140,7 +81557,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, toArray) { ZEPHIR_CONCAT_SVS(_5, "Column '", attribute, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _4, "__construct", &_6, 9, _5); zephir_check_call_status(); - zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4297 TSRMLS_CC); + zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4298 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -81452,7 +81869,7 @@ static PHP_METHOD(Phalcon_Mvc_Router, __construct) { add_assoc_long_ex(_1, SS("controller"), 1); ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "#^/([\\w0-9\\_\\-]+)[/]{0,1}$#u", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 74, _2, _1); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 76, _2, _1); zephir_check_temp_parameter(_2); zephir_check_call_status(); zephir_array_append(&routes, _0, PH_SEPARATE, "phalcon/mvc/router.zep", 120); @@ -81465,7 +81882,7 @@ static PHP_METHOD(Phalcon_Mvc_Router, __construct) { add_assoc_long_ex(_4, SS("params"), 3); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "#^/([\\w0-9\\_\\-]+)/([\\w0-9\\.\\_]+)(/.*)*$#u", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 74, _5, _4); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 76, _5, _4); zephir_check_temp_parameter(_5); zephir_check_call_status(); zephir_array_append(&routes, _2, PH_SEPARATE, "phalcon/mvc/router.zep", 126); @@ -81990,7 +82407,7 @@ static PHP_METHOD(Phalcon_Mvc_Router, handle) { ZEPHIR_OBS_VAR(notFoundPaths); zephir_read_property_this(¬FoundPaths, this_ptr, SL("_notFoundPaths"), PH_NOISY_CC); if (Z_TYPE_P(notFoundPaths) != IS_NULL) { - ZEPHIR_CALL_CE_STATIC(&parts, phalcon_mvc_router_route_ce, "getroutepaths", &_20, 75, notFoundPaths); + ZEPHIR_CALL_CE_STATIC(&parts, phalcon_mvc_router_route_ce, "getroutepaths", &_20, 77, notFoundPaths); zephir_check_call_status(); ZEPHIR_INIT_NVAR(routeFound); ZVAL_BOOL(routeFound, 1); @@ -82103,7 +82520,7 @@ static PHP_METHOD(Phalcon_Mvc_Router, add) { ZEPHIR_INIT_VAR(route); object_init_ex(route, phalcon_mvc_router_route_ce); - ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 74, pattern, paths, httpMethods); + ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 76, pattern, paths, httpMethods); zephir_check_call_status(); do { if (ZEPHIR_IS_LONG(position, 1)) { @@ -82890,11 +83307,11 @@ static PHP_METHOD(Phalcon_Mvc_Url, getBasePath) { static PHP_METHOD(Phalcon_Mvc_Url, get) { - unsigned char _10, _12; + unsigned char _10, _12, _15; int ZEPHIR_LAST_CALL_STATUS; - zend_bool _0, _1, _11; + zend_bool _0, _1, _11, _13, _14; zval *strUri = NULL, *_9 = NULL; - zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_13; + zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_16; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 0, 4, &uri, &args, &local, &baseUri); @@ -83011,19 +83428,33 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) { _12 = ZEPHIR_STRING_OFFSET(strUri, 1); _11 = _12 != '/'; } - ZEPHIR_INIT_NVAR(uri); if (_11) { ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 1); ZEPHIR_INIT_NVAR(_3); zephir_substr(_3, strUri, 1 , 0, ZEPHIR_SUBSTR_NO_LENGTH); + ZEPHIR_INIT_NVAR(uri); ZEPHIR_CONCAT_VV(uri, baseUri, _3); } else { - ZEPHIR_CONCAT_VV(uri, baseUri, strUri); + _13 = ZEPHIR_IS_STRING(baseUri, "/"); + if (_13) { + _13 = zephir_fast_strlen_ev(strUri) == 1; + } + _14 = _13; + if (_14) { + _15 = ZEPHIR_STRING_OFFSET(strUri, 0); + _14 = _15 == '/'; + } + if (_14) { + ZEPHIR_CPY_WRT(uri, baseUri); + } else { + ZEPHIR_INIT_NVAR(uri); + ZEPHIR_CONCAT_VV(uri, baseUri, strUri); + } } } if (zephir_is_true(args)) { - ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 369, args); + ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 362, args); zephir_check_call_status(); _0 = Z_TYPE_P(queryString) == IS_STRING; if (_0) { @@ -83039,9 +83470,9 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) { ZEPHIR_CONCAT_SV(_7, "&", queryString); zephir_concat_self(&uri, _7 TSRMLS_CC); } else { - ZEPHIR_INIT_VAR(_13); - ZEPHIR_CONCAT_SV(_13, "?", queryString); - zephir_concat_self(&uri, _13 TSRMLS_CC); + ZEPHIR_INIT_VAR(_16); + ZEPHIR_CONCAT_SV(_16, "?", queryString); + zephir_concat_self(&uri, _16 TSRMLS_CC); } } } @@ -83645,7 +84076,7 @@ static PHP_METHOD(Phalcon_Mvc_View, start) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_content"), ZEPHIR_GLOBAL(global_null) TSRMLS_CC); RETURN_THIS(); @@ -83674,7 +84105,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _loadTemplateEngines) { if (Z_TYPE_P(registeredEngines) != IS_ARRAY) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_mvc_view_engine_php_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 370, this_ptr, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 363, this_ptr, dependencyInjector); zephir_check_call_status(); zephir_array_update_string(&engines, SL(".phtml"), &_1, PH_COPY | PH_SEPARATE); } else { @@ -83982,7 +84413,7 @@ static PHP_METHOD(Phalcon_Mvc_View, render) { zephir_update_property_this(this_ptr, SL("_currentRenderLevel"), _0 TSRMLS_CC); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_disabled"), PH_NOISY_CC); if (!ZEPHIR_IS_FALSE(_0)) { - ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 117); + ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 119); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_content"), _1 TSRMLS_CC); RETURN_MM_BOOL(0); @@ -84042,7 +84473,7 @@ static PHP_METHOD(Phalcon_Mvc_View, render) { RETURN_MM_BOOL(0); } } - ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 117); + ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 119); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_content"), _1 TSRMLS_CC); mustClean = 1; @@ -84221,11 +84652,11 @@ static PHP_METHOD(Phalcon_Mvc_View, getPartial) { } - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, this_ptr, "partial", NULL, 0, partialPath, params); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 284); zephir_check_call_status(); RETURN_MM(); @@ -84350,7 +84781,7 @@ static PHP_METHOD(Phalcon_Mvc_View, getRender) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, view, "render", NULL, 0, controllerName, actionName); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(view, "getcontent", NULL, 0); zephir_check_call_status(); @@ -84364,7 +84795,7 @@ static PHP_METHOD(Phalcon_Mvc_View, finish) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); RETURN_THIS(); @@ -85123,7 +85554,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection_Document, toArray) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 23, this_ptr); + ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM(); @@ -85806,7 +86237,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection_Behavior_Timestampable, notify) { ZVAL_NULL(timestamp); ZEPHIR_OBS_VAR(format); if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format); + ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 293, format); zephir_check_call_status(); } else { ZEPHIR_OBS_VAR(generator); @@ -87250,9 +87681,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, betweenWhere) { ZEPHIR_INIT_VAR(nextHiddenParam); ZVAL_LONG(nextHiddenParam, (zephir_get_numberval(hiddenParam) + 1)); ZEPHIR_INIT_VAR(minimumKey); - ZEPHIR_CONCAT_SV(minimumKey, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(minimumKey, "ACP", hiddenParam); ZEPHIR_INIT_VAR(maximumKey); - ZEPHIR_CONCAT_SV(maximumKey, "AP", nextHiddenParam); + ZEPHIR_CONCAT_SV(maximumKey, "ACP", nextHiddenParam); ZEPHIR_INIT_VAR(_0); ZEPHIR_CONCAT_VSVSVS(_0, expr, " BETWEEN :", minimumKey, ": AND :", maximumKey, ":"); ZEPHIR_INIT_VAR(_1); @@ -87296,9 +87727,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, notBetweenWhere) { ZEPHIR_INIT_VAR(nextHiddenParam); ZVAL_LONG(nextHiddenParam, (zephir_get_numberval(hiddenParam) + 1)); ZEPHIR_INIT_VAR(minimumKey); - ZEPHIR_CONCAT_SV(minimumKey, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(minimumKey, "ACP", hiddenParam); ZEPHIR_INIT_VAR(maximumKey); - ZEPHIR_CONCAT_SV(maximumKey, "AP", nextHiddenParam); + ZEPHIR_CONCAT_SV(maximumKey, "ACP", nextHiddenParam); ZEPHIR_INIT_VAR(_0); ZEPHIR_CONCAT_VSVSVS(_0, expr, " NOT BETWEEN :", minimumKey, ": AND :", maximumKey, ":"); ZEPHIR_INIT_VAR(_1); @@ -87347,17 +87778,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, inWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 451); + zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 450); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(value, _2); ZEPHIR_INIT_NVAR(key); - ZEPHIR_CONCAT_SV(key, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(key, "ACP", hiddenParam); ZEPHIR_INIT_NVAR(queryKey); ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":"); - zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 442); + zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 441); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); ZEPHIR_SEPARATE(hiddenParam); zephir_increment(hiddenParam); @@ -87406,17 +87837,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, notInWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 488); + zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 487); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(value, _2); ZEPHIR_INIT_NVAR(key); - ZEPHIR_CONCAT_SV(key, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(key, "ACP", hiddenParam); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVS(_3, ":", key, ":"); - zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 478); + zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 477); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); ZEPHIR_SEPARATE(hiddenParam); zephir_increment(hiddenParam); @@ -87751,11 +88182,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { zend_class_entry *_2; int ZEPHIR_LAST_CALL_STATUS; zval *data = NULL; - zval *modelName = NULL; - zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *attribute = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *columnMap = NULL, *_0 = NULL, *_1 = NULL, **_5, *_8 = NULL, *_9 = NULL; + zval *modelName = NULL, *operator = NULL, *_10; + zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *operator_param = NULL, *attribute = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *columnMap = NULL, *_0 = NULL, *_1 = NULL, **_5, *_8 = NULL, *_9 = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 3, 0, &dependencyInjector, &modelName_param, &data_param); + zephir_fetch_params(1, 3, 1, &dependencyInjector, &modelName_param, &data_param, &operator_param); if (unlikely(Z_TYPE_P(modelName_param) != IS_STRING && Z_TYPE_P(modelName_param) != IS_NULL)) { zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'modelName' must be a string") TSRMLS_CC); @@ -87770,6 +88201,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } data = data_param; + if (!operator_param) { + ZEPHIR_INIT_VAR(operator); + ZVAL_STRING(operator, "AND", 1); + } else { + if (unlikely(Z_TYPE_P(operator_param) != IS_STRING && Z_TYPE_P(operator_param) != IS_NULL)) { + zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'operator' must be a string") TSRMLS_CC); + RETURN_MM_NULL(); + } + + if (likely(Z_TYPE_P(operator_param) == IS_STRING)) { + zephir_get_strval(operator, operator_param); + } else { + ZEPHIR_INIT_VAR(operator); + ZVAL_EMPTY_STRING(operator); + } + } ZEPHIR_INIT_VAR(conditions); @@ -87794,7 +88241,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { zephir_check_call_status(); ZEPHIR_INIT_VAR(bind); array_init(bind); - zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 732); + zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 731); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -87807,7 +88254,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } if (_6) { ZEPHIR_OBS_NVAR(attribute); - zephir_array_fetch(&attribute, columnMap, field, PH_NOISY, "phalcon/mvc/model/criteria.zep", 709 TSRMLS_CC); + zephir_array_fetch(&attribute, columnMap, field, PH_NOISY, "phalcon/mvc/model/criteria.zep", 708 TSRMLS_CC); } else { ZEPHIR_CPY_WRT(attribute, field); } @@ -87821,7 +88268,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { if (ZEPHIR_IS_LONG(type, 2)) { ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] LIKE :", field, ":"); - zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 721); + zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 720); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, "%", value, "%"); zephir_array_update_zval(&bind, field, &_9, PH_COPY | PH_SEPARATE); @@ -87829,7 +88276,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] = :", field, ":"); - zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 728); + zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 727); zephir_array_update_zval(&bind, field, &value, PH_COPY | PH_SEPARATE); } } @@ -87843,13 +88290,15 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } if (zephir_fast_count_int(conditions TSRMLS_CC)) { ZEPHIR_INIT_NVAR(_0); - zephir_fast_join_str(_0, SL(" AND "), conditions TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 313, _0); + ZEPHIR_INIT_VAR(_10); + ZEPHIR_CONCAT_SVS(_10, " ", operator, " "); + zephir_fast_join(_0, _10, conditions TSRMLS_CC); + ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 306, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 314, bind); + ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 307, bind); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, modelName); + ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 303, modelName); zephir_check_call_status(); RETURN_CCTOR(criteria); @@ -87866,7 +88315,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, execute) { ZEPHIR_CALL_METHOD(&model, this_ptr, "getmodelname", NULL, 0); zephir_check_call_status(); if (Z_TYPE_P(model) != IS_STRING) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 756); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 755); return; } ZEPHIR_CALL_METHOD(&_0, this_ptr, "getparams", NULL, 0); @@ -87940,8 +88389,6 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, getOrder); ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, getParams); -ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, fromInput); - ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, execute); @@ -88871,7 +89318,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasOne) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 1); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _1, referencedModel, fields, referencedFields, options); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -88948,7 +89395,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addBelongsTo) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 0); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _1, referencedModel, fields, referencedFields, options); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -89026,7 +89473,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasMany) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, 2); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _0, referencedModel, fields, referencedFields, options); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -89123,9 +89570,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasManyToMany) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, 4); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _0, referencedModel, fields, referencedFields, options); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 316, intermediateFields, intermediateModel, intermediateReferencedFields); + ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 309, intermediateFields, intermediateModel, intermediateReferencedFields); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -89423,7 +89870,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { ZEPHIR_INIT_VAR(findParams); array_init(findParams); if (Z_TYPE_P(findParamsOne) == IS_ARRAY) { - zephir_is_iterable(findParamsOne, &_3, &_2, 0, 0, "phalcon/mvc/model/manager.zep", 1140); + zephir_is_iterable(findParamsOne, &_3, &_2, 0, 0, "phalcon/mvc/model/manager.zep", 1137); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -89436,12 +89883,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } if (_5) { if (!(zephir_array_isset_long(findParams, 0))) { - zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1131); + zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1128); } else { - zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1133 TSRMLS_CC); + zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1130 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSV(_1, "(", _6, ") AND ", value); - zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1133); + zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1130); } continue; } @@ -89455,7 +89902,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } } if (Z_TYPE_P(findParamsTwo) == IS_ARRAY) { - zephir_is_iterable(findParamsTwo, &_8, &_7, 0, 0, "phalcon/mvc/model/manager.zep", 1174); + zephir_is_iterable(findParamsTwo, &_8, &_7, 0, 0, "phalcon/mvc/model/manager.zep", 1171); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) @@ -89468,12 +89915,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } if (_5) { if (!(zephir_array_isset_long(findParams, 0))) { - zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1152); + zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1149); } else { - zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1154 TSRMLS_CC); + zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1151 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSV(_1, "(", _6, ") AND ", value); - zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1154); + zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1151); } continue; } @@ -89489,7 +89936,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } else { if (Z_TYPE_P(value) == IS_ARRAY) { ZEPHIR_INIT_NVAR(_11); - zephir_array_fetch(&_6, findParams, key, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1166 TSRMLS_CC); + zephir_array_fetch(&_6, findParams, key, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1163 TSRMLS_CC); zephir_fast_array_merge(_11, &(_6), &(value) TSRMLS_CC); zephir_array_update_zval(&findParams, key, &_11, PH_COPY | PH_SEPARATE); } @@ -89501,12 +89948,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } else { if (Z_TYPE_P(findParamsTwo) == IS_STRING) { if (!(zephir_array_isset_long(findParams, 0))) { - zephir_array_update_long(&findParams, 0, &findParamsTwo, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1177); + zephir_array_update_long(&findParams, 0, &findParamsTwo, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1174); } else { - zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1179 TSRMLS_CC); + zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1176 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSV(_1, "(", _6, ") AND ", findParamsTwo); - zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1179); + zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1176); } } } @@ -89564,12 +90011,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { if (Z_TYPE_P(fields) != IS_ARRAY) { ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVSVS(_1, "[", intermediateModel, "].[", intermediateFields, "] = :APR0:"); - zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1230); + zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1227); ZEPHIR_CALL_METHOD(&_2, record, "readattribute", NULL, 0, fields); zephir_check_call_status(); zephir_array_update_string(&placeholders, SL("APR0"), &_2, PH_COPY | PH_SEPARATE); } else { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1233); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1230); return; } ZEPHIR_INIT_VAR(joinConditions); @@ -89581,12 +90028,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSVSVSVS(_1, "[", intermediateModel, "].[", intermediateFields, "] = [", referencedModel, "].[", _2, "]"); - zephir_array_append(&joinConditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1243); + zephir_array_append(&joinConditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1240); } else { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1245); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1242); return; } - ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 317, extraParameters, parameters); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 310, extraParameters, parameters); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&builder, this_ptr, "createbuilder", NULL, 0, _2); zephir_check_call_status(); @@ -89615,7 +90062,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "[", _6, "] = :APR0:"); - zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1272); + zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1269); ZEPHIR_CALL_METHOD(&_7, record, "readattribute", NULL, 0, fields); zephir_check_call_status(); zephir_array_update_string(&placeholders, SL("APR0"), &_7, PH_COPY | PH_SEPARATE); @@ -89624,17 +90071,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_6, relation, "getreferencedfields", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_6, &_9, &_8, 0, 0, "phalcon/mvc/model/manager.zep", 1284); + zephir_is_iterable(_6, &_9, &_8, 0, 0, "phalcon/mvc/model/manager.zep", 1281); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) ) { ZEPHIR_GET_HMKEY(refPosition, _9, _8); ZEPHIR_GET_HVALUE(field, _10); - zephir_array_fetch(&_11, referencedFields, refPosition, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1281 TSRMLS_CC); + zephir_array_fetch(&_11, referencedFields, refPosition, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1278 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SVSVS(_12, "[", _11, "] = :APR", refPosition, ":"); - zephir_array_append(&conditions, _12, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1281); + zephir_array_append(&conditions, _12, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1278); ZEPHIR_CALL_METHOD(&_7, record, "readattribute", &_13, 0, field); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); @@ -89651,10 +90098,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { ZEPHIR_CALL_METHOD(&_2, record, "getdi", NULL, 0); zephir_check_call_status(); zephir_array_update_string(&findParams, SL("di"), &_2, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 317, findParams, parameters); + ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 310, findParams, parameters); zephir_check_call_status(); if (Z_TYPE_P(extraParameters) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 317, findArguments, extraParameters); + ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 310, findArguments, extraParameters); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(findParams, findArguments); @@ -89673,7 +90120,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { ZVAL_STRING(retrieveMethod, "find", 1); break; } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown relation type", "phalcon/mvc/model/manager.zep", 1320); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown relation type", "phalcon/mvc/model/manager.zep", 1317); return; } while(0); @@ -89849,8 +90296,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getBelongsToRecords) { RETURN_MM_BOOL(0); } ZEPHIR_OBS_VAR(relations); - zephir_array_fetch(&relations, belongsTo, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1407 TSRMLS_CC); - zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1408 TSRMLS_CC); + zephir_array_fetch(&relations, belongsTo, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1404 TSRMLS_CC); + zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1405 TSRMLS_CC); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getrelationrecords", NULL, 0, _2, method, record, parameters); zephir_check_call_status(); RETURN_MM(); @@ -89908,8 +90355,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getHasManyRecords) { RETURN_MM_BOOL(0); } ZEPHIR_OBS_VAR(relations); - zephir_array_fetch(&relations, hasMany, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1437 TSRMLS_CC); - zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1438 TSRMLS_CC); + zephir_array_fetch(&relations, hasMany, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1434 TSRMLS_CC); + zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1435 TSRMLS_CC); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getrelationrecords", NULL, 0, _2, method, record, parameters); zephir_check_call_status(); RETURN_MM(); @@ -89967,8 +90414,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getHasOneRecords) { RETURN_MM_BOOL(0); } ZEPHIR_OBS_VAR(relations); - zephir_array_fetch(&relations, hasOne, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1467 TSRMLS_CC); - zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1468 TSRMLS_CC); + zephir_array_fetch(&relations, hasOne, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1464 TSRMLS_CC); + zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1465 TSRMLS_CC); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getrelationrecords", NULL, 0, _2, method, record, parameters); zephir_check_call_status(); RETURN_MM(); @@ -90115,13 +90562,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelations) { if (Z_TYPE_P(belongsTo) == IS_ARRAY) { ZEPHIR_OBS_VAR(relations); if (zephir_array_isset_fetch(&relations, belongsTo, entityName, 0 TSRMLS_CC)) { - zephir_is_iterable(relations, &_1, &_0, 0, 0, "phalcon/mvc/model/manager.zep", 1567); + zephir_is_iterable(relations, &_1, &_0, 0, 0, "phalcon/mvc/model/manager.zep", 1564); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(relation, _2); - zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1565); + zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1562); } } } @@ -90129,13 +90576,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelations) { if (Z_TYPE_P(hasMany) == IS_ARRAY) { ZEPHIR_OBS_NVAR(relations); if (zephir_array_isset_fetch(&relations, hasMany, entityName, 0 TSRMLS_CC)) { - zephir_is_iterable(relations, &_4, &_3, 0, 0, "phalcon/mvc/model/manager.zep", 1579); + zephir_is_iterable(relations, &_4, &_3, 0, 0, "phalcon/mvc/model/manager.zep", 1576); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) ) { ZEPHIR_GET_HVALUE(relation, _5); - zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1577); + zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1574); } } } @@ -90143,13 +90590,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelations) { if (Z_TYPE_P(hasOne) == IS_ARRAY) { ZEPHIR_OBS_NVAR(relations); if (zephir_array_isset_fetch(&relations, hasOne, entityName, 0 TSRMLS_CC)) { - zephir_is_iterable(relations, &_7, &_6, 0, 0, "phalcon/mvc/model/manager.zep", 1591); + zephir_is_iterable(relations, &_7, &_6, 0, 0, "phalcon/mvc/model/manager.zep", 1588); for ( ; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS ; zephir_hash_move_forward_ex(_7, &_6) ) { ZEPHIR_GET_HVALUE(relation, _8); - zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1589); + zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1586); } } } @@ -90246,7 +90693,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, createQuery) { ZEPHIR_OBS_VAR(dependencyInjector); zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1648); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1645); return; } ZEPHIR_INIT_VAR(_1); @@ -90296,7 +90743,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, executeQuery) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _0); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1668); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1665); return; } ZEPHIR_INIT_VAR(_2); @@ -90341,7 +90788,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, createBuilder) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _0); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1700); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1697); return; } ZEPHIR_INIT_VAR(_2); @@ -90414,7 +90861,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getNamespaceAlias) { ZEPHIR_CONCAT_SVS(_2, "Namespace alias '", alias, "' is not registered"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/manager.zep", 1735 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/manager.zep", 1732 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -91684,7 +92131,7 @@ static void phalcon_orm_singlequotes(zval *return_value, zval *str TSRMLS_DC) { if (Z_TYPE_P(str) != IS_STRING) { RETURN_ZVAL(str, 1, 0); - } + } marker = Z_STRVAL_P(str); @@ -91709,10 +92156,10 @@ static void phalcon_orm_singlequotes(zval *return_value, zval *str TSRMLS_DC) { if (escaped_str.len) { RETURN_STRINGL(escaped_str.c, escaped_str.len, 0); - } else { - smart_str_free(&escaped_str); - RETURN_EMPTY_STRING(); } + + smart_str_free(&escaped_str); + RETURN_EMPTY_STRING(); } @@ -91770,6 +92217,8 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_Query) { zend_declare_property_null(phalcon_mvc_model_query_ce, SL("_bindTypes"), ZEND_ACC_PROTECTED TSRMLS_CC); + zend_declare_property_null(phalcon_mvc_model_query_ce, SL("_enableImplicitJoins"), ZEND_ACC_PROTECTED TSRMLS_CC); + zend_declare_property_null(phalcon_mvc_model_query_ce, SL("_irPhqlCache"), ZEND_ACC_STATIC|ZEND_ACC_PROTECTED TSRMLS_CC); zend_declare_class_constant_long(phalcon_mvc_model_query_ce, SL("TYPE_SELECT"), 309 TSRMLS_CC); @@ -91788,11 +92237,12 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_Query) { static PHP_METHOD(Phalcon_Mvc_Model_Query, __construct) { + zend_bool _0; int ZEPHIR_LAST_CALL_STATUS; - zval *phql = NULL, *dependencyInjector = NULL; + zval *phql = NULL, *dependencyInjector = NULL, *options = NULL, *enableImplicitJoins; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 0, 2, &phql, &dependencyInjector); + zephir_fetch_params(1, 0, 3, &phql, &dependencyInjector, &options); if (!phql) { phql = ZEPHIR_GLOBAL(global_null); @@ -91800,6 +92250,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, __construct) { if (!dependencyInjector) { dependencyInjector = ZEPHIR_GLOBAL(global_null); } + if (!options) { + options = ZEPHIR_GLOBAL(global_null); + } if (Z_TYPE_P(phql) != IS_NULL) { @@ -91809,6 +92262,16 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, __construct) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdi", NULL, 0, dependencyInjector); zephir_check_call_status(); } + _0 = Z_TYPE_P(options) == IS_ARRAY; + if (_0) { + ZEPHIR_OBS_VAR(enableImplicitJoins); + _0 = zephir_array_isset_string_fetch(&enableImplicitJoins, options, SS("enable_implicit_joins"), 0 TSRMLS_CC); + } + if (_0) { + zephir_update_property_this(this_ptr, SL("_enableImplicitJoins"), (ZEPHIR_IS_TRUE(enableImplicitJoins)) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); + } else { + zephir_update_property_this(this_ptr, SL("_enableImplicitJoins"), (ZEPHIR_GLOBAL(orm).enable_implicit_joins) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); + } ZEPHIR_MM_RESTORE(); } @@ -91829,7 +92292,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, setDI) { zephir_check_temp_parameter(_0); zephir_check_call_status(); if (Z_TYPE_P(manager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsManager' is invalid", "phalcon/mvc/model/query.zep", 137); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsManager' is invalid", "phalcon/mvc/model/query.zep", 147); return; } ZEPHIR_INIT_NVAR(_0); @@ -91838,7 +92301,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, setDI) { zephir_check_temp_parameter(_0); zephir_check_call_status(); if (Z_TYPE_P(metaData) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsMetaData' is invalid", "phalcon/mvc/model/query.zep", 142); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsMetaData' is invalid", "phalcon/mvc/model/query.zep", 152); return; } zephir_update_property_this(this_ptr, SL("_manager"), manager TSRMLS_CC); @@ -91894,7 +92357,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_OBS_VAR(columnName); - zephir_array_fetch_string(&columnName, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 186 TSRMLS_CC); + zephir_array_fetch_string(&columnName, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 196 TSRMLS_CC); ZEPHIR_OBS_VAR(sqlColumnAliases); zephir_read_property_this(&sqlColumnAliases, this_ptr, SL("_sqlColumnAliases"), PH_NOISY_CC); if (zephir_array_isset(sqlColumnAliases, columnName)) { @@ -91918,7 +92381,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Unknown model or alias '", columnDomain, "' (11), when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 212 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 222 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -91934,7 +92397,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "There is no model related to model or alias '", columnDomain, "', when executing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 229 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 239 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -91954,7 +92417,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSVSV(_2, "Column '", columnName, "' doesn't belong to the model or alias '", columnDomain, "', when executing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 239 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 249 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -91966,7 +92429,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_INIT_VAR(hasModel); ZVAL_BOOL(hasModel, 0); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); - zephir_is_iterable(_1, &_4, &_3, 0, 0, "phalcon/mvc/model/query.zep", 269); + zephir_is_iterable(_1, &_4, &_3, 0, 0, "phalcon/mvc/model/query.zep", 279); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -91984,7 +92447,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "The column '", columnName, "' is ambiguous, when preparing: ", _8); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 260 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 270 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -91999,14 +92462,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Column '", columnName, "' doesn't belong to any of the selected models (1), when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 270 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 280 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_VAR(models); zephir_read_property_this(&models, this_ptr, SL("_models"), PH_NOISY_CC); if (Z_TYPE_P(models) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The models list was not loaded correctly", "phalcon/mvc/model/query.zep", 278); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The models list was not loaded correctly", "phalcon/mvc/model/query.zep", 288); return; } ZEPHIR_INIT_VAR(className); @@ -92020,7 +92483,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Can't obtain model's source from models list: '", className, "', when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 286 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 296 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -92041,7 +92504,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Column '", columnName, "' doesn't belong to any of the selected models (3), when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 303 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 313 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -92071,13 +92534,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCallArgument) { - zephir_array_fetch_string(&_0, argument, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 326 TSRMLS_CC); + zephir_array_fetch_string(&_0, argument, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 336 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 352)) { zephir_create_array(return_value, 1, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("all"), 1); RETURN_MM(); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 323, argument); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 316, argument); zephir_check_call_status(); RETURN_MM(); @@ -92101,8 +92564,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) { ZEPHIR_INIT_VAR(whenClauses); array_init(whenClauses); - zephir_array_fetch_string(&_0, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 340 TSRMLS_CC); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 355); + zephir_array_fetch_string(&_0, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 350 TSRMLS_CC); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 365); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -92112,30 +92575,30 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) { ZEPHIR_INIT_NVAR(_4); zephir_create_array(_4, 3, 0 TSRMLS_CC); add_assoc_stringl_ex(_4, SS("type"), SL("when"), 1); - zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 344 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6); + zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 354 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _6); zephir_check_call_status(); zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE); - zephir_array_fetch_string(&_8, whenExpr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 345 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _8); + zephir_array_fetch_string(&_8, whenExpr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 355 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _8); zephir_check_call_status(); zephir_array_update_string(&_4, SL("then"), &_5, PH_COPY | PH_SEPARATE); - zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 346); + zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 356); } else { ZEPHIR_INIT_NVAR(_4); zephir_create_array(_4, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(_4, SS("type"), SL("else"), 1); - zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 350 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6); + zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 360 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _6); zephir_check_call_status(); zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE); - zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 351); + zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 361); } } zephir_create_array(return_value, 3, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("case"), 1); - zephir_array_fetch_string(&_6, expr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 357 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6); + zephir_array_fetch_string(&_6, expr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 367 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _6); zephir_check_call_status(); zephir_array_update_string(&return_value, SL("expr"), &_5, PH_COPY | PH_SEPARATE); zephir_array_update_string(&return_value, SL("when-clauses"), &whenClauses, PH_COPY | PH_SEPARATE); @@ -92169,19 +92632,19 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { ZEPHIR_INIT_VAR(functionArgs); if (zephir_array_isset_long(arguments, 0)) { array_init(functionArgs); - zephir_is_iterable(arguments, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 383); + zephir_is_iterable(arguments, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 393); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(argument, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, argument); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 317, argument); zephir_check_call_status(); - zephir_array_append(&functionArgs, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 381); + zephir_array_append(&functionArgs, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 391); } } else { zephir_create_array(functionArgs, 1, 0 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, arguments); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 317, arguments); zephir_check_call_status(); zephir_array_fast_append(functionArgs, _3); } @@ -92189,7 +92652,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { zephir_create_array(return_value, 4, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("functionCall"), 1); ZEPHIR_OBS_VAR(_5); - zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 391 TSRMLS_CC); + zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 401 TSRMLS_CC); zephir_array_update_string(&return_value, SL("name"), &_5, PH_COPY | PH_SEPARATE); zephir_array_update_string(&return_value, SL("arguments"), &functionArgs, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_6); @@ -92200,7 +92663,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { zephir_create_array(return_value, 3, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("functionCall"), 1); ZEPHIR_OBS_NVAR(_5); - zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 398 TSRMLS_CC); + zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 408 TSRMLS_CC); zephir_array_update_string(&return_value, SL("name"), &_5, PH_COPY | PH_SEPARATE); zephir_array_update_string(&return_value, SL("arguments"), &functionArgs, PH_COPY | PH_SEPARATE); RETURN_MM(); @@ -92209,7 +92672,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { zephir_create_array(return_value, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("functionCall"), 1); ZEPHIR_OBS_NVAR(_5); - zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 407 TSRMLS_CC); + zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 417 TSRMLS_CC); zephir_array_update_string(&return_value, SL("name"), &_5, PH_COPY | PH_SEPARATE); RETURN_MM(); @@ -92244,12 +92707,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { if (!ZEPHIR_IS_LONG(exprType, 409)) { ZEPHIR_OBS_VAR(exprLeft); if (zephir_array_isset_string_fetch(&exprLeft, expr, SS("left"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 323, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 316, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } ZEPHIR_OBS_VAR(exprRight); if (zephir_array_isset_string_fetch(&exprRight, expr, SS("right"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 323, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 316, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } } @@ -92327,7 +92790,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { break; } if (ZEPHIR_IS_LONG(exprType, 355)) { - ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 325, expr); + ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 318, expr); zephir_check_call_status(); break; } @@ -92414,7 +92877,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("literal"), 1); ZEPHIR_OBS_VAR(_2); - zephir_array_fetch_string(&_2, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 525 TSRMLS_CC); + zephir_array_fetch_string(&_2, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 535 TSRMLS_CC); zephir_array_update_string(&exprReturn, SL("value"), &_2, PH_COPY | PH_SEPARATE); break; } @@ -92434,9 +92897,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { } if (ZEPHIR_IS_LONG(exprType, 260)) { ZEPHIR_OBS_VAR(value); - zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 537 TSRMLS_CC); + zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 547 TSRMLS_CC); if (quoting == 1) { - if (zephir_memnstr_str(value, SL("'"), "phalcon/mvc/model/query.zep", 542)) { + if (zephir_memnstr_str(value, SL("'"), "phalcon/mvc/model/query.zep", 552)) { ZEPHIR_INIT_VAR(escapedValue); phalcon_orm_singlequotes(escapedValue, value TSRMLS_CC); } else { @@ -92458,7 +92921,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("placeholder"), 1); ZEPHIR_INIT_VAR(_3); - zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 555 TSRMLS_CC); + zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 565 TSRMLS_CC); ZEPHIR_SINIT_VAR(_5); ZVAL_STRING(&_5, "?", 0); ZEPHIR_SINIT_VAR(_6); @@ -92471,7 +92934,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_INIT_NVAR(exprReturn); zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("placeholder"), 1); - zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 559 TSRMLS_CC); + zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 569 TSRMLS_CC); ZEPHIR_INIT_VAR(_7); ZEPHIR_CONCAT_SV(_7, ":", _4); zephir_array_update_string(&exprReturn, SL("value"), &_7, PH_COPY | PH_SEPARATE); @@ -92479,14 +92942,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { } if (ZEPHIR_IS_LONG(exprType, 277)) { ZEPHIR_OBS_NVAR(value); - zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 563 TSRMLS_CC); - if (zephir_memnstr_str(value, SL(":"), "phalcon/mvc/model/query.zep", 564)) { + zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 573 TSRMLS_CC); + if (zephir_memnstr_str(value, SL(":"), "phalcon/mvc/model/query.zep", 574)) { ZEPHIR_INIT_VAR(valueParts); zephir_fast_explode_str(valueParts, SL(":"), value, LONG_MAX TSRMLS_CC); ZEPHIR_OBS_VAR(name); - zephir_array_fetch_long(&name, valueParts, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 567 TSRMLS_CC); + zephir_array_fetch_long(&name, valueParts, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 577 TSRMLS_CC); ZEPHIR_OBS_VAR(bindType); - zephir_array_fetch_long(&bindType, valueParts, 1, PH_NOISY, "phalcon/mvc/model/query.zep", 568 TSRMLS_CC); + zephir_array_fetch_long(&bindType, valueParts, 1, PH_NOISY, "phalcon/mvc/model/query.zep", 578 TSRMLS_CC); do { if (ZEPHIR_IS_STRING(bindType, "str")) { ZEPHIR_INIT_NVAR(_3); @@ -92570,7 +93033,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_7, "Bind value is required for array type placeholder: ", name); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 607 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 617 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -92581,7 +93044,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_10, "Bind type requires an array in placeholder: ", name); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 611 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 621 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -92592,7 +93055,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_10, "At least one value must be bound in placeholder: ", name); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 615 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 625 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -92612,7 +93075,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_10, "Unknown bind type: ", bindType); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 627 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 637 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -92767,17 +93230,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("literal"), 1); ZEPHIR_OBS_NVAR(_2); - zephir_array_fetch_string(&_2, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 700 TSRMLS_CC); + zephir_array_fetch_string(&_2, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 710 TSRMLS_CC); zephir_array_update_string(&exprReturn, SL("value"), &_2, PH_COPY | PH_SEPARATE); break; } if (ZEPHIR_IS_LONG(exprType, 350)) { - ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 326, expr); + ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 319, expr); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(exprType, 409)) { - ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 327, expr); + ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 320, expr); zephir_check_call_status(); break; } @@ -92787,7 +93250,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { add_assoc_stringl_ex(exprReturn, SS("type"), SL("select"), 1); ZEPHIR_INIT_NVAR(_3); ZVAL_BOOL(_3, 1); - ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 328, expr, _3); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 321, expr, _3); zephir_check_call_status(); zephir_array_update_string(&exprReturn, SL("value"), &_12, PH_COPY | PH_SEPARATE); break; @@ -92798,7 +93261,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_7, "Unknown expression type ", exprType); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 716 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 726 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -92806,29 +93269,29 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { RETURN_CCTOR(exprReturn); } if (zephir_array_isset_string(expr, SS("domain"))) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 325, expr); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 318, expr); zephir_check_call_status(); RETURN_MM(); } if (zephir_array_isset_long(expr, 0)) { ZEPHIR_INIT_VAR(listItems); array_init(listItems); - zephir_is_iterable(expr, &_14, &_13, 0, 0, "phalcon/mvc/model/query.zep", 737); + zephir_is_iterable(expr, &_14, &_13, 0, 0, "phalcon/mvc/model/query.zep", 747); for ( ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS ; zephir_hash_move_forward_ex(_14, &_13) ) { ZEPHIR_GET_HVALUE(exprListItem, _15); - ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 323, exprListItem); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 316, exprListItem); zephir_check_call_status(); - zephir_array_append(&listItems, _12, PH_SEPARATE, "phalcon/mvc/model/query.zep", 735); + zephir_array_append(&listItems, _12, PH_SEPARATE, "phalcon/mvc/model/query.zep", 745); } zephir_create_array(return_value, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("list"), 1); zephir_array_fast_append(return_value, listItems); RETURN_MM(); } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown expression", "phalcon/mvc/model/query.zep", 740); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown expression", "phalcon/mvc/model/query.zep", 750); return; } @@ -92836,10 +93299,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSelectColumn) { int ZEPHIR_LAST_CALL_STATUS; + zephir_fcall_cache_entry *_5 = NULL; HashTable *_2; HashPosition _1; - zval *column_param = NULL, *sqlColumns, *columnType, *sqlAliases, *modelName = NULL, *source = NULL, *columnDomain, *sqlColumnAlias = NULL, *preparedAlias = NULL, *sqlExprColumn = NULL, *sqlAliasesModels, *sqlColumn, *columnData, *balias, *_0, **_3, *_5 = NULL, *_6 = NULL; - zval *column = NULL, *_4 = NULL; + zval *column_param = NULL, *sqlColumns, *columnType, *sqlAliases, *modelName = NULL, *source = NULL, *columnDomain, *sqlColumnAlias = NULL, *preparedAlias = NULL, *sqlExprColumn = NULL, *sqlAliasesModels, *sqlColumn = NULL, *columnData, *balias, *eager, *_0, **_3, *_4 = NULL, *_6, *_7 = NULL, *_8 = NULL, *_9; + zval *column = NULL; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 1, 0, &column_param); @@ -92850,95 +93314,119 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSelectColumn) { ZEPHIR_OBS_VAR(columnType); if (!(zephir_array_isset_string_fetch(&columnType, column, SS("type"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 757); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 764); return; } ZEPHIR_INIT_VAR(sqlColumns); array_init(sqlColumns); + ZEPHIR_OBS_VAR(eager); + zephir_array_isset_string_fetch(&eager, column, SS("eager"), 0 TSRMLS_CC); if (ZEPHIR_IS_LONG(columnType, 352)) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_models"), PH_NOISY_CC); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 773); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 794); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) ) { ZEPHIR_GET_HMKEY(modelName, _2, _1); ZEPHIR_GET_HVALUE(source, _3); - ZEPHIR_INIT_NVAR(_4); - zephir_create_array(_4, 3, 0 TSRMLS_CC); - add_assoc_stringl_ex(_4, SS("type"), SL("object"), 1); - zephir_array_update_string(&_4, SL("model"), &modelName, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_4, SL("column"), &source, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 771); + ZEPHIR_INIT_NVAR(sqlColumn); + zephir_create_array(sqlColumn, 4, 0 TSRMLS_CC); + add_assoc_stringl_ex(sqlColumn, SS("type"), SL("object"), 1); + zephir_array_update_string(&sqlColumn, SL("model"), &modelName, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlColumn, SL("column"), &source, PH_COPY | PH_SEPARATE); + ZEPHIR_CALL_FUNCTION(&_4, "lcfirst", &_5, 67, modelName); + zephir_check_call_status(); + zephir_array_update_string(&sqlColumn, SL("balias"), &_4, PH_COPY | PH_SEPARATE); + if (Z_TYPE_P(eager) != IS_NULL) { + zephir_array_update_string(&sqlColumn, SL("eager"), &eager, PH_COPY | PH_SEPARATE); + zephir_array_fetch_string(&_6, column, SL("eagerType"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 789 TSRMLS_CC); + zephir_array_update_string(&sqlColumn, SL("eagerType"), &_6, PH_COPY | PH_SEPARATE); + } + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 792); } RETURN_CCTOR(sqlColumns); } if (!(zephir_array_isset_string(column, SS("column")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 777); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 798); return; } if (ZEPHIR_IS_LONG(columnType, 353)) { ZEPHIR_OBS_VAR(sqlAliases); zephir_read_property_this(&sqlAliases, this_ptr, SL("_sqlAliases"), PH_NOISY_CC); ZEPHIR_OBS_VAR(columnDomain); - zephir_array_fetch_string(&columnDomain, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 790 TSRMLS_CC); + zephir_array_fetch_string(&columnDomain, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 811 TSRMLS_CC); ZEPHIR_OBS_VAR(source); if (!(zephir_array_isset_fetch(&source, sqlAliases, columnDomain, 0 TSRMLS_CC))) { - ZEPHIR_INIT_VAR(_5); - object_init_ex(_5, phalcon_mvc_model_exception_ce); + ZEPHIR_INIT_VAR(_7); + object_init_ex(_7, phalcon_mvc_model_exception_ce); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_6); - ZEPHIR_CONCAT_SVSV(_6, "Unknown model or alias '", columnDomain, "' (2), when preparing: ", _0); - ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 9, _6); + ZEPHIR_INIT_VAR(_8); + ZEPHIR_CONCAT_SVSV(_8, "Unknown model or alias '", columnDomain, "' (2), when preparing: ", _0); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", NULL, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 793 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 814 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_CPY_WRT(sqlColumnAlias, source); + ZEPHIR_OBS_VAR(preparedAlias); + zephir_array_isset_string_fetch(&preparedAlias, column, SS("balias"), 0 TSRMLS_CC); ZEPHIR_OBS_VAR(sqlAliasesModels); zephir_read_property_this(&sqlAliasesModels, this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch(&modelName, sqlAliasesModels, columnDomain, PH_NOISY, "phalcon/mvc/model/query.zep", 805 TSRMLS_CC); - if (ZEPHIR_IS_EQUAL(columnDomain, modelName)) { - ZEPHIR_CALL_FUNCTION(&preparedAlias, "lcfirst", NULL, 65, modelName); - zephir_check_call_status(); - } else { - ZEPHIR_CPY_WRT(preparedAlias, columnDomain); + zephir_array_fetch(&modelName, sqlAliasesModels, columnDomain, PH_NOISY, "phalcon/mvc/model/query.zep", 828 TSRMLS_CC); + if (Z_TYPE_P(preparedAlias) != IS_STRING) { + if (ZEPHIR_IS_EQUAL(columnDomain, modelName)) { + ZEPHIR_CALL_FUNCTION(&preparedAlias, "lcfirst", &_5, 67, modelName); + zephir_check_call_status(); + } else { + ZEPHIR_CPY_WRT(preparedAlias, columnDomain); + } } - ZEPHIR_INIT_NVAR(_4); - zephir_create_array(_4, 4, 0 TSRMLS_CC); - add_assoc_stringl_ex(_4, SS("type"), SL("object"), 1); - zephir_array_update_string(&_4, SL("model"), &modelName, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_4, SL("column"), &sqlColumnAlias, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_4, SL("balias"), &preparedAlias, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 824); + ZEPHIR_INIT_NVAR(sqlColumn); + zephir_create_array(sqlColumn, 4, 0 TSRMLS_CC); + add_assoc_stringl_ex(sqlColumn, SS("type"), SL("object"), 1); + zephir_array_update_string(&sqlColumn, SL("model"), &modelName, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlColumn, SL("column"), &sqlColumnAlias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlColumn, SL("balias"), &preparedAlias, PH_COPY | PH_SEPARATE); + if (Z_TYPE_P(eager) != IS_NULL) { + zephir_array_update_string(&sqlColumn, SL("eager"), &eager, PH_COPY | PH_SEPARATE); + zephir_array_fetch_string(&_6, column, SL("eagerType"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 854 TSRMLS_CC); + zephir_array_update_string(&sqlColumn, SL("eagerType"), &_6, PH_COPY | PH_SEPARATE); + } + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 857); RETURN_CCTOR(sqlColumns); } if (ZEPHIR_IS_LONG(columnType, 354)) { - ZEPHIR_INIT_VAR(sqlColumn); + ZEPHIR_INIT_NVAR(sqlColumn); zephir_create_array(sqlColumn, 1, 0 TSRMLS_CC); add_assoc_stringl_ex(sqlColumn, SS("type"), SL("scalar"), 1); ZEPHIR_OBS_VAR(columnData); - zephir_array_fetch_string(&columnData, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 838 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 323, columnData); + zephir_array_fetch_string(&columnData, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 871 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 316, columnData); zephir_check_call_status(); ZEPHIR_OBS_VAR(balias); if (zephir_array_isset_string_fetch(&balias, sqlExprColumn, SS("balias"), 0 TSRMLS_CC)) { zephir_array_update_string(&sqlColumn, SL("balias"), &balias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&sqlColumn, SL("sqlAlias"), &balias, PH_COPY | PH_SEPARATE); } + if (Z_TYPE_P(eager) != IS_NULL) { + zephir_array_update_string(&sqlColumn, SL("eager"), &eager, PH_COPY | PH_SEPARATE); + zephir_array_fetch_string(&_9, column, SL("eagerType"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 884 TSRMLS_CC); + zephir_array_update_string(&sqlColumn, SL("eagerType"), &_9, PH_COPY | PH_SEPARATE); + } zephir_array_update_string(&sqlColumn, SL("column"), &sqlExprColumn, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 850); + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 888); RETURN_CCTOR(sqlColumns); } - ZEPHIR_INIT_NVAR(_5); - object_init_ex(_5, phalcon_mvc_model_exception_ce); - ZEPHIR_INIT_LNVAR(_6); - ZEPHIR_CONCAT_SV(_6, "Unknown type of column ", columnType); - ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 9, _6); + ZEPHIR_INIT_NVAR(_7); + object_init_ex(_7, phalcon_mvc_model_exception_ce); + ZEPHIR_INIT_LNVAR(_8); + ZEPHIR_CONCAT_SV(_8, "Unknown type of column ", columnType); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", NULL, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 855 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 893 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -92956,7 +93444,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getTable) { ZEPHIR_OBS_VAR(modelName); if (!(zephir_array_isset_string_fetch(&modelName, qualifiedName, SS("name"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 870); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 908); return; } ZEPHIR_CALL_METHOD(&model, manager, "load", NULL, 0, modelName); @@ -92987,17 +93475,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoin) { ZEPHIR_OBS_VAR(qualified); if (zephir_array_isset_string_fetch(&qualified, join, SS("qualified"), 0 TSRMLS_CC)) { - zephir_array_fetch_string(&_0, qualified, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 897 TSRMLS_CC); + zephir_array_fetch_string(&_0, qualified, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 932 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 355)) { ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_string(&modelName, qualified, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 899 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 901)) { + zephir_array_fetch_string(&modelName, qualified, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 934 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 936)) { ZEPHIR_INIT_VAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_2, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 903 TSRMLS_CC); + zephir_array_fetch_long(&_2, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 938 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_1, manager, "getnamespacealias", NULL, 0, _2); zephir_check_call_status(); - zephir_array_fetch_long(&_3, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 903 TSRMLS_CC); + zephir_array_fetch_long(&_3, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 938 TSRMLS_CC); ZEPHIR_INIT_VAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _1, "\\", _3); } else { @@ -93019,7 +93507,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoin) { RETURN_MM(); } } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 921); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 956); return; } @@ -93036,7 +93524,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoinType) { ZEPHIR_OBS_VAR(type); if (!(zephir_array_isset_string_fetch(&type, join, SS("type"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 935); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 970); return; } do { @@ -93064,7 +93552,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoinType) { ZEPHIR_CONCAT_SVSV(_2, "Unknown join type ", type, ", when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 956 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 991 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -93114,7 +93602,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_long_ex(_2, SS("type"), 355); zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_2, SL("name"), &fields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _2); zephir_check_call_status(); zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_4); @@ -93122,14 +93610,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _4); zephir_check_call_status(); zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE); zephir_array_fast_append(sqlJoinConditions, _0); } else { ZEPHIR_INIT_VAR(sqlJoinPartialConditions); array_init(sqlJoinPartialConditions); - zephir_is_iterable(fields, &_6, &_5, 0, 0, "phalcon/mvc/model/query.zep", 1044); + zephir_is_iterable(fields, &_6, &_5, 0, 0, "phalcon/mvc/model/query.zep", 1079); for ( ; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS ; zephir_hash_move_forward_ex(_6, &_5) @@ -93145,7 +93633,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { ZEPHIR_CONCAT_SVSVSV(_10, "The number of fields must be equal to the number of referenced fields in join ", modelAlias, "-", joinAlias, ", when preparing: ", _9); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 1020 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 1055 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -93158,7 +93646,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_long_ex(_2, SS("type"), 355); zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_2, SL("name"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _2); zephir_check_call_status(); zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_NVAR(_4); @@ -93166,10 +93654,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("name"), &referencedField, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _4); zephir_check_call_status(); zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlJoinPartialConditions, _0, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1041); + zephir_array_append(&sqlJoinPartialConditions, _0, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1076); } } zephir_create_array(return_value, 3, 0 TSRMLS_CC); @@ -93219,7 +93707,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { ZEPHIR_CALL_METHOD(&referencedModelName, relation, "getreferencedmodel", NULL, 0); zephir_check_call_status(); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1169); + zephir_is_iterable(fields, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1204); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -93234,12 +93722,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { ZEPHIR_CONCAT_SVSVSV(_5, "The number of fields must be equal to the number of referenced fields in join ", modelAlias, "-", joinAlias, ", when preparing: ", _4); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_6, 9, _5); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 1140 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 1175 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_NVAR(intermediateField); - zephir_array_fetch(&intermediateField, intermediateFields, position, PH_NOISY, "phalcon/mvc/model/query.zep", 1146 TSRMLS_CC); + zephir_array_fetch(&intermediateField, intermediateFields, position, PH_NOISY, "phalcon/mvc/model/query.zep", 1181 TSRMLS_CC); ZEPHIR_INIT_NVAR(sqlEqualsJoinCondition); zephir_create_array(sqlEqualsJoinCondition, 4, 0 TSRMLS_CC); add_assoc_stringl_ex(sqlEqualsJoinCondition, SS("type"), SL("binary-op"), 1); @@ -93249,7 +93737,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_long_ex(_8, SS("type"), 355); zephir_array_update_string(&_8, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_8, SL("name"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _8); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _8); zephir_check_call_status(); zephir_array_update_string(&sqlEqualsJoinCondition, SL("left"), &_7, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_NVAR(_10); @@ -93257,7 +93745,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_stringl_ex(_10, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_10, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_10, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _10); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _10); zephir_check_call_status(); zephir_array_update_string(&sqlEqualsJoinCondition, SL("right"), &_7, PH_COPY | PH_SEPARATE); } @@ -93279,7 +93767,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_long_ex(_12, SS("type"), 355); zephir_array_update_string(&_12, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_12, SL("name"), &fields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _12); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _12); zephir_check_call_status(); zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_13); @@ -93287,7 +93775,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_stringl_ex(_13, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_13, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_13, SL("name"), &intermediateFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _13); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _13); zephir_check_call_status(); zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE); zephir_array_fast_append(_10, _11); @@ -93308,7 +93796,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_long_ex(_14, SS("type"), 355); zephir_array_update_string(&_14, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_14, SL("name"), &intermediateReferencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _14); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _14); zephir_check_call_status(); zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_15); @@ -93316,7 +93804,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_stringl_ex(_15, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_15, SL("domain"), &referencedModelName, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_15, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _15); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _15); zephir_check_call_status(); zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE); zephir_array_fast_append(_10, _11); @@ -93329,12 +93817,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { - zval *_28 = NULL, *_29 = NULL; - zephir_fcall_cache_entry *_3 = NULL, *_4 = NULL, *_8 = NULL, *_13 = NULL, *_20 = NULL, *_21 = NULL, *_23 = NULL, *_24 = NULL; + zval *_17 = NULL, *_18 = NULL, *_40 = NULL; + zephir_fcall_cache_entry *_3 = NULL, *_4 = NULL, *_8 = NULL, *_13 = NULL, *_31 = NULL, *_32 = NULL, *_35 = NULL, *_36 = NULL; int ZEPHIR_LAST_CALL_STATUS; - HashTable *_1, *_10, *_15, *_18, *_26; - HashPosition _0, _9, _14, _17, _25; - zval *select, *models, *sqlAliases, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *modelsInstances, *fromModels = NULL, *sqlJoins, *joinModels, *joinSources, *joinTypes, *joinPreCondition, *joinPrepared, *manager = NULL, *selectJoins = NULL, *joinItem = NULL, *joins, *joinData = NULL, *schema = NULL, *source = NULL, *model = NULL, *realModelName = NULL, *completeSource = NULL, *joinType = NULL, *aliasExpr = NULL, *alias = NULL, *joinAliasName = NULL, *joinExpr = NULL, *fromModelName = NULL, *joinAlias = NULL, *joinModel = NULL, *joinSource = NULL, *preCondition = NULL, *modelNameAlias = NULL, *relation = NULL, *relations = NULL, *modelAlias = NULL, *sqlJoin = NULL, *sqlJoinItem = NULL, **_2, *_5 = NULL, *_6, *_7 = NULL, **_11, *_12 = NULL, **_16, **_19, *_22 = NULL, **_27; + HashTable *_1, *_10, *_15, *_20, *_26, *_29, *_38; + HashPosition _0, _9, _14, _19, _25, _28, _37; + zval *select, *models, *sqlAliases, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *modelsInstances, *fromModels = NULL, *sqlJoins, *joinModels, *joinSources, *joinTypes, *joinPreCondition, *joinPrepared, *manager, *selectJoins = NULL, *joinItem = NULL, *joins, *joinData = NULL, *schema = NULL, *source = NULL, *model = NULL, *realModelName = NULL, *completeSource = NULL, *joinType = NULL, *aliasExpr = NULL, *alias = NULL, *joinAliasName = NULL, *joinExpr = NULL, *fromModelName = NULL, *joinAlias = NULL, *joinModel = NULL, *joinSource = NULL, *preCondition = NULL, *modelNameAlias = NULL, *relation = NULL, *relations = NULL, *modelAlias = NULL, *sqlJoin = NULL, *sqlJoinItem = NULL, *selectTables = NULL, *tables, *tableItem = NULL, **_2, *_5 = NULL, *_6, *_7 = NULL, **_11, *_12 = NULL, **_16, **_21, *_22, *_23 = NULL, *_24 = NULL, **_27, **_30, *_33 = NULL, *_34, **_39; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 1, 0, &select); @@ -93368,8 +93856,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { array_init(joinPrepared); ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tables); + zephir_array_fetch_string(&tables, select, SL("tables"), PH_NOISY, "phalcon/mvc/model/query.zep", 1295 TSRMLS_CC); + if (!(zephir_array_isset_long(tables, 0))) { + ZEPHIR_INIT_VAR(selectTables); + zephir_create_array(selectTables, 1, 0 TSRMLS_CC); + zephir_array_fast_append(selectTables, tables); + } else { + ZEPHIR_CPY_WRT(selectTables, tables); + } ZEPHIR_OBS_VAR(joins); - zephir_array_fetch_string(&joins, select, SL("joins"), PH_NOISY, "phalcon/mvc/model/query.zep", 1260 TSRMLS_CC); + zephir_array_fetch_string(&joins, select, SL("joins"), PH_NOISY, "phalcon/mvc/model/query.zep", 1302 TSRMLS_CC); if (!(zephir_array_isset_long(joins, 0))) { ZEPHIR_INIT_VAR(selectJoins); zephir_create_array(selectJoins, 1, 0 TSRMLS_CC); @@ -93377,32 +93874,32 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { } else { ZEPHIR_CPY_WRT(selectJoins, joins); } - zephir_is_iterable(selectJoins, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1409); + zephir_is_iterable(selectJoins, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1451); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(joinItem, _2); - ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 329, manager, joinItem); + ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 322, manager, joinItem); zephir_check_call_status(); ZEPHIR_OBS_NVAR(source); - zephir_array_fetch_string(&source, joinData, SL("source"), PH_NOISY, "phalcon/mvc/model/query.zep", 1273 TSRMLS_CC); + zephir_array_fetch_string(&source, joinData, SL("source"), PH_NOISY, "phalcon/mvc/model/query.zep", 1315 TSRMLS_CC); ZEPHIR_OBS_NVAR(schema); - zephir_array_fetch_string(&schema, joinData, SL("schema"), PH_NOISY, "phalcon/mvc/model/query.zep", 1274 TSRMLS_CC); + zephir_array_fetch_string(&schema, joinData, SL("schema"), PH_NOISY, "phalcon/mvc/model/query.zep", 1316 TSRMLS_CC); ZEPHIR_OBS_NVAR(model); - zephir_array_fetch_string(&model, joinData, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 1275 TSRMLS_CC); + zephir_array_fetch_string(&model, joinData, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 1317 TSRMLS_CC); ZEPHIR_OBS_NVAR(realModelName); - zephir_array_fetch_string(&realModelName, joinData, SL("modelName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1276 TSRMLS_CC); + zephir_array_fetch_string(&realModelName, joinData, SL("modelName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1318 TSRMLS_CC); ZEPHIR_INIT_NVAR(completeSource); zephir_create_array(completeSource, 2, 0 TSRMLS_CC); zephir_array_fast_append(completeSource, source); zephir_array_fast_append(completeSource, schema); - ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 330, joinItem); + ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 323, joinItem); zephir_check_call_status(); ZEPHIR_OBS_NVAR(aliasExpr); if (zephir_array_isset_string_fetch(&aliasExpr, joinItem, SS("alias"), 0 TSRMLS_CC)) { ZEPHIR_OBS_NVAR(alias); - zephir_array_fetch_string(&alias, aliasExpr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1289 TSRMLS_CC); + zephir_array_fetch_string(&alias, aliasExpr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1331 TSRMLS_CC); if (zephir_array_isset(joinModels, alias)) { ZEPHIR_INIT_NVAR(_5); object_init_ex(_5, phalcon_mvc_model_exception_ce); @@ -93411,11 +93908,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { ZEPHIR_CONCAT_SVSV(_7, "Cannot use '", alias, "' as join alias because it was already used, when preparing: ", _6); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1295 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1337 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1301); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1343); zephir_array_update_zval(&joinTypes, alias, &joinType, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliases, alias, &alias, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&joinModels, alias, &realModelName, PH_COPY | PH_SEPARATE); @@ -93434,7 +93931,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { ZEPHIR_CONCAT_SVSV(_7, "Cannot use '", realModelName, "' as join alias because it was already used, when preparing: ", _6); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1354 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1396 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -93456,7 +93953,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), sqlModelsAliases TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), sqlAliasesModelsInstances TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_modelsInstances"), modelsInstances TSRMLS_CC); - zephir_is_iterable(joinPrepared, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 1429); + zephir_is_iterable(joinPrepared, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 1471); for ( ; zephir_hash_get_current_data_ex(_10, (void**) &_11, &_9) == SUCCESS ; zephir_hash_move_forward_ex(_10, &_9) @@ -93465,102 +93962,141 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { ZEPHIR_GET_HVALUE(joinItem, _11); ZEPHIR_OBS_NVAR(joinExpr); if (zephir_array_isset_string_fetch(&joinExpr, joinItem, SS("conditions"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 323, joinExpr); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 316, joinExpr); zephir_check_call_status(); zephir_array_update_zval(&joinPreCondition, joinAliasName, &_12, PH_COPY | PH_SEPARATE); } } - ZEPHIR_OBS_NVAR(manager); - zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); - ZEPHIR_INIT_NVAR(_5); - zephir_is_iterable(fromModels, &_15, &_14, 0, 0, "phalcon/mvc/model/query.zep", 1537); + _6 = zephir_fetch_nproperty_this(this_ptr, SL("_enableImplicitJoins"), PH_NOISY_CC); + if (!(zephir_is_true(_6))) { + ZEPHIR_INIT_NVAR(_5); + zephir_is_iterable(joinPrepared, &_15, &_14, 0, 0, "phalcon/mvc/model/query.zep", 1482); + for ( + ; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS + ; zephir_hash_move_forward_ex(_15, &_14) + ) { + ZEPHIR_GET_HMKEY(joinAliasName, _15, _14); + ZEPHIR_GET_HVALUE(_5, _16); + ZEPHIR_OBS_NVAR(joinType); + zephir_array_fetch(&joinType, joinTypes, joinAliasName, PH_NOISY, "phalcon/mvc/model/query.zep", 1473 TSRMLS_CC); + ZEPHIR_OBS_NVAR(joinSource); + zephir_array_fetch(&joinSource, joinSources, joinAliasName, PH_NOISY, "phalcon/mvc/model/query.zep", 1474 TSRMLS_CC); + ZEPHIR_OBS_NVAR(preCondition); + zephir_array_fetch(&preCondition, joinPreCondition, joinAliasName, PH_NOISY, "phalcon/mvc/model/query.zep", 1475 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_17); + zephir_create_array(_17, 3, 0 TSRMLS_CC); + zephir_array_update_string(&_17, SL("type"), &joinType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_17, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_18); + zephir_create_array(_18, 1, 0 TSRMLS_CC); + zephir_array_fast_append(_18, preCondition); + zephir_array_update_string(&_17, SL("conditions"), &_18, PH_COPY | PH_SEPARATE); + zephir_array_append(&sqlJoins, _17, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1480); + } + RETURN_CCTOR(sqlJoins); + } + ZEPHIR_INIT_NVAR(fromModels); + array_init(fromModels); + zephir_is_iterable(selectTables, &_20, &_19, 0, 0, "phalcon/mvc/model/query.zep", 1496); for ( - ; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS - ; zephir_hash_move_forward_ex(_15, &_14) + ; zephir_hash_get_current_data_ex(_20, (void**) &_21, &_19) == SUCCESS + ; zephir_hash_move_forward_ex(_20, &_19) + ) { + ZEPHIR_GET_HVALUE(tableItem, _21); + zephir_array_fetch_string(&_22, tableItem, SL("qualifiedName"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1490 TSRMLS_CC); + ZEPHIR_OBS_NVAR(_23); + zephir_array_fetch_string(&_23, _22, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1490 TSRMLS_CC); + zephir_array_update_zval(&fromModels, _23, &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE); + } + ZEPHIR_INIT_VAR(_24); + zephir_is_iterable(fromModels, &_26, &_25, 0, 0, "phalcon/mvc/model/query.zep", 1602); + for ( + ; zephir_hash_get_current_data_ex(_26, (void**) &_27, &_25) == SUCCESS + ; zephir_hash_move_forward_ex(_26, &_25) ) { - ZEPHIR_GET_HMKEY(fromModelName, _15, _14); - ZEPHIR_GET_HVALUE(_5, _16); - zephir_is_iterable(joinModels, &_18, &_17, 0, 0, "phalcon/mvc/model/query.zep", 1535); + ZEPHIR_GET_HMKEY(fromModelName, _26, _25); + ZEPHIR_GET_HVALUE(_24, _27); + zephir_is_iterable(joinModels, &_29, &_28, 0, 0, "phalcon/mvc/model/query.zep", 1600); for ( - ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS - ; zephir_hash_move_forward_ex(_18, &_17) + ; zephir_hash_get_current_data_ex(_29, (void**) &_30, &_28) == SUCCESS + ; zephir_hash_move_forward_ex(_29, &_28) ) { - ZEPHIR_GET_HMKEY(joinAlias, _18, _17); - ZEPHIR_GET_HVALUE(joinModel, _19); + ZEPHIR_GET_HMKEY(joinAlias, _29, _28); + ZEPHIR_GET_HVALUE(joinModel, _30); ZEPHIR_OBS_NVAR(joinSource); - zephir_array_fetch(&joinSource, joinSources, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1438 TSRMLS_CC); + zephir_array_fetch(&joinSource, joinSources, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1503 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinType); - zephir_array_fetch(&joinType, joinTypes, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1443 TSRMLS_CC); + zephir_array_fetch(&joinType, joinTypes, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1508 TSRMLS_CC); ZEPHIR_OBS_NVAR(preCondition); if (!(zephir_array_isset_fetch(&preCondition, joinPreCondition, joinAlias, 0 TSRMLS_CC))) { ZEPHIR_OBS_NVAR(modelNameAlias); - zephir_array_fetch(&modelNameAlias, sqlAliasesModels, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1453 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&relation, manager, "getrelationbyalias", &_20, 0, fromModelName, modelNameAlias); + zephir_array_fetch(&modelNameAlias, sqlAliasesModels, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1518 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&relation, manager, "getrelationbyalias", &_31, 0, fromModelName, modelNameAlias); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(relation)) { - ZEPHIR_CALL_METHOD(&relations, manager, "getrelationsbetween", &_21, 0, fromModelName, modelNameAlias); + ZEPHIR_CALL_METHOD(&relations, manager, "getrelationsbetween", &_32, 0, fromModelName, modelNameAlias); zephir_check_call_status(); if (Z_TYPE_P(relations) == IS_ARRAY) { if (zephir_fast_count_int(relations TSRMLS_CC) != 1) { - ZEPHIR_INIT_NVAR(_22); - object_init_ex(_22, phalcon_mvc_model_exception_ce); - _6 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); + ZEPHIR_INIT_NVAR(_33); + object_init_ex(_33, phalcon_mvc_model_exception_ce); + _34 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); ZEPHIR_INIT_LNVAR(_7); - ZEPHIR_CONCAT_SVSVSV(_7, "There is more than one relation between models '", fromModelName, "' and '", joinModel, "', the join must be done using an alias, when preparing: ", _6); - ZEPHIR_CALL_METHOD(NULL, _22, "__construct", &_8, 9, _7); + ZEPHIR_CONCAT_SVSVSV(_7, "There is more than one relation between models '", fromModelName, "' and '", joinModel, "', the join must be done using an alias, when preparing: ", _34); + ZEPHIR_CALL_METHOD(NULL, _33, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_22, "phalcon/mvc/model/query.zep", 1471 TSRMLS_CC); + zephir_throw_exception_debug(_33, "phalcon/mvc/model/query.zep", 1536 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_NVAR(relation); - zephir_array_fetch_long(&relation, relations, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 1477 TSRMLS_CC); + zephir_array_fetch_long(&relation, relations, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 1542 TSRMLS_CC); } } if (Z_TYPE_P(relation) == IS_OBJECT) { ZEPHIR_OBS_NVAR(modelAlias); - zephir_array_fetch(&modelAlias, sqlModelsAliases, fromModelName, PH_NOISY, "phalcon/mvc/model/query.zep", 1489 TSRMLS_CC); + zephir_array_fetch(&modelAlias, sqlModelsAliases, fromModelName, PH_NOISY, "phalcon/mvc/model/query.zep", 1554 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_12, relation, "isthrough", NULL, 0); zephir_check_call_status(); if (!(zephir_is_true(_12))) { - ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_23, 331, joinType, joinSource, modelAlias, joinAlias, relation); + ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_35, 324, joinType, joinSource, modelAlias, joinAlias, relation); zephir_check_call_status(); } else { - ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_24, 332, joinType, joinSource, modelAlias, joinAlias, relation); + ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_36, 325, joinType, joinSource, modelAlias, joinAlias, relation); zephir_check_call_status(); } if (zephir_array_isset_long(sqlJoin, 0)) { - zephir_is_iterable(sqlJoin, &_26, &_25, 0, 0, "phalcon/mvc/model/query.zep", 1507); + zephir_is_iterable(sqlJoin, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 1572); for ( - ; zephir_hash_get_current_data_ex(_26, (void**) &_27, &_25) == SUCCESS - ; zephir_hash_move_forward_ex(_26, &_25) + ; zephir_hash_get_current_data_ex(_38, (void**) &_39, &_37) == SUCCESS + ; zephir_hash_move_forward_ex(_38, &_37) ) { - ZEPHIR_GET_HVALUE(sqlJoinItem, _27); - zephir_array_append(&sqlJoins, sqlJoinItem, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1505); + ZEPHIR_GET_HVALUE(sqlJoinItem, _39); + zephir_array_append(&sqlJoins, sqlJoinItem, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1570); } } else { - zephir_array_append(&sqlJoins, sqlJoin, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1508); + zephir_array_append(&sqlJoins, sqlJoin, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1573); } } else { - ZEPHIR_INIT_NVAR(_28); - zephir_create_array(_28, 3, 0 TSRMLS_CC); - zephir_array_update_string(&_28, SL("type"), &joinType, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_28, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); - ZEPHIR_INIT_NVAR(_22); - array_init(_22); - zephir_array_update_string(&_28, SL("conditions"), &_22, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlJoins, _28, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1520); + ZEPHIR_INIT_NVAR(_17); + zephir_create_array(_17, 3, 0 TSRMLS_CC); + zephir_array_update_string(&_17, SL("type"), &joinType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_17, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_33); + array_init(_33); + zephir_array_update_string(&_17, SL("conditions"), &_33, PH_COPY | PH_SEPARATE); + zephir_array_append(&sqlJoins, _17, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1585); } } else { - ZEPHIR_INIT_NVAR(_28); - zephir_create_array(_28, 3, 0 TSRMLS_CC); - zephir_array_update_string(&_28, SL("type"), &joinType, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_28, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); - ZEPHIR_INIT_NVAR(_29); - zephir_create_array(_29, 1, 0 TSRMLS_CC); - zephir_array_fast_append(_29, preCondition); - zephir_array_update_string(&_28, SL("conditions"), &_29, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlJoins, _28, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1532); + ZEPHIR_INIT_NVAR(_18); + zephir_create_array(_18, 3, 0 TSRMLS_CC); + zephir_array_update_string(&_18, SL("type"), &joinType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_18, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_40); + zephir_create_array(_40, 1, 0 TSRMLS_CC); + zephir_array_fast_append(_40, preCondition); + zephir_array_update_string(&_18, SL("conditions"), &_40, PH_COPY | PH_SEPARATE); + zephir_array_append(&sqlJoins, _18, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1597); } } } @@ -93590,14 +94126,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getOrderClause) { } ZEPHIR_INIT_VAR(orderParts); array_init(orderParts); - zephir_is_iterable(orderColumns, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1578); + zephir_is_iterable(orderColumns, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1643); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(orderItem, _2); - zephir_array_fetch_string(&_3, orderItem, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1560 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 323, _3); + zephir_array_fetch_string(&_3, orderItem, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1625 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 316, _3); zephir_check_call_status(); if (zephir_array_isset_string_fetch(&orderSort, orderItem, SS("sort"), 1 TSRMLS_CC)) { ZEPHIR_INIT_NVAR(orderPartSort); @@ -93619,7 +94155,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getOrderClause) { zephir_create_array(orderPartSort, 1, 0 TSRMLS_CC); zephir_array_fast_append(orderPartSort, orderPartExpr); } - zephir_array_append(&orderParts, orderPartSort, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1575); + zephir_array_append(&orderParts, orderPartSort, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1640); } RETURN_CCTOR(orderParts); @@ -93644,19 +94180,19 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getGroupClause) { ZEPHIR_INIT_VAR(groupParts); if (zephir_array_isset_long(group, 0)) { array_init(groupParts); - zephir_is_iterable(group, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1596); + zephir_is_iterable(group, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1661); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(groupItem, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, groupItem); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 316, groupItem); zephir_check_call_status(); - zephir_array_append(&groupParts, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1594); + zephir_array_append(&groupParts, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1659); } } else { zephir_create_array(groupParts, 1, 0 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, group); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 316, group); zephir_check_call_status(); zephir_array_fast_append(groupParts, _3); } @@ -93682,13 +94218,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getLimitClause) { ZEPHIR_OBS_VAR(number); if (zephir_array_isset_string_fetch(&number, limitClause, SS("number"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, number); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 316, number); zephir_check_call_status(); zephir_array_update_string(&limit, SL("number"), &_0, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(offset); if (zephir_array_isset_string_fetch(&offset, limitClause, SS("offset"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, offset); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 316, offset); zephir_check_call_status(); zephir_array_update_string(&limit, SL("offset"), &_0, PH_COPY | PH_SEPARATE); } @@ -93698,12 +94234,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getLimitClause) { static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { - zval *_30 = NULL; - zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_11 = NULL, *_25 = NULL, *_31 = NULL; - HashTable *_1, *_23, *_27; - HashPosition _0, _22, _26; - int position, ZEPHIR_LAST_CALL_STATUS; - zval *ast = NULL, *merge = NULL, *sqlModels, *sqlTables, *sqlAliases, *sqlColumns, *select = NULL, *tables, *columns, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *models, *modelsInstances, *selectedModels = NULL, *manager, *metaData, *selectedModel = NULL, *qualifiedName = NULL, *modelName = NULL, *nsAlias = NULL, *realModelName = NULL, *model = NULL, *schema = NULL, *source = NULL, *completeSource = NULL, *alias = NULL, *joins, *sqlJoins = NULL, *selectColumns = NULL, *sqlColumnAliases, *column = NULL, *sqlColumn = NULL, *sqlSelect, *distinct, *having, *where, *groupBy, *order, *limit, **_2, *_3 = NULL, *_4, *_6, *_7 = NULL, *_9, *_10 = NULL, *_12, *_13, *_14, *_15, *_16, *_17, *_18, *_19, *_20, *_21, **_24, **_28, _29 = zval_used_for_init, *_32 = NULL; + zval *_19 = NULL, *_20 = NULL, *_21 = NULL; + zval *_16 = NULL; + zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_11 = NULL, *_17 = NULL, *_18 = NULL, *_32 = NULL, *_36 = NULL, *_40 = NULL; + HashTable *_1, *_13, *_34, *_38; + HashPosition _0, _12, _33, _37; + int position, number, ZEPHIR_LAST_CALL_STATUS; + zval *ast = NULL, *merge = NULL, *sqlModels, *sqlTables, *sqlAliases, *sqlColumns, *select = NULL, *tables, *columns, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *models, *modelsInstances, *selectedModels = NULL, *manager, *metaData, *selectedModel = NULL, *qualifiedName = NULL, *modelName = NULL, *nsAlias = NULL, *realModelName = NULL, *model = NULL, *schema = NULL, *source = NULL, *completeSource = NULL, *alias = NULL, *joins, *sqlJoins = NULL, *selectColumns = NULL, *sqlColumnAliases, *column = NULL, *sqlColumn = NULL, *sqlSelect, *distinct, *having, *where, *groupBy, *order, *limit, *tempModels, *tempModelsInstances, *tempSqlAliases, *tempSqlModelsAliases, *tempSqlAliasesModelsInstances, *tempSqlAliasesModels, *with = NULL, *withs = NULL, *withItem = NULL, *automaticJoins, *relation = NULL, *joinAlias = NULL, *relationModel = NULL, *bestAlias = NULL, *eagerType = NULL, **_2, *_3 = NULL, *_4, *_6, *_7 = NULL, *_9, *_10 = NULL, **_14, _15 = zval_used_for_init, *_22, *_23, *_24, *_25, *_26, *_27, *_28, *_29, *_30, *_31, **_35, **_39, *_41 = NULL; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 0, 2, &ast, &merge); @@ -93734,22 +94271,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } ZEPHIR_OBS_VAR(tables); if (!(zephir_array_isset_string_fetch(&tables, select, SS("tables"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1648); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1716); return; } ZEPHIR_OBS_VAR(columns); if (!(zephir_array_isset_string_fetch(&columns, select, SS("columns"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1652); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1720); return; } ZEPHIR_INIT_VAR(sqlModels); array_init(sqlModels); ZEPHIR_INIT_VAR(sqlTables); array_init(sqlTables); - ZEPHIR_INIT_VAR(sqlAliases); - array_init(sqlAliases); ZEPHIR_INIT_VAR(sqlColumns); array_init(sqlColumns); + ZEPHIR_INIT_VAR(sqlAliases); + array_init(sqlAliases); ZEPHIR_INIT_VAR(sqlAliasesModels); array_init(sqlAliasesModels); ZEPHIR_INIT_VAR(sqlModelsAliases); @@ -93767,35 +94304,45 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } else { ZEPHIR_CPY_WRT(selectedModels, tables); } + if (!(zephir_array_isset_long(columns, 0))) { + ZEPHIR_INIT_VAR(selectColumns); + zephir_create_array(selectColumns, 1, 0 TSRMLS_CC); + zephir_array_fast_append(selectColumns, columns); + } else { + ZEPHIR_CPY_WRT(selectColumns, columns); + } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); ZEPHIR_OBS_VAR(metaData); zephir_read_property_this(&metaData, this_ptr, SL("_metaData"), PH_NOISY_CC); if (Z_TYPE_P(manager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A models-manager is required to execute the query", "phalcon/mvc/model/query.zep", 1706); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A models-manager is required to execute the query", "phalcon/mvc/model/query.zep", 1782); return; } if (Z_TYPE_P(metaData) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A meta-data is required to execute the query", "phalcon/mvc/model/query.zep", 1710); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A meta-data is required to execute the query", "phalcon/mvc/model/query.zep", 1786); return; } - zephir_is_iterable(selectedModels, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1784); + number = 0; + ZEPHIR_INIT_VAR(automaticJoins); + array_init(automaticJoins); + zephir_is_iterable(selectedModels, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1913); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(selectedModel, _2); ZEPHIR_OBS_NVAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, selectedModel, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1716 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, selectedModel, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1795 TSRMLS_CC); ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1717 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 1722)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1796 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 1799)) { ZEPHIR_INIT_NVAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1724 TSRMLS_CC); + zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1801 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, manager, "getnamespacealias", &_5, 0, _4); zephir_check_call_status(); - zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1724 TSRMLS_CC); + zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1801 TSRMLS_CC); ZEPHIR_INIT_NVAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _3, "\\", _6); } else { @@ -93824,10 +94371,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { object_init_ex(_7, phalcon_mvc_model_exception_ce); _9 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); ZEPHIR_INIT_LNVAR(_10); - ZEPHIR_CONCAT_SVSV(_10, "Alias '", alias, "' is already used, when preparing: ", _9); + ZEPHIR_CONCAT_SVSV(_10, "Alias '", alias, "' is used more than once, when preparing: ", _9); ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 1752 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 1825 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -93836,7 +94383,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { zephir_array_update_zval(&sqlModelsAliases, realModelName, &alias, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, alias, &model, PH_COPY | PH_SEPARATE); if (Z_TYPE_P(completeSource) == IS_ARRAY) { - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1764); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1837); } else { ZEPHIR_INIT_NVAR(completeSource); zephir_create_array(completeSource, 3, 0 TSRMLS_CC); @@ -93846,14 +94393,100 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } zephir_array_update_zval(&models, realModelName, &alias, PH_COPY | PH_SEPARATE); } else { + ZEPHIR_CPY_WRT(alias, source); zephir_array_update_zval(&sqlAliases, realModelName, &source, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModels, realModelName, &realModelName, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlModelsAliases, realModelName, &realModelName, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&models, realModelName, &source, PH_COPY | PH_SEPARATE); } - zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1778); - zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1779); + ZEPHIR_OBS_NVAR(with); + if (zephir_array_isset_string_fetch(&with, selectedModel, SS("with"), 0 TSRMLS_CC)) { + if (!(zephir_array_isset_long(with, 0))) { + ZEPHIR_INIT_NVAR(withs); + zephir_create_array(withs, 1, 0 TSRMLS_CC); + zephir_array_fast_append(withs, with); + } else { + ZEPHIR_CPY_WRT(withs, with); + } + zephir_is_iterable(withs, &_13, &_12, 0, 0, "phalcon/mvc/model/query.zep", 1905); + for ( + ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS + ; zephir_hash_move_forward_ex(_13, &_12) + ) { + ZEPHIR_GET_HVALUE(withItem, _14); + ZEPHIR_SINIT_NVAR(_15); + ZVAL_LONG(&_15, number); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SV(_16, "AA", &_15); + ZEPHIR_CPY_WRT(joinAlias, _16); + ZEPHIR_OBS_NVAR(relationModel); + zephir_array_fetch_string(&relationModel, withItem, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1865 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&relation, manager, "getrelationbyalias", &_17, 0, realModelName, relationModel); + zephir_check_call_status(); + if (Z_TYPE_P(relation) == IS_OBJECT) { + ZEPHIR_INIT_NVAR(_7); + ZVAL_STRING(_7, "alias", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&bestAlias, relation, "getoption", NULL, 0, _7); + zephir_check_temp_parameter(_7); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&relationModel, relation, "getreferencedmodel", NULL, 0); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&eagerType, relation, "gettype", NULL, 0); + zephir_check_call_status(); + } else { + ZEPHIR_CALL_METHOD(&relation, manager, "getrelationsbetween", &_18, 0, realModelName, relationModel); + zephir_check_call_status(); + if (Z_TYPE_P(relation) == IS_OBJECT) { + ZEPHIR_INIT_NVAR(_7); + ZVAL_STRING(_7, "alias", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&bestAlias, relation, "getoption", NULL, 0, _7); + zephir_check_temp_parameter(_7); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&relationModel, relation, "getreferencedmodel", NULL, 0); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&eagerType, relation, "gettype", NULL, 0); + zephir_check_call_status(); + } else { + ZEPHIR_INIT_NVAR(_7); + object_init_ex(_7, phalcon_mvc_model_exception_ce); + _9 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); + ZEPHIR_INIT_LNVAR(_10); + ZEPHIR_CONCAT_SVSVSV(_10, "Can't find a relationship between '", realModelName, "' and '", relationModel, "' when preparing: ", _9); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_11, 9, _10); + zephir_check_call_status(); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 1879 TSRMLS_CC); + ZEPHIR_MM_RESTORE(); + return; + } + } + ZEPHIR_INIT_NVAR(_19); + zephir_create_array(_19, 5, 0 TSRMLS_CC); + add_assoc_long_ex(_19, SS("type"), 353); + zephir_array_update_string(&_19, SL("column"), &joinAlias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_19, SL("eager"), &alias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_19, SL("eagerType"), &eagerType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_19, SL("balias"), &bestAlias, PH_COPY | PH_SEPARATE); + zephir_array_append(&selectColumns, _19, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1889); + ZEPHIR_INIT_NVAR(_20); + zephir_create_array(_20, 3, 0 TSRMLS_CC); + add_assoc_long_ex(_20, SS("type"), 360); + ZEPHIR_INIT_NVAR(_21); + zephir_create_array(_21, 2, 0 TSRMLS_CC); + add_assoc_long_ex(_21, SS("type"), 355); + zephir_array_update_string(&_21, SL("name"), &relationModel, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_20, SL("qualified"), &_21, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_21); + zephir_create_array(_21, 2, 0 TSRMLS_CC); + add_assoc_long_ex(_21, SS("type"), 355); + zephir_array_update_string(&_21, SL("name"), &joinAlias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_20, SL("alias"), &_21, PH_COPY | PH_SEPARATE); + zephir_array_append(&automaticJoins, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1901); + number++; + } + } + zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1907); + zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1908); zephir_array_update_zval(&modelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); } if (!(zephir_is_true(merge))) { @@ -93864,68 +94497,85 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), sqlModelsAliases TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), sqlAliasesModelsInstances TSRMLS_CC); } else { + ZEPHIR_OBS_VAR(tempModels); + zephir_read_property_this(&tempModels, this_ptr, SL("_models"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempModelsInstances); + zephir_read_property_this(&tempModelsInstances, this_ptr, SL("_modelsInstances"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlAliases); + zephir_read_property_this(&tempSqlAliases, this_ptr, SL("_sqlAliases"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlAliasesModels); + zephir_read_property_this(&tempSqlAliasesModels, this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlModelsAliases); + zephir_read_property_this(&tempSqlModelsAliases, this_ptr, SL("_sqlModelsAliases"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlAliasesModelsInstances); + zephir_read_property_this(&tempSqlAliasesModelsInstances, this_ptr, SL("_sqlAliasesModelsInstances"), PH_NOISY_CC); ZEPHIR_INIT_NVAR(_7); _9 = zephir_fetch_nproperty_this(this_ptr, SL("_models"), PH_NOISY_CC); zephir_fast_array_merge(_7, &(_9), &(models) TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_models"), _7 TSRMLS_CC); - ZEPHIR_INIT_VAR(_12); - _13 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); - zephir_fast_array_merge(_12, &(_13), &(modelsInstances) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_modelsInstances"), _12 TSRMLS_CC); - ZEPHIR_INIT_VAR(_14); - _15 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliases"), PH_NOISY_CC); - zephir_fast_array_merge(_14, &(_15), &(sqlAliases) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlAliases"), _14 TSRMLS_CC); - ZEPHIR_INIT_VAR(_16); - _17 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); - zephir_fast_array_merge(_16, &(_17), &(sqlAliasesModels) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlAliasesModels"), _16 TSRMLS_CC); - ZEPHIR_INIT_VAR(_18); - _19 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlModelsAliases"), PH_NOISY_CC); - zephir_fast_array_merge(_18, &(_19), &(sqlModelsAliases) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), _18 TSRMLS_CC); - ZEPHIR_INIT_VAR(_20); - _21 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModelsInstances"), PH_NOISY_CC); - zephir_fast_array_merge(_20, &(_21), &(sqlAliasesModelsInstances) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), _20 TSRMLS_CC); + ZEPHIR_INIT_VAR(_22); + _23 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); + zephir_fast_array_merge(_22, &(_23), &(modelsInstances) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_modelsInstances"), _22 TSRMLS_CC); + ZEPHIR_INIT_VAR(_24); + _25 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliases"), PH_NOISY_CC); + zephir_fast_array_merge(_24, &(_25), &(sqlAliases) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliases"), _24 TSRMLS_CC); + ZEPHIR_INIT_VAR(_26); + _27 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); + zephir_fast_array_merge(_26, &(_27), &(sqlAliasesModels) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModels"), _26 TSRMLS_CC); + ZEPHIR_INIT_VAR(_28); + _29 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlModelsAliases"), PH_NOISY_CC); + zephir_fast_array_merge(_28, &(_29), &(sqlModelsAliases) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), _28 TSRMLS_CC); + ZEPHIR_INIT_VAR(_30); + _31 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModelsInstances"), PH_NOISY_CC); + zephir_fast_array_merge(_30, &(_31), &(sqlAliasesModelsInstances) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), _30 TSRMLS_CC); } ZEPHIR_OBS_VAR(joins); - if (zephir_array_isset_string_fetch(&joins, select, SS("joins"), 0 TSRMLS_CC)) { - if (zephir_fast_count_int(joins TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", NULL, 333, select); + zephir_array_isset_string_fetch(&joins, select, SS("joins"), 0 TSRMLS_CC); + if (zephir_fast_count_int(joins TSRMLS_CC)) { + if (zephir_fast_count_int(automaticJoins TSRMLS_CC)) { + if (zephir_array_isset_long(joins, 0)) { + ZEPHIR_INIT_NVAR(_7); + zephir_fast_array_merge(_7, &(joins), &(automaticJoins) TSRMLS_CC); + zephir_array_update_string(&select, SL("joins"), &_7, PH_COPY | PH_SEPARATE); + } else { + zephir_array_append(&automaticJoins, joins, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1945); + zephir_array_update_string(&select, SL("joins"), &automaticJoins, PH_COPY | PH_SEPARATE); + } + } + ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", &_32, 326, select); + zephir_check_call_status(); + } else { + if (zephir_fast_count_int(automaticJoins TSRMLS_CC)) { + zephir_array_update_string(&select, SL("joins"), &automaticJoins, PH_COPY | PH_SEPARATE); + ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", &_32, 326, select); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(sqlJoins); array_init(sqlJoins); } - } else { - ZEPHIR_INIT_NVAR(sqlJoins); - array_init(sqlJoins); - } - if (!(zephir_array_isset_long(columns, 0))) { - ZEPHIR_INIT_VAR(selectColumns); - zephir_create_array(selectColumns, 1, 0 TSRMLS_CC); - zephir_array_fast_append(selectColumns, columns); - } else { - ZEPHIR_CPY_WRT(selectColumns, columns); } position = 0; ZEPHIR_INIT_VAR(sqlColumnAliases); array_init(sqlColumnAliases); - zephir_is_iterable(selectColumns, &_23, &_22, 0, 0, "phalcon/mvc/model/query.zep", 1857); + zephir_is_iterable(selectColumns, &_34, &_33, 0, 0, "phalcon/mvc/model/query.zep", 1998); for ( - ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS - ; zephir_hash_move_forward_ex(_23, &_22) + ; zephir_hash_get_current_data_ex(_34, (void**) &_35, &_33) == SUCCESS + ; zephir_hash_move_forward_ex(_34, &_33) ) { - ZEPHIR_GET_HVALUE(column, _24); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_25, 334, column); + ZEPHIR_GET_HVALUE(column, _35); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_36, 327, column); zephir_check_call_status(); - zephir_is_iterable(_3, &_27, &_26, 0, 0, "phalcon/mvc/model/query.zep", 1856); + zephir_is_iterable(_3, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 1997); for ( - ; zephir_hash_get_current_data_ex(_27, (void**) &_28, &_26) == SUCCESS - ; zephir_hash_move_forward_ex(_27, &_26) + ; zephir_hash_get_current_data_ex(_38, (void**) &_39, &_37) == SUCCESS + ; zephir_hash_move_forward_ex(_38, &_37) ) { - ZEPHIR_GET_HVALUE(sqlColumn, _28); + ZEPHIR_GET_HVALUE(sqlColumn, _39); ZEPHIR_OBS_NVAR(alias); if (zephir_array_isset_string_fetch(&alias, column, SS("alias"), 0 TSRMLS_CC)) { zephir_array_update_string(&sqlColumn, SL("balias"), &alias, PH_COPY | PH_SEPARATE); @@ -93937,15 +94587,15 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { if (zephir_array_isset_string_fetch(&alias, sqlColumn, SS("balias"), 0 TSRMLS_CC)) { zephir_array_update_zval(&sqlColumns, alias, &sqlColumn, PH_COPY | PH_SEPARATE); } else { - zephir_array_fetch_string(&_4, sqlColumn, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1846 TSRMLS_CC); + zephir_array_fetch_string(&_4, sqlColumn, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1987 TSRMLS_CC); if (ZEPHIR_IS_STRING(_4, "scalar")) { - ZEPHIR_SINIT_NVAR(_29); - ZVAL_LONG(&_29, position); - ZEPHIR_INIT_LNVAR(_30); - ZEPHIR_CONCAT_SV(_30, "_", &_29); - zephir_array_update_zval(&sqlColumns, _30, &sqlColumn, PH_COPY | PH_SEPARATE); + ZEPHIR_SINIT_NVAR(_15); + ZVAL_LONG(&_15, position); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SV(_16, "_", &_15); + zephir_array_update_zval(&sqlColumns, _16, &sqlColumn, PH_COPY | PH_SEPARATE); } else { - zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1849); + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1990); } } } @@ -93967,37 +94617,45 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } ZEPHIR_OBS_VAR(where); if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_31, 323, where); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_40, 316, where); zephir_check_call_status(); zephir_array_update_string(&sqlSelect, SL("where"), &_3, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(groupBy); if (zephir_array_isset_string_fetch(&groupBy, ast, SS("groupBy"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getgroupclause", NULL, 335, groupBy); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getgroupclause", NULL, 328, groupBy); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("group"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("group"), &_41, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(having); if (zephir_array_isset_string_fetch(&having, ast, SS("having"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getexpression", &_31, 323, having); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getexpression", &_40, 316, having); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("having"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("having"), &_41, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(order); if (zephir_array_isset_string_fetch(&order, ast, SS("orderBy"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getorderclause", NULL, 336, order); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getorderclause", NULL, 329, order); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("order"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("order"), &_41, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(limit); if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getlimitclause", NULL, 337, limit); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getlimitclause", NULL, 330, limit); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("limit"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("limit"), &_41, PH_COPY | PH_SEPARATE); } if (zephir_array_isset_string(ast, SS("forUpdate"))) { zephir_array_update_string(&sqlSelect, SL("forUpdate"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE); } + if (zephir_is_true(merge)) { + zephir_update_property_this(this_ptr, SL("_models"), tempModels TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_modelsInstances"), tempModelsInstances TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliases"), tempSqlAliases TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModels"), tempSqlAliasesModels TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), tempSqlModelsAliases TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), tempSqlAliasesModelsInstances TSRMLS_CC); + } RETURN_CCTOR(sqlSelect); } @@ -94017,30 +94675,30 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { ZEPHIR_OBS_VAR(ast); zephir_read_property_this(&ast, this_ptr, SL("_ast"), PH_NOISY_CC); if (!(zephir_array_isset_string(ast, SS("qualifiedName")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 1920); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 2070); return; } if (!(zephir_array_isset_string(ast, SS("values")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 1924); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 2074); return; } ZEPHIR_OBS_VAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, ast, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1927 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, ast, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2077 TSRMLS_CC); if (!(zephir_array_isset_string(qualifiedName, SS("name")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 1931); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 2081); return; } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1935 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 1938)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2085 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2088)) { ZEPHIR_INIT_VAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_1, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1940 TSRMLS_CC); + zephir_array_fetch_long(&_1, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2090 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_0, manager, "getnamespacealias", NULL, 0, _1); zephir_check_call_status(); - zephir_array_fetch_long(&_2, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1940 TSRMLS_CC); + zephir_array_fetch_long(&_2, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2090 TSRMLS_CC); ZEPHIR_INIT_VAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _0, "\\", _2); } else { @@ -94063,8 +94721,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { notQuoting = 0; ZEPHIR_INIT_VAR(exprValues); array_init(exprValues); - zephir_array_fetch_string(&_1, ast, SL("values"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1956 TSRMLS_CC); - zephir_is_iterable(_1, &_5, &_4, 0, 0, "phalcon/mvc/model/query.zep", 1965); + zephir_array_fetch_string(&_1, ast, SL("values"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2106 TSRMLS_CC); + zephir_is_iterable(_1, &_5, &_4, 0, 0, "phalcon/mvc/model/query.zep", 2115); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -94073,12 +94731,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { ZEPHIR_INIT_NVAR(_7); zephir_create_array(_7, 2, 0 TSRMLS_CC); ZEPHIR_OBS_NVAR(_8); - zephir_array_fetch_string(&_8, exprValue, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 1960 TSRMLS_CC); + zephir_array_fetch_string(&_8, exprValue, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2110 TSRMLS_CC); zephir_array_update_string(&_7, SL("type"), &_8, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 323, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 316, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_array_update_string(&_7, SL("value"), &_0, PH_COPY | PH_SEPARATE); - zephir_array_append(&exprValues, _7, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1962); + zephir_array_append(&exprValues, _7, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2112); } ZEPHIR_INIT_VAR(sqlInsert); zephir_create_array(sqlInsert, 2, 0 TSRMLS_CC); @@ -94090,14 +94748,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { if (zephir_array_isset_string_fetch(&fields, ast, SS("fields"), 0 TSRMLS_CC)) { ZEPHIR_INIT_VAR(sqlFields); array_init(sqlFields); - zephir_is_iterable(fields, &_11, &_10, 0, 0, "phalcon/mvc/model/query.zep", 1987); + zephir_is_iterable(fields, &_11, &_10, 0, 0, "phalcon/mvc/model/query.zep", 2137); for ( ; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS ; zephir_hash_move_forward_ex(_11, &_10) ) { ZEPHIR_GET_HVALUE(field, _12); ZEPHIR_OBS_NVAR(name); - zephir_array_fetch_string(&name, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1976 TSRMLS_CC); + zephir_array_fetch_string(&name, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2126 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_0, metaData, "hasattribute", &_13, 0, model, name); zephir_check_call_status(); if (!(zephir_is_true(_0))) { @@ -94108,11 +94766,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { ZEPHIR_CONCAT_SVSVSV(_15, "The model '", modelName, "' doesn't have the attribute '", name, "', when preparing: ", _14); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_16, 9, _15); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 1980 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 2130 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&sqlFields, name, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1984); + zephir_array_append(&sqlFields, name, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2134); } zephir_array_update_string(&sqlInsert, SL("fields"), &sqlFields, PH_COPY | PH_SEPARATE); } @@ -94137,17 +94795,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { zephir_read_property_this(&ast, this_ptr, SL("_ast"), PH_NOISY_CC); ZEPHIR_OBS_VAR(update); if (!(zephir_array_isset_string_fetch(&update, ast, SS("update"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2011); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2161); return; } ZEPHIR_OBS_VAR(tables); if (!(zephir_array_isset_string_fetch(&tables, update, SS("tables"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2015); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2165); return; } ZEPHIR_OBS_VAR(values); if (!(zephir_array_isset_string_fetch(&values, update, SS("values"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2019); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2169); return; } ZEPHIR_INIT_VAR(models); @@ -94171,23 +94829,23 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); - zephir_is_iterable(updateTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2094); + zephir_is_iterable(updateTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2244); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(table, _2); ZEPHIR_OBS_NVAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2042 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2192 TSRMLS_CC); ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2043 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2048)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2193 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2198)) { ZEPHIR_INIT_NVAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2050 TSRMLS_CC); + zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2200 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, manager, "getnamespacealias", &_5, 0, _4); zephir_check_call_status(); - zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2050 TSRMLS_CC); + zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2200 TSRMLS_CC); ZEPHIR_INIT_NVAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _3, "\\", _6); } else { @@ -94214,17 +94872,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { ZEPHIR_OBS_NVAR(alias); if (zephir_array_isset_string_fetch(&alias, table, SS("alias"), 0 TSRMLS_CC)) { zephir_array_update_zval(&sqlAliases, alias, &alias, PH_COPY | PH_SEPARATE); - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2076); - zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2077); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2226); + zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2227); zephir_array_update_zval(&sqlAliasesModelsInstances, alias, &model, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&models, alias, &realModelName, PH_COPY | PH_SEPARATE); } else { zephir_array_update_zval(&sqlAliases, realModelName, &source, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2083); + zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2233); zephir_array_update_zval(&models, realModelName, &source, PH_COPY | PH_SEPARATE); } - zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2087); + zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2237); zephir_array_update_zval(&modelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); } zephir_update_property_this(this_ptr, SL("_models"), models TSRMLS_CC); @@ -94243,27 +94901,27 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { ZEPHIR_CPY_WRT(updateValues, values); } notQuoting = 0; - zephir_is_iterable(updateValues, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 2119); + zephir_is_iterable(updateValues, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 2268); for ( ; zephir_hash_get_current_data_ex(_10, (void**) &_11, &_9) == SUCCESS ; zephir_hash_move_forward_ex(_10, &_9) ) { ZEPHIR_GET_HVALUE(updateValue, _11); - zephir_array_fetch_string(&_4, updateValue, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2110 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 323, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_4, updateValue, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2260 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 316, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - zephir_array_append(&sqlFields, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2110); + zephir_array_append(&sqlFields, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2260); ZEPHIR_OBS_NVAR(exprColumn); - zephir_array_fetch_string(&exprColumn, updateValue, SL("expr"), PH_NOISY, "phalcon/mvc/model/query.zep", 2111 TSRMLS_CC); + zephir_array_fetch_string(&exprColumn, updateValue, SL("expr"), PH_NOISY, "phalcon/mvc/model/query.zep", 2261 TSRMLS_CC); ZEPHIR_INIT_NVAR(_13); zephir_create_array(_13, 2, 0 TSRMLS_CC); ZEPHIR_OBS_NVAR(_14); - zephir_array_fetch_string(&_14, exprColumn, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2113 TSRMLS_CC); + zephir_array_fetch_string(&_14, exprColumn, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2263 TSRMLS_CC); zephir_array_update_string(&_13, SL("type"), &_14, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 316, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_array_update_string(&_13, SL("value"), &_15, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlValues, _13, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2115); + zephir_array_append(&sqlValues, _13, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2265); } ZEPHIR_INIT_VAR(sqlUpdate); zephir_create_array(sqlUpdate, 4, 0 TSRMLS_CC); @@ -94275,13 +94933,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) { ZEPHIR_SINIT_VAR(_16); ZVAL_BOOL(&_16, 1); - ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, where, &_16); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 316, where, &_16); zephir_check_call_status(); zephir_array_update_string(&sqlUpdate, SL("where"), &_15, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(limit); if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 337, limit); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 330, limit); zephir_check_call_status(); zephir_array_update_string(&sqlUpdate, SL("limit"), &_15, PH_COPY | PH_SEPARATE); } @@ -94303,12 +94961,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { zephir_read_property_this(&ast, this_ptr, SL("_ast"), PH_NOISY_CC); ZEPHIR_OBS_VAR(delete); if (!(zephir_array_isset_string_fetch(&delete, ast, SS("delete"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2151); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2300); return; } ZEPHIR_OBS_VAR(tables); if (!(zephir_array_isset_string_fetch(&tables, delete, SS("tables"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2155); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2304); return; } ZEPHIR_INIT_VAR(models); @@ -94332,23 +94990,23 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); - zephir_is_iterable(deleteTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2226); + zephir_is_iterable(deleteTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2374); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(table, _2); ZEPHIR_OBS_NVAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2177 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2328 TSRMLS_CC); ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2178 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2186)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2329 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2334)) { ZEPHIR_INIT_NVAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2188 TSRMLS_CC); + zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2336 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, manager, "getnamespacealias", &_5, 0, _4); zephir_check_call_status(); - zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2188 TSRMLS_CC); + zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2336 TSRMLS_CC); ZEPHIR_INIT_NVAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _3, "\\", _6); } else { @@ -94375,17 +95033,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { ZEPHIR_OBS_NVAR(alias); if (zephir_array_isset_string_fetch(&alias, table, SS("alias"), 0 TSRMLS_CC)) { zephir_array_update_zval(&sqlAliases, alias, &alias, PH_COPY | PH_SEPARATE); - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2208); - zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2209); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2356); + zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2357); zephir_array_update_zval(&sqlAliasesModelsInstances, alias, &model, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&models, alias, &realModelName, PH_COPY | PH_SEPARATE); } else { zephir_array_update_zval(&sqlAliases, realModelName, &source, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2215); + zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2363); zephir_array_update_zval(&models, realModelName, &source, PH_COPY | PH_SEPARATE); } - zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2219); + zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2367); zephir_array_update_zval(&modelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); } zephir_update_property_this(this_ptr, SL("_models"), models TSRMLS_CC); @@ -94400,13 +95058,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) { ZEPHIR_SINIT_VAR(_9); ZVAL_BOOL(&_9, 1); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 323, where, &_9); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 316, where, &_9); zephir_check_call_status(); zephir_array_update_string(&sqlDelete, SL("where"), &_3, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(limit); if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 337, limit); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 330, limit); zephir_check_call_status(); zephir_array_update_string(&sqlDelete, SL("limit"), &_10, PH_COPY | PH_SEPARATE); } @@ -94442,7 +95100,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { _0 = zephir_fetch_static_property_ce(phalcon_mvc_model_query_ce, SL("_irPhqlCache") TSRMLS_CC); if (zephir_array_isset_fetch(&irPhql, _0, uniqueId, 0 TSRMLS_CC)) { if (Z_TYPE_P(irPhql) == IS_ARRAY) { - zephir_array_fetch_string(&_1, ast, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2277 TSRMLS_CC); + zephir_array_fetch_string(&_1, ast, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2425 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); RETURN_CCTOR(irPhql); } @@ -94454,22 +95112,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { zephir_update_property_this(this_ptr, SL("_type"), type TSRMLS_CC); do { if (ZEPHIR_IS_LONG(type, 309)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 328); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 321); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 306)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 338); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 331); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 300)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 339); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 332); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 303)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 340); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 333); zephir_check_call_status(); break; } @@ -94479,7 +95137,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { ZEPHIR_CONCAT_SVSV(_3, "Unknown statement ", type, ", when preparing: ", phql); ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/mvc/model/query.zep", 2310 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/mvc/model/query.zep", 2458 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -94487,7 +95145,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { } } if (Z_TYPE_P(irPhql) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted AST", "phalcon/mvc/model/query.zep", 2316); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted AST", "phalcon/mvc/model/query.zep", 2464); return; } if (Z_TYPE_P(uniqueId) == IS_LONG) { @@ -94531,8 +95189,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_INIT_VAR(connectionTypes); array_init(connectionTypes); ZEPHIR_OBS_VAR(models); - zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2359 TSRMLS_CC); - zephir_is_iterable(models, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2387); + zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2507 TSRMLS_CC); + zephir_is_iterable(models, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2535); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -94551,7 +95209,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_CALL_METHOD(&connection, model, "selectreadconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectReadConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2374); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectReadConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2522); return; } } else { @@ -94562,28 +95220,28 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_check_call_status(); zephir_array_update_zval(&connectionTypes, _6, &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE); if (zephir_fast_count_int(connectionTypes TSRMLS_CC) == 2) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot use models of different database systems in the same query", "phalcon/mvc/model/query.zep", 2383); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot use models of different database systems in the same query", "phalcon/mvc/model/query.zep", 2531); return; } } ZEPHIR_OBS_VAR(columns); - zephir_array_fetch_string(&columns, intermediate, SL("columns"), PH_NOISY, "phalcon/mvc/model/query.zep", 2387 TSRMLS_CC); + zephir_array_fetch_string(&columns, intermediate, SL("columns"), PH_NOISY, "phalcon/mvc/model/query.zep", 2535 TSRMLS_CC); haveObjects = 0; haveScalars = 0; isComplex = 0; numberObjects = 0; ZEPHIR_CPY_WRT(columns1, columns); - zephir_is_iterable(columns, &_8, &_7, 0, 0, "phalcon/mvc/model/query.zep", 2414); + zephir_is_iterable(columns, &_8, &_7, 0, 0, "phalcon/mvc/model/query.zep", 2562); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) ) { ZEPHIR_GET_HVALUE(column, _9); if (Z_TYPE_P(column) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid column definition", "phalcon/mvc/model/query.zep", 2400); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid column definition", "phalcon/mvc/model/query.zep", 2548); return; } - zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2403 TSRMLS_CC); + zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2551 TSRMLS_CC); if (ZEPHIR_IS_STRING(_10, "scalar")) { if (!(zephir_array_isset_string(column, SS("balias")))) { isComplex = 1; @@ -94617,7 +95275,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { array_init(simpleColumnMap); ZEPHIR_OBS_VAR(metaData); zephir_read_property_this(&metaData, this_ptr, SL("_metaData"), PH_NOISY_CC); - zephir_is_iterable(columns, &_12, &_11, 0, 0, "phalcon/mvc/model/query.zep", 2513); + zephir_is_iterable(columns, &_12, &_11, 0, 0, "phalcon/mvc/model/query.zep", 2661); for ( ; zephir_hash_get_current_data_ex(_12, (void**) &_13, &_11) == SUCCESS ; zephir_hash_move_forward_ex(_12, &_11) @@ -94625,11 +95283,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_GET_HMKEY(aliasCopy, _12, _11); ZEPHIR_GET_HVALUE(column, _13); ZEPHIR_OBS_NVAR(sqlColumn); - zephir_array_fetch_string(&sqlColumn, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 2438 TSRMLS_CC); - zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2441 TSRMLS_CC); + zephir_array_fetch_string(&sqlColumn, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 2586 TSRMLS_CC); + zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2589 TSRMLS_CC); if (ZEPHIR_IS_STRING(_10, "object")) { ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, column, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2443 TSRMLS_CC); + zephir_array_fetch_string(&modelName, column, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2591 TSRMLS_CC); ZEPHIR_OBS_NVAR(instance); _3 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&instance, _3, modelName, 0 TSRMLS_CC))) { @@ -94647,7 +95305,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_INIT_NVAR(columnMap); ZVAL_NULL(columnMap); } - zephir_is_iterable(attributes, &_18, &_17, 0, 0, "phalcon/mvc/model/query.zep", 2469); + zephir_is_iterable(attributes, &_18, &_17, 0, 0, "phalcon/mvc/model/query.zep", 2617); for ( ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS ; zephir_hash_move_forward_ex(_18, &_17) @@ -94660,7 +95318,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_INIT_LNVAR(_21); ZEPHIR_CONCAT_SVSV(_21, "_", sqlColumn, "_", attribute); zephir_array_fast_append(_20, _21); - zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2465); + zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2613); } zephir_array_update_multi(&columns1, &instance TSRMLS_CC, SL("zs"), 3, aliasCopy, SL("instance")); zephir_array_update_multi(&columns1, &attributes TSRMLS_CC, SL("zs"), 3, aliasCopy, SL("attributes")); @@ -94674,7 +95332,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_array_update_multi(&columns1, &_4 TSRMLS_CC, SL("zs"), 3, aliasCopy, SL("keepSnapshots")); } } else { - zephir_is_iterable(attributes, &_24, &_23, 0, 0, "phalcon/mvc/model/query.zep", 2487); + zephir_is_iterable(attributes, &_24, &_23, 0, 0, "phalcon/mvc/model/query.zep", 2635); for ( ; zephir_hash_get_current_data_ex(_24, (void**) &_25, &_23) == SUCCESS ; zephir_hash_move_forward_ex(_24, &_23) @@ -94684,7 +95342,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_create_array(_20, 2, 0 TSRMLS_CC); zephir_array_fast_append(_20, attribute); zephir_array_fast_append(_20, sqlColumn); - zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2485); + zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2633); } } } else { @@ -94699,7 +95357,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_array_fast_append(columnAlias, ZEPHIR_GLOBAL(global_null)); zephir_array_fast_append(columnAlias, aliasCopy); } - zephir_array_append(&selectColumns, columnAlias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2498); + zephir_array_append(&selectColumns, columnAlias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2646); } _26 = isComplex == 0; if (_26) { @@ -94720,7 +95378,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { if (Z_TYPE_P(bindParams) == IS_ARRAY) { ZEPHIR_INIT_VAR(processed); array_init(processed); - zephir_is_iterable(bindParams, &_28, &_27, 0, 0, "phalcon/mvc/model/query.zep", 2534); + zephir_is_iterable(bindParams, &_28, &_27, 0, 0, "phalcon/mvc/model/query.zep", 2682); for ( ; zephir_hash_get_current_data_ex(_28, (void**) &_29, &_27) == SUCCESS ; zephir_hash_move_forward_ex(_28, &_27) @@ -94746,7 +95404,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { if (Z_TYPE_P(bindTypes) == IS_ARRAY) { ZEPHIR_INIT_VAR(processedTypes); array_init(processedTypes); - zephir_is_iterable(bindTypes, &_31, &_30, 0, 0, "phalcon/mvc/model/query.zep", 2550); + zephir_is_iterable(bindTypes, &_31, &_30, 0, 0, "phalcon/mvc/model/query.zep", 2698); for ( ; zephir_hash_get_current_data_ex(_31, (void**) &_32, &_30) == SUCCESS ; zephir_hash_move_forward_ex(_31, &_30) @@ -94818,7 +95476,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { array_init(simpleColumnMap); ZEPHIR_CALL_METHOD(&_6, metaData, "getattributes", NULL, 0, model); zephir_check_call_status(); - zephir_is_iterable(_6, &_34, &_33, 0, 0, "phalcon/mvc/model/query.zep", 2633); + zephir_is_iterable(_6, &_34, &_33, 0, 0, "phalcon/mvc/model/query.zep", 2781); for ( ; zephir_hash_get_current_data_ex(_34, (void**) &_35, &_33) == SUCCESS ; zephir_hash_move_forward_ex(_34, &_33) @@ -94828,13 +95486,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_create_array(_20, 2, 0 TSRMLS_CC); zephir_array_fast_append(_20, attribute); ZEPHIR_OBS_NVAR(_36); - zephir_array_fetch(&_36, typesColumnMap, attribute, PH_NOISY, "phalcon/mvc/model/query.zep", 2631 TSRMLS_CC); + zephir_array_fetch(&_36, typesColumnMap, attribute, PH_NOISY, "phalcon/mvc/model/query.zep", 2779 TSRMLS_CC); zephir_array_fast_append(_20, _36); zephir_array_update_zval(&simpleColumnMap, attribute, &_20, PH_COPY | PH_SEPARATE); } } else { array_init(simpleColumnMap); - zephir_is_iterable(columnMap, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 2638); + zephir_is_iterable(columnMap, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 2786); for ( ; zephir_hash_get_current_data_ex(_38, (void**) &_39, &_37) == SUCCESS ; zephir_hash_move_forward_ex(_38, &_37) @@ -94845,7 +95503,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_create_array(_20, 2, 0 TSRMLS_CC); zephir_array_fast_append(_20, attribute); ZEPHIR_OBS_NVAR(_36); - zephir_array_fetch(&_36, typesColumnMap, column, PH_NOISY, "phalcon/mvc/model/query.zep", 2636 TSRMLS_CC); + zephir_array_fetch(&_36, typesColumnMap, column, PH_NOISY, "phalcon/mvc/model/query.zep", 2784 TSRMLS_CC); zephir_array_fast_append(_20, _36); zephir_array_update_zval(&simpleColumnMap, column, &_20, PH_COPY | PH_SEPARATE); } @@ -94856,12 +95514,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { isKeepingSnapshots = zephir_get_boolval(_40); } object_init_ex(return_value, phalcon_mvc_model_resultset_simple_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 341, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 334, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); } object_init_ex(return_value, phalcon_mvc_model_resultset_complex_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 342, columns1, resultData, cache); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 335, columns1, resultData, cache); zephir_check_call_status(); RETURN_MM(); @@ -94882,7 +95540,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_string(&modelName, intermediate, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2675 TSRMLS_CC); + zephir_array_fetch_string(&modelName, intermediate, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2823 TSRMLS_CC); ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); ZEPHIR_OBS_VAR(model); @@ -94897,7 +95555,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2688); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2836); return; } } else { @@ -94922,16 +95580,16 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { } } ZEPHIR_OBS_VAR(values); - zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2711 TSRMLS_CC); + zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2859 TSRMLS_CC); if (zephir_fast_count_int(fields TSRMLS_CC) != zephir_fast_count_int(values TSRMLS_CC)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The column count does not match the values count", "phalcon/mvc/model/query.zep", 2717); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The column count does not match the values count", "phalcon/mvc/model/query.zep", 2865); return; } ZEPHIR_CALL_METHOD(&dialect, connection, "getdialect", NULL, 0); zephir_check_call_status(); ZEPHIR_INIT_VAR(insertValues); array_init(insertValues); - zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 2785); + zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 2933); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -94939,8 +95597,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_GET_HMKEY(number, _3, _2); ZEPHIR_GET_HVALUE(value, _4); ZEPHIR_OBS_NVAR(exprValue); - zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 2728 TSRMLS_CC); - zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2729 TSRMLS_CC); + zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 2876 TSRMLS_CC); + zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2877 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_5, 260) || ZEPHIR_IS_LONG(_5, 258) || ZEPHIR_IS_LONG(_5, 259)) { ZEPHIR_CALL_METHOD(&insertValue, dialect, "getsqlexpression", &_6, 0, exprValue); @@ -94954,7 +95612,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { } if (ZEPHIR_IS_LONG(_5, 273) || ZEPHIR_IS_LONG(_5, 274) || ZEPHIR_IS_LONG(_5, 277)) { if (Z_TYPE_P(bindParams) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 2746); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 2894); return; } ZEPHIR_CALL_METHOD(&_7, dialect, "getsqlexpression", &_8, 0, exprValue); @@ -94973,7 +95631,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_CONCAT_SVS(_11, "Bound parameter '", wildcard, "' cannot be replaced because it isn't in the placeholders list"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_12, 9, _11); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2751 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2899 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -94989,7 +95647,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { } while(0); ZEPHIR_OBS_NVAR(fieldName); - zephir_array_fetch(&fieldName, fields, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2761 TSRMLS_CC); + zephir_array_fetch(&fieldName, fields, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2909 TSRMLS_CC); if (automaticFields == 1) { if (Z_TYPE_P(columnMap) == IS_ARRAY) { ZEPHIR_OBS_NVAR(attributeName); @@ -95000,7 +95658,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_CONCAT_SVS(_11, "Column '", fieldName, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_12, 9, _11); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2769 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2917 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -95021,7 +95679,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_CALL_METHOD(&_15, insertModel, "create", NULL, 0, insertValues); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 343, _15, insertModel); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 336, _15, insertModel); zephir_check_call_status(); RETURN_MM(); @@ -95042,13 +95700,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_OBS_VAR(models); - zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2809 TSRMLS_CC); + zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2957 TSRMLS_CC); if (zephir_array_isset_long(models, 1)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Updating several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 2812); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Updating several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 2960); return; } ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 2815 TSRMLS_CC); + zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 2963 TSRMLS_CC); ZEPHIR_OBS_VAR(model); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&model, _0, modelName, 0 TSRMLS_CC))) { @@ -95060,7 +95718,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2827); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2975); return; } } else { @@ -95070,14 +95728,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CALL_METHOD(&dialect, connection, "getdialect", NULL, 0); zephir_check_call_status(); ZEPHIR_OBS_VAR(fields); - zephir_array_fetch_string(&fields, intermediate, SL("fields"), PH_NOISY, "phalcon/mvc/model/query.zep", 2835 TSRMLS_CC); + zephir_array_fetch_string(&fields, intermediate, SL("fields"), PH_NOISY, "phalcon/mvc/model/query.zep", 2983 TSRMLS_CC); ZEPHIR_OBS_VAR(values); - zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2836 TSRMLS_CC); + zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2984 TSRMLS_CC); ZEPHIR_INIT_VAR(updateValues); array_init(updateValues); ZEPHIR_CPY_WRT(selectBindParams, bindParams); ZEPHIR_CPY_WRT(selectBindTypes, bindTypes); - zephir_is_iterable(fields, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 2903); + zephir_is_iterable(fields, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 3051); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -95085,17 +95743,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_GET_HMKEY(number, _3, _2); ZEPHIR_GET_HVALUE(field, _4); ZEPHIR_OBS_NVAR(value); - zephir_array_fetch(&value, values, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2851 TSRMLS_CC); + zephir_array_fetch(&value, values, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2999 TSRMLS_CC); ZEPHIR_OBS_NVAR(exprValue); - zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 2852 TSRMLS_CC); + zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 3000 TSRMLS_CC); if (zephir_array_isset_string(field, SS("balias"))) { ZEPHIR_OBS_NVAR(fieldName); - zephir_array_fetch_string(&fieldName, field, SL("balias"), PH_NOISY, "phalcon/mvc/model/query.zep", 2855 TSRMLS_CC); + zephir_array_fetch_string(&fieldName, field, SL("balias"), PH_NOISY, "phalcon/mvc/model/query.zep", 3003 TSRMLS_CC); } else { ZEPHIR_OBS_NVAR(fieldName); - zephir_array_fetch_string(&fieldName, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2857 TSRMLS_CC); + zephir_array_fetch_string(&fieldName, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 3005 TSRMLS_CC); } - zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2860 TSRMLS_CC); + zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 3008 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_5, 260) || ZEPHIR_IS_LONG(_5, 258) || ZEPHIR_IS_LONG(_5, 259)) { ZEPHIR_CALL_METHOD(&updateValue, dialect, "getsqlexpression", &_6, 0, exprValue); @@ -95109,7 +95767,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { } if (ZEPHIR_IS_LONG(_5, 273) || ZEPHIR_IS_LONG(_5, 274) || ZEPHIR_IS_LONG(_5, 277)) { if (Z_TYPE_P(bindParams) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 2877); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 3025); return; } ZEPHIR_CALL_METHOD(&_7, dialect, "getsqlexpression", &_8, 0, exprValue); @@ -95131,14 +95789,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CONCAT_SVS(_12, "Bound parameter '", wildcard, "' cannot be replaced because it's not in the placeholders list"); ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_13, 9, _12); zephir_check_call_status(); - zephir_throw_exception_debug(_11, "phalcon/mvc/model/query.zep", 2885 TSRMLS_CC); + zephir_throw_exception_debug(_11, "phalcon/mvc/model/query.zep", 3033 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } break; } if (ZEPHIR_IS_LONG(_5, 277)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/query.zep", 2890); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/query.zep", 3038); return; } ZEPHIR_INIT_NVAR(updateValue); @@ -95152,13 +95810,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { zephir_array_update_zval(&updateValues, fieldName, &updateValue, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, selectBindParams, selectBindTypes); + ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 337, model, intermediate, selectBindParams, selectBindTypes); zephir_check_call_status(); if (!(zephir_fast_count_int(records TSRMLS_CC))) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_11); ZVAL_BOOL(_11, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 336, _11); zephir_check_call_status(); RETURN_MM(); } @@ -95166,7 +95824,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2915); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 3063); return; } } else { @@ -95191,7 +95849,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_11); ZVAL_BOOL(_11, 0); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11, record); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 336, _11, record); zephir_check_call_status(); RETURN_MM(); } @@ -95202,7 +95860,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_11); ZVAL_BOOL(_11, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 336, _11); zephir_check_call_status(); RETURN_MM(); @@ -95221,13 +95879,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { ZEPHIR_OBS_VAR(models); - zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2962 TSRMLS_CC); + zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 3110 TSRMLS_CC); if (zephir_array_isset_long(models, 1)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Delete from several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 2965); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Delete from several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 3113); return; } ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 2968 TSRMLS_CC); + zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 3116 TSRMLS_CC); ZEPHIR_OBS_VAR(model); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&model, _0, modelName, 0 TSRMLS_CC))) { @@ -95235,13 +95893,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { ZEPHIR_CALL_METHOD(&model, _1, "load", NULL, 0, modelName); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, bindParams, bindTypes); + ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 337, model, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (!(zephir_fast_count_int(records TSRMLS_CC))) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_VAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 336, _2); zephir_check_call_status(); RETURN_MM(); } @@ -95249,7 +95907,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2992); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 3140); return; } } else { @@ -95274,7 +95932,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_2); ZVAL_BOOL(_2, 0); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2, record); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 336, _2, record); zephir_check_call_status(); RETURN_MM(); } @@ -95285,7 +95943,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 336, _2); zephir_check_call_status(); RETURN_MM(); @@ -95318,10 +95976,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getRelatedRecords) { zephir_array_fast_append(_0, _1); zephir_array_update_string(&selectIr, SL("columns"), &_0, PH_COPY | PH_SEPARATE); ZEPHIR_OBS_VAR(_4); - zephir_array_fetch_string(&_4, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 3053 TSRMLS_CC); + zephir_array_fetch_string(&_4, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 3201 TSRMLS_CC); zephir_array_update_string(&selectIr, SL("models"), &_4, PH_COPY | PH_SEPARATE); ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, intermediate, SL("tables"), PH_NOISY, "phalcon/mvc/model/query.zep", 3055 TSRMLS_CC); + zephir_array_fetch_string(&_4, intermediate, SL("tables"), PH_NOISY, "phalcon/mvc/model/query.zep", 3203 TSRMLS_CC); zephir_array_update_string(&selectIr, SL("tables"), &_4, PH_COPY | PH_SEPARATE); ZEPHIR_OBS_VAR(whereConditions); if (zephir_array_isset_string_fetch(&whereConditions, intermediate, SS("where"), 0 TSRMLS_CC)) { @@ -95333,18 +95991,18 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getRelatedRecords) { } ZEPHIR_INIT_VAR(query); object_init_ex(query, phalcon_mvc_model_query_ce); - ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345); + ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 338); zephir_check_call_status(); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 346, _5); + ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 339, _5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_2); ZVAL_LONG(_2, 309); - ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 347, _2); + ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 340, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 348, selectIr); + ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 341, selectIr); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 349, bindParams, bindTypes); + ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 342, bindParams, bindTypes); zephir_check_call_status(); RETURN_MM(); @@ -95373,12 +96031,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { zephir_read_property_this(&cacheOptions, this_ptr, SL("_cacheOptions"), PH_NOISY_CC); if (Z_TYPE_P(cacheOptions) != IS_NULL) { if (Z_TYPE_P(cacheOptions) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid caching options", "phalcon/mvc/model/query.zep", 3101); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid caching options", "phalcon/mvc/model/query.zep", 3249); return; } ZEPHIR_OBS_VAR(key); if (!(zephir_array_isset_string_fetch(&key, cacheOptions, SS("key"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A cache key must be provided to identify the cached resultset in the cache backend", "phalcon/mvc/model/query.zep", 3108); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A cache key must be provided to identify the cached resultset in the cache backend", "phalcon/mvc/model/query.zep", 3256); return; } ZEPHIR_OBS_VAR(lifetime); @@ -95395,14 +96053,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { ZEPHIR_CALL_METHOD(&cache, _0, "getshared", NULL, 0, cacheService); zephir_check_call_status(); if (Z_TYPE_P(cache) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache service must be an object", "phalcon/mvc/model/query.zep", 3127); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache service must be an object", "phalcon/mvc/model/query.zep", 3275); return; } ZEPHIR_CALL_METHOD(&result, cache, "get", NULL, 0, key, lifetime); zephir_check_call_status(); if (Z_TYPE_P(result) != IS_NULL) { if (Z_TYPE_P(result) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache didn't return a valid resultset", "phalcon/mvc/model/query.zep", 3134); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache didn't return a valid resultset", "phalcon/mvc/model/query.zep", 3282); return; } ZEPHIR_INIT_VAR(_1); @@ -95450,7 +96108,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { _2 = Z_TYPE_P(mergedParams) != IS_ARRAY; } if (_2) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameters must be an array", "phalcon/mvc/model/query.zep", 3188); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameters must be an array", "phalcon/mvc/model/query.zep", 3336); return; } _3 = Z_TYPE_P(mergedTypes) != IS_NULL; @@ -95458,29 +96116,29 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { _3 = Z_TYPE_P(mergedTypes) != IS_ARRAY; } if (_3) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter types must be an array", "phalcon/mvc/model/query.zep", 3192); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter types must be an array", "phalcon/mvc/model/query.zep", 3340); return; } ZEPHIR_OBS_VAR(type); zephir_read_property_this(&type, this_ptr, SL("_type"), PH_NOISY_CC); do { if (ZEPHIR_IS_LONG(type, 309)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 350, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 343, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 306)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 351, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 344, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 300)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 352, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 345, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 303)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 353, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 346, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } @@ -95490,14 +96148,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { ZEPHIR_CONCAT_SV(_4, "Unknown statement ", type); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 3215 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 3363 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); if (Z_TYPE_P(cacheOptions) != IS_NULL) { if (!ZEPHIR_IS_LONG(type, 309)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only PHQL statements that return resultsets can be cached", "phalcon/mvc/model/query.zep", 3227); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only PHQL statements that return resultsets can be cached", "phalcon/mvc/model/query.zep", 3375); return; } ZEPHIR_CALL_METHOD(NULL, cache, "save", NULL, 0, key, result, lifetime); @@ -95535,7 +96193,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, getSingleResult) { zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 349, bindParams, bindTypes); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 342, bindParams, bindTypes); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(_1, "getfirst", NULL, 0); zephir_check_call_status(); @@ -95707,11 +96365,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, getSql) { _2 = zephir_fetch_nproperty_this(this_ptr, SL("_bindTypes"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_3); ZVAL_BOOL(&_3, 1); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 350, intermediate, _1, _2, &_3); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 343, intermediate, _1, _2, &_3); zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "This type of statement generates multiple SQL statements", "phalcon/mvc/model/query.zep", 3397); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "This type of statement generates multiple SQL statements", "phalcon/mvc/model/query.zep", 3545); return; } @@ -95899,6 +96557,35 @@ static PHP_METHOD(Phalcon_Mvc_Model_Relation, getOptions) { } +static PHP_METHOD(Phalcon_Mvc_Model_Relation, getOption) { + + zval *name_param = NULL, *option, *_0; + zval *name = NULL; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &name_param); + + if (unlikely(Z_TYPE_P(name_param) != IS_STRING && Z_TYPE_P(name_param) != IS_NULL)) { + zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'name' must be a string") TSRMLS_CC); + RETURN_MM_NULL(); + } + + if (likely(Z_TYPE_P(name_param) == IS_STRING)) { + zephir_get_strval(name, name_param); + } else { + ZEPHIR_INIT_VAR(name); + ZVAL_EMPTY_STRING(name); + } + + + _0 = zephir_fetch_nproperty_this(this_ptr, SL("_options"), PH_NOISY_CC); + if (zephir_array_isset_fetch(&option, _0, name, 1 TSRMLS_CC)) { + RETURN_CTOR(option); + } + RETURN_MM_NULL(); + +} + static PHP_METHOD(Phalcon_Mvc_Model_Relation, isForeignKey) { zval *options; @@ -96191,7 +96878,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, next) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_pointer"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, (zephir_get_numberval(_0) + 1)); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_1); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -96231,7 +96918,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, rewind) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 0); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_0); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_0); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -96358,7 +97045,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, offsetGet) { if (ZEPHIR_GT_LONG(_0, index)) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, index); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_1); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_1); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "current", NULL, 0); zephir_check_call_status(); @@ -96428,7 +97115,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, getFirst) { } ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_1); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_1); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "current", NULL, 0); zephir_check_call_status(); @@ -96450,7 +97137,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, getLast) { } ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, (zephir_get_numberval(count) - 1)); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_0); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_0); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "current", NULL, 0); zephir_check_call_status(); @@ -96880,7 +97567,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Row, toArray) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 23, this_ptr); + ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM(); @@ -97068,7 +97755,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction, rollback) { ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_mvc_model_transaction_failed_ce); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackRecord"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 360, rollbackMessage, _5); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 353, rollbackMessage, _5); zephir_check_call_status(); zephir_throw_exception_debug(_0, "phalcon/mvc/model/transaction.zep", 160 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -97087,7 +97774,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction, getConnection) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackOnAbort"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 361); + ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 354); zephir_check_call_status(); if (zephir_is_true(_1)) { ZEPHIR_INIT_VAR(_2); @@ -97657,7 +98344,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Behavior_Timestampable, notify) { ZVAL_NULL(timestamp); ZEPHIR_OBS_VAR(format); if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format); + ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 293, format); zephir_check_call_status(); } else { ZEPHIR_OBS_VAR(generator); @@ -97773,7 +98460,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Apc, read) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_prefix"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); - ZEPHIR_CALL_FUNCTION(&data, "apc_fetch", NULL, 79, _1); + ZEPHIR_CALL_FUNCTION(&data, "apc_fetch", NULL, 81, _1); zephir_check_call_status(); if (Z_TYPE_P(data) == IS_ARRAY) { RETURN_CCTOR(data); @@ -97808,7 +98495,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Apc, write) { ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); _2 = zephir_fetch_nproperty_this(this_ptr, SL("_ttl"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "apc_store", NULL, 80, _1, data, _2); + ZEPHIR_CALL_FUNCTION(NULL, "apc_store", NULL, 82, _1, data, _2); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -98013,9 +98700,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 312, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -98114,7 +98801,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, reset) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 320); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 313); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -98199,9 +98886,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 314, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -98300,7 +98987,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, reset) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 320); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 313); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -98477,9 +99164,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 315, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -98578,7 +99265,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, reset) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_redis_ce, this_ptr, "reset", &_5, 320); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_redis_ce, this_ptr, "reset", &_5, 313); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -98794,7 +99481,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Xcache, read) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_prefix"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); - ZEPHIR_CALL_FUNCTION(&data, "xcache_get", NULL, 81, _1); + ZEPHIR_CALL_FUNCTION(&data, "xcache_get", NULL, 83, _1); zephir_check_call_status(); if (Z_TYPE_P(data) == IS_ARRAY) { RETURN_CCTOR(data); @@ -98829,7 +99516,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Xcache, write) { ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); _2 = zephir_fetch_nproperty_this(this_ptr, SL("_ttl"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, _1, data, _2); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, _1, data, _2); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -99697,14 +100384,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, from) { static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, addFrom) { - zval *model, *alias = NULL, *models = NULL, *currentModel = NULL; + zval *model, *alias = NULL, *with = NULL, *models = NULL, *currentModel = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 1, &model, &alias); + zephir_fetch_params(1, 1, 2, &model, &alias, &with); if (!alias) { alias = ZEPHIR_GLOBAL(global_null); } + if (!with) { + with = ZEPHIR_GLOBAL(global_null); + } ZEPHIR_OBS_VAR(models); @@ -99723,7 +100413,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, addFrom) { if (Z_TYPE_P(alias) == IS_STRING) { zephir_array_update_zval(&models, alias, &model, PH_COPY | PH_SEPARATE); } else { - zephir_array_append(&models, model, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 388); + zephir_array_append(&models, model, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 395); } zephir_update_property_this(this_ptr, SL("_models"), models TSRMLS_CC); RETURN_THIS(); @@ -100194,7 +100884,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, inWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 757); + zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 776); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -100207,7 +100897,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, inWhere) { ZEPHIR_CPY_WRT(key, _0); ZEPHIR_INIT_NVAR(queryKey); ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":"); - zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 748); + zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 767); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); hiddenParam++; } @@ -100266,7 +100956,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, notInWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 800); + zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 819); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -100279,7 +100969,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, notInWhere) { ZEPHIR_CPY_WRT(key, _0); ZEPHIR_INIT_NVAR(queryKey); ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":"); - zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 791); + zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 810); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); hiddenParam++; } @@ -100455,13 +101145,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getGroupBy) { static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { - HashTable *_7, *_10, *_14, *_18, *_21, *_26, *_32; - HashPosition _6, _9, _13, _17, _20, _25, _31; + HashTable *_7, *_10, *_13, *_18, *_23, *_29; + HashPosition _6, _9, _12, _17, _22, _28; zend_class_entry *_3; int ZEPHIR_LAST_CALL_STATUS; - zephir_fcall_cache_entry *_0 = NULL, *_35 = NULL; + zephir_fcall_cache_entry *_0 = NULL, *_32 = NULL; zend_bool noPrimary, _5; - zval *dependencyInjector = NULL, *models, *conditions = NULL, *model = NULL, *metaData = NULL, *modelInstance, *primaryKeys = NULL, *firstPrimaryKey, *columnMap = NULL, *modelAlias = NULL, *attributeField = NULL, *phql = NULL, *column = NULL, *columns, *selectedColumns = NULL, *selectedColumn = NULL, *selectedModel = NULL, *selectedModels, *columnAlias = NULL, *modelColumnAlias = NULL, *joins, *join = NULL, *joinModel = NULL, *joinConditions = NULL, *joinAlias = NULL, *joinType = NULL, *group = NULL, *groupItems = NULL, *groupItem = NULL, *having, *order, *orderItems, *orderItem = NULL, *limit, *number = NULL, *offset = NULL, *forUpdate, *distinct, *withModels, *hiddenParam, *_1 = NULL, *_2 = NULL, *_4 = NULL, **_8, **_11, *_12 = NULL, **_15, *_16 = NULL, **_19, **_22, *_23 = NULL, *_24 = NULL, **_27, *_28 = NULL, _29 = zval_used_for_init, _30, **_33, *_34 = NULL, *_36, *_37; + zval *dependencyInjector = NULL, *models, *conditions = NULL, *model = NULL, *metaData = NULL, *modelInstance, *primaryKeys = NULL, *firstPrimaryKey, *columnMap = NULL, *modelAlias = NULL, *attributeField = NULL, *phql = NULL, *column = NULL, *columns, *selectedColumns = NULL, *selectedColumn = NULL, *selectedModel = NULL, *selectedModels, *columnAlias = NULL, *modelColumnAlias = NULL, *joins, *join = NULL, *joinModel = NULL, *joinConditions = NULL, *joinAlias = NULL, *joinType = NULL, *group = NULL, *groupItems = NULL, *groupItem = NULL, *having, *order, *orderItems, *orderItem = NULL, *limit, *number = NULL, *offset = NULL, *forUpdate, *distinct, *_1 = NULL, *_2 = NULL, *_4 = NULL, **_8, **_11, **_14, *_15 = NULL, *_16 = NULL, **_19, *_20 = NULL, *_21 = NULL, **_24, *_25 = NULL, _26 = zval_used_for_init, _27, **_30, *_31 = NULL, *_33, *_34, *_35, *_36; ZEPHIR_MM_GROW(); @@ -100476,12 +101166,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { zephir_read_property_this(&models, this_ptr, SL("_models"), PH_NOISY_CC); if (Z_TYPE_P(models) == IS_ARRAY) { if (!(zephir_fast_count_int(models TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 981); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 1000); return; } } else { if (!(zephir_is_true(models))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 985); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 1004); return; } } @@ -100490,11 +101180,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (zephir_is_numeric(conditions)) { if (Z_TYPE_P(models) == IS_ARRAY) { if (zephir_fast_count_int(models TSRMLS_CC) > 1) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot build the query. Invalid condition", "phalcon/mvc/model/query/builder.zep", 997); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot build the query. Invalid condition", "phalcon/mvc/model/query/builder.zep", 1017); return; } ZEPHIR_OBS_VAR(model); - zephir_array_fetch_long(&model, models, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 999 TSRMLS_CC); + zephir_array_fetch_long(&model, models, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1019 TSRMLS_CC); } else { ZEPHIR_CPY_WRT(model, models); } @@ -100533,7 +101223,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZEPHIR_CONCAT_SVS(_4, "Column '", firstPrimaryKey, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query/builder.zep", 1027 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query/builder.zep", 1047 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -100547,7 +101237,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { } } if (noPrimary == 1) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Source related to this model does not have a primary key defined", "phalcon/mvc/model/query/builder.zep", 1042); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Source related to this model does not have a primary key defined", "phalcon/mvc/model/query/builder.zep", 1062); return; } } @@ -100574,7 +101264,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(columns) == IS_ARRAY) { ZEPHIR_INIT_VAR(selectedColumns); array_init(selectedColumns); - zephir_is_iterable(columns, &_7, &_6, 0, 0, "phalcon/mvc/model/query/builder.zep", 1074); + zephir_is_iterable(columns, &_7, &_6, 0, 0, "phalcon/mvc/model/query/builder.zep", 1098); for ( ; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS ; zephir_hash_move_forward_ex(_7, &_6) @@ -100582,11 +101272,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZEPHIR_GET_HMKEY(columnAlias, _7, _6); ZEPHIR_GET_HVALUE(column, _8); if (Z_TYPE_P(columnAlias) == IS_LONG) { - zephir_array_append(&selectedColumns, column, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1068); + zephir_array_append(&selectedColumns, column, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1088); } else { - ZEPHIR_INIT_LNVAR(_4); - ZEPHIR_CONCAT_VSV(_4, column, " AS ", columnAlias); - zephir_array_append(&selectedColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1070); + if (zephir_memnstr_str(columnAlias, SL("["), "phalcon/mvc/model/query/builder.zep", 1090)) { + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_VSV(_4, column, " AS ", columnAlias); + zephir_array_append(&selectedColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1091); + } else { + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_VSVS(_4, column, " AS [", columnAlias, "]"); + zephir_array_append(&selectedColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1093); + } } } ZEPHIR_INIT_NVAR(_1); @@ -100599,7 +101295,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(models) == IS_ARRAY) { ZEPHIR_INIT_NVAR(selectedColumns); array_init(selectedColumns); - zephir_is_iterable(models, &_10, &_9, 0, 0, "phalcon/mvc/model/query/builder.zep", 1097); + zephir_is_iterable(models, &_10, &_9, 0, 0, "phalcon/mvc/model/query/builder.zep", 1121); for ( ; zephir_hash_get_current_data_ex(_10, (void**) &_11, &_9) == SUCCESS ; zephir_hash_move_forward_ex(_10, &_9) @@ -100612,136 +101308,115 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { } else { ZEPHIR_CONCAT_SVS(selectedColumn, "[", modelColumnAlias, "].*"); } - zephir_array_append(&selectedColumns, selectedColumn, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1094); + zephir_array_append(&selectedColumns, selectedColumn, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1118); } ZEPHIR_INIT_NVAR(_1); zephir_fast_join_str(_1, SL(", "), selectedColumns TSRMLS_CC); zephir_concat_self(&phql, _1 TSRMLS_CC); } else { - ZEPHIR_INIT_VAR(_12); - ZEPHIR_CONCAT_SVS(_12, "[", models, "].*"); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_SVS(_4, "[", models, "].*"); + zephir_concat_self(&phql, _4 TSRMLS_CC); } } if (Z_TYPE_P(models) == IS_ARRAY) { ZEPHIR_INIT_VAR(selectedModels); array_init(selectedModels); - zephir_is_iterable(models, &_14, &_13, 0, 0, "phalcon/mvc/model/query/builder.zep", 1128); + zephir_is_iterable(models, &_13, &_12, 0, 0, "phalcon/mvc/model/query/builder.zep", 1152); for ( - ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS - ; zephir_hash_move_forward_ex(_14, &_13) + ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS + ; zephir_hash_move_forward_ex(_13, &_12) ) { - ZEPHIR_GET_HMKEY(modelAlias, _14, _13); - ZEPHIR_GET_HVALUE(model, _15); + ZEPHIR_GET_HMKEY(modelAlias, _13, _12); + ZEPHIR_GET_HVALUE(model, _14); if (Z_TYPE_P(modelAlias) == IS_STRING) { ZEPHIR_INIT_NVAR(selectedModel); - if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1112)) { + if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1136)) { ZEPHIR_CONCAT_VSVS(selectedModel, model, " AS [", modelAlias, "]"); } else { ZEPHIR_CONCAT_SVSVS(selectedModel, "[", model, "] AS [", modelAlias, "]"); } } else { - if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1118)) { + if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1142)) { ZEPHIR_CPY_WRT(selectedModel, model); } else { ZEPHIR_INIT_NVAR(selectedModel); ZEPHIR_CONCAT_SVS(selectedModel, "[", model, "]"); } } - zephir_array_append(&selectedModels, selectedModel, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1125); + zephir_array_append(&selectedModels, selectedModel, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1149); } ZEPHIR_INIT_NVAR(_1); zephir_fast_join_str(_1, SL(", "), selectedModels TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " FROM ", _1); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_VAR(_15); + ZEPHIR_CONCAT_SV(_15, " FROM ", _1); + zephir_concat_self(&phql, _15 TSRMLS_CC); } else { - if (zephir_memnstr_str(models, SL("["), "phalcon/mvc/model/query/builder.zep", 1132)) { + if (zephir_memnstr_str(models, SL("["), "phalcon/mvc/model/query/builder.zep", 1156)) { + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SVS(_15, " FROM ", models, ""); + zephir_concat_self(&phql, _15 TSRMLS_CC); + } else { ZEPHIR_INIT_VAR(_16); - ZEPHIR_CONCAT_SVS(_16, " FROM ", models, ""); + ZEPHIR_CONCAT_SVS(_16, " FROM [", models, "]"); zephir_concat_self(&phql, _16 TSRMLS_CC); - } else { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SVS(_12, " FROM [", models, "]"); - zephir_concat_self(&phql, _12 TSRMLS_CC); } } - ZEPHIR_OBS_VAR(withModels); - zephir_read_property_this(&withModels, this_ptr, SL("_with"), PH_NOISY_CC); - if (Z_TYPE_P(withModels) == IS_ARRAY) { - ZEPHIR_INIT_NVAR(selectedColumns); - array_init(selectedColumns); - zephir_is_iterable(withModels, &_18, &_17, 0, 0, "phalcon/mvc/model/query/builder.zep", 1150); - for ( - ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS - ; zephir_hash_move_forward_ex(_18, &_17) - ) { - ZEPHIR_GET_HVALUE(model, _19); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SVS(_12, "[", model, "]"); - zephir_array_append(&selectedColumns, _12, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1147); - } - ZEPHIR_INIT_NVAR(_1); - zephir_fast_join_str(_1, SL(", "), selectedColumns TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " WITH ", _1); - zephir_concat_self(&phql, _12 TSRMLS_CC); - } ZEPHIR_OBS_VAR(joins); zephir_read_property_this(&joins, this_ptr, SL("_joins"), PH_NOISY_CC); if (Z_TYPE_P(joins) == IS_ARRAY) { - zephir_is_iterable(joins, &_21, &_20, 0, 0, "phalcon/mvc/model/query/builder.zep", 1212); + zephir_is_iterable(joins, &_18, &_17, 0, 0, "phalcon/mvc/model/query/builder.zep", 1222); for ( - ; zephir_hash_get_current_data_ex(_21, (void**) &_22, &_20) == SUCCESS - ; zephir_hash_move_forward_ex(_21, &_20) + ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS + ; zephir_hash_move_forward_ex(_18, &_17) ) { - ZEPHIR_GET_HVALUE(join, _22); + ZEPHIR_GET_HVALUE(join, _19); ZEPHIR_OBS_NVAR(joinModel); - zephir_array_fetch_long(&joinModel, join, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1164 TSRMLS_CC); + zephir_array_fetch_long(&joinModel, join, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1174 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinConditions); - zephir_array_fetch_long(&joinConditions, join, 1, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1169 TSRMLS_CC); + zephir_array_fetch_long(&joinConditions, join, 1, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1179 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinAlias); - zephir_array_fetch_long(&joinAlias, join, 2, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1174 TSRMLS_CC); + zephir_array_fetch_long(&joinAlias, join, 2, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1184 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinType); - zephir_array_fetch_long(&joinType, join, 3, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1179 TSRMLS_CC); + zephir_array_fetch_long(&joinType, join, 3, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1189 TSRMLS_CC); if (zephir_is_true(joinType)) { - if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1185)) { + if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1195)) { + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SVSV(_15, " ", joinType, " JOIN ", joinModel); + zephir_concat_self(&phql, _15 TSRMLS_CC); + } else { ZEPHIR_INIT_LNVAR(_16); - ZEPHIR_CONCAT_SVSV(_16, " ", joinType, " JOIN ", joinModel); + ZEPHIR_CONCAT_SVSVS(_16, " ", joinType, " JOIN [", joinModel, "]"); zephir_concat_self(&phql, _16 TSRMLS_CC); - } else { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVSVS(_23, " ", joinType, " JOIN [", joinModel, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); } } else { - if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1191)) { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " JOIN ", joinModel, ""); - zephir_concat_self(&phql, _23 TSRMLS_CC); + if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1201)) { + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " JOIN ", joinModel, ""); + zephir_concat_self(&phql, _20 TSRMLS_CC); } else { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " JOIN [", joinModel, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " JOIN [", joinModel, "]"); + zephir_concat_self(&phql, _20 TSRMLS_CC); } } if (zephir_is_true(joinAlias)) { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " AS [", joinAlias, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " AS [", joinAlias, "]"); + zephir_concat_self(&phql, _20 TSRMLS_CC); } if (zephir_is_true(joinConditions)) { - ZEPHIR_INIT_LNVAR(_24); - ZEPHIR_CONCAT_SV(_24, " ON ", joinConditions); - zephir_concat_self(&phql, _24 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_21); + ZEPHIR_CONCAT_SV(_21, " ON ", joinConditions); + zephir_concat_self(&phql, _21 TSRMLS_CC); } } } if (Z_TYPE_P(conditions) == IS_STRING) { if (!(ZEPHIR_IS_EMPTY(conditions))) { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " WHERE ", conditions); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SV(_15, " WHERE ", conditions); + zephir_concat_self(&phql, _15 TSRMLS_CC); } } ZEPHIR_OBS_VAR(group); @@ -100750,21 +101425,21 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(group) == IS_ARRAY) { ZEPHIR_INIT_VAR(groupItems); array_init(groupItems); - zephir_is_iterable(group, &_26, &_25, 0, 0, "phalcon/mvc/model/query/builder.zep", 1239); + zephir_is_iterable(group, &_23, &_22, 0, 0, "phalcon/mvc/model/query/builder.zep", 1249); for ( - ; zephir_hash_get_current_data_ex(_26, (void**) &_27, &_25) == SUCCESS - ; zephir_hash_move_forward_ex(_26, &_25) + ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS + ; zephir_hash_move_forward_ex(_23, &_22) ) { - ZEPHIR_GET_HVALUE(groupItem, _27); + ZEPHIR_GET_HVALUE(groupItem, _24); if (zephir_is_numeric(groupItem)) { - zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1230); + zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1240); } else { - if (zephir_memnstr_str(groupItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1232)) { - zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1233); + if (zephir_memnstr_str(groupItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1242)) { + zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1243); } else { ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, "[", groupItem, "]"); - zephir_array_append(&groupItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1235); + zephir_array_append(&groupItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1245); } } } @@ -100775,30 +101450,30 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { zephir_concat_self(&phql, _4 TSRMLS_CC); } else { if (zephir_is_numeric(group)) { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " GROUP BY ", group); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SV(_15, " GROUP BY ", group); + zephir_concat_self(&phql, _15 TSRMLS_CC); } else { - if (zephir_memnstr_str(group, SL("."), "phalcon/mvc/model/query/builder.zep", 1244)) { + if (zephir_memnstr_str(group, SL("."), "phalcon/mvc/model/query/builder.zep", 1254)) { ZEPHIR_INIT_LNVAR(_16); ZEPHIR_CONCAT_SV(_16, " GROUP BY ", group); zephir_concat_self(&phql, _16 TSRMLS_CC); } else { - if (zephir_memnstr_str(group, SL(","), "phalcon/mvc/model/query/builder.zep", 1247)) { - ZEPHIR_INIT_VAR(_28); - ZEPHIR_SINIT_VAR(_29); - ZVAL_STRING(&_29, " ", 0); - ZEPHIR_SINIT_VAR(_30); - ZVAL_STRING(&_30, "", 0); - zephir_fast_str_replace(&_28, &_29, &_30, group TSRMLS_CC); - ZEPHIR_CPY_WRT(group, _28); + if (zephir_memnstr_str(group, SL(","), "phalcon/mvc/model/query/builder.zep", 1257)) { + ZEPHIR_INIT_VAR(_25); + ZEPHIR_SINIT_VAR(_26); + ZVAL_STRING(&_26, " ", 0); + ZEPHIR_SINIT_VAR(_27); + ZVAL_STRING(&_27, "", 0); + zephir_fast_str_replace(&_25, &_26, &_27, group TSRMLS_CC); + ZEPHIR_CPY_WRT(group, _25); ZEPHIR_INIT_NVAR(groupItems); zephir_fast_explode_str(groupItems, SL(","), group, LONG_MAX TSRMLS_CC); - ZEPHIR_INIT_NVAR(_28); - zephir_fast_join_str(_28, SL("], ["), groupItems TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " GROUP BY [", _28, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_25); + zephir_fast_join_str(_25, SL("], ["), groupItems TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " GROUP BY [", _25, "]"); + zephir_concat_self(&phql, _20 TSRMLS_CC); } else { ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, " GROUP BY [", group, "]"); @@ -100823,21 +101498,21 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(order) == IS_ARRAY) { ZEPHIR_INIT_VAR(orderItems); array_init(orderItems); - zephir_is_iterable(order, &_32, &_31, 0, 0, "phalcon/mvc/model/query/builder.zep", 1284); + zephir_is_iterable(order, &_29, &_28, 0, 0, "phalcon/mvc/model/query/builder.zep", 1294); for ( - ; zephir_hash_get_current_data_ex(_32, (void**) &_33, &_31) == SUCCESS - ; zephir_hash_move_forward_ex(_32, &_31) + ; zephir_hash_get_current_data_ex(_29, (void**) &_30, &_28) == SUCCESS + ; zephir_hash_move_forward_ex(_29, &_28) ) { - ZEPHIR_GET_HVALUE(orderItem, _33); + ZEPHIR_GET_HVALUE(orderItem, _30); if (zephir_is_numeric(orderItem)) { - zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1275); + zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1285); } else { - if (zephir_memnstr_str(orderItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1277)) { - zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1278); + if (zephir_memnstr_str(orderItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1287)) { + zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1288); } else { ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, "[", orderItem, "]"); - zephir_array_append(&orderItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1280); + zephir_array_append(&orderItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1290); } } } @@ -100847,9 +101522,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZEPHIR_CONCAT_SV(_4, " ORDER BY ", _1); zephir_concat_self(&phql, _4 TSRMLS_CC); } else { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " ORDER BY ", order); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SV(_15, " ORDER BY ", order); + zephir_concat_self(&phql, _15 TSRMLS_CC); } } ZEPHIR_OBS_VAR(limit); @@ -100859,7 +101534,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZVAL_NULL(number); if (Z_TYPE_P(limit) == IS_ARRAY) { ZEPHIR_OBS_NVAR(number); - zephir_array_fetch_string(&number, limit, SL("number"), PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1299 TSRMLS_CC); + zephir_array_fetch_string(&number, limit, SL("number"), PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1309 TSRMLS_CC); ZEPHIR_OBS_VAR(offset); if (zephir_array_isset_string_fetch(&offset, limit, SS("offset"), 0 TSRMLS_CC)) { if (!(zephir_is_numeric(offset))) { @@ -100881,45 +101556,34 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { } } if (zephir_is_numeric(number)) { - ZEPHIR_OBS_VAR(hiddenParam); - zephir_read_property_this(&hiddenParam, this_ptr, SL("_hiddenParamNumber"), PH_NOISY_CC); - ZEPHIR_INIT_LNVAR(_4); - ZEPHIR_CONCAT_SVS(_4, " LIMIT :AP", hiddenParam, ":"); - zephir_concat_self(&phql, _4 TSRMLS_CC); - ZEPHIR_SINIT_NVAR(_29); - ZVAL_LONG(&_29, 10); - ZEPHIR_CALL_FUNCTION(&_34, "intval", &_35, 25, number, &_29); + zephir_concat_self_str(&phql, SL(" LIMIT :APL0:") TSRMLS_CC); + ZEPHIR_SINIT_NVAR(_26); + ZVAL_LONG(&_26, 10); + ZEPHIR_CALL_FUNCTION(&_31, "intval", &_32, 26, number, &_26); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, "AP", hiddenParam); - zephir_update_property_array(this_ptr, SL("_bindParams"), _12, _34 TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_16); - ZEPHIR_CONCAT_SV(_16, "AP", hiddenParam); ZEPHIR_INIT_NVAR(_1); - ZVAL_LONG(_1, 1); - zephir_update_property_array(this_ptr, SL("_bindTypes"), _16, _1 TSRMLS_CC); + ZVAL_STRING(_1, "APL0", 1); + zephir_update_property_array(this_ptr, SL("_bindParams"), _1, _31 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_25); + ZVAL_STRING(_25, "APL0", 1); + ZEPHIR_INIT_VAR(_33); + ZVAL_LONG(_33, 1); + zephir_update_property_array(this_ptr, SL("_bindTypes"), _25, _33 TSRMLS_CC); if (zephir_is_numeric(offset)) { - ZEPHIR_SEPARATE(hiddenParam); - zephir_increment(hiddenParam); - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " OFFSET :AP", hiddenParam, ":"); - zephir_concat_self(&phql, _23 TSRMLS_CC); - ZEPHIR_SINIT_NVAR(_29); - ZVAL_LONG(&_29, 10); - ZEPHIR_CALL_FUNCTION(&_34, "intval", &_35, 25, offset, &_29); + zephir_concat_self_str(&phql, SL(" OFFSET :APL1:") TSRMLS_CC); + ZEPHIR_SINIT_NVAR(_26); + ZVAL_LONG(&_26, 10); + ZEPHIR_CALL_FUNCTION(&_31, "intval", &_32, 26, offset, &_26); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_24); - ZEPHIR_CONCAT_SV(_24, "AP", hiddenParam); - zephir_update_property_array(this_ptr, SL("_bindParams"), _24, _34 TSRMLS_CC); + ZEPHIR_INIT_VAR(_34); + ZVAL_STRING(_34, "APL1", 1); + zephir_update_property_array(this_ptr, SL("_bindParams"), _34, _31 TSRMLS_CC); + ZEPHIR_INIT_VAR(_35); + ZVAL_STRING(_35, "APL1", 1); ZEPHIR_INIT_VAR(_36); - ZEPHIR_CONCAT_SV(_36, "AP", hiddenParam); - ZEPHIR_INIT_NVAR(_28); - ZVAL_LONG(_28, 1); - zephir_update_property_array(this_ptr, SL("_bindTypes"), _36, _28 TSRMLS_CC); + ZVAL_LONG(_36, 1); + zephir_update_property_array(this_ptr, SL("_bindTypes"), _35, _36 TSRMLS_CC); } - ZEPHIR_INIT_ZVAL_NREF(_37); - ZVAL_LONG(_37, (zephir_get_numberval(hiddenParam) + 1)); - zephir_update_property_this(this_ptr, SL("_hiddenParamNumber"), _37 TSRMLS_CC); } } forUpdate = zephir_fetch_nproperty_this(this_ptr, SL("_forUpdate"), PH_NOISY_CC); @@ -100941,21 +101605,21 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getQuery) { ZEPHIR_INIT_VAR(query); object_init_ex(query, phalcon_mvc_model_query_ce); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 354); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 347); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345, _0, _1); + ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 338, _0, _1); zephir_check_call_status(); ZEPHIR_OBS_VAR(bindParams); zephir_read_property_this(&bindParams, this_ptr, SL("_bindParams"), PH_NOISY_CC); if (Z_TYPE_P(bindParams) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 355, bindParams); + ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 348, bindParams); zephir_check_call_status(); } ZEPHIR_OBS_VAR(bindTypes); zephir_read_property_this(&bindTypes, this_ptr, SL("_bindTypes"), PH_NOISY_CC); if (Z_TYPE_P(bindTypes) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 356, bindTypes); + ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 349, bindTypes); zephir_check_call_status(); } RETURN_CCTOR(query); @@ -101210,7 +101874,7 @@ static zval *phql_ret_select_statement(zval *S, zval *W, zval *O, zval *G, zval return ret; } -static zval *phql_ret_select_clause(zval *distinct, zval *columns, zval *tables, zval *with_list, zval *join_list) +static zval *phql_ret_select_clause(zval *distinct, zval *columns, zval *tables, zval *join_list) { zval *ret; @@ -101224,10 +101888,6 @@ static zval *phql_ret_select_clause(zval *distinct, zval *columns, zval *tables, add_assoc_zval(ret, "columns", columns); add_assoc_zval(ret, "tables", tables); - if (with_list) { - add_assoc_zval(ret, "with", with_list); - } - if (join_list) { add_assoc_zval(ret, "joins", join_list); } @@ -101446,7 +102106,7 @@ static zval *phql_ret_column_item(int type, zval *column, phql_parser_token *ide return ret; } -static zval *phql_ret_assoc_name(zval *qualified_name, phql_parser_token *alias) +static zval *phql_ret_assoc_name(zval *qualified_name, phql_parser_token *alias, zval *with) { zval *ret; @@ -101454,11 +102114,16 @@ static zval *phql_ret_assoc_name(zval *qualified_name, phql_parser_token *alias) MAKE_STD_ZVAL(ret); array_init(ret); add_assoc_zval(ret, "qualifiedName", qualified_name); + if (alias) { add_assoc_stringl(ret, "alias", alias->token, alias->token_len, 0); efree(alias); } + if (with) { + add_assoc_zval(ret, "with", with); + } + return ret; } @@ -101536,7 +102201,7 @@ static zval *phql_ret_func_call(phql_parser_token *name, zval *arguments, zval * } -// 459 "parser.c" +// 460 "parser.c" /* Next is all token values, in a form suitable for use by makeheaders. ** This section will be null unless lemon is run with the -m switch. */ @@ -101579,23 +102244,23 @@ static zval *phql_ret_func_call(phql_parser_token *name, zval *arguments, zval * ** defined, then do no error processing. */ #define PPCODETYPE unsigned char -#define PPNOCODE 135 +#define PPNOCODE 134 #define PPACTIONTYPE unsigned short int #define phql_TOKENTYPE phql_parser_token* typedef union { phql_TOKENTYPE pp0; - zval* pp244; - int pp269; + zval* pp162; + int pp267; } PPMINORTYPE; #define PPSTACKDEPTH 100 #define phql_ARG_SDECL phql_parser_status *status; #define phql_ARG_PDECL ,phql_parser_status *status #define phql_ARG_FETCH phql_parser_status *status = pppParser->status #define phql_ARG_STORE pppParser->status = status -#define PPNSTATE 280 -#define PPNRULE 157 +#define PPNSTATE 293 +#define PPNRULE 161 #define PPERRORSYMBOL 79 -#define PPERRSYMDT pp269 +#define PPERRSYMDT pp267 #define PP_NO_ACTION (PPNSTATE+PPNRULE+2) #define PP_ACCEPT_ACTION (PPNSTATE+PPNRULE+1) #define PP_ERROR_ACTION (PPNSTATE+PPNRULE) @@ -101648,254 +102313,266 @@ typedef union { ** pp_default[] Default action for each state. */ static PPACTIONTYPE pp_action[] = { - /* 0 */ 92, 98, 55, 57, 59, 61, 63, 65, 45, 47, + /* 0 */ 120, 126, 55, 57, 59, 61, 63, 65, 45, 47, /* 10 */ 67, 72, 49, 51, 53, 41, 39, 43, 37, 34, - /* 20 */ 94, 74, 69, 92, 98, 55, 57, 59, 61, 63, + /* 20 */ 122, 74, 69, 120, 126, 55, 57, 59, 61, 63, /* 30 */ 65, 45, 47, 67, 72, 49, 51, 53, 41, 39, - /* 40 */ 43, 37, 34, 94, 74, 69, 19, 20, 21, 22, - /* 50 */ 23, 106, 32, 33, 92, 98, 55, 57, 59, 61, - /* 60 */ 63, 65, 45, 47, 67, 72, 49, 51, 53, 41, - /* 70 */ 39, 43, 37, 34, 94, 74, 69, 94, 74, 69, - /* 80 */ 82, 70, 215, 207, 83, 205, 185, 85, 165, 86, - /* 90 */ 163, 193, 217, 126, 196, 160, 234, 92, 98, 55, + /* 40 */ 43, 37, 34, 122, 74, 69, 37, 34, 122, 74, + /* 50 */ 69, 166, 220, 92, 218, 45, 47, 67, 72, 49, + /* 60 */ 51, 53, 41, 39, 43, 37, 34, 122, 74, 69, + /* 70 */ 154, 429, 186, 91, 120, 126, 55, 57, 59, 61, + /* 80 */ 63, 65, 45, 47, 67, 72, 49, 51, 53, 41, + /* 90 */ 39, 43, 37, 34, 122, 74, 69, 120, 126, 55, /* 100 */ 57, 59, 61, 63, 65, 45, 47, 67, 72, 49, - /* 110 */ 51, 53, 41, 39, 43, 37, 34, 94, 74, 69, - /* 120 */ 92, 98, 55, 57, 59, 61, 63, 65, 45, 47, - /* 130 */ 67, 72, 49, 51, 53, 41, 39, 43, 37, 34, - /* 140 */ 94, 74, 69, 92, 98, 55, 57, 59, 61, 63, + /* 110 */ 51, 53, 41, 39, 43, 37, 34, 122, 74, 69, + /* 120 */ 19, 20, 21, 22, 23, 227, 32, 33, 67, 72, + /* 130 */ 49, 51, 53, 41, 39, 43, 37, 34, 122, 74, + /* 140 */ 69, 130, 238, 120, 126, 55, 57, 59, 61, 63, /* 150 */ 65, 45, 47, 67, 72, 49, 51, 53, 41, 39, - /* 160 */ 43, 37, 34, 94, 74, 69, 239, 247, 128, 45, - /* 170 */ 47, 67, 72, 49, 51, 53, 41, 39, 43, 37, - /* 180 */ 34, 94, 74, 69, 266, 273, 269, 118, 102, 92, - /* 190 */ 98, 55, 57, 59, 61, 63, 65, 45, 47, 67, - /* 200 */ 72, 49, 51, 53, 41, 39, 43, 37, 34, 94, - /* 210 */ 74, 69, 438, 1, 2, 3, 4, 5, 6, 198, - /* 220 */ 112, 79, 92, 98, 55, 57, 59, 61, 63, 65, + /* 160 */ 43, 37, 34, 122, 74, 69, 41, 39, 43, 37, + /* 170 */ 34, 122, 74, 69, 140, 8, 120, 126, 55, 57, + /* 180 */ 59, 61, 63, 65, 45, 47, 67, 72, 49, 51, + /* 190 */ 53, 41, 39, 43, 37, 34, 122, 74, 69, 120, + /* 200 */ 126, 55, 57, 59, 61, 63, 65, 45, 47, 67, + /* 210 */ 72, 49, 51, 53, 41, 39, 43, 37, 34, 122, + /* 220 */ 74, 69, 120, 126, 55, 57, 59, 61, 63, 65, /* 230 */ 45, 47, 67, 72, 49, 51, 53, 41, 39, 43, - /* 240 */ 37, 34, 94, 74, 69, 140, 107, 258, 35, 96, - /* 250 */ 6, 141, 143, 274, 124, 126, 248, 160, 131, 257, - /* 260 */ 67, 72, 49, 51, 53, 41, 39, 43, 37, 34, - /* 270 */ 94, 74, 69, 100, 413, 49, 51, 53, 41, 39, - /* 280 */ 43, 37, 34, 94, 74, 69, 268, 269, 146, 147, - /* 290 */ 153, 154, 155, 105, 109, 115, 367, 121, 84, 85, - /* 300 */ 95, 86, 150, 148, 149, 151, 152, 55, 57, 59, - /* 310 */ 61, 63, 65, 45, 47, 67, 72, 49, 51, 53, - /* 320 */ 41, 39, 43, 37, 34, 94, 74, 69, 140, 7, - /* 330 */ 254, 35, 134, 183, 141, 143, 181, 76, 191, 245, - /* 340 */ 189, 131, 41, 39, 43, 37, 34, 94, 74, 69, - /* 350 */ 252, 249, 145, 246, 261, 140, 100, 238, 35, 145, - /* 360 */ 137, 141, 143, 130, 179, 135, 156, 177, 131, 166, - /* 370 */ 130, 146, 147, 153, 154, 155, 105, 109, 115, 280, - /* 380 */ 121, 87, 186, 100, 281, 150, 148, 149, 151, 152, - /* 390 */ 192, 213, 221, 166, 282, 6, 6, 243, 146, 147, - /* 400 */ 153, 154, 155, 105, 109, 115, 138, 121, 134, 134, - /* 410 */ 123, 162, 150, 148, 149, 151, 152, 200, 242, 158, - /* 420 */ 35, 78, 283, 141, 143, 208, 204, 212, 145, 145, - /* 430 */ 201, 175, 284, 132, 173, 76, 211, 219, 227, 130, - /* 440 */ 130, 203, 156, 156, 8, 100, 145, 168, 184, 170, - /* 450 */ 172, 236, 176, 180, 159, 17, 263, 130, 277, 245, - /* 460 */ 146, 147, 153, 154, 155, 105, 109, 115, 232, 121, - /* 470 */ 241, 225, 202, 246, 150, 148, 149, 151, 152, 145, - /* 480 */ 9, 35, 209, 210, 141, 143, 132, 76, 145, 24, - /* 490 */ 130, 131, 103, 229, 233, 243, 6, 26, 138, 130, - /* 500 */ 134, 37, 34, 94, 74, 69, 100, 10, 35, 101, - /* 510 */ 15, 141, 143, 13, 11, 14, 253, 12, 131, 220, - /* 520 */ 145, 146, 147, 153, 154, 155, 105, 109, 115, 145, - /* 530 */ 121, 130, 16, 100, 139, 150, 148, 149, 151, 152, - /* 540 */ 130, 27, 18, 29, 25, 69, 77, 31, 146, 147, - /* 550 */ 153, 154, 155, 105, 109, 115, 75, 121, 81, 232, - /* 560 */ 167, 138, 150, 148, 149, 151, 152, 145, 31, 80, - /* 570 */ 28, 224, 88, 90, 197, 199, 204, 272, 130, 145, - /* 580 */ 89, 188, 412, 97, 38, 231, 104, 76, 145, 108, - /* 590 */ 130, 245, 30, 166, 40, 110, 145, 145, 271, 130, - /* 600 */ 42, 36, 113, 44, 145, 244, 216, 130, 130, 223, - /* 610 */ 114, 145, 119, 125, 145, 130, 157, 133, 46, 116, - /* 620 */ 145, 145, 130, 145, 226, 130, 145, 48, 50, 145, - /* 630 */ 235, 130, 130, 52, 130, 120, 54, 130, 145, 158, - /* 640 */ 130, 159, 136, 164, 145, 169, 313, 145, 145, 130, - /* 650 */ 145, 56, 58, 145, 60, 130, 145, 62, 130, 130, - /* 660 */ 171, 130, 314, 174, 130, 315, 111, 130, 187, 64, - /* 670 */ 66, 145, 145, 316, 145, 188, 117, 145, 68, 91, - /* 680 */ 178, 317, 130, 130, 71, 130, 145, 166, 130, 145, - /* 690 */ 145, 122, 73, 93, 161, 318, 145, 130, 145, 145, - /* 700 */ 130, 130, 182, 319, 145, 320, 321, 130, 99, 130, - /* 710 */ 130, 145, 145, 145, 145, 130, 190, 195, 206, 279, - /* 720 */ 144, 127, 130, 130, 130, 130, 188, 264, 145, 142, - /* 730 */ 129, 194, 228, 230, 188, 214, 218, 237, 166, 130, - /* 740 */ 145, 145, 222, 240, 324, 256, 166, 250, 325, 145, - /* 750 */ 145, 130, 130, 255, 251, 259, 260, 332, 366, 262, - /* 760 */ 130, 130, 265, 267, 270, 275, 276, 338, 278, + /* 240 */ 37, 34, 122, 74, 69, 168, 109, 156, 35, 95, + /* 250 */ 99, 169, 171, 26, 76, 151, 188, 81, 159, 160, + /* 260 */ 82, 111, 209, 113, 114, 17, 146, 285, 192, 208, + /* 270 */ 194, 196, 128, 200, 204, 222, 223, 455, 1, 2, + /* 280 */ 3, 4, 5, 6, 199, 173, 284, 197, 174, 175, + /* 290 */ 181, 182, 183, 133, 137, 143, 76, 149, 158, 24, + /* 300 */ 212, 217, 178, 176, 177, 179, 180, 168, 135, 271, + /* 310 */ 35, 249, 6, 169, 171, 287, 276, 110, 290, 173, + /* 320 */ 159, 49, 51, 53, 41, 39, 43, 37, 34, 122, + /* 330 */ 74, 69, 158, 384, 128, 430, 192, 208, 194, 196, + /* 340 */ 80, 200, 204, 292, 210, 122, 74, 69, 84, 84, + /* 350 */ 174, 175, 181, 182, 183, 133, 137, 143, 125, 149, + /* 360 */ 107, 107, 95, 90, 178, 176, 177, 179, 180, 55, + /* 370 */ 57, 59, 61, 63, 65, 45, 47, 67, 72, 49, + /* 380 */ 51, 53, 41, 39, 43, 37, 34, 122, 74, 69, + /* 390 */ 213, 274, 258, 35, 70, 228, 169, 171, 131, 109, + /* 400 */ 245, 265, 6, 214, 259, 230, 279, 286, 282, 234, + /* 410 */ 173, 83, 203, 6, 129, 201, 84, 128, 173, 152, + /* 420 */ 154, 207, 186, 158, 205, 162, 244, 96, 107, 85, + /* 430 */ 219, 158, 173, 174, 175, 181, 182, 183, 133, 137, + /* 440 */ 143, 94, 149, 173, 7, 158, 102, 178, 176, 177, + /* 450 */ 179, 180, 162, 232, 35, 89, 158, 169, 171, 184, + /* 460 */ 76, 112, 113, 114, 159, 211, 215, 79, 94, 78, + /* 470 */ 173, 226, 221, 217, 94, 6, 277, 240, 128, 160, + /* 480 */ 165, 84, 98, 158, 250, 163, 184, 162, 103, 95, + /* 490 */ 104, 173, 94, 107, 174, 175, 181, 182, 183, 133, + /* 500 */ 137, 143, 92, 149, 158, 173, 108, 155, 178, 176, + /* 510 */ 177, 179, 180, 168, 92, 224, 35, 258, 158, 169, + /* 520 */ 171, 184, 100, 27, 258, 173, 159, 166, 216, 257, + /* 530 */ 191, 115, 189, 254, 105, 173, 259, 124, 158, 69, + /* 540 */ 128, 110, 173, 107, 166, 281, 282, 225, 158, 252, + /* 550 */ 260, 31, 253, 10, 251, 158, 174, 175, 181, 182, + /* 560 */ 183, 133, 137, 143, 233, 149, 107, 106, 42, 173, + /* 570 */ 178, 176, 177, 179, 180, 30, 247, 35, 329, 245, + /* 580 */ 169, 171, 158, 147, 31, 229, 173, 159, 123, 328, + /* 590 */ 261, 332, 256, 270, 101, 327, 162, 173, 326, 158, + /* 600 */ 325, 128, 173, 173, 242, 246, 206, 28, 237, 18, + /* 610 */ 158, 50, 255, 202, 173, 158, 158, 174, 175, 181, + /* 620 */ 182, 183, 133, 137, 143, 121, 149, 158, 239, 173, + /* 630 */ 167, 178, 176, 177, 179, 180, 97, 269, 164, 119, + /* 640 */ 148, 263, 158, 173, 324, 264, 173, 71, 15, 132, + /* 650 */ 150, 267, 323, 161, 145, 256, 158, 173, 73, 158, + /* 660 */ 134, 170, 172, 198, 62, 173, 322, 333, 173, 60, + /* 670 */ 158, 262, 173, 66, 93, 266, 173, 195, 158, 173, + /* 680 */ 173, 158, 173, 187, 139, 158, 136, 173, 268, 158, + /* 690 */ 11, 173, 158, 158, 76, 158, 295, 185, 58, 340, + /* 700 */ 158, 173, 173, 56, 158, 272, 236, 36, 321, 54, + /* 710 */ 38, 383, 293, 157, 158, 158, 173, 127, 40, 273, + /* 720 */ 193, 173, 275, 278, 173, 173, 280, 173, 173, 158, + /* 730 */ 190, 173, 68, 52, 158, 173, 173, 158, 158, 138, + /* 740 */ 158, 158, 48, 283, 158, 13, 25, 88, 158, 158, + /* 750 */ 173, 173, 16, 248, 87, 86, 44, 46, 64, 297, + /* 760 */ 173, 294, 141, 158, 158, 296, 142, 288, 153, 289, + /* 770 */ 346, 173, 291, 158, 173, 173, 173, 12, 29, 75, + /* 780 */ 77, 144, 9, 235, 158, 117, 241, 158, 158, 158, + /* 790 */ 118, 231, 243, 296, 116, 14, }; static PPCODETYPE pp_lookahead[] = { /* 0 */ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, /* 10 */ 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, /* 20 */ 21, 22, 23, 1, 2, 3, 4, 5, 6, 7, /* 30 */ 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, - /* 40 */ 18, 19, 20, 21, 22, 23, 60, 61, 62, 63, - /* 50 */ 64, 45, 53, 54, 1, 2, 3, 4, 5, 6, - /* 60 */ 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, - /* 70 */ 17, 18, 19, 20, 21, 22, 23, 21, 22, 23, - /* 80 */ 97, 11, 12, 30, 101, 32, 103, 104, 30, 106, - /* 90 */ 32, 102, 22, 71, 105, 73, 50, 1, 2, 3, + /* 40 */ 18, 19, 20, 21, 22, 23, 19, 20, 21, 22, + /* 50 */ 23, 25, 30, 25, 32, 9, 10, 11, 12, 13, + /* 60 */ 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, + /* 70 */ 71, 45, 73, 45, 1, 2, 3, 4, 5, 6, + /* 80 */ 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, + /* 90 */ 17, 18, 19, 20, 21, 22, 23, 1, 2, 3, /* 100 */ 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, /* 110 */ 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, - /* 120 */ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, - /* 130 */ 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, - /* 140 */ 21, 22, 23, 1, 2, 3, 4, 5, 6, 7, + /* 120 */ 60, 61, 62, 63, 64, 45, 53, 54, 11, 12, + /* 130 */ 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, + /* 140 */ 23, 45, 56, 1, 2, 3, 4, 5, 6, 7, /* 150 */ 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, - /* 160 */ 18, 19, 20, 21, 22, 23, 44, 45, 72, 9, - /* 170 */ 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, - /* 180 */ 20, 21, 22, 23, 117, 118, 119, 68, 46, 1, - /* 190 */ 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, - /* 200 */ 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, - /* 210 */ 22, 23, 80, 81, 82, 83, 84, 85, 86, 25, - /* 220 */ 32, 27, 1, 2, 3, 4, 5, 6, 7, 8, + /* 160 */ 18, 19, 20, 21, 22, 23, 16, 17, 18, 19, + /* 170 */ 20, 21, 22, 23, 32, 88, 1, 2, 3, 4, + /* 180 */ 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, + /* 190 */ 15, 16, 17, 18, 19, 20, 21, 22, 23, 1, + /* 200 */ 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, + /* 210 */ 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, + /* 220 */ 22, 23, 1, 2, 3, 4, 5, 6, 7, 8, /* 230 */ 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, - /* 240 */ 19, 20, 21, 22, 23, 17, 82, 115, 20, 23, - /* 250 */ 86, 23, 24, 121, 70, 71, 111, 73, 30, 114, - /* 260 */ 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, - /* 270 */ 21, 22, 23, 45, 46, 13, 14, 15, 16, 17, - /* 280 */ 18, 19, 20, 21, 22, 23, 118, 119, 60, 61, - /* 290 */ 62, 63, 64, 65, 66, 67, 0, 69, 103, 104, - /* 300 */ 74, 106, 74, 75, 76, 77, 78, 3, 4, 5, - /* 310 */ 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, - /* 320 */ 16, 17, 18, 19, 20, 21, 22, 23, 17, 87, - /* 330 */ 25, 20, 99, 35, 23, 24, 38, 26, 30, 99, - /* 340 */ 32, 30, 16, 17, 18, 19, 20, 21, 22, 23, - /* 350 */ 110, 46, 119, 113, 58, 17, 45, 107, 20, 119, - /* 360 */ 127, 23, 24, 130, 35, 132, 133, 38, 30, 119, - /* 370 */ 130, 60, 61, 62, 63, 64, 65, 66, 67, 0, - /* 380 */ 69, 107, 25, 45, 0, 74, 75, 76, 77, 78, - /* 390 */ 33, 82, 82, 119, 0, 86, 86, 25, 60, 61, - /* 400 */ 62, 63, 64, 65, 66, 67, 25, 69, 99, 99, - /* 410 */ 128, 129, 74, 75, 76, 77, 78, 17, 46, 31, - /* 420 */ 20, 94, 0, 23, 24, 98, 99, 46, 119, 119, - /* 430 */ 30, 35, 0, 45, 38, 26, 127, 127, 55, 130, - /* 440 */ 130, 17, 133, 133, 88, 45, 119, 34, 35, 36, - /* 450 */ 37, 42, 39, 40, 30, 25, 47, 130, 49, 99, - /* 460 */ 60, 61, 62, 63, 64, 65, 66, 67, 99, 69, - /* 470 */ 110, 56, 31, 113, 74, 75, 76, 77, 78, 119, - /* 480 */ 89, 20, 28, 29, 23, 24, 45, 26, 119, 59, - /* 490 */ 130, 30, 82, 124, 125, 25, 86, 51, 25, 130, - /* 500 */ 99, 19, 20, 21, 22, 23, 45, 90, 20, 99, - /* 510 */ 58, 23, 24, 57, 91, 47, 46, 92, 30, 46, - /* 520 */ 119, 60, 61, 62, 63, 64, 65, 66, 67, 119, - /* 530 */ 69, 130, 126, 45, 133, 74, 75, 76, 77, 78, - /* 540 */ 130, 52, 126, 25, 126, 23, 93, 99, 60, 61, - /* 550 */ 62, 63, 64, 65, 66, 67, 45, 69, 96, 99, - /* 560 */ 30, 25, 74, 75, 76, 77, 78, 119, 99, 95, - /* 570 */ 122, 123, 108, 41, 100, 98, 99, 99, 130, 119, - /* 580 */ 109, 107, 46, 74, 99, 125, 46, 26, 119, 46, - /* 590 */ 130, 99, 123, 119, 99, 45, 119, 119, 120, 130, - /* 600 */ 99, 99, 30, 99, 119, 113, 99, 130, 130, 99, - /* 610 */ 46, 119, 30, 129, 119, 130, 28, 131, 99, 45, - /* 620 */ 119, 119, 130, 119, 99, 130, 119, 99, 99, 119, - /* 630 */ 99, 130, 130, 99, 130, 46, 99, 130, 119, 31, - /* 640 */ 130, 30, 46, 30, 119, 35, 30, 119, 119, 130, - /* 650 */ 119, 99, 99, 119, 99, 130, 119, 99, 130, 130, - /* 660 */ 35, 130, 30, 35, 130, 30, 99, 130, 100, 99, - /* 670 */ 99, 119, 119, 30, 119, 107, 99, 119, 99, 99, - /* 680 */ 35, 30, 130, 130, 99, 130, 119, 119, 130, 119, - /* 690 */ 119, 99, 99, 99, 99, 30, 119, 130, 119, 119, - /* 700 */ 130, 130, 35, 30, 119, 30, 30, 130, 99, 130, - /* 710 */ 130, 119, 119, 119, 119, 130, 30, 30, 30, 100, - /* 720 */ 99, 99, 130, 130, 130, 130, 107, 100, 119, 99, - /* 730 */ 99, 105, 52, 25, 107, 46, 45, 43, 119, 130, - /* 740 */ 119, 119, 46, 45, 0, 30, 119, 44, 0, 119, - /* 750 */ 119, 130, 130, 114, 45, 87, 116, 0, 0, 126, - /* 760 */ 130, 130, 48, 25, 3, 87, 116, 0, 27, + /* 240 */ 19, 20, 21, 22, 23, 17, 31, 72, 20, 119, + /* 250 */ 120, 23, 24, 51, 26, 127, 128, 96, 30, 44, + /* 260 */ 25, 100, 101, 102, 103, 25, 68, 98, 33, 34, + /* 270 */ 35, 36, 44, 38, 39, 28, 29, 80, 81, 82, + /* 280 */ 83, 84, 85, 86, 34, 116, 117, 37, 60, 61, + /* 290 */ 62, 63, 64, 65, 66, 67, 26, 69, 129, 59, + /* 300 */ 97, 98, 74, 75, 76, 77, 78, 17, 82, 112, + /* 310 */ 20, 41, 86, 23, 24, 118, 46, 30, 48, 116, + /* 320 */ 30, 13, 14, 15, 16, 17, 18, 19, 20, 21, + /* 330 */ 22, 23, 129, 0, 44, 45, 33, 34, 35, 36, + /* 340 */ 95, 38, 39, 99, 99, 21, 22, 23, 104, 104, + /* 350 */ 60, 61, 62, 63, 64, 65, 66, 67, 74, 69, + /* 360 */ 116, 116, 119, 120, 74, 75, 76, 77, 78, 3, + /* 370 */ 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, + /* 380 */ 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, + /* 390 */ 17, 58, 98, 20, 11, 12, 23, 24, 82, 31, + /* 400 */ 98, 107, 86, 30, 110, 22, 114, 115, 116, 82, + /* 410 */ 116, 99, 34, 86, 98, 37, 104, 44, 116, 70, + /* 420 */ 71, 34, 73, 129, 37, 98, 124, 30, 116, 32, + /* 430 */ 30, 129, 116, 60, 61, 62, 63, 64, 65, 66, + /* 440 */ 67, 30, 69, 116, 87, 129, 49, 74, 75, 76, + /* 450 */ 77, 78, 98, 126, 20, 44, 129, 23, 24, 132, + /* 460 */ 26, 101, 102, 103, 30, 25, 31, 27, 30, 94, + /* 470 */ 116, 82, 97, 98, 30, 86, 99, 55, 44, 44, + /* 480 */ 126, 104, 44, 129, 42, 131, 132, 98, 44, 119, + /* 490 */ 120, 116, 30, 116, 60, 61, 62, 63, 64, 65, + /* 500 */ 66, 67, 25, 69, 129, 116, 30, 98, 74, 75, + /* 510 */ 76, 77, 78, 17, 25, 126, 20, 98, 129, 23, + /* 520 */ 24, 132, 45, 52, 98, 116, 30, 25, 17, 110, + /* 530 */ 30, 104, 32, 107, 45, 116, 110, 23, 129, 23, + /* 540 */ 44, 30, 116, 116, 25, 115, 116, 45, 129, 43, + /* 550 */ 44, 98, 44, 90, 104, 129, 60, 61, 62, 63, + /* 560 */ 64, 65, 66, 67, 45, 69, 116, 119, 98, 116, + /* 570 */ 74, 75, 76, 77, 78, 122, 50, 20, 30, 98, + /* 580 */ 23, 24, 129, 30, 98, 98, 116, 30, 74, 30, + /* 590 */ 108, 0, 25, 111, 119, 30, 98, 116, 30, 129, + /* 600 */ 30, 44, 116, 116, 123, 124, 34, 121, 122, 125, + /* 610 */ 129, 98, 45, 34, 116, 129, 129, 60, 61, 62, + /* 620 */ 63, 64, 65, 66, 67, 98, 69, 129, 98, 116, + /* 630 */ 132, 74, 75, 76, 77, 78, 49, 30, 45, 98, + /* 640 */ 45, 43, 129, 116, 30, 44, 116, 98, 58, 45, + /* 650 */ 98, 25, 30, 130, 98, 25, 129, 116, 98, 129, + /* 660 */ 44, 98, 98, 34, 98, 116, 30, 0, 116, 98, + /* 670 */ 129, 45, 116, 98, 119, 45, 116, 34, 129, 116, + /* 680 */ 116, 129, 116, 98, 98, 129, 45, 116, 111, 129, + /* 690 */ 91, 116, 129, 129, 26, 129, 0, 28, 98, 0, + /* 700 */ 129, 116, 116, 98, 129, 87, 98, 98, 30, 98, + /* 710 */ 98, 0, 0, 98, 129, 129, 116, 98, 98, 113, + /* 720 */ 34, 116, 125, 47, 116, 116, 25, 116, 116, 129, + /* 730 */ 30, 116, 98, 98, 129, 116, 116, 129, 129, 44, + /* 740 */ 129, 129, 98, 3, 129, 57, 125, 119, 129, 129, + /* 750 */ 116, 116, 125, 98, 49, 30, 98, 98, 98, 0, + /* 760 */ 116, 0, 30, 129, 129, 0, 45, 87, 128, 113, + /* 770 */ 0, 116, 27, 129, 116, 116, 116, 92, 25, 44, + /* 780 */ 93, 44, 89, 45, 129, 106, 52, 129, 129, 129, + /* 790 */ 40, 44, 25, 133, 105, 46, }; -#define PP_SHIFT_USE_DFLT (-15) +#define PP_SHIFT_USE_DFLT (-2) static short pp_shift_ofst[] = { - /* 0 */ 409, 379, 384, 394, 422, 432, 46, 383, 415, 446, - /* 10 */ 452, 456, -15, 468, -15, -14, 430, -14, -15, -15, - /* 20 */ -15, -15, -15, -15, -14, -15, 489, 488, 518, 488, - /* 30 */ -15, -1, -15, -15, 488, 488, 56, 488, 56, 488, - /* 40 */ 482, 488, 482, 488, 482, 488, 249, 488, 249, 488, - /* 50 */ 326, 488, 326, 488, 326, 488, 160, 488, 160, 488, - /* 60 */ 160, 488, 160, 488, 160, 488, 160, 488, 262, 70, - /* 70 */ 488, 522, 488, 262, 511, 311, 454, 400, 194, 530, - /* 80 */ 357, 413, -15, 413, -15, -15, 530, 58, 532, -15, - /* 90 */ 488, 221, 488, 221, 226, -15, 509, -15, 488, 304, - /* 100 */ 461, 142, -15, 540, -15, 6, 561, 543, -15, 550, - /* 110 */ 488, 188, 572, 564, -15, 574, 488, 119, 582, 589, - /* 120 */ -15, 488, 22, 184, -15, -15, 488, 96, 488, 221, - /* 130 */ -15, 388, 588, 228, 221, 596, -15, 536, 338, -15, - /* 140 */ -15, 488, 522, 488, 522, -15, -15, -15, -15, -15, - /* 150 */ -15, -15, -15, -15, -15, -15, -15, -15, 611, -15, - /* 160 */ 488, 221, -15, 613, -15, -15, -15, 608, 610, 616, - /* 170 */ 625, 632, 396, 628, 635, 643, 329, 645, 651, 665, - /* 180 */ 298, 667, 673, 675, 676, -15, 530, -15, 308, 686, - /* 190 */ -15, -15, 687, 687, -15, -15, -15, -15, 400, -15, - /* 200 */ -15, 441, 424, -15, 53, 688, -15, -15, -15, -15, - /* 210 */ -15, 381, -15, 689, -15, 488, 522, 691, 311, 473, - /* 220 */ -15, 696, -15, 56, -15, 488, 221, 680, 488, 708, - /* 230 */ 488, -15, 221, -15, 488, 221, 694, 530, 122, 698, - /* 240 */ 488, 372, 744, 488, -15, 221, -15, 715, 305, 703, - /* 250 */ 709, 488, 470, 748, 715, -15, -15, -15, 46, 296, - /* 260 */ 757, -14, 758, 530, 714, 530, 738, 530, -15, 761, - /* 270 */ 488, -15, 221, -15, 46, 296, 767, 741, 530, -15, + /* 0 */ 270, 712, 761, 696, 765, 759, 526, 422, 86, 202, + /* 10 */ 590, 688, -2, 749, -2, 60, 240, 60, -2, -2, + /* 20 */ -2, -2, -2, -2, 60, -2, 471, 557, 753, 557, + /* 30 */ -2, 73, -2, -2, 557, 557, 324, 557, 324, 557, + /* 40 */ 27, 557, 27, 557, 27, 557, 117, 557, 117, 557, + /* 50 */ 150, 557, 150, 557, 150, 557, 46, 557, 46, 557, + /* 60 */ 46, 557, 46, 557, 46, 557, 46, 557, 308, 383, + /* 70 */ 557, 516, 557, 308, 735, 228, 247, 373, 440, 476, + /* 80 */ 235, -2, 476, -2, 397, 725, 705, 411, -2, 462, + /* 90 */ 28, -2, 462, -2, -2, -2, 587, 438, 462, 477, + /* 100 */ -2, -2, 444, 462, 489, -2, -2, -2, 368, 287, + /* 110 */ -2, 303, -2, -2, 476, 500, 750, -2, 557, 221, + /* 120 */ 557, 221, 514, -2, 284, -2, 557, 366, 434, 96, + /* 130 */ -2, 604, -2, 616, 668, 641, -2, 695, 557, 142, + /* 140 */ 732, 721, -2, 737, 557, 198, 553, 595, -2, 557, + /* 150 */ -1, 349, -2, -2, 557, 175, 557, 221, -2, 215, + /* 160 */ 669, 290, 221, 593, -2, 26, 496, -2, -2, 557, + /* 170 */ 516, 557, 516, -2, -2, -2, -2, -2, -2, -2, + /* 180 */ -2, -2, -2, -2, -2, -2, 557, 221, -2, 700, + /* 190 */ -2, -2, 686, 678, 643, 636, 250, 629, 622, 614, + /* 200 */ 378, 579, 570, 568, 387, 572, 565, 559, 548, -2, + /* 210 */ -2, 373, -2, -2, 435, 511, -2, 22, 400, -2, + /* 220 */ -2, -2, -2, -2, 502, -2, 80, -2, 557, 516, + /* 230 */ 747, 228, 519, -2, 738, -2, 324, -2, 557, 221, + /* 240 */ 734, 557, 767, 557, -2, 221, -2, 557, 221, 442, + /* 250 */ 476, 506, 508, 557, 567, 591, 557, -2, 221, -2, + /* 260 */ 607, 626, 598, 601, 557, 630, 667, 607, -2, -2, + /* 270 */ -2, 526, 333, 699, 60, 711, 476, 676, 476, 701, + /* 280 */ 476, -2, 740, 557, -2, 221, -2, 526, 333, 770, + /* 290 */ 745, 476, -2, }; -#define PP_REDUCE_USE_DFLT (-18) +#define PP_REDUCE_USE_DFLT (-1) static short pp_reduce_ofst[] = { - /* 0 */ 132, -18, -18, -18, -18, -18, 242, 356, 391, 417, - /* 10 */ 423, 425, -18, -18, -18, 406, -18, 416, -18, -18, - /* 20 */ -18, -18, -18, -18, 418, -18, -18, 448, -18, 469, - /* 30 */ -18, -18, -18, -18, 510, 502, -18, 485, -18, 495, - /* 40 */ -18, 501, -18, 504, -18, 519, -18, 528, -18, 529, - /* 50 */ -18, 534, -18, 537, -18, 552, -18, 553, -18, 555, - /* 60 */ -18, 558, -18, 570, -18, 571, -18, 579, -18, -18, - /* 70 */ 585, -18, 593, -18, -18, 309, 453, 327, -18, 474, - /* 80 */ 462, -17, -18, 195, -18, -18, 274, 464, 471, -18, - /* 90 */ 580, -18, 594, -18, -18, -18, -18, -18, 609, -18, - /* 100 */ 410, -18, -18, -18, -18, -18, 164, -18, -18, -18, - /* 110 */ 567, -18, -18, -18, -18, -18, 577, -18, -18, -18, - /* 120 */ -18, 592, 282, 484, -18, -18, 622, -18, 631, -18, - /* 130 */ -18, -18, 486, 233, -18, -18, -18, -18, 401, -18, - /* 140 */ -18, 630, -18, 621, -18, -18, -18, -18, -18, -18, - /* 150 */ -18, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 160 */ 595, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 170 */ -18, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 180 */ -18, -18, -18, -18, -18, -18, 568, -18, -18, -18, - /* 190 */ -18, -18, -11, 626, -18, -18, -18, -18, 477, -18, - /* 200 */ -18, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 210 */ -18, -18, -18, -18, -18, 507, -18, -18, 310, -18, - /* 220 */ -18, -18, -18, -18, -18, 525, -18, -18, 369, -18, - /* 230 */ 460, -18, -18, -18, 531, -18, -18, 250, -18, -18, - /* 240 */ 360, -18, -18, 492, -18, -18, -18, 145, -18, -18, - /* 250 */ -18, 240, -18, -18, 639, -18, -18, -18, 668, 640, - /* 260 */ -18, 633, -18, 627, -18, 67, -18, 168, -18, -18, - /* 270 */ 478, -18, -18, -18, 678, 650, -18, -18, 619, -18, + /* 0 */ 197, -1, -1, -1, -1, -1, 357, 87, 693, 463, + /* 10 */ 599, 685, -1, -1, -1, 627, -1, 484, -1, -1, + /* 20 */ -1, -1, -1, -1, 621, -1, -1, 486, -1, 453, + /* 30 */ -1, -1, -1, -1, 608, 609, -1, 612, -1, 620, + /* 40 */ -1, 470, -1, 658, -1, 659, -1, 644, -1, 513, + /* 50 */ -1, 635, -1, 611, -1, 605, -1, 600, -1, 571, + /* 60 */ -1, 566, -1, 660, -1, 575, -1, 634, -1, -1, + /* 70 */ 549, -1, 560, -1, -1, 389, 687, 375, -1, 245, + /* 80 */ 161, -1, 312, -1, -1, -1, -1, 628, -1, 243, + /* 90 */ -1, -1, 555, -1, -1, -1, -1, 475, 130, -1, + /* 100 */ -1, -1, 448, 370, -1, -1, -1, -1, -1, -1, + /* 110 */ -1, 360, -1, -1, 427, 689, 679, -1, 541, -1, + /* 120 */ 527, -1, -1, -1, -1, -1, 619, -1, 316, -1, + /* 130 */ -1, -1, -1, -1, 226, -1, -1, -1, 586, -1, + /* 140 */ -1, -1, -1, -1, 556, -1, -1, -1, -1, 552, + /* 150 */ 128, 640, -1, -1, 409, -1, 615, -1, -1, -1, + /* 160 */ 523, 354, -1, -1, -1, -1, 498, -1, -1, 563, + /* 170 */ -1, 564, -1, -1, -1, -1, -1, -1, -1, -1, + /* 180 */ -1, -1, -1, -1, -1, -1, 585, -1, -1, -1, + /* 190 */ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + /* 200 */ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + /* 210 */ -1, 203, -1, -1, -1, -1, -1, -1, -1, -1, + /* 220 */ -1, -1, -1, -1, -1, -1, -1, -1, 487, -1, + /* 230 */ -1, 327, -1, -1, -1, -1, -1, -1, 530, -1, + /* 240 */ -1, 481, -1, 302, -1, -1, -1, 655, -1, -1, + /* 250 */ 450, -1, -1, 426, -1, -1, 419, -1, -1, -1, + /* 260 */ 482, -1, -1, -1, 294, -1, -1, 577, -1, -1, + /* 270 */ -1, 618, 606, -1, 597, -1, 377, -1, 292, -1, + /* 280 */ 430, -1, -1, 169, -1, -1, -1, 680, 656, -1, + /* 290 */ -1, 244, -1, }; static PPACTIONTYPE pp_default[] = { - /* 0 */ 437, 437, 437, 437, 437, 437, 345, 354, 359, 347, - /* 10 */ 365, 361, 285, 437, 360, 437, 362, 437, 363, 368, - /* 20 */ 369, 370, 371, 372, 437, 364, 437, 437, 346, 437, - /* 30 */ 348, 350, 351, 352, 437, 437, 373, 437, 375, 437, - /* 40 */ 376, 437, 377, 437, 378, 437, 379, 437, 380, 437, - /* 50 */ 381, 437, 382, 437, 383, 437, 384, 437, 385, 437, - /* 60 */ 386, 437, 387, 437, 388, 437, 389, 437, 390, 437, - /* 70 */ 437, 391, 437, 392, 437, 437, 289, 437, 437, 437, - /* 80 */ 302, 300, 286, 299, 303, 305, 437, 312, 323, 309, - /* 90 */ 437, 322, 437, 400, 437, 418, 437, 419, 437, 420, - /* 100 */ 437, 437, 423, 437, 396, 437, 437, 437, 399, 437, - /* 110 */ 437, 437, 437, 437, 401, 437, 437, 437, 437, 437, - /* 120 */ 402, 437, 437, 437, 403, 404, 437, 437, 437, 406, - /* 130 */ 408, 436, 411, 437, 417, 437, 409, 437, 437, 414, - /* 140 */ 416, 437, 421, 437, 422, 424, 425, 426, 427, 428, - /* 150 */ 429, 430, 431, 432, 433, 434, 415, 410, 437, 435, - /* 160 */ 437, 407, 405, 437, 310, 311, 343, 436, 437, 437, - /* 170 */ 437, 437, 437, 437, 437, 437, 437, 437, 437, 437, - /* 180 */ 437, 437, 437, 437, 437, 304, 437, 297, 342, 437, - /* 190 */ 340, 341, 437, 301, 306, 308, 307, 298, 437, 290, - /* 200 */ 292, 436, 437, 293, 296, 437, 294, 295, 291, 287, - /* 210 */ 288, 437, 394, 437, 397, 437, 393, 437, 437, 437, - /* 220 */ 395, 437, 398, 374, 349, 437, 358, 437, 437, 353, - /* 230 */ 437, 355, 357, 356, 437, 344, 437, 437, 437, 437, - /* 240 */ 437, 437, 437, 437, 326, 328, 327, 437, 437, 437, - /* 250 */ 437, 437, 437, 437, 437, 329, 331, 330, 345, 437, - /* 260 */ 437, 437, 437, 437, 437, 437, 333, 437, 334, 437, - /* 270 */ 437, 336, 337, 335, 345, 437, 437, 437, 437, 339, + /* 0 */ 454, 454, 454, 454, 454, 454, 362, 371, 376, 364, + /* 10 */ 382, 378, 298, 454, 377, 454, 379, 454, 380, 385, + /* 20 */ 386, 387, 388, 389, 454, 381, 454, 454, 363, 454, + /* 30 */ 365, 367, 368, 369, 454, 454, 390, 454, 392, 454, + /* 40 */ 393, 454, 394, 454, 395, 454, 396, 454, 397, 454, + /* 50 */ 398, 454, 399, 454, 400, 454, 401, 454, 402, 454, + /* 60 */ 403, 454, 404, 454, 405, 454, 406, 454, 407, 454, + /* 70 */ 454, 408, 454, 409, 454, 454, 302, 454, 454, 454, + /* 80 */ 313, 299, 454, 310, 350, 454, 348, 454, 351, 454, + /* 90 */ 454, 352, 454, 357, 359, 358, 349, 454, 454, 454, + /* 100 */ 353, 354, 454, 454, 454, 355, 356, 360, 453, 454, + /* 110 */ 452, 312, 314, 316, 454, 320, 331, 317, 454, 330, + /* 120 */ 454, 417, 454, 435, 454, 436, 454, 437, 454, 454, + /* 130 */ 440, 454, 413, 454, 454, 454, 416, 454, 454, 454, + /* 140 */ 454, 454, 418, 454, 454, 454, 454, 454, 419, 454, + /* 150 */ 454, 454, 420, 421, 454, 454, 454, 423, 425, 453, + /* 160 */ 428, 454, 434, 454, 426, 454, 454, 431, 433, 454, + /* 170 */ 438, 454, 439, 441, 442, 443, 444, 445, 446, 447, + /* 180 */ 448, 449, 450, 451, 432, 427, 454, 424, 422, 454, + /* 190 */ 318, 319, 454, 454, 454, 454, 454, 454, 454, 454, + /* 200 */ 454, 454, 454, 454, 454, 454, 454, 454, 454, 315, + /* 210 */ 311, 454, 303, 305, 453, 454, 306, 309, 454, 307, + /* 220 */ 308, 304, 300, 301, 454, 411, 454, 414, 454, 410, + /* 230 */ 454, 454, 454, 412, 454, 415, 391, 366, 454, 375, + /* 240 */ 454, 454, 370, 454, 372, 374, 373, 454, 361, 454, + /* 250 */ 454, 454, 454, 454, 454, 454, 454, 334, 336, 335, + /* 260 */ 454, 454, 454, 454, 454, 454, 454, 454, 337, 339, + /* 270 */ 338, 362, 454, 454, 454, 454, 454, 454, 454, 341, + /* 280 */ 454, 342, 454, 454, 344, 345, 343, 362, 454, 454, + /* 290 */ 454, 454, 347, }; #define PP_SZ_ACTTAB (sizeof(pp_action)/sizeof(pp_action[0])) @@ -101972,11 +102649,11 @@ static const char *ppTokenName[] = { "MINUS", "IS", "IN", "NOT", "BITWISE_NOT", "COMMA", "SELECT", "FROM", "DISTINCT", "ALL", "IDENTIFIER", "DOT", - "AS", "WITH", "INNER", "JOIN", - "CROSS", "LEFT", "OUTER", "RIGHT", - "FULL", "ON", "INSERT", "INTO", - "VALUES", "PARENTHESES_OPEN", "PARENTHESES_CLOSE", "UPDATE", - "SET", "DELETE", "WHERE", "ORDER", + "AS", "INNER", "JOIN", "CROSS", + "LEFT", "OUTER", "RIGHT", "FULL", + "ON", "INSERT", "INTO", "VALUES", + "PARENTHESES_OPEN", "PARENTHESES_CLOSE", "UPDATE", "SET", + "DELETE", "WITH", "WHERE", "ORDER", "BY", "ASC", "DESC", "GROUP", "HAVING", "FOR", "LIMIT", "OFFSET", "INTEGER", "HINTEGER", "NPLACEHOLDER", "SPLACEHOLDER", @@ -101988,16 +102665,16 @@ static const char *ppTokenName[] = { "update_statement", "delete_statement", "select_clause", "where_clause", "group_clause", "having_clause", "order_clause", "select_limit_clause", "for_update_clause", "distinct_all", "column_list", "associated_name_list", - "with_list_or_null", "join_list_or_null", "column_item", "expr", - "associated_name", "join_list", "with_list", "join_item", - "join_clause", "with_item", "join_type", "aliased_or_qualified_name", - "join_associated_name", "join_conditions", "values_list", "field_list", - "value_list", "value_item", "field_item", "update_clause", - "limit_clause", "update_item_list", "update_item", "qualified_name", - "new_value", "delete_clause", "order_list", "order_item", - "group_list", "group_item", "integer_or_placeholder", "argument_list", - "when_clauses", "when_clause", "function_call", "distinct_or_null", - "argument_list_or_null", "argument_item", + "join_list_or_null", "column_item", "expr", "associated_name", + "join_list", "join_item", "join_clause", "join_type", + "aliased_or_qualified_name", "join_associated_name", "join_conditions", "values_list", + "field_list", "value_list", "value_item", "field_item", + "update_clause", "limit_clause", "update_item_list", "update_item", + "qualified_name", "new_value", "delete_clause", "with_item", + "with_list", "order_list", "order_item", "group_list", + "group_item", "integer_or_placeholder", "argument_list", "when_clauses", + "when_clause", "function_call", "distinct_or_null", "argument_list_or_null", + "argument_item", }; #endif /* NDEBUG */ @@ -102011,7 +102688,7 @@ static const char *ppRuleName[] = { /* 3 */ "query_language ::= update_statement", /* 4 */ "query_language ::= delete_statement", /* 5 */ "select_statement ::= select_clause where_clause group_clause having_clause order_clause select_limit_clause for_update_clause", - /* 6 */ "select_clause ::= SELECT distinct_all column_list FROM associated_name_list with_list_or_null join_list_or_null", + /* 6 */ "select_clause ::= SELECT distinct_all column_list FROM associated_name_list join_list_or_null", /* 7 */ "distinct_all ::= DISTINCT", /* 8 */ "distinct_all ::= ALL", /* 9 */ "distinct_all ::=", @@ -102026,142 +102703,146 @@ static const char *ppRuleName[] = { /* 18 */ "associated_name_list ::= associated_name", /* 19 */ "join_list_or_null ::= join_list", /* 20 */ "join_list_or_null ::=", - /* 21 */ "with_list_or_null ::= WITH with_list", - /* 22 */ "with_list_or_null ::=", - /* 23 */ "join_list ::= join_list join_item", - /* 24 */ "join_list ::= join_item", - /* 25 */ "join_item ::= join_clause", - /* 26 */ "with_list ::= with_list with_item", - /* 27 */ "with_list ::= with_item", - /* 28 */ "with_item ::= IDENTIFIER", - /* 29 */ "join_clause ::= join_type aliased_or_qualified_name join_associated_name join_conditions", - /* 30 */ "join_associated_name ::= AS IDENTIFIER", - /* 31 */ "join_associated_name ::= IDENTIFIER", - /* 32 */ "join_associated_name ::=", - /* 33 */ "join_type ::= INNER JOIN", - /* 34 */ "join_type ::= CROSS JOIN", - /* 35 */ "join_type ::= LEFT OUTER JOIN", - /* 36 */ "join_type ::= LEFT JOIN", - /* 37 */ "join_type ::= RIGHT OUTER JOIN", - /* 38 */ "join_type ::= RIGHT JOIN", - /* 39 */ "join_type ::= FULL OUTER JOIN", - /* 40 */ "join_type ::= FULL JOIN", - /* 41 */ "join_type ::= JOIN", - /* 42 */ "join_conditions ::= ON expr", - /* 43 */ "join_conditions ::=", - /* 44 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", - /* 45 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name PARENTHESES_OPEN field_list PARENTHESES_CLOSE VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", - /* 46 */ "values_list ::= values_list COMMA value_item", - /* 47 */ "values_list ::= value_item", - /* 48 */ "value_item ::= expr", - /* 49 */ "field_list ::= field_list COMMA field_item", - /* 50 */ "field_list ::= field_item", - /* 51 */ "field_item ::= IDENTIFIER", - /* 52 */ "update_statement ::= update_clause where_clause limit_clause", - /* 53 */ "update_clause ::= UPDATE associated_name SET update_item_list", - /* 54 */ "update_item_list ::= update_item_list COMMA update_item", - /* 55 */ "update_item_list ::= update_item", - /* 56 */ "update_item ::= qualified_name EQUALS new_value", - /* 57 */ "new_value ::= expr", - /* 58 */ "delete_statement ::= delete_clause where_clause limit_clause", - /* 59 */ "delete_clause ::= DELETE FROM associated_name", - /* 60 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER", - /* 61 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER", - /* 62 */ "associated_name ::= aliased_or_qualified_name", - /* 63 */ "aliased_or_qualified_name ::= qualified_name", - /* 64 */ "where_clause ::= WHERE expr", - /* 65 */ "where_clause ::=", - /* 66 */ "order_clause ::= ORDER BY order_list", - /* 67 */ "order_clause ::=", - /* 68 */ "order_list ::= order_list COMMA order_item", - /* 69 */ "order_list ::= order_item", - /* 70 */ "order_item ::= expr", - /* 71 */ "order_item ::= expr ASC", - /* 72 */ "order_item ::= expr DESC", - /* 73 */ "group_clause ::= GROUP BY group_list", - /* 74 */ "group_clause ::=", - /* 75 */ "group_list ::= group_list COMMA group_item", - /* 76 */ "group_list ::= group_item", - /* 77 */ "group_item ::= expr", - /* 78 */ "having_clause ::= HAVING expr", - /* 79 */ "having_clause ::=", - /* 80 */ "for_update_clause ::= FOR UPDATE", - /* 81 */ "for_update_clause ::=", - /* 82 */ "select_limit_clause ::= LIMIT integer_or_placeholder", - /* 83 */ "select_limit_clause ::= LIMIT integer_or_placeholder COMMA integer_or_placeholder", - /* 84 */ "select_limit_clause ::= LIMIT integer_or_placeholder OFFSET integer_or_placeholder", - /* 85 */ "select_limit_clause ::=", - /* 86 */ "limit_clause ::= LIMIT integer_or_placeholder", - /* 87 */ "limit_clause ::=", - /* 88 */ "integer_or_placeholder ::= INTEGER", - /* 89 */ "integer_or_placeholder ::= HINTEGER", - /* 90 */ "integer_or_placeholder ::= NPLACEHOLDER", - /* 91 */ "integer_or_placeholder ::= SPLACEHOLDER", - /* 92 */ "integer_or_placeholder ::= BPLACEHOLDER", - /* 93 */ "expr ::= MINUS expr", - /* 94 */ "expr ::= expr MINUS expr", - /* 95 */ "expr ::= expr PLUS expr", - /* 96 */ "expr ::= expr TIMES expr", - /* 97 */ "expr ::= expr DIVIDE expr", - /* 98 */ "expr ::= expr MOD expr", - /* 99 */ "expr ::= expr AND expr", - /* 100 */ "expr ::= expr OR expr", - /* 101 */ "expr ::= expr BITWISE_AND expr", - /* 102 */ "expr ::= expr BITWISE_OR expr", - /* 103 */ "expr ::= expr BITWISE_XOR expr", - /* 104 */ "expr ::= expr EQUALS expr", - /* 105 */ "expr ::= expr NOTEQUALS expr", - /* 106 */ "expr ::= expr LESS expr", - /* 107 */ "expr ::= expr GREATER expr", - /* 108 */ "expr ::= expr GREATEREQUAL expr", - /* 109 */ "expr ::= expr LESSEQUAL expr", - /* 110 */ "expr ::= expr LIKE expr", - /* 111 */ "expr ::= expr NOT LIKE expr", - /* 112 */ "expr ::= expr ILIKE expr", - /* 113 */ "expr ::= expr NOT ILIKE expr", - /* 114 */ "expr ::= expr IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", - /* 115 */ "expr ::= expr NOT IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", - /* 116 */ "expr ::= PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 117 */ "expr ::= expr IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 118 */ "expr ::= expr NOT IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 119 */ "expr ::= EXISTS PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 120 */ "expr ::= expr AGAINST expr", - /* 121 */ "expr ::= CAST PARENTHESES_OPEN expr AS IDENTIFIER PARENTHESES_CLOSE", - /* 122 */ "expr ::= CONVERT PARENTHESES_OPEN expr USING IDENTIFIER PARENTHESES_CLOSE", - /* 123 */ "expr ::= CASE expr when_clauses END", - /* 124 */ "when_clauses ::= when_clauses when_clause", - /* 125 */ "when_clauses ::= when_clause", - /* 126 */ "when_clause ::= WHEN expr THEN expr", - /* 127 */ "when_clause ::= ELSE expr", - /* 128 */ "expr ::= function_call", - /* 129 */ "function_call ::= IDENTIFIER PARENTHESES_OPEN distinct_or_null argument_list_or_null PARENTHESES_CLOSE", - /* 130 */ "distinct_or_null ::= DISTINCT", - /* 131 */ "distinct_or_null ::=", - /* 132 */ "argument_list_or_null ::= argument_list", - /* 133 */ "argument_list_or_null ::=", - /* 134 */ "argument_list ::= argument_list COMMA argument_item", - /* 135 */ "argument_list ::= argument_item", - /* 136 */ "argument_item ::= TIMES", - /* 137 */ "argument_item ::= expr", - /* 138 */ "expr ::= expr IS NULL", - /* 139 */ "expr ::= expr IS NOT NULL", - /* 140 */ "expr ::= expr BETWEEN expr", - /* 141 */ "expr ::= NOT expr", - /* 142 */ "expr ::= BITWISE_NOT expr", - /* 143 */ "expr ::= PARENTHESES_OPEN expr PARENTHESES_CLOSE", - /* 144 */ "expr ::= qualified_name", - /* 145 */ "expr ::= INTEGER", - /* 146 */ "expr ::= HINTEGER", - /* 147 */ "expr ::= STRING", - /* 148 */ "expr ::= DOUBLE", - /* 149 */ "expr ::= NULL", - /* 150 */ "expr ::= TRUE", - /* 151 */ "expr ::= FALSE", - /* 152 */ "expr ::= NPLACEHOLDER", - /* 153 */ "expr ::= SPLACEHOLDER", - /* 154 */ "expr ::= BPLACEHOLDER", - /* 155 */ "qualified_name ::= IDENTIFIER DOT IDENTIFIER", - /* 156 */ "qualified_name ::= IDENTIFIER", + /* 21 */ "join_list ::= join_list join_item", + /* 22 */ "join_list ::= join_item", + /* 23 */ "join_item ::= join_clause", + /* 24 */ "join_clause ::= join_type aliased_or_qualified_name join_associated_name join_conditions", + /* 25 */ "join_associated_name ::= AS IDENTIFIER", + /* 26 */ "join_associated_name ::= IDENTIFIER", + /* 27 */ "join_associated_name ::=", + /* 28 */ "join_type ::= INNER JOIN", + /* 29 */ "join_type ::= CROSS JOIN", + /* 30 */ "join_type ::= LEFT OUTER JOIN", + /* 31 */ "join_type ::= LEFT JOIN", + /* 32 */ "join_type ::= RIGHT OUTER JOIN", + /* 33 */ "join_type ::= RIGHT JOIN", + /* 34 */ "join_type ::= FULL OUTER JOIN", + /* 35 */ "join_type ::= FULL JOIN", + /* 36 */ "join_type ::= JOIN", + /* 37 */ "join_conditions ::= ON expr", + /* 38 */ "join_conditions ::=", + /* 39 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", + /* 40 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name PARENTHESES_OPEN field_list PARENTHESES_CLOSE VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", + /* 41 */ "values_list ::= values_list COMMA value_item", + /* 42 */ "values_list ::= value_item", + /* 43 */ "value_item ::= expr", + /* 44 */ "field_list ::= field_list COMMA field_item", + /* 45 */ "field_list ::= field_item", + /* 46 */ "field_item ::= IDENTIFIER", + /* 47 */ "update_statement ::= update_clause where_clause limit_clause", + /* 48 */ "update_clause ::= UPDATE associated_name SET update_item_list", + /* 49 */ "update_item_list ::= update_item_list COMMA update_item", + /* 50 */ "update_item_list ::= update_item", + /* 51 */ "update_item ::= qualified_name EQUALS new_value", + /* 52 */ "new_value ::= expr", + /* 53 */ "delete_statement ::= delete_clause where_clause limit_clause", + /* 54 */ "delete_clause ::= DELETE FROM associated_name", + /* 55 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER", + /* 56 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER", + /* 57 */ "associated_name ::= aliased_or_qualified_name", + /* 58 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER WITH with_item", + /* 59 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER WITH PARENTHESES_OPEN with_list PARENTHESES_CLOSE", + /* 60 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER WITH PARENTHESES_OPEN with_list PARENTHESES_CLOSE", + /* 61 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER WITH with_item", + /* 62 */ "associated_name ::= aliased_or_qualified_name WITH PARENTHESES_OPEN with_list PARENTHESES_CLOSE", + /* 63 */ "associated_name ::= aliased_or_qualified_name WITH with_item", + /* 64 */ "with_list ::= with_list COMMA with_item", + /* 65 */ "with_list ::= with_item", + /* 66 */ "with_item ::= IDENTIFIER", + /* 67 */ "aliased_or_qualified_name ::= qualified_name", + /* 68 */ "where_clause ::= WHERE expr", + /* 69 */ "where_clause ::=", + /* 70 */ "order_clause ::= ORDER BY order_list", + /* 71 */ "order_clause ::=", + /* 72 */ "order_list ::= order_list COMMA order_item", + /* 73 */ "order_list ::= order_item", + /* 74 */ "order_item ::= expr", + /* 75 */ "order_item ::= expr ASC", + /* 76 */ "order_item ::= expr DESC", + /* 77 */ "group_clause ::= GROUP BY group_list", + /* 78 */ "group_clause ::=", + /* 79 */ "group_list ::= group_list COMMA group_item", + /* 80 */ "group_list ::= group_item", + /* 81 */ "group_item ::= expr", + /* 82 */ "having_clause ::= HAVING expr", + /* 83 */ "having_clause ::=", + /* 84 */ "for_update_clause ::= FOR UPDATE", + /* 85 */ "for_update_clause ::=", + /* 86 */ "select_limit_clause ::= LIMIT integer_or_placeholder", + /* 87 */ "select_limit_clause ::= LIMIT integer_or_placeholder COMMA integer_or_placeholder", + /* 88 */ "select_limit_clause ::= LIMIT integer_or_placeholder OFFSET integer_or_placeholder", + /* 89 */ "select_limit_clause ::=", + /* 90 */ "limit_clause ::= LIMIT integer_or_placeholder", + /* 91 */ "limit_clause ::=", + /* 92 */ "integer_or_placeholder ::= INTEGER", + /* 93 */ "integer_or_placeholder ::= HINTEGER", + /* 94 */ "integer_or_placeholder ::= NPLACEHOLDER", + /* 95 */ "integer_or_placeholder ::= SPLACEHOLDER", + /* 96 */ "integer_or_placeholder ::= BPLACEHOLDER", + /* 97 */ "expr ::= MINUS expr", + /* 98 */ "expr ::= expr MINUS expr", + /* 99 */ "expr ::= expr PLUS expr", + /* 100 */ "expr ::= expr TIMES expr", + /* 101 */ "expr ::= expr DIVIDE expr", + /* 102 */ "expr ::= expr MOD expr", + /* 103 */ "expr ::= expr AND expr", + /* 104 */ "expr ::= expr OR expr", + /* 105 */ "expr ::= expr BITWISE_AND expr", + /* 106 */ "expr ::= expr BITWISE_OR expr", + /* 107 */ "expr ::= expr BITWISE_XOR expr", + /* 108 */ "expr ::= expr EQUALS expr", + /* 109 */ "expr ::= expr NOTEQUALS expr", + /* 110 */ "expr ::= expr LESS expr", + /* 111 */ "expr ::= expr GREATER expr", + /* 112 */ "expr ::= expr GREATEREQUAL expr", + /* 113 */ "expr ::= expr LESSEQUAL expr", + /* 114 */ "expr ::= expr LIKE expr", + /* 115 */ "expr ::= expr NOT LIKE expr", + /* 116 */ "expr ::= expr ILIKE expr", + /* 117 */ "expr ::= expr NOT ILIKE expr", + /* 118 */ "expr ::= expr IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", + /* 119 */ "expr ::= expr NOT IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", + /* 120 */ "expr ::= PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 121 */ "expr ::= expr IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 122 */ "expr ::= expr NOT IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 123 */ "expr ::= EXISTS PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 124 */ "expr ::= expr AGAINST expr", + /* 125 */ "expr ::= CAST PARENTHESES_OPEN expr AS IDENTIFIER PARENTHESES_CLOSE", + /* 126 */ "expr ::= CONVERT PARENTHESES_OPEN expr USING IDENTIFIER PARENTHESES_CLOSE", + /* 127 */ "expr ::= CASE expr when_clauses END", + /* 128 */ "when_clauses ::= when_clauses when_clause", + /* 129 */ "when_clauses ::= when_clause", + /* 130 */ "when_clause ::= WHEN expr THEN expr", + /* 131 */ "when_clause ::= ELSE expr", + /* 132 */ "expr ::= function_call", + /* 133 */ "function_call ::= IDENTIFIER PARENTHESES_OPEN distinct_or_null argument_list_or_null PARENTHESES_CLOSE", + /* 134 */ "distinct_or_null ::= DISTINCT", + /* 135 */ "distinct_or_null ::=", + /* 136 */ "argument_list_or_null ::= argument_list", + /* 137 */ "argument_list_or_null ::=", + /* 138 */ "argument_list ::= argument_list COMMA argument_item", + /* 139 */ "argument_list ::= argument_item", + /* 140 */ "argument_item ::= TIMES", + /* 141 */ "argument_item ::= expr", + /* 142 */ "expr ::= expr IS NULL", + /* 143 */ "expr ::= expr IS NOT NULL", + /* 144 */ "expr ::= expr BETWEEN expr", + /* 145 */ "expr ::= NOT expr", + /* 146 */ "expr ::= BITWISE_NOT expr", + /* 147 */ "expr ::= PARENTHESES_OPEN expr PARENTHESES_CLOSE", + /* 148 */ "expr ::= qualified_name", + /* 149 */ "expr ::= INTEGER", + /* 150 */ "expr ::= HINTEGER", + /* 151 */ "expr ::= STRING", + /* 152 */ "expr ::= DOUBLE", + /* 153 */ "expr ::= NULL", + /* 154 */ "expr ::= TRUE", + /* 155 */ "expr ::= FALSE", + /* 156 */ "expr ::= NPLACEHOLDER", + /* 157 */ "expr ::= SPLACEHOLDER", + /* 158 */ "expr ::= BPLACEHOLDER", + /* 159 */ "qualified_name ::= IDENTIFIER DOT IDENTIFIER", + /* 160 */ "qualified_name ::= IDENTIFIER", }; #endif /* NDEBUG */ @@ -102281,7 +102962,7 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 76: case 77: case 78: -// 557 "parser.lemon" +// 558 "parser.lemon" { if ((pppminor->pp0)) { if ((pppminor->pp0)->free_flag) { @@ -102290,7 +102971,7 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ efree((pppminor->pp0)); } } -// 1253 "parser.c" +// 1270 "parser.c" break; case 81: case 82: @@ -102300,6 +102981,7 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 86: case 94: case 95: + case 97: case 98: case 99: case 100: @@ -102307,27 +102989,26 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 102: case 103: case 104: - case 105: - case 106: - case 107: + case 108: + case 109: case 111: case 112: case 114: case 115: - case 117: + case 116: case 118: case 119: + case 120: case 121: case 122: case 123: case 124: - case 125: - case 127: - case 130: - case 133: -// 570 "parser.lemon" -{ zval_ptr_dtor(&(pppminor->pp244)); } -// 1290 "parser.c" + case 126: + case 129: + case 132: +// 571 "parser.lemon" +{ zval_ptr_dtor(&(pppminor->pp162)); } +// 1307 "parser.c" break; case 87: case 88: @@ -102336,14 +103017,14 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 91: case 92: case 93: - case 108: - case 109: - case 116: + case 105: + case 106: + case 113: + case 130: case 131: - case 132: -// 882 "parser.lemon" -{ zephir_safe_zval_ptr_dtor((pppminor->pp244)); } -// 1306 "parser.c" +// 899 "parser.lemon" +{ zephir_safe_zval_ptr_dtor((pppminor->pp162)); } +// 1323 "parser.c" break; default: break; /* If no destructor action specified: do nothing */ } @@ -102486,78 +103167,82 @@ static struct { { 81, 1 }, { 81, 1 }, { 82, 7 }, - { 86, 7 }, + { 86, 6 }, { 93, 1 }, { 93, 1 }, { 93, 0 }, { 94, 3 }, { 94, 1 }, - { 98, 1 }, - { 98, 3 }, - { 98, 3 }, - { 98, 2 }, - { 98, 1 }, + { 97, 1 }, + { 97, 3 }, + { 97, 3 }, + { 97, 2 }, + { 97, 1 }, { 95, 3 }, { 95, 1 }, - { 97, 1 }, - { 97, 0 }, - { 96, 2 }, + { 96, 1 }, { 96, 0 }, - { 101, 2 }, + { 100, 2 }, + { 100, 1 }, { 101, 1 }, - { 103, 1 }, - { 102, 2 }, - { 102, 1 }, + { 102, 4 }, + { 105, 2 }, { 105, 1 }, - { 104, 4 }, - { 108, 2 }, - { 108, 1 }, - { 108, 0 }, - { 106, 2 }, - { 106, 2 }, - { 106, 3 }, - { 106, 2 }, - { 106, 3 }, - { 106, 2 }, - { 106, 3 }, + { 105, 0 }, + { 103, 2 }, + { 103, 2 }, + { 103, 3 }, + { 103, 2 }, + { 103, 3 }, + { 103, 2 }, + { 103, 3 }, + { 103, 2 }, + { 103, 1 }, { 106, 2 }, - { 106, 1 }, - { 109, 2 }, - { 109, 0 }, + { 106, 0 }, { 83, 7 }, { 83, 10 }, - { 110, 3 }, + { 107, 3 }, + { 107, 1 }, { 110, 1 }, - { 113, 1 }, - { 111, 3 }, + { 108, 3 }, + { 108, 1 }, { 111, 1 }, - { 114, 1 }, { 84, 3 }, - { 115, 4 }, - { 117, 3 }, + { 112, 4 }, + { 114, 3 }, + { 114, 1 }, + { 115, 3 }, { 117, 1 }, + { 85, 3 }, { 118, 3 }, + { 99, 3 }, + { 99, 2 }, + { 99, 1 }, + { 99, 5 }, + { 99, 7 }, + { 99, 6 }, + { 99, 4 }, + { 99, 5 }, + { 99, 3 }, + { 120, 3 }, { 120, 1 }, - { 85, 3 }, - { 121, 3 }, - { 100, 3 }, - { 100, 2 }, - { 100, 1 }, - { 107, 1 }, + { 119, 1 }, + { 104, 1 }, { 87, 2 }, { 87, 0 }, { 90, 3 }, { 90, 0 }, - { 122, 3 }, + { 121, 3 }, + { 121, 1 }, { 122, 1 }, - { 123, 1 }, - { 123, 2 }, - { 123, 2 }, + { 122, 2 }, + { 122, 2 }, { 88, 3 }, { 88, 0 }, - { 124, 3 }, + { 123, 3 }, + { 123, 1 }, { 124, 1 }, - { 125, 1 }, { 89, 2 }, { 89, 0 }, { 92, 2 }, @@ -102566,77 +103251,77 @@ static struct { { 91, 4 }, { 91, 4 }, { 91, 0 }, - { 116, 2 }, - { 116, 0 }, - { 126, 1 }, - { 126, 1 }, - { 126, 1 }, - { 126, 1 }, - { 126, 1 }, - { 99, 2 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 4 }, - { 99, 3 }, - { 99, 4 }, - { 99, 5 }, - { 99, 6 }, - { 99, 3 }, - { 99, 5 }, - { 99, 6 }, - { 99, 4 }, - { 99, 3 }, - { 99, 6 }, - { 99, 6 }, - { 99, 4 }, + { 113, 2 }, + { 113, 0 }, + { 125, 1 }, + { 125, 1 }, + { 125, 1 }, + { 125, 1 }, + { 125, 1 }, + { 98, 2 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 4 }, + { 98, 3 }, + { 98, 4 }, + { 98, 5 }, + { 98, 6 }, + { 98, 3 }, + { 98, 5 }, + { 98, 6 }, + { 98, 4 }, + { 98, 3 }, + { 98, 6 }, + { 98, 6 }, + { 98, 4 }, + { 127, 2 }, + { 127, 1 }, + { 128, 4 }, { 128, 2 }, - { 128, 1 }, - { 129, 4 }, - { 129, 2 }, - { 99, 1 }, - { 130, 5 }, + { 98, 1 }, + { 129, 5 }, + { 130, 1 }, + { 130, 0 }, { 131, 1 }, { 131, 0 }, + { 126, 3 }, + { 126, 1 }, { 132, 1 }, - { 132, 0 }, - { 127, 3 }, - { 127, 1 }, - { 133, 1 }, - { 133, 1 }, - { 99, 3 }, - { 99, 4 }, - { 99, 3 }, - { 99, 2 }, - { 99, 2 }, - { 99, 3 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 119, 3 }, - { 119, 1 }, + { 132, 1 }, + { 98, 3 }, + { 98, 4 }, + { 98, 3 }, + { 98, 2 }, + { 98, 2 }, + { 98, 3 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 116, 3 }, + { 116, 1 }, }; static void pp_accept(ppParser*); /* Forward Declaration */ @@ -102670,11 +103355,11 @@ static void pp_reduce( ** break; */ case 0: -// 566 "parser.lemon" +// 567 "parser.lemon" { - status->ret = ppmsp[0].minor.pp244; + status->ret = ppmsp[0].minor.pp162; } -// 1680 "parser.c" +// 1701 "parser.c" break; case 1: case 2: @@ -102682,880 +103367,927 @@ static void pp_reduce( case 4: case 18: case 19: - case 24: - case 25: - case 27: - case 48: - case 55: - case 57: - case 63: - case 69: - case 76: - case 77: - case 128: + case 22: + case 23: + case 43: + case 50: + case 52: + case 65: + case 67: + case 73: + case 80: + case 81: case 132: - case 137: - case 144: -// 572 "parser.lemon" + case 136: + case 141: + case 148: +// 573 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; } -// 1706 "parser.c" +// 1727 "parser.c" break; case 5: -// 590 "parser.lemon" +// 591 "parser.lemon" { - ppgotominor.pp244 = phql_ret_select_statement(ppmsp[-6].minor.pp244, ppmsp[-5].minor.pp244, ppmsp[-2].minor.pp244, ppmsp[-4].minor.pp244, ppmsp[-3].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_select_statement(ppmsp[-6].minor.pp162, ppmsp[-5].minor.pp162, ppmsp[-2].minor.pp162, ppmsp[-4].minor.pp162, ppmsp[-3].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1713 "parser.c" +// 1734 "parser.c" break; case 6: -// 596 "parser.lemon" +// 597 "parser.lemon" { - ppgotominor.pp244 = phql_ret_select_clause(ppmsp[-5].minor.pp244, ppmsp[-4].minor.pp244, ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); - pp_destructor(26,&ppmsp[-6].minor); - pp_destructor(27,&ppmsp[-3].minor); + ppgotominor.pp162 = phql_ret_select_clause(ppmsp[-4].minor.pp162, ppmsp[-3].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); + pp_destructor(26,&ppmsp[-5].minor); + pp_destructor(27,&ppmsp[-2].minor); } -// 1722 "parser.c" +// 1743 "parser.c" break; case 7: -// 602 "parser.lemon" +// 603 "parser.lemon" { - ppgotominor.pp244 = phql_ret_distinct_all(1); + ppgotominor.pp162 = phql_ret_distinct_all(1); pp_destructor(28,&ppmsp[0].minor); } -// 1730 "parser.c" +// 1751 "parser.c" break; case 8: -// 606 "parser.lemon" +// 607 "parser.lemon" { - ppgotominor.pp244 = phql_ret_distinct_all(0); + ppgotominor.pp162 = phql_ret_distinct_all(0); pp_destructor(29,&ppmsp[0].minor); } -// 1738 "parser.c" +// 1759 "parser.c" break; case 9: case 20: - case 22: - case 32: - case 43: - case 65: - case 67: - case 74: - case 79: - case 81: + case 27: + case 38: + case 69: + case 71: + case 78: + case 83: case 85: - case 87: - case 131: - case 133: -// 610 "parser.lemon" + case 89: + case 91: + case 135: + case 137: +// 611 "parser.lemon" { - ppgotominor.pp244 = NULL; + ppgotominor.pp162 = NULL; } -// 1758 "parser.c" +// 1778 "parser.c" break; case 10: case 17: - case 46: + case 41: + case 44: case 49: - case 54: - case 68: - case 75: - case 134: -// 616 "parser.lemon" + case 64: + case 72: + case 79: + case 138: +// 617 "parser.lemon" { - ppgotominor.pp244 = phql_ret_zval_list(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_zval_list(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(25,&ppmsp[-1].minor); } -// 1773 "parser.c" +// 1794 "parser.c" break; case 11: - case 47: - case 50: - case 125: - case 135: -// 620 "parser.lemon" + case 42: + case 45: + case 129: + case 139: +// 621 "parser.lemon" { - ppgotominor.pp244 = phql_ret_zval_list(ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_zval_list(ppmsp[0].minor.pp162, NULL); } -// 1784 "parser.c" +// 1805 "parser.c" break; case 12: - case 136: -// 626 "parser.lemon" + case 140: +// 627 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_STARALL, NULL, NULL, NULL); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_STARALL, NULL, NULL, NULL); pp_destructor(17,&ppmsp[0].minor); } -// 1793 "parser.c" +// 1814 "parser.c" break; case 13: -// 630 "parser.lemon" +// 631 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_DOMAINALL, NULL, ppmsp[-2].minor.pp0, NULL); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_DOMAINALL, NULL, ppmsp[-2].minor.pp0, NULL); pp_destructor(31,&ppmsp[-1].minor); pp_destructor(17,&ppmsp[0].minor); } -// 1802 "parser.c" +// 1823 "parser.c" break; case 14: -// 634 "parser.lemon" +// 635 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-2].minor.pp244, NULL, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-2].minor.pp162, NULL, ppmsp[0].minor.pp0); pp_destructor(32,&ppmsp[-1].minor); } -// 1810 "parser.c" +// 1831 "parser.c" break; case 15: -// 638 "parser.lemon" +// 639 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-1].minor.pp244, NULL, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-1].minor.pp162, NULL, ppmsp[0].minor.pp0); } -// 1817 "parser.c" +// 1838 "parser.c" break; case 16: -// 642 "parser.lemon" +// 643 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[0].minor.pp244, NULL, NULL); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[0].minor.pp162, NULL, NULL); } -// 1824 "parser.c" +// 1845 "parser.c" break; case 21: -// 664 "parser.lemon" + case 128: +// 667 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; - pp_destructor(33,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_zval_list(ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1832 "parser.c" +// 1853 "parser.c" + break; + case 24: +// 684 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_join_item(ppmsp[-3].minor.pp162, ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); +} +// 1860 "parser.c" + break; + case 25: +// 690 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); + pp_destructor(32,&ppmsp[-1].minor); +} +// 1868 "parser.c" break; - case 23: case 26: - case 124: -// 674 "parser.lemon" + case 46: + case 66: + case 160: +// 694 "parser.lemon" { - ppgotominor.pp244 = phql_ret_zval_list(ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); } -// 1841 "parser.c" +// 1878 "parser.c" break; case 28: - case 31: - case 51: - case 156: -// 700 "parser.lemon" +// 704 "parser.lemon" { - ppgotominor.pp244 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_INNERJOIN); + pp_destructor(33,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1851 "parser.c" +// 1887 "parser.c" break; case 29: -// 707 "parser.lemon" +// 708 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_item(ppmsp[-3].minor.pp244, ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_CROSSJOIN); + pp_destructor(35,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1858 "parser.c" +// 1896 "parser.c" break; case 30: -// 713 "parser.lemon" +// 712 "parser.lemon" { - ppgotominor.pp244 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); - pp_destructor(32,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_LEFTJOIN); + pp_destructor(36,&ppmsp[-2].minor); + pp_destructor(37,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1866 "parser.c" +// 1906 "parser.c" break; - case 33: -// 727 "parser.lemon" + case 31: +// 716 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_INNERJOIN); - pp_destructor(34,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_LEFTJOIN); + pp_destructor(36,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1875 "parser.c" +// 1915 "parser.c" break; - case 34: -// 731 "parser.lemon" + case 32: +// 720 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_CROSSJOIN); - pp_destructor(36,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_RIGHTJOIN); + pp_destructor(38,&ppmsp[-2].minor); + pp_destructor(37,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1884 "parser.c" +// 1925 "parser.c" break; - case 35: -// 735 "parser.lemon" + case 33: +// 724 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_LEFTJOIN); - pp_destructor(37,&ppmsp[-2].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_RIGHTJOIN); pp_destructor(38,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1894 "parser.c" +// 1934 "parser.c" break; - case 36: -// 739 "parser.lemon" + case 34: +// 728 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_LEFTJOIN); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_FULLJOIN); + pp_destructor(39,&ppmsp[-2].minor); pp_destructor(37,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1903 "parser.c" +// 1944 "parser.c" break; - case 37: -// 743 "parser.lemon" + case 35: +// 732 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_RIGHTJOIN); - pp_destructor(39,&ppmsp[-2].minor); - pp_destructor(38,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_FULLJOIN); + pp_destructor(39,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1913 "parser.c" +// 1953 "parser.c" break; - case 38: -// 747 "parser.lemon" + case 36: +// 736 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_RIGHTJOIN); - pp_destructor(39,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_INNERJOIN); + pp_destructor(34,&ppmsp[0].minor); } -// 1922 "parser.c" +// 1961 "parser.c" break; - case 39: -// 751 "parser.lemon" + case 37: +// 742 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_FULLJOIN); - pp_destructor(40,&ppmsp[-2].minor); - pp_destructor(38,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = ppmsp[0].minor.pp162; + pp_destructor(40,&ppmsp[-1].minor); } -// 1932 "parser.c" +// 1969 "parser.c" + break; + case 39: +// 753 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_insert_statement(ppmsp[-4].minor.pp162, NULL, ppmsp[-1].minor.pp162); + pp_destructor(41,&ppmsp[-6].minor); + pp_destructor(42,&ppmsp[-5].minor); + pp_destructor(43,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); +} +// 1981 "parser.c" break; case 40: -// 755 "parser.lemon" +// 757 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_FULLJOIN); - pp_destructor(40,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_insert_statement(ppmsp[-7].minor.pp162, ppmsp[-5].minor.pp162, ppmsp[-1].minor.pp162); + pp_destructor(41,&ppmsp[-9].minor); + pp_destructor(42,&ppmsp[-8].minor); + pp_destructor(44,&ppmsp[-6].minor); + pp_destructor(45,&ppmsp[-4].minor); + pp_destructor(43,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 1941 "parser.c" +// 1995 "parser.c" break; - case 41: -// 759 "parser.lemon" + case 47: +// 795 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_INNERJOIN); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_update_statement(ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1949 "parser.c" +// 2002 "parser.c" break; - case 42: -// 765 "parser.lemon" + case 48: +// 801 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; - pp_destructor(41,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_update_clause(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); + pp_destructor(46,&ppmsp[-3].minor); + pp_destructor(47,&ppmsp[-1].minor); } -// 1957 "parser.c" +// 2011 "parser.c" break; - case 44: -// 776 "parser.lemon" + case 51: +// 817 "parser.lemon" { - ppgotominor.pp244 = phql_ret_insert_statement(ppmsp[-4].minor.pp244, NULL, ppmsp[-1].minor.pp244); - pp_destructor(42,&ppmsp[-6].minor); - pp_destructor(43,&ppmsp[-5].minor); - pp_destructor(44,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_update_item(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); + pp_destructor(3,&ppmsp[-1].minor); } -// 1969 "parser.c" +// 2019 "parser.c" break; - case 45: -// 780 "parser.lemon" + case 53: +// 829 "parser.lemon" { - ppgotominor.pp244 = phql_ret_insert_statement(ppmsp[-7].minor.pp244, ppmsp[-5].minor.pp244, ppmsp[-1].minor.pp244); - pp_destructor(42,&ppmsp[-9].minor); - pp_destructor(43,&ppmsp[-8].minor); - pp_destructor(45,&ppmsp[-6].minor); - pp_destructor(46,&ppmsp[-4].minor); - pp_destructor(44,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_delete_statement(ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1983 "parser.c" +// 2026 "parser.c" break; - case 52: -// 818 "parser.lemon" + case 54: +// 835 "parser.lemon" { - ppgotominor.pp244 = phql_ret_update_statement(ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_delete_clause(ppmsp[0].minor.pp162); + pp_destructor(48,&ppmsp[-2].minor); + pp_destructor(27,&ppmsp[-1].minor); } -// 1990 "parser.c" +// 2035 "parser.c" break; - case 53: -// 824 "parser.lemon" + case 55: +// 841 "parser.lemon" { - ppgotominor.pp244 = phql_ret_update_clause(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); - pp_destructor(47,&ppmsp[-3].minor); - pp_destructor(48,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp0, NULL); + pp_destructor(32,&ppmsp[-1].minor); } -// 1999 "parser.c" +// 2043 "parser.c" break; case 56: -// 840 "parser.lemon" +// 845 "parser.lemon" { - ppgotominor.pp244 = phql_ret_update_item(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); - pp_destructor(3,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-1].minor.pp162, ppmsp[0].minor.pp0, NULL); +} +// 2050 "parser.c" + break; + case 57: +// 849 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[0].minor.pp162, NULL, NULL); } -// 2007 "parser.c" +// 2057 "parser.c" break; case 58: -// 852 "parser.lemon" +// 853 "parser.lemon" { - ppgotominor.pp244 = phql_ret_delete_statement(ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-4].minor.pp162, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp162); + pp_destructor(32,&ppmsp[-3].minor); + pp_destructor(49,&ppmsp[-1].minor); } -// 2014 "parser.c" +// 2066 "parser.c" break; case 59: -// 858 "parser.lemon" +// 857 "parser.lemon" { - ppgotominor.pp244 = phql_ret_delete_clause(ppmsp[0].minor.pp244); - pp_destructor(49,&ppmsp[-2].minor); - pp_destructor(27,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-6].minor.pp162, ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp162); + pp_destructor(32,&ppmsp[-5].minor); + pp_destructor(49,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2023 "parser.c" +// 2077 "parser.c" break; case 60: -// 864 "parser.lemon" +// 861 "parser.lemon" { - ppgotominor.pp244 = phql_ret_assoc_name(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp0); - pp_destructor(32,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-5].minor.pp162, ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp162); + pp_destructor(49,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2031 "parser.c" +// 2087 "parser.c" break; case 61: -// 868 "parser.lemon" +// 865 "parser.lemon" { - ppgotominor.pp244 = phql_ret_assoc_name(ppmsp[-1].minor.pp244, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-3].minor.pp162, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp162); + pp_destructor(49,&ppmsp[-1].minor); } -// 2038 "parser.c" +// 2095 "parser.c" break; case 62: -// 872 "parser.lemon" +// 869 "parser.lemon" { - ppgotominor.pp244 = phql_ret_assoc_name(ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-4].minor.pp162, NULL, ppmsp[-1].minor.pp162); + pp_destructor(49,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2045 "parser.c" +// 2105 "parser.c" break; - case 64: -// 884 "parser.lemon" + case 63: +// 873 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-2].minor.pp162, NULL, ppmsp[0].minor.pp162); + pp_destructor(49,&ppmsp[-1].minor); +} +// 2113 "parser.c" + break; + case 68: +// 901 "parser.lemon" +{ + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(50,&ppmsp[-1].minor); } -// 2053 "parser.c" +// 2121 "parser.c" break; - case 66: -// 894 "parser.lemon" + case 70: +// 911 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(51,&ppmsp[-2].minor); pp_destructor(52,&ppmsp[-1].minor); } -// 2062 "parser.c" +// 2130 "parser.c" break; - case 70: -// 914 "parser.lemon" + case 74: +// 931 "parser.lemon" { - ppgotominor.pp244 = phql_ret_order_item(ppmsp[0].minor.pp244, 0); + ppgotominor.pp162 = phql_ret_order_item(ppmsp[0].minor.pp162, 0); } -// 2069 "parser.c" +// 2137 "parser.c" break; - case 71: -// 918 "parser.lemon" + case 75: +// 935 "parser.lemon" { - ppgotominor.pp244 = phql_ret_order_item(ppmsp[-1].minor.pp244, PHQL_T_ASC); + ppgotominor.pp162 = phql_ret_order_item(ppmsp[-1].minor.pp162, PHQL_T_ASC); pp_destructor(53,&ppmsp[0].minor); } -// 2077 "parser.c" +// 2145 "parser.c" break; - case 72: -// 922 "parser.lemon" + case 76: +// 939 "parser.lemon" { - ppgotominor.pp244 = phql_ret_order_item(ppmsp[-1].minor.pp244, PHQL_T_DESC); + ppgotominor.pp162 = phql_ret_order_item(ppmsp[-1].minor.pp162, PHQL_T_DESC); pp_destructor(54,&ppmsp[0].minor); } -// 2085 "parser.c" +// 2153 "parser.c" break; - case 73: -// 928 "parser.lemon" + case 77: +// 945 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(55,&ppmsp[-2].minor); pp_destructor(52,&ppmsp[-1].minor); } -// 2094 "parser.c" +// 2162 "parser.c" break; - case 78: -// 954 "parser.lemon" + case 82: +// 971 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(56,&ppmsp[-1].minor); } -// 2102 "parser.c" +// 2170 "parser.c" break; - case 80: -// 964 "parser.lemon" + case 84: +// 981 "parser.lemon" { - ppgotominor.pp244 = phql_ret_for_update_clause(); + ppgotominor.pp162 = phql_ret_for_update_clause(); pp_destructor(57,&ppmsp[-1].minor); - pp_destructor(47,&ppmsp[0].minor); + pp_destructor(46,&ppmsp[0].minor); } -// 2111 "parser.c" +// 2179 "parser.c" break; - case 82: case 86: -// 974 "parser.lemon" + case 90: +// 991 "parser.lemon" { - ppgotominor.pp244 = phql_ret_limit_clause(ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_limit_clause(ppmsp[0].minor.pp162, NULL); pp_destructor(58,&ppmsp[-1].minor); } -// 2120 "parser.c" +// 2188 "parser.c" break; - case 83: -// 978 "parser.lemon" + case 87: +// 995 "parser.lemon" { - ppgotominor.pp244 = phql_ret_limit_clause(ppmsp[0].minor.pp244, ppmsp[-2].minor.pp244); + ppgotominor.pp162 = phql_ret_limit_clause(ppmsp[0].minor.pp162, ppmsp[-2].minor.pp162); pp_destructor(58,&ppmsp[-3].minor); pp_destructor(25,&ppmsp[-1].minor); } -// 2129 "parser.c" +// 2197 "parser.c" break; - case 84: -// 982 "parser.lemon" + case 88: +// 999 "parser.lemon" { - ppgotominor.pp244 = phql_ret_limit_clause(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_limit_clause(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(58,&ppmsp[-3].minor); pp_destructor(59,&ppmsp[-1].minor); } -// 2138 "parser.c" +// 2206 "parser.c" break; - case 88: - case 145: -// 1000 "parser.lemon" + case 92: + case 149: +// 1017 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_INTEGER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_INTEGER, ppmsp[0].minor.pp0); } -// 2146 "parser.c" +// 2214 "parser.c" break; - case 89: - case 146: -// 1004 "parser.lemon" + case 93: + case 150: +// 1021 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_HINTEGER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_HINTEGER, ppmsp[0].minor.pp0); } -// 2154 "parser.c" +// 2222 "parser.c" break; - case 90: - case 152: -// 1008 "parser.lemon" + case 94: + case 156: +// 1025 "parser.lemon" { - ppgotominor.pp244 = phql_ret_placeholder_zval(PHQL_T_NPLACEHOLDER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_placeholder_zval(PHQL_T_NPLACEHOLDER, ppmsp[0].minor.pp0); } -// 2162 "parser.c" +// 2230 "parser.c" break; - case 91: - case 153: -// 1012 "parser.lemon" + case 95: + case 157: +// 1029 "parser.lemon" { - ppgotominor.pp244 = phql_ret_placeholder_zval(PHQL_T_SPLACEHOLDER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_placeholder_zval(PHQL_T_SPLACEHOLDER, ppmsp[0].minor.pp0); } -// 2170 "parser.c" +// 2238 "parser.c" break; - case 92: - case 154: -// 1016 "parser.lemon" + case 96: + case 158: +// 1033 "parser.lemon" { - ppgotominor.pp244 = phql_ret_placeholder_zval(PHQL_T_BPLACEHOLDER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_placeholder_zval(PHQL_T_BPLACEHOLDER, ppmsp[0].minor.pp0); } -// 2178 "parser.c" +// 2246 "parser.c" break; - case 93: -// 1022 "parser.lemon" + case 97: +// 1039 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_MINUS, NULL, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_MINUS, NULL, ppmsp[0].minor.pp162); pp_destructor(20,&ppmsp[-1].minor); } -// 2186 "parser.c" +// 2254 "parser.c" break; - case 94: -// 1026 "parser.lemon" + case 98: +// 1043 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_SUB, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_SUB, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(20,&ppmsp[-1].minor); } -// 2194 "parser.c" +// 2262 "parser.c" break; - case 95: -// 1030 "parser.lemon" + case 99: +// 1047 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ADD, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ADD, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(19,&ppmsp[-1].minor); } -// 2202 "parser.c" +// 2270 "parser.c" break; - case 96: -// 1034 "parser.lemon" + case 100: +// 1051 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_MUL, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_MUL, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(17,&ppmsp[-1].minor); } -// 2210 "parser.c" +// 2278 "parser.c" break; - case 97: -// 1038 "parser.lemon" + case 101: +// 1055 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_DIV, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_DIV, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(16,&ppmsp[-1].minor); } -// 2218 "parser.c" +// 2286 "parser.c" break; - case 98: -// 1042 "parser.lemon" + case 102: +// 1059 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_MOD, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_MOD, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(18,&ppmsp[-1].minor); } -// 2226 "parser.c" +// 2294 "parser.c" break; - case 99: -// 1046 "parser.lemon" + case 103: +// 1063 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_AND, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_AND, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(9,&ppmsp[-1].minor); } -// 2234 "parser.c" +// 2302 "parser.c" break; - case 100: -// 1050 "parser.lemon" + case 104: +// 1067 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_OR, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_OR, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(10,&ppmsp[-1].minor); } -// 2242 "parser.c" +// 2310 "parser.c" break; - case 101: -// 1054 "parser.lemon" + case 105: +// 1071 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_AND, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_AND, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(13,&ppmsp[-1].minor); } -// 2250 "parser.c" +// 2318 "parser.c" break; - case 102: -// 1058 "parser.lemon" + case 106: +// 1075 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_OR, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_OR, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(14,&ppmsp[-1].minor); } -// 2258 "parser.c" +// 2326 "parser.c" break; - case 103: -// 1062 "parser.lemon" + case 107: +// 1079 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_XOR, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_XOR, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(15,&ppmsp[-1].minor); } -// 2266 "parser.c" +// 2334 "parser.c" break; - case 104: -// 1066 "parser.lemon" + case 108: +// 1083 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_EQUALS, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_EQUALS, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(3,&ppmsp[-1].minor); } -// 2274 "parser.c" +// 2342 "parser.c" break; - case 105: -// 1070 "parser.lemon" + case 109: +// 1087 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NOTEQUALS, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NOTEQUALS, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(4,&ppmsp[-1].minor); } -// 2282 "parser.c" +// 2350 "parser.c" break; - case 106: -// 1074 "parser.lemon" + case 110: +// 1091 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_LESS, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_LESS, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(5,&ppmsp[-1].minor); } -// 2290 "parser.c" +// 2358 "parser.c" break; - case 107: -// 1078 "parser.lemon" + case 111: +// 1095 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_GREATER, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_GREATER, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(6,&ppmsp[-1].minor); } -// 2298 "parser.c" +// 2366 "parser.c" break; - case 108: -// 1082 "parser.lemon" + case 112: +// 1099 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_GREATEREQUAL, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_GREATEREQUAL, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(7,&ppmsp[-1].minor); } -// 2306 "parser.c" +// 2374 "parser.c" break; - case 109: -// 1086 "parser.lemon" + case 113: +// 1103 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_LESSEQUAL, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_LESSEQUAL, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(8,&ppmsp[-1].minor); } -// 2314 "parser.c" +// 2382 "parser.c" break; - case 110: -// 1090 "parser.lemon" + case 114: +// 1107 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_LIKE, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_LIKE, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(11,&ppmsp[-1].minor); } -// 2322 "parser.c" +// 2390 "parser.c" break; - case 111: -// 1094 "parser.lemon" + case 115: +// 1111 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NLIKE, ppmsp[-3].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NLIKE, ppmsp[-3].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(23,&ppmsp[-2].minor); pp_destructor(11,&ppmsp[-1].minor); } -// 2331 "parser.c" +// 2399 "parser.c" break; - case 112: -// 1098 "parser.lemon" + case 116: +// 1115 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ILIKE, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ILIKE, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(12,&ppmsp[-1].minor); } -// 2339 "parser.c" +// 2407 "parser.c" break; - case 113: -// 1102 "parser.lemon" + case 117: +// 1119 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NILIKE, ppmsp[-3].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NILIKE, ppmsp[-3].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(23,&ppmsp[-2].minor); pp_destructor(12,&ppmsp[-1].minor); } -// 2348 "parser.c" +// 2416 "parser.c" break; - case 114: - case 117: -// 1106 "parser.lemon" + case 118: + case 121: +// 1123 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_IN, ppmsp[-4].minor.pp244, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_IN, ppmsp[-4].minor.pp162, ppmsp[-1].minor.pp162); pp_destructor(22,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2359 "parser.c" +// 2427 "parser.c" break; - case 115: - case 118: -// 1110 "parser.lemon" + case 119: + case 122: +// 1127 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NOTIN, ppmsp[-5].minor.pp244, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NOTIN, ppmsp[-5].minor.pp162, ppmsp[-1].minor.pp162); pp_destructor(23,&ppmsp[-4].minor); pp_destructor(22,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2371 "parser.c" +// 2439 "parser.c" break; - case 116: -// 1114 "parser.lemon" + case 120: +// 1131 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_SUBQUERY, ppmsp[-1].minor.pp244, NULL); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_SUBQUERY, ppmsp[-1].minor.pp162, NULL); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2380 "parser.c" +// 2448 "parser.c" break; - case 119: -// 1126 "parser.lemon" + case 123: +// 1143 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_EXISTS, NULL, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_EXISTS, NULL, ppmsp[-1].minor.pp162); pp_destructor(65,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2390 "parser.c" +// 2458 "parser.c" break; - case 120: -// 1130 "parser.lemon" + case 124: +// 1147 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_AGAINST, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_AGAINST, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(1,&ppmsp[-1].minor); } -// 2398 "parser.c" +// 2466 "parser.c" break; - case 121: -// 1134 "parser.lemon" + case 125: +// 1151 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_CAST, ppmsp[-3].minor.pp244, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_CAST, ppmsp[-3].minor.pp162, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); pp_destructor(66,&ppmsp[-5].minor); - pp_destructor(45,&ppmsp[-4].minor); + pp_destructor(44,&ppmsp[-4].minor); pp_destructor(32,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2409 "parser.c" +// 2477 "parser.c" break; - case 122: -// 1138 "parser.lemon" + case 126: +// 1155 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_CONVERT, ppmsp[-3].minor.pp244, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_CONVERT, ppmsp[-3].minor.pp162, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); pp_destructor(67,&ppmsp[-5].minor); - pp_destructor(45,&ppmsp[-4].minor); + pp_destructor(44,&ppmsp[-4].minor); pp_destructor(68,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2420 "parser.c" +// 2488 "parser.c" break; - case 123: -// 1142 "parser.lemon" + case 127: +// 1159 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_CASE, ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_CASE, ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162); pp_destructor(69,&ppmsp[-3].minor); pp_destructor(70,&ppmsp[0].minor); } -// 2429 "parser.c" +// 2497 "parser.c" break; - case 126: -// 1154 "parser.lemon" + case 130: +// 1171 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_WHEN, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_WHEN, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(71,&ppmsp[-3].minor); pp_destructor(72,&ppmsp[-1].minor); } -// 2438 "parser.c" +// 2506 "parser.c" break; - case 127: -// 1158 "parser.lemon" + case 131: +// 1175 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ELSE, ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ELSE, ppmsp[0].minor.pp162, NULL); pp_destructor(73,&ppmsp[-1].minor); } -// 2446 "parser.c" +// 2514 "parser.c" break; - case 129: -// 1168 "parser.lemon" + case 133: +// 1185 "parser.lemon" { - ppgotominor.pp244 = phql_ret_func_call(ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp244, ppmsp[-2].minor.pp244); - pp_destructor(45,&ppmsp[-3].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_func_call(ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp162, ppmsp[-2].minor.pp162); + pp_destructor(44,&ppmsp[-3].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2455 "parser.c" +// 2523 "parser.c" break; - case 130: -// 1174 "parser.lemon" + case 134: +// 1191 "parser.lemon" { - ppgotominor.pp244 = phql_ret_distinct(); + ppgotominor.pp162 = phql_ret_distinct(); pp_destructor(28,&ppmsp[0].minor); } -// 2463 "parser.c" +// 2531 "parser.c" break; - case 138: -// 1212 "parser.lemon" + case 142: +// 1229 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ISNULL, ppmsp[-2].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ISNULL, ppmsp[-2].minor.pp162, NULL); pp_destructor(21,&ppmsp[-1].minor); pp_destructor(74,&ppmsp[0].minor); } -// 2472 "parser.c" +// 2540 "parser.c" break; - case 139: -// 1216 "parser.lemon" + case 143: +// 1233 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ISNOTNULL, ppmsp[-3].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ISNOTNULL, ppmsp[-3].minor.pp162, NULL); pp_destructor(21,&ppmsp[-2].minor); pp_destructor(23,&ppmsp[-1].minor); pp_destructor(74,&ppmsp[0].minor); } -// 2482 "parser.c" +// 2550 "parser.c" break; - case 140: -// 1220 "parser.lemon" + case 144: +// 1237 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BETWEEN, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BETWEEN, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(2,&ppmsp[-1].minor); } -// 2490 "parser.c" +// 2558 "parser.c" break; - case 141: -// 1224 "parser.lemon" + case 145: +// 1241 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NOT, NULL, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NOT, NULL, ppmsp[0].minor.pp162); pp_destructor(23,&ppmsp[-1].minor); } -// 2498 "parser.c" +// 2566 "parser.c" break; - case 142: -// 1228 "parser.lemon" + case 146: +// 1245 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_NOT, NULL, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_NOT, NULL, ppmsp[0].minor.pp162); pp_destructor(24,&ppmsp[-1].minor); } -// 2506 "parser.c" +// 2574 "parser.c" break; - case 143: -// 1232 "parser.lemon" + case 147: +// 1249 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ENCLOSED, ppmsp[-1].minor.pp244, NULL); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ENCLOSED, ppmsp[-1].minor.pp162, NULL); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2515 "parser.c" +// 2583 "parser.c" break; - case 147: -// 1248 "parser.lemon" + case 151: +// 1265 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_STRING, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_STRING, ppmsp[0].minor.pp0); } -// 2522 "parser.c" +// 2590 "parser.c" break; - case 148: -// 1252 "parser.lemon" + case 152: +// 1269 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_DOUBLE, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_DOUBLE, ppmsp[0].minor.pp0); } -// 2529 "parser.c" +// 2597 "parser.c" break; - case 149: -// 1256 "parser.lemon" + case 153: +// 1273 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_NULL, NULL); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_NULL, NULL); pp_destructor(74,&ppmsp[0].minor); } -// 2537 "parser.c" +// 2605 "parser.c" break; - case 150: -// 1260 "parser.lemon" + case 154: +// 1277 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_TRUE, NULL); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_TRUE, NULL); pp_destructor(77,&ppmsp[0].minor); } -// 2545 "parser.c" +// 2613 "parser.c" break; - case 151: -// 1264 "parser.lemon" + case 155: +// 1281 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_FALSE, NULL); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_FALSE, NULL); pp_destructor(78,&ppmsp[0].minor); } -// 2553 "parser.c" +// 2621 "parser.c" break; - case 155: -// 1285 "parser.lemon" + case 159: +// 1302 "parser.lemon" { - ppgotominor.pp244 = phql_ret_qualified_name(NULL, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_qualified_name(NULL, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp0); pp_destructor(31,&ppmsp[-1].minor); } -// 2561 "parser.c" +// 2629 "parser.c" break; }; ppgoto = ppRuleInfo[ppruleno].lhs; @@ -103591,7 +104323,7 @@ static void pp_syntax_error( ){ phql_ARG_FETCH; #define PPTOKEN (ppminor.pp0) -// 490 "parser.lemon" +// 491 "parser.lemon" if (status->scanner_state->start_length) { { @@ -103658,7 +104390,7 @@ static void pp_syntax_error( status->status = PHQL_PARSING_FAILED; -// 2670 "parser.c" +// 2738 "parser.c" phql_ARG_STORE; /* Suppress warning about unused %extra_argument variable */ } @@ -104418,7 +105150,7 @@ static int phql_internal_parse_phql(zval **result, char *phql, unsigned int phql } -/* Generated by re2c 0.13.6 on Mon Jul 6 13:03:04 2015 */ +/* Generated by re2c 0.13.6 on Wed Aug 5 14:30:06 2015 */ // 1 "scanner.re" @@ -110837,7 +111569,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, __construct) { zephir_update_property_this(this_ptr, SL("_columnTypes"), columnTypes TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 357, result, cache); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 350, result, cache); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -110845,12 +111577,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, __construct) { static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { - zephir_fcall_cache_entry *_12 = NULL, *_14 = NULL; - zend_class_entry *_11; - HashTable *_2, *_5; - HashPosition _1, _4; + zephir_fcall_cache_entry *_13 = NULL, *_15 = NULL; + zend_class_entry *_12; + HashTable *_3, *_6; + HashPosition _2, _5; int dirtyState, ZEPHIR_LAST_CALL_STATUS; - zval *row, *hydrateMode, *alias = NULL, *activeRow = NULL, *type = NULL, *columnTypes, *column = NULL, *columnValue = NULL, *value = NULL, *attribute = NULL, *source = NULL, *attributes = NULL, *columnMap = NULL, *rowModel = NULL, *keepSnapshots = NULL, *sqlAlias = NULL, *modelName = NULL, *_0, **_3, **_6, *_7 = NULL, *_8 = NULL, *_9, *_10 = NULL, *_13, _15 = zval_used_for_init, _16 = zval_used_for_init; + zval *row, *hydrateMode, *eager, *alias = NULL, *activeRow = NULL, *type = NULL, *column = NULL, *columnValue = NULL, *value = NULL, *attribute = NULL, *source = NULL, *attributes = NULL, *columnMap = NULL, *rowModel = NULL, *keepSnapshots = NULL, *sqlAlias = NULL, *modelName = NULL, *_0, *_1, **_4, **_7, *_8 = NULL, *_9 = NULL, *_10, *_11 = NULL, *_14, _16 = zval_used_for_init, _17 = zval_used_for_init; ZEPHIR_MM_GROW(); @@ -110892,41 +111624,40 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { break; } while(0); - ZEPHIR_OBS_VAR(columnTypes); - zephir_read_property_this(&columnTypes, this_ptr, SL("_columnTypes"), PH_NOISY_CC); dirtyState = 0; - zephir_is_iterable(columnTypes, &_2, &_1, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 245); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_columnTypes"), PH_NOISY_CC); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 246); for ( - ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS - ; zephir_hash_move_forward_ex(_2, &_1) + ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS + ; zephir_hash_move_forward_ex(_3, &_2) ) { - ZEPHIR_GET_HMKEY(alias, _2, _1); - ZEPHIR_GET_HVALUE(column, _3); + ZEPHIR_GET_HMKEY(alias, _3, _2); + ZEPHIR_GET_HVALUE(column, _4); if (Z_TYPE_P(column) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Column type is corrupt", "phalcon/mvc/model/resultset/complex.zep", 135); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Column type is corrupt", "phalcon/mvc/model/resultset/complex.zep", 133); return; } ZEPHIR_OBS_NVAR(type); - zephir_array_fetch_string(&type, column, SL("type"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 138 TSRMLS_CC); + zephir_array_fetch_string(&type, column, SL("type"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 136 TSRMLS_CC); if (ZEPHIR_IS_STRING(type, "object")) { ZEPHIR_OBS_NVAR(source); - zephir_array_fetch_string(&source, column, SL("column"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 144 TSRMLS_CC); + zephir_array_fetch_string(&source, column, SL("column"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 142 TSRMLS_CC); ZEPHIR_OBS_NVAR(attributes); - zephir_array_fetch_string(&attributes, column, SL("attributes"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 145 TSRMLS_CC); + zephir_array_fetch_string(&attributes, column, SL("attributes"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 143 TSRMLS_CC); ZEPHIR_OBS_NVAR(columnMap); - zephir_array_fetch_string(&columnMap, column, SL("columnMap"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 146 TSRMLS_CC); + zephir_array_fetch_string(&columnMap, column, SL("columnMap"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 144 TSRMLS_CC); ZEPHIR_INIT_NVAR(rowModel); array_init(rowModel); - zephir_is_iterable(attributes, &_5, &_4, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 164); + zephir_is_iterable(attributes, &_6, &_5, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 162); for ( - ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS - ; zephir_hash_move_forward_ex(_5, &_4) + ; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS + ; zephir_hash_move_forward_ex(_6, &_5) ) { - ZEPHIR_GET_HVALUE(attribute, _6); + ZEPHIR_GET_HVALUE(attribute, _7); ZEPHIR_OBS_NVAR(columnValue); - ZEPHIR_INIT_LNVAR(_7); - ZEPHIR_CONCAT_SVSV(_7, "_", source, "_", attribute); - zephir_array_fetch(&columnValue, row, _7, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 157 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_8); + ZEPHIR_CONCAT_SVSV(_8, "_", source, "_", attribute); + zephir_array_fetch(&columnValue, row, _8, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 155 TSRMLS_CC); zephir_array_update_zval(&rowModel, attribute, &columnValue, PH_COPY | PH_SEPARATE); } do { @@ -110937,43 +111668,43 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { ZVAL_BOOL(keepSnapshots, 0); } if (ZEPHIR_GLOBAL(orm).late_state_binding) { - ZEPHIR_OBS_NVAR(_8); - zephir_array_fetch_string(&_8, column, SL("instance"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 175 TSRMLS_CC); - if (zephir_instance_of_ev(_8, phalcon_mvc_model_ce TSRMLS_CC)) { - zephir_array_fetch_string(&_9, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 176 TSRMLS_CC); + ZEPHIR_OBS_NVAR(_9); + zephir_array_fetch_string(&_9, column, SL("instance"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 173 TSRMLS_CC); + if (zephir_instance_of_ev(_9, phalcon_mvc_model_ce TSRMLS_CC)) { + zephir_array_fetch_string(&_10, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 174 TSRMLS_CC); ZEPHIR_INIT_NVAR(modelName); - zephir_get_class(modelName, _9, 0 TSRMLS_CC); + zephir_get_class(modelName, _10, 0 TSRMLS_CC); } else { ZEPHIR_INIT_NVAR(modelName); ZVAL_STRING(modelName, "Phalcon\\Mvc\\Model", 1); } - zephir_array_fetch_string(&_9, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 182 TSRMLS_CC); - ZEPHIR_INIT_NVAR(_10); - ZVAL_LONG(_10, dirtyState); - _11 = zephir_fetch_class(modelName TSRMLS_CC); - ZEPHIR_CALL_CE_STATIC(&value, _11, "cloneresultmap", NULL, 0, _9, rowModel, columnMap, _10, keepSnapshots); + zephir_array_fetch_string(&_10, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 180 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_11); + ZVAL_LONG(_11, dirtyState); + _12 = zephir_fetch_class(modelName TSRMLS_CC); + ZEPHIR_CALL_CE_STATIC(&value, _12, "cloneresultmap", NULL, 0, _10, rowModel, columnMap, _11, keepSnapshots); zephir_check_call_status(); } else { - zephir_array_fetch_string(&_13, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 190 TSRMLS_CC); - ZEPHIR_INIT_NVAR(_10); - ZVAL_LONG(_10, dirtyState); - ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmap", &_12, 0, _13, rowModel, columnMap, _10, keepSnapshots); + zephir_array_fetch_string(&_14, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 188 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_11); + ZVAL_LONG(_11, dirtyState); + ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmap", &_13, 0, _14, rowModel, columnMap, _11, keepSnapshots); zephir_check_call_status(); } break; } - ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_14, 0, rowModel, columnMap, hydrateMode); + ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_15, 0, rowModel, columnMap, hydrateMode); zephir_check_call_status(); break; } while(0); ZEPHIR_OBS_NVAR(attribute); - zephir_array_fetch_string(&attribute, column, SL("balias"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 204 TSRMLS_CC); + zephir_array_fetch_string(&attribute, column, SL("balias"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 202 TSRMLS_CC); } else { ZEPHIR_OBS_NVAR(sqlAlias); if (zephir_array_isset_string_fetch(&sqlAlias, column, SS("sqlAlias"), 0 TSRMLS_CC)) { ZEPHIR_OBS_NVAR(value); - zephir_array_fetch(&value, row, sqlAlias, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 212 TSRMLS_CC); + zephir_array_fetch(&value, row, sqlAlias, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 210 TSRMLS_CC); } else { ZEPHIR_OBS_NVAR(value); zephir_array_isset_fetch(&value, row, alias, 0 TSRMLS_CC); @@ -110981,23 +111712,25 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { if (zephir_array_isset_string(column, SS("balias"))) { ZEPHIR_CPY_WRT(attribute, alias); } else { - ZEPHIR_SINIT_NVAR(_15); - ZVAL_STRING(&_15, "_", 0); ZEPHIR_SINIT_NVAR(_16); - ZVAL_STRING(&_16, "", 0); + ZVAL_STRING(&_16, "_", 0); + ZEPHIR_SINIT_NVAR(_17); + ZVAL_STRING(&_17, "", 0); ZEPHIR_INIT_NVAR(attribute); - zephir_fast_str_replace(&attribute, &_15, &_16, alias TSRMLS_CC); + zephir_fast_str_replace(&attribute, &_16, &_17, alias TSRMLS_CC); } } - do { - if (ZEPHIR_IS_LONG(hydrateMode, 1)) { - zephir_array_update_zval(&activeRow, attribute, &value, PH_COPY | PH_SEPARATE); + if (!(zephir_array_isset_string_fetch(&eager, column, SS("eager"), 1 TSRMLS_CC))) { + do { + if (ZEPHIR_IS_LONG(hydrateMode, 1)) { + zephir_array_update_zval(&activeRow, attribute, &value, PH_COPY | PH_SEPARATE); + break; + } + zephir_update_property_zval_zval(activeRow, attribute, value TSRMLS_CC); break; - } - zephir_update_property_zval_zval(activeRow, attribute, value TSRMLS_CC); - break; - } while(0); + } while(0); + } } zephir_update_property_this(this_ptr, SL("_activeRow"), activeRow TSRMLS_CC); RETURN_CCTOR(activeRow); @@ -111021,7 +111754,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, toArray) { _0->funcs->get_current_data(_0, &ZEPHIR_TMP_ITERATOR_PTR TSRMLS_CC); ZEPHIR_CPY_WRT(current, (*ZEPHIR_TMP_ITERATOR_PTR)); } - zephir_array_append(&records, current, PH_SEPARATE, "phalcon/mvc/model/resultset/complex.zep", 258); + zephir_array_append(&records, current, PH_SEPARATE, "phalcon/mvc/model/resultset/complex.zep", 259); } _0->funcs->dtor(_0 TSRMLS_CC); RETURN_CCTOR(records); @@ -111050,7 +111783,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, serialize) { zephir_array_update_string(&_0, SL("rows"), &records, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_0, SL("columnTypes"), &columnTypes, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_0, SL("hydrateMode"), &hydrateMode, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 71, _0); + ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_CCTOR(serialized); @@ -111079,23 +111812,23 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, unserialize) { zephir_update_property_this(this_ptr, SL("_disableHydration"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(resultset) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/complex.zep", 303); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/complex.zep", 304); return; } - zephir_array_fetch_string(&_0, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 306 TSRMLS_CC); + zephir_array_fetch_string(&_0, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 307 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_rows"), _0 TSRMLS_CC); - zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 307 TSRMLS_CC); + zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 308 TSRMLS_CC); ZEPHIR_INIT_ZVAL_NREF(_2); ZVAL_LONG(_2, zephir_fast_count_int(_1 TSRMLS_CC)); zephir_update_property_this(this_ptr, SL("_count"), _2 TSRMLS_CC); - zephir_array_fetch_string(&_3, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 308 TSRMLS_CC); + zephir_array_fetch_string(&_3, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 309 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_cache"), _3 TSRMLS_CC); - zephir_array_fetch_string(&_4, resultset, SL("columnTypes"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 309 TSRMLS_CC); + zephir_array_fetch_string(&_4, resultset, SL("columnTypes"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 310 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_columnTypes"), _4 TSRMLS_CC); - zephir_array_fetch_string(&_5, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 310 TSRMLS_CC); + zephir_array_fetch_string(&_5, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 311 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_hydrateMode"), _5 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -111154,7 +111887,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, __construct) { zephir_update_property_this(this_ptr, SL("_model"), model TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_columnMap"), columnMap TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_keepSnapshots"), keepSnapshots TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 357, result, cache); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 350, result, cache); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -111209,12 +111942,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, current) { _6 = zephir_fetch_nproperty_this(this_ptr, SL("_keepSnapshots"), PH_NOISY_CC); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, 0); - ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 358, _2, row, columnMap, _3, _6); + ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 351, _2, row, columnMap, _3, _6); zephir_check_call_status(); } break; } - ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 359, row, columnMap, hydrateMode); + ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 352, row, columnMap, hydrateMode); zephir_check_call_status(); break; } while(0); @@ -111346,7 +112079,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, serialize) { ZEPHIR_OBS_NVAR(_1); zephir_read_property_this(&_1, this_ptr, SL("_hydrateMode"), PH_NOISY_CC); zephir_array_update_string(&_0, SL("hydrateMode"), &_1, PH_COPY | PH_SEPARATE); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -111374,7 +112107,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, unserialize) { } - ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(resultset) != IS_ARRAY) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/simple.zep", 252); @@ -111681,7 +112414,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, get) { ZEPHIR_INIT_VAR(_3); ZVAL_STRING(_3, "rollbackPendent", 1); zephir_array_fast_append(_2, _3); - ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 362, _2); + ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 355, _2); zephir_check_call_status(); } zephir_update_property_this(this_ptr, SL("_initialized"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); @@ -111740,9 +112473,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, getOrCreateTransaction) ZEPHIR_INIT_VAR(transaction); object_init_ex(transaction, phalcon_mvc_model_transaction_ce); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_service"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 363, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5); + ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 356, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 364, this_ptr); + ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 357, this_ptr); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_transactions"), transaction TSRMLS_CC); RETURN_ON_FAILURE(zephir_property_incr(this_ptr, SL("_number") TSRMLS_CC)); @@ -112030,7 +112763,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Email, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 274); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_0); @@ -112045,7 +112778,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Email, validate) { ZEPHIR_INIT_VAR(_5); zephir_create_array(_5, 1, 0 TSRMLS_CC); zephir_array_update_string(&_5, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, _5); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, _5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Email", ZEPHIR_TEMP_PARAM_COPY); @@ -112173,7 +112906,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Exclusionin, validate) { ZEPHIR_INIT_NVAR(_0); zephir_fast_join_str(_0, SL(", "), domain TSRMLS_CC); zephir_array_update_string(&_4, SL(":domain"), &_0, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Exclusion", ZEPHIR_TEMP_PARAM_COPY); @@ -112303,7 +113036,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Inclusionin, validate) { zephir_check_temp_parameter(_0); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 365, value, domain, strict); + ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 358, value, domain, strict); zephir_check_call_status(); if (!(zephir_is_true(_5))) { ZEPHIR_INIT_NVAR(_0); @@ -112321,7 +113054,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Inclusionin, validate) { ZEPHIR_INIT_NVAR(_0); zephir_fast_join_str(_0, SL(", "), domain TSRMLS_CC); zephir_array_update_string(&_6, SL(":domain"), &_0, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 53, message, _6); + ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 54, message, _6); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Inclusion", ZEPHIR_TEMP_PARAM_COPY); @@ -112449,7 +113182,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Ip, validate) { zephir_array_update_string(&options, SL("flags"), &_6, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, 275); - ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 191, value, &_5, options); + ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 192, value, &_5, options); zephir_check_call_status(); if (!(zephir_is_true(_7))) { ZEPHIR_INIT_NVAR(_0); @@ -112463,7 +113196,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Ip, validate) { ZEPHIR_INIT_NVAR(_4); zephir_create_array(_4, 1, 0 TSRMLS_CC); zephir_array_update_string(&_4, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "IP", ZEPHIR_TEMP_PARAM_COPY); @@ -112570,7 +113303,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Numericality, validate) { ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 1, 0 TSRMLS_CC); zephir_array_update_string(&_3, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, _3); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Numericality", ZEPHIR_TEMP_PARAM_COPY); @@ -112673,7 +113406,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_PresenceOf, validate) { ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 1, 0 TSRMLS_CC); zephir_array_update_string(&_3, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, _3); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "PresenceOf", ZEPHIR_TEMP_PARAM_COPY); @@ -112805,7 +113538,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Regex, validate) { ZEPHIR_INIT_VAR(_6); zephir_create_array(_6, 1, 0 TSRMLS_CC); zephir_array_update_string(&_6, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 53, message, _6); + ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 54, message, _6); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_5); ZVAL_STRING(_5, "Regex", ZEPHIR_TEMP_PARAM_COPY); @@ -112919,7 +113652,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) { RETURN_MM_BOOL(1); } if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value); + ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 359, value); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(length); @@ -112945,7 +113678,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) { zephir_create_array(_4, 2, 0 TSRMLS_CC); zephir_array_update_string(&_4, SL(":field"), &field, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL(":max"), &maximum, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "TooLong", ZEPHIR_TEMP_PARAM_COPY); @@ -112975,7 +113708,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) { zephir_create_array(_4, 2, 0 TSRMLS_CC); zephir_array_update_string(&_4, SL(":field"), &field, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL(":min"), &minimum, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "TooShort", ZEPHIR_TEMP_PARAM_COPY); @@ -113256,7 +113989,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) { ZVAL_STRING(message, "Value of field: ':field' is already present in another record", 1); } } - ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_18); ZVAL_STRING(_18, "Unique", ZEPHIR_TEMP_PARAM_COPY); @@ -113352,7 +114085,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Url, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 273); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_0); @@ -113367,7 +114100,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Url, validate) { ZEPHIR_INIT_VAR(_5); zephir_create_array(_5, 1, 0 TSRMLS_CC); zephir_array_update_string(&_5, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, _5); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, _5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Url", ZEPHIR_TEMP_PARAM_COPY); @@ -113687,7 +114420,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Annotations, handle) { } zephir_update_property_this(this_ptr, SL("_processed"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 367, realUri); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 360, realUri); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -113902,7 +114635,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Annotations, processActionAnnotation) { zephir_check_temp_parameter(_3); zephir_check_call_status(); if (Z_TYPE_P(converts) == IS_ARRAY) { - zephir_is_iterable(converts, &_5, &_4, 0, 0, "phalcon/mvc/router/annotations.zep", 360); + zephir_is_iterable(converts, &_5, &_4, 0, 0, "phalcon/mvc/router/annotations.zep", 354); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -113919,7 +114652,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Annotations, processActionAnnotation) { zephir_check_temp_parameter(_3); zephir_check_call_status(); if (Z_TYPE_P(converts) == IS_ARRAY) { - zephir_is_iterable(converts, &_9, &_8, 0, 0, "phalcon/mvc/router/annotations.zep", 370); + zephir_is_iterable(converts, &_9, &_8, 0, 0, "phalcon/mvc/router/annotations.zep", 364); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) @@ -114519,7 +115252,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Group, _addRoute) { zephir_read_property_this(&defaultPaths, this_ptr, SL("_paths"), PH_NOISY_CC); if (Z_TYPE_P(defaultPaths) == IS_ARRAY) { if (Z_TYPE_P(paths) == IS_STRING) { - ZEPHIR_CALL_CE_STATIC(&processedPaths, phalcon_mvc_router_route_ce, "getroutepaths", &_0, 75, paths); + ZEPHIR_CALL_CE_STATIC(&processedPaths, phalcon_mvc_router_route_ce, "getroutepaths", &_0, 77, paths); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(processedPaths, paths); @@ -114538,10 +115271,10 @@ static PHP_METHOD(Phalcon_Mvc_Router_Group, _addRoute) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_prefix"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_2); ZEPHIR_CONCAT_VV(_2, _1, pattern); - ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 74, _2, mergedPaths, httpMethods); + ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 76, _2, mergedPaths, httpMethods); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_routes"), route TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 368, this_ptr); + ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 361, this_ptr); zephir_check_call_status(); RETURN_CCTOR(route); @@ -116050,7 +116783,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, _loadTemplateEngines) { if (Z_TYPE_P(registeredEngines) != IS_ARRAY) { ZEPHIR_INIT_VAR(_0); object_init_ex(_0, phalcon_mvc_view_engine_php_ce); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 370, this_ptr, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 363, this_ptr, dependencyInjector); zephir_check_call_status(); zephir_array_update_string(&engines, SL(".phtml"), &_0, PH_COPY | PH_SEPARATE); } else { @@ -116289,7 +117022,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, render) { ZEPHIR_INIT_VAR(_1); zephir_create_symbol_table(TSRMLS_C); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_OBS_VAR(viewParams); zephir_read_property_this(&viewParams, this_ptr, SL("_viewParams"), PH_NOISY_CC); @@ -116303,7 +117036,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, render) { } else { ZEPHIR_CPY_WRT(mergedParams, viewParams); } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 389, path, mergedParams); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 382, path, mergedParams); zephir_check_call_status(); if (Z_TYPE_P(cache) == IS_OBJECT) { ZEPHIR_CALL_METHOD(&_0, cache, "isstarted", NULL, 0); @@ -116323,7 +117056,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, render) { zephir_check_call_status(); } } - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); RETURN_MM_MEMBER(this_ptr, "_content"); @@ -116354,7 +117087,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, partial) { } - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); if (Z_TYPE_P(params) == IS_ARRAY) { ZEPHIR_OBS_VAR(viewParams); @@ -116371,12 +117104,12 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, partial) { } else { ZEPHIR_CPY_WRT(mergedParams, params); } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 389, partialPath, mergedParams); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 382, partialPath, mergedParams); zephir_check_call_status(); if (Z_TYPE_P(params) == IS_ARRAY) { zephir_update_property_this(this_ptr, SL("_viewParams"), viewParams TSRMLS_CC); } - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_content"), PH_NOISY_CC); zend_print_zval(_1, 0); @@ -116755,7 +117488,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Php, render) { if (mustClean == 1) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371); + ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 364); zephir_check_call_status(); } if (Z_TYPE_P(params) == IS_ARRAY) { @@ -116777,7 +117510,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Php, render) { } if (mustClean == 1) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 117); + ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 119); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _4, "setcontent", NULL, 0, _5); zephir_check_call_status(); @@ -116850,18 +117583,18 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, getCompiler) { ZEPHIR_INIT_NVAR(compiler); object_init_ex(compiler, phalcon_mvc_view_engine_volt_compiler_ce); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 372, _0); + ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 365, _0); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _1); if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) { - ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 373, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 366, dependencyInjector); zephir_check_call_status(); } ZEPHIR_OBS_VAR(options); zephir_read_property_this(&options, this_ptr, SL("_options"), PH_NOISY_CC); if (Z_TYPE_P(options) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 374, options); + ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 367, options); zephir_check_call_status(); } zephir_update_property_this(this_ptr, SL("_compiler"), compiler TSRMLS_CC); @@ -116901,7 +117634,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) { if (mustClean) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371); + ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 364); zephir_check_call_status(); } ZEPHIR_CALL_METHOD(&compiler, this_ptr, "getcompiler", NULL, 0); @@ -116929,7 +117662,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) { } if (mustClean) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 117); + ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 119); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _4, "setcontent", NULL, 0, _5); zephir_check_call_status(); @@ -116960,7 +117693,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, length) { ZVAL_LONG(length, zephir_fast_count_int(item TSRMLS_CC)); } else { if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, item); + ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 359, item); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(length); @@ -116986,7 +117719,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, isIncluded) { } if (Z_TYPE_P(haystack) == IS_STRING) { if ((zephir_function_exists_ex(SS("mb_strpos") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 375, haystack, needle); + ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 368, haystack, needle); zephir_check_call_status(); RETURN_MM_BOOL(!ZEPHIR_IS_FALSE_IDENTICAL(_0)); } @@ -117039,7 +117772,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) { _0 = ZEPHIR_IS_STRING(to, "utf8"); } if (_0) { - ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 376, text); + ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 369, text); zephir_check_call_status(); RETURN_MM(); } @@ -117048,17 +117781,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) { _1 = ZEPHIR_IS_STRING(from, "utf8"); } if (_1) { - ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 377, text); + ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 370, text); zephir_check_call_status(); RETURN_MM(); } if ((zephir_function_exists_ex(SS("mb_convert_encoding") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, text, from, to); + ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 181, text, from, to); zephir_check_call_status(); RETURN_MM(); } if ((zephir_function_exists_ex(SS("iconv") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 378, from, to, text); + ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 371, from, to, text); zephir_check_call_status(); RETURN_MM(); } @@ -117129,7 +117862,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) { if (Z_TYPE_P(value) == IS_ARRAY) { ZEPHIR_SINIT_VAR(_5); ZVAL_LONG(&_5, start); - ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 379, value, &_5, length); + ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 372, value, &_5, length); zephir_check_call_status(); RETURN_MM(); } @@ -117137,13 +117870,13 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) { if (Z_TYPE_P(length) != IS_NULL) { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, start); - ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5, length); + ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 373, value, &_5, length); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, start); - ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5); + ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 373, value, &_5); zephir_check_call_status(); RETURN_MM(); } @@ -117173,7 +117906,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, sort) { Z_SET_ISREF_P(value); - ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 381, value); + ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 374, value); Z_UNSET_ISREF_P(value); zephir_check_call_status(); RETURN_CTOR(value); @@ -117217,7 +117950,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, callMacro) { ZEPHIR_MM_RESTORE(); return; } - ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 382, macro, arguments); + ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 375, macro, arguments); zephir_check_call_status(); RETURN_MM(); @@ -117479,7 +118212,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, addExtension) { if (Z_TYPE_P(extension) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The extension is not valid", "phalcon/mvc/view/engine/volt/compiler.zep", 198); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "The extension is not valid", "phalcon/mvc/view/engine/volt/compiler.zep", 198); return; } if ((zephir_method_exists_ex(extension, SS("initialize") TSRMLS_CC) == SUCCESS)) { @@ -117619,7 +118352,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, getUniquePrefix) { } } if (Z_TYPE_P(prefix) != IS_STRING) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The unique compilation prefix is invalid", "phalcon/mvc/view/engine/volt/compiler.zep", 292); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "The unique compilation prefix is invalid", "phalcon/mvc/view/engine/volt/compiler.zep", 292); return; } RETURN_CCTOR(prefix); @@ -117680,7 +118413,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) { } } } else { - ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 383, left); + ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 376, left); zephir_check_call_status(); ZEPHIR_OBS_VAR(leftType); zephir_array_fetch_string(&leftType, left, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 339 TSRMLS_CC); @@ -117702,7 +118435,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) { zephir_array_fetch_string(&_7, right, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 352 TSRMLS_CC); zephir_concat_self(&exprCode, _7 TSRMLS_CC); } else { - ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 383, right); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 376, right); zephir_check_call_status(); zephir_concat_self(&exprCode, _1 TSRMLS_CC); } @@ -117712,10 +118445,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) { static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { - zend_bool _7; + zend_bool _6; zephir_fcall_cache_entry *_0 = NULL; int ZEPHIR_LAST_CALL_STATUS; - zval *expr_param = NULL, *code = NULL, *funcArguments = NULL, *arguments = NULL, *nameExpr, *nameType, *name, *extensions, *functions, *definition, *extendedBlocks, *block, *currentBlock, *exprLevel, *escapedCode = NULL, *method = NULL, *arrayHelpers = NULL, *className, *_2 = NULL, *_3, *_4, *_5 = NULL, *_6, *_8 = NULL; + zval *expr_param = NULL, *code = NULL, *funcArguments = NULL, *arguments = NULL, *nameExpr, *nameType, *name, *extensions, *functions, *definition, *extendedBlocks, *block, *currentBlock, *exprLevel, *escapedCode = NULL, *method = NULL, *arrayHelpers = NULL, *className, *_2 = NULL, *_3, *_4, *_5, *_7 = NULL; zval *expr = NULL, *_1 = NULL; ZEPHIR_MM_GROW(); @@ -117731,7 +118464,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { ZVAL_NULL(funcArguments); ZEPHIR_OBS_NVAR(funcArguments); if (zephir_array_isset_string_fetch(&funcArguments, expr, SS("arguments"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 383, funcArguments); + ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 376, funcArguments); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(arguments); @@ -117754,7 +118487,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { zephir_array_fast_append(_1, funcArguments); ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "compileFunction", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _2, _1); + ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 377, _2, _1); zephir_check_temp_parameter(_2); zephir_check_call_status(); if (Z_TYPE_P(code) == IS_STRING) { @@ -117782,7 +118515,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { } } ZEPHIR_INIT_NVAR(_2); - object_init_ex(_2, phalcon_mvc_view_exception_ce); + object_init_ex(_2, phalcon_mvc_view_engine_volt_exception_ce); zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 427 TSRMLS_CC); zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 427 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); @@ -117794,16 +118527,11 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { return; } } - _6 = zephir_fetch_nproperty_this(this_ptr, SL("_macros"), PH_NOISY_CC); - if (zephir_array_isset(_6, name)) { - ZEPHIR_CONCAT_SVSVS(return_value, "$this->callMacro('", name, "', array(", arguments, "))"); - RETURN_MM(); - } - _7 = ZEPHIR_IS_STRING(name, "get_content"); - if (!(_7)) { - _7 = ZEPHIR_IS_STRING(name, "content"); + _6 = ZEPHIR_IS_STRING(name, "get_content"); + if (!(_6)) { + _6 = ZEPHIR_IS_STRING(name, "content"); } - if (_7) { + if (_6) { RETURN_MM_STRING("$this->getContent()", 1); } if (ZEPHIR_IS_STRING(name, "partial")) { @@ -117821,7 +118549,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { ZEPHIR_OBS_VAR(exprLevel); zephir_read_property_this(&exprLevel, this_ptr, SL("_exprLevel"), PH_NOISY_CC); if (Z_TYPE_P(block) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 385, block); + ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 378, block); zephir_check_call_status(); if (ZEPHIR_IS_LONG(exprLevel, 1)) { ZEPHIR_CPY_WRT(escapedCode, code); @@ -117848,7 +118576,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { } ZEPHIR_INIT_NVAR(_2); zephir_camelize(_2, name); - ZEPHIR_CALL_FUNCTION(&method, "lcfirst", NULL, 65, _2); + ZEPHIR_CALL_FUNCTION(&method, "lcfirst", NULL, 67, _2); zephir_check_call_status(); ZEPHIR_INIT_VAR(className); ZVAL_STRING(className, "Phalcon\\Tag", 1); @@ -117914,21 +118642,12 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { ZEPHIR_CONCAT_SVS(return_value, "constant(", arguments, ")"); RETURN_MM(); } - ZEPHIR_INIT_NVAR(_2); - object_init_ex(_2, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC); - zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_5); - ZEPHIR_CONCAT_SVSVSV(_5, "Undefined function '", name, "' in ", _3, " on line ", _4); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _5); - zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC); - ZEPHIR_MM_RESTORE(); - return; + ZEPHIR_CONCAT_SVSVS(return_value, "$this->callMacro('", name, "', array(", arguments, "))"); + RETURN_MM(); } - ZEPHIR_CALL_METHOD(&_8, this_ptr, "expression", &_0, 383, nameExpr); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "expression", &_0, 376, nameExpr); zephir_check_call_status(); - ZEPHIR_CONCAT_VSVS(return_value, _8, "(", arguments, ")"); + ZEPHIR_CONCAT_VSVS(return_value, _7, "(", arguments, ")"); RETURN_MM(); } @@ -117950,10 +118669,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) { ZEPHIR_OBS_VAR(type); - zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 586 TSRMLS_CC); + zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 579 TSRMLS_CC); if (ZEPHIR_IS_LONG(type, 265)) { ZEPHIR_OBS_VAR(name); - zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 593 TSRMLS_CC); + zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 586 TSRMLS_CC); if (ZEPHIR_IS_STRING(name, "empty")) { ZEPHIR_CONCAT_SVS(return_value, "empty(", left, ")"); RETURN_MM(); @@ -117981,33 +118700,33 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) { } if (ZEPHIR_IS_LONG(type, 350)) { ZEPHIR_OBS_VAR(testName); - zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 644 TSRMLS_CC); + zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 637 TSRMLS_CC); ZEPHIR_OBS_NVAR(name); if (zephir_array_isset_string_fetch(&name, testName, SS("value"), 0 TSRMLS_CC)) { if (ZEPHIR_IS_STRING(name, "divisibleby")) { - zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 648 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1); + zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 641 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, _1); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "(((", left, ") % (", _0, ")) == 0)"); RETURN_MM(); } if (ZEPHIR_IS_STRING(name, "sameas")) { - zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 655 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1); + zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 648 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, _1); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "(", left, ") === (", _0, ")"); RETURN_MM(); } if (ZEPHIR_IS_STRING(name, "type")) { - zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 662 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1); + zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 655 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, _1); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "gettype(", left, ") === (", _0, ")"); RETURN_MM(); } } } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, test); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, test); zephir_check_call_status(); ZEPHIR_CONCAT_VSV(return_value, left, " == ", _0); RETURN_MM(); @@ -118033,28 +118752,28 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { ZEPHIR_INIT_VAR(code); ZVAL_NULL(code); ZEPHIR_OBS_VAR(type); - zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 681 TSRMLS_CC); + zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 674 TSRMLS_CC); if (ZEPHIR_IS_LONG(type, 265)) { ZEPHIR_OBS_VAR(name); - zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 687 TSRMLS_CC); + zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 680 TSRMLS_CC); } else { if (!ZEPHIR_IS_LONG(type, 350)) { ZEPHIR_INIT_VAR(_0); - object_init_ex(_0, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC); - zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC); + object_init_ex(_0, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 688 TSRMLS_CC); + zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 688 TSRMLS_CC); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SVSV(_3, "Unknown filter type in ", _1, " on line ", _2); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 688 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_VAR(functionName); - zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 698 TSRMLS_CC); + zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 691 TSRMLS_CC); ZEPHIR_OBS_NVAR(name); - zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 699 TSRMLS_CC); + zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 692 TSRMLS_CC); } ZEPHIR_INIT_VAR(funcArguments); ZVAL_NULL(funcArguments); @@ -118064,9 +118783,9 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { if (zephir_array_isset_string_fetch(&funcArguments, filter, SS("arguments"), 0 TSRMLS_CC)) { if (!ZEPHIR_IS_STRING(name, "default")) { ZEPHIR_OBS_VAR(file); - zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC); + zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 707 TSRMLS_CC); ZEPHIR_OBS_VAR(line); - zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC); + zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 707 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); zephir_create_array(_4, 3, 0 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); @@ -118079,11 +118798,11 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { zephir_array_update_string(&_4, SL("file"), &file, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("line"), &line, PH_COPY | PH_SEPARATE); Z_SET_ISREF_P(funcArguments); - ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 386, funcArguments, _4); + ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 379, funcArguments, _4); Z_UNSET_ISREF_P(funcArguments); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 383, funcArguments); + ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 376, funcArguments); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(arguments, left); @@ -118098,7 +118817,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { zephir_array_fast_append(_4, funcArguments); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "compileFilter", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _0, _4); + ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 377, _0, _4); zephir_check_temp_parameter(_0); zephir_check_call_status(); if (Z_TYPE_P(code) == IS_STRING) { @@ -118126,14 +118845,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { } } ZEPHIR_INIT_NVAR(_0); - object_init_ex(_0, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC); - zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC); + object_init_ex(_0, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 770 TSRMLS_CC); + zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 770 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVSVSV(_3, "Invalid definition for user filter '", name, "' in ", _1, " on line ", _2); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 770 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -118255,14 +118974,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { RETURN_MM(); } ZEPHIR_INIT_NVAR(_0); - object_init_ex(_0, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC); - zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC); + object_init_ex(_0, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 959 TSRMLS_CC); + zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 959 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVSVSV(_3, "Unknown filter \"", name, "\" in ", _1, " on line ", _2); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 959 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -118296,7 +119015,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { zephir_array_fast_append(_0, expr); ZEPHIR_INIT_NVAR(_1); ZVAL_STRING(_1, "resolveExpression", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 384, _1, _0); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 377, _1, _0); zephir_check_temp_parameter(_1); zephir_check_call_status(); if (Z_TYPE_P(exprCode) == IS_STRING) { @@ -118307,22 +119026,22 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { if (!(zephir_array_isset_string_fetch(&type, expr, SS("type"), 0 TSRMLS_CC))) { ZEPHIR_INIT_NVAR(items); array_init(items); - zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1007); + zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1000); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) ) { ZEPHIR_GET_HVALUE(singleExpr, _5); - zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1000 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 383, _6); + zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 993 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 376, _6); zephir_check_call_status(); ZEPHIR_OBS_NVAR(name); if (zephir_array_isset_string_fetch(&name, singleExpr, SS("name"), 0 TSRMLS_CC)) { ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSV(_8, "'", name, "' => ", singleExprCode); - zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1002); + zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 995); } else { - zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1004); + zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 997); } } ZEPHIR_INIT_NVAR(exprCode); @@ -118336,24 +119055,24 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } ZEPHIR_OBS_NVAR(left); if (zephir_array_isset_string_fetch(&left, expr, SS("left"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 383, left); + ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 376, left); zephir_check_call_status(); } if (ZEPHIR_IS_LONG(type, 311)) { - zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1030 TSRMLS_CC); + zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1023 TSRMLS_CC); ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvetest", &_10, 0, _6, leftCode); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 124)) { - zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1038 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 387, _11, leftCode); + zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1031 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 380, _11, leftCode); zephir_check_call_status(); break; } ZEPHIR_OBS_NVAR(right); if (zephir_array_isset_string_fetch(&right, expr, SS("right"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 383, right); + ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 376, right); zephir_check_call_status(); } ZEPHIR_INIT_NVAR(exprCode); @@ -118425,17 +119144,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } if (ZEPHIR_IS_LONG(type, 258)) { ZEPHIR_OBS_NVAR(exprCode); - zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1105 TSRMLS_CC); + zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1098 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(type, 259)) { ZEPHIR_OBS_NVAR(exprCode); - zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1109 TSRMLS_CC); + zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1102 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(type, 260)) { ZEPHIR_INIT_NVAR(_1); - zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1113 TSRMLS_CC); + zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1106 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_13); ZVAL_STRING(&_13, "'", 0); ZEPHIR_SINIT_NVAR(_14); @@ -118461,7 +119180,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { break; } if (ZEPHIR_IS_LONG(type, 265)) { - zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1129 TSRMLS_CC); + zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1122 TSRMLS_CC); ZEPHIR_INIT_NVAR(exprCode); ZEPHIR_CONCAT_SV(exprCode, "$", _11); break; @@ -118529,7 +119248,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { if (ZEPHIR_IS_LONG(type, 365)) { ZEPHIR_OBS_NVAR(start); if (zephir_array_isset_string_fetch(&start, expr, SS("start"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 383, start); + ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 376, start); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(startCode); @@ -118537,7 +119256,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } ZEPHIR_OBS_NVAR(end); if (zephir_array_isset_string_fetch(&end, expr, SS("end"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 383, end); + ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 376, end); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(endCode); @@ -118628,8 +119347,8 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { break; } if (ZEPHIR_IS_LONG(type, 366)) { - zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1268 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 383, _6); + zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1261 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 376, _6); zephir_check_call_status(); ZEPHIR_INIT_NVAR(exprCode); ZEPHIR_CONCAT_SVSVSVS(exprCode, "(", _16, " ? ", leftCode, " : ", rightCode, ")"); @@ -118647,18 +119366,18 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } if (ZEPHIR_IS_LONG(type, 364)) { ZEPHIR_OBS_NVAR(exprCode); - zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1280 TSRMLS_CC); + zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1273 TSRMLS_CC); break; } ZEPHIR_INIT_NVAR(_1); - object_init_ex(_1, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC); - zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC); + object_init_ex(_1, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1277 TSRMLS_CC); + zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1277 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSVSV(_8, "Unknown expression ", type, " in ", _11, " on line ", _17); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_18, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1277 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -118689,7 +119408,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends } isStatementList = 1; if (!(zephir_array_isset_string(statements, SS("type")))) { - zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1324); + zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1317); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -118702,7 +119421,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends } } if (isStatementList == 1) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 388, statements); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 381, statements); zephir_check_call_status(); RETURN_MM(); } @@ -118734,7 +119453,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { if (!(zephir_array_isset_string(statement, SS("expr")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1352); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1345); return; } ZEPHIR_INIT_VAR(compilation); @@ -118749,15 +119468,15 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { ZEPHIR_INIT_VAR(prefixLevel); ZEPHIR_CONCAT_VV(prefixLevel, prefix, level); ZEPHIR_OBS_VAR(expr); - zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1370 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr); + zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1363 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 376, expr); zephir_check_call_status(); ZEPHIR_OBS_VAR(blockStatements); - zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1376 TSRMLS_CC); + zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1369 TSRMLS_CC); ZEPHIR_INIT_NVAR(forElse); ZVAL_BOOL(forElse, 0); if (Z_TYPE_P(blockStatements) == IS_ARRAY) { - zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1402); + zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1395); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -118780,7 +119499,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { } } } - ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 381, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_OBS_VAR(loopContext); zephir_read_property_this(&loopContext, this_ptr, SL("_loopPointers"), PH_NOISY_CC); @@ -118815,7 +119534,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { ZEPHIR_CPY_WRT(iterator, exprCode); } ZEPHIR_OBS_VAR(variable); - zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1431 TSRMLS_CC); + zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1424 TSRMLS_CC); ZEPHIR_OBS_VAR(key); if (zephir_array_isset_string_fetch(&key, statement, SS("key"), 0 TSRMLS_CC)) { ZEPHIR_INIT_LNVAR(_5); @@ -118828,7 +119547,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { } ZEPHIR_OBS_VAR(ifExpr); if (zephir_array_isset_string_fetch(&ifExpr, statement, SS("if_expr"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 383, ifExpr); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 376, ifExpr); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVS(_5, "if (", _12, ") { ?>"); @@ -118923,19 +119642,19 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileIf) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1522); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1515); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); - zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1528 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 388, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1521 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 381, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_INIT_VAR(compilation); ZEPHIR_CONCAT_SVSV(compilation, "", _1); ZEPHIR_OBS_VAR(blockStatements); if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("false_statements"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 381, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SV(_5, "", _4); @@ -118961,10 +119680,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileElseIf) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1557); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1550); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, ""); RETURN_MM(); @@ -118993,12 +119712,12 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1577); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1570); return; } - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 376, expr); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 383, expr); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 376, expr); zephir_check_call_status(); ZEPHIR_INIT_VAR(compilation); ZEPHIR_CONCAT_SVS(compilation, "di->get('viewCache'); "); @@ -119007,14 +119726,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) { ZEPHIR_INIT_VAR(_2); ZEPHIR_CONCAT_SVS(_2, "$_cacheKey[", exprCode, "]"); zephir_concat_self(&compilation, _2 TSRMLS_CC); - zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1587 TSRMLS_CC); + zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1580 TSRMLS_CC); if (ZEPHIR_IS_LONG(_3, 265)) { - zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1588 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1581 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", $", _4, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); } else { - zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1590 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1583 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", ", _4, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); @@ -119027,20 +119746,20 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) { ZEPHIR_INIT_LNVAR(_2); ZEPHIR_CONCAT_SVS(_2, "if ($_cacheKey[", exprCode, "] === null) { ?>"); zephir_concat_self(&compilation, _2 TSRMLS_CC); - zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1600 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 388, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1593 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 381, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_concat_self(&compilation, _6 TSRMLS_CC); ZEPHIR_OBS_NVAR(lifetime); if (zephir_array_isset_string_fetch(&lifetime, statement, SS("lifetime"), 0 TSRMLS_CC)) { - zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1606 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1599 TSRMLS_CC); if (ZEPHIR_IS_LONG(_4, 265)) { - zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1607 TSRMLS_CC); + zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1600 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, $", _7, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); } else { - zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1609 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1602 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, ", _4, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); @@ -119075,24 +119794,24 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileSet) { ZEPHIR_OBS_VAR(assignments); if (!(zephir_array_isset_string_fetch(&assignments, statement, SS("assignments"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1630); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1623); return; } ZEPHIR_INIT_VAR(compilation); ZVAL_STRING(compilation, ""); RETURN_MM(); @@ -119170,10 +119889,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileReturn) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1711); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1704); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, ""); RETURN_MM(); @@ -119197,14 +119916,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileAutoEscape) { ZEPHIR_OBS_VAR(autoescape); if (!(zephir_array_isset_string_fetch(&autoescape, statement, SS("enable"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1731); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1724); return; } ZEPHIR_OBS_VAR(oldAutoescape); zephir_read_property_this(&oldAutoescape, this_ptr, SL("_autoescape"), PH_NOISY_CC); zephir_update_property_this(this_ptr, SL("_autoescape"), autoescape TSRMLS_CC); - zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1740 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 388, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1733 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 381, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_autoescape"), oldAutoescape TSRMLS_CC); RETURN_CCTOR(compilation); @@ -119226,17 +119945,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileEcho) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1761); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1754); return; } - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); - zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1769 TSRMLS_CC); + zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1762 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 350)) { - zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1771 TSRMLS_CC); - zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1773 TSRMLS_CC); + zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1764 TSRMLS_CC); + zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1766 TSRMLS_CC); if (ZEPHIR_IS_LONG(_1, 265)) { - zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1778 TSRMLS_CC); + zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1771 TSRMLS_CC); if (ZEPHIR_IS_STRING(_2, "super")) { RETURN_CCTOR(exprCode); } @@ -119268,14 +119987,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) { ZEPHIR_OBS_VAR(pathExpr); if (!(zephir_array_isset_string_fetch(&pathExpr, statement, SS("path"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1806); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1799); return; } - zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1813 TSRMLS_CC); + zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1806 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 260)) { if (!(zephir_array_isset_string(statement, SS("params")))) { ZEPHIR_OBS_VAR(path); - zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1823 TSRMLS_CC); + zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1816 TSRMLS_CC); ZEPHIR_OBS_VAR(view); zephir_read_property_this(&view, this_ptr, SL("_view"), PH_NOISY_CC); if (Z_TYPE_P(view) == IS_OBJECT) { @@ -119303,14 +120022,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) { RETURN_CCTOR(compilation); } } - ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 383, pathExpr); + ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 376, pathExpr); zephir_check_call_status(); ZEPHIR_OBS_VAR(params); if (!(zephir_array_isset_string_fetch(¶ms, statement, SS("params"), 0 TSRMLS_CC))) { ZEPHIR_CONCAT_SVS(return_value, "partial(", path, "); ?>"); RETURN_MM(); } - ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 383, params); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 376, params); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "partial(", path, ", ", _1, "); ?>"); RETURN_MM(); @@ -119337,18 +120056,18 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { ZEPHIR_OBS_VAR(name); if (!(zephir_array_isset_string_fetch(&name, statement, SS("name"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1878); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1871); return; } _0 = zephir_fetch_nproperty_this(this_ptr, SL("_macros"), PH_NOISY_CC); if (zephir_array_isset(_0, name)) { ZEPHIR_INIT_VAR(_1); - object_init_ex(_1, phalcon_mvc_view_exception_ce); + object_init_ex(_1, phalcon_mvc_view_engine_volt_exception_ce); ZEPHIR_INIT_VAR(_2); ZEPHIR_CONCAT_SVS(_2, "Macro '", name, "' is already defined"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1885 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1878 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -119366,7 +120085,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { ZEPHIR_INIT_LNVAR(_2); ZEPHIR_CONCAT_VS(_2, macroName, " = function($__p = null) { "); zephir_concat_self(&code, _2 TSRMLS_CC); - zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1923); + zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1916); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -119374,7 +120093,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { ZEPHIR_GET_HMKEY(position, _4, _3); ZEPHIR_GET_HVALUE(parameter, _5); ZEPHIR_OBS_NVAR(variableName); - zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1907 TSRMLS_CC); + zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1900 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_6); ZEPHIR_CONCAT_SVS(_6, "if (isset($__p[", position, "])) { "); zephir_concat_self(&code, _6 TSRMLS_CC); @@ -119391,7 +120110,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { zephir_concat_self_str(&code, SL(" } else { ") TSRMLS_CC); ZEPHIR_OBS_NVAR(defaultValue); if (zephir_array_isset_string_fetch(&defaultValue, parameter, SS("default"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 383, defaultValue); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 376, defaultValue); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SVSVS(_12, "$", variableName, " = ", _10, ";"); @@ -119407,7 +120126,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { } ZEPHIR_OBS_VAR(blockStatements); if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("block_statements"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 381, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_2); ZEPHIR_CONCAT_VS(_2, _10, " + +#include +#include +#include + + + +ZEPHIR_INIT_CLASS(Phalcon_Mvc_View_Engine_Volt_Exception) { + + ZEPHIR_REGISTER_CLASS_EX(Phalcon\\Mvc\\View\\Engine\\Volt, Exception, phalcon, mvc_view_engine_volt_exception, phalcon_mvc_view_exception_ce, NULL, 0); + + return SUCCESS; + +} + + + /* Driver template for the LEMON parser generator. ** The author disclaims copyright to this source code. */ @@ -130015,7 +130756,7 @@ static PHP_METHOD(Phalcon_Paginator_Adapter_NativeArray, getPaginate) { number = zephir_fast_count_int(items TSRMLS_CC); ZEPHIR_SINIT_VAR(_2); ZVAL_LONG(&_2, show); - ZEPHIR_CALL_FUNCTION(&_3, "floatval", NULL, 311, &_2); + ZEPHIR_CALL_FUNCTION(&_3, "floatval", NULL, 304, &_2); zephir_check_call_status(); roundedTotal = zephir_safe_div_long_zval(number, _3 TSRMLS_CC); totalPages = (int) (roundedTotal); @@ -130026,7 +130767,7 @@ static PHP_METHOD(Phalcon_Paginator_Adapter_NativeArray, getPaginate) { ZVAL_LONG(&_2, (show * ((pageNumber - 1)))); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, show); - ZEPHIR_CALL_FUNCTION(&_5, "array_slice", NULL, 379, items, &_2, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "array_slice", NULL, 372, items, &_2, &_4); zephir_check_call_status(); ZEPHIR_CPY_WRT(items, _5); if (pageNumber < totalPages) { @@ -130336,7 +131077,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, connect) { ZEPHIR_INIT_VAR(_3); ZVAL_NULL(_3); Z_SET_ISREF_P(_2); - ZEPHIR_CALL_FUNCTION(&connection, "fsockopen", NULL, 390, _0, _1, _2, _3); + ZEPHIR_CALL_FUNCTION(&connection, "fsockopen", NULL, 383, _0, _1, _2, _3); Z_UNSET_ISREF_P(_2); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_RESOURCE) { @@ -130345,7 +131086,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, connect) { } ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, -1); - ZEPHIR_CALL_FUNCTION(NULL, "stream_set_timeout", NULL, 391, connection, &_4, ZEPHIR_GLOBAL(global_null)); + ZEPHIR_CALL_FUNCTION(NULL, "stream_set_timeout", NULL, 384, connection, &_4, ZEPHIR_GLOBAL(global_null)); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_connection"), connection TSRMLS_CC); RETURN_CCTOR(connection); @@ -130382,7 +131123,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, put) { ZEPHIR_INIT_NVAR(ttr); ZVAL_LONG(ttr, 86400); } - ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 71, data); + ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 73, data); zephir_check_call_status(); ZEPHIR_INIT_VAR(length); ZVAL_LONG(length, zephir_fast_strlen_ev(serialized)); @@ -130392,7 +131133,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, put) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", &_1, 0, serialized); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&status, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 128 TSRMLS_CC); _2 = !ZEPHIR_IS_STRING(status, "INSERTED"); @@ -130428,7 +131169,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, reserve) { } ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, command); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&_0, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 153 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_0, "RESERVED")) { @@ -130439,9 +131180,9 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, reserve) { zephir_array_fetch_long(&_3, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 163 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_2, this_ptr, "read", NULL, 0, _3); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "unserialize", NULL, 72, _2); + ZEPHIR_CALL_FUNCTION(&_4, "unserialize", NULL, 74, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 393, this_ptr, _1, _4); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 386, this_ptr, _1, _4); zephir_check_call_status(); RETURN_MM(); @@ -130473,7 +131214,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, choose) { ZEPHIR_CONCAT_SV(_0, "use ", tube); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 176 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "USING")) { @@ -130510,7 +131251,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, watch) { ZEPHIR_CONCAT_SV(_0, "watch ", tube); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 193 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "WATCHING")) { @@ -130533,7 +131274,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, stats) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_temp_parameter(_0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 394); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 387); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 210 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "OK")) { @@ -130570,7 +131311,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, statsTube) { ZEPHIR_CONCAT_SV(_0, "stats-tube ", tube); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 394); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 387); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 227 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "OK")) { @@ -130581,6 +131322,29 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, statsTube) { } +static PHP_METHOD(Phalcon_Queue_Beanstalk, listTubes) { + + int ZEPHIR_LAST_CALL_STATUS; + zval *response = NULL, *_0, *_1, *_2; + + ZEPHIR_MM_GROW(); + + ZEPHIR_INIT_VAR(_0); + ZVAL_STRING(_0, "list-tubes", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); + zephir_check_temp_parameter(_0); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 387); + zephir_check_call_status(); + zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 244 TSRMLS_CC); + if (!ZEPHIR_IS_STRING(_1, "OK")) { + RETURN_MM_BOOL(0); + } + zephir_array_fetch_long(&_2, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 248 TSRMLS_CC); + RETURN_CTOR(_2); + +} + static PHP_METHOD(Phalcon_Queue_Beanstalk, peekReady) { int ZEPHIR_LAST_CALL_STATUS; @@ -130593,20 +131357,20 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, peekReady) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_temp_parameter(_0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); - zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 244 TSRMLS_CC); + zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 261 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "FOUND")) { RETURN_MM_BOOL(0); } object_init_ex(return_value, phalcon_queue_beanstalk_job_ce); - zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 248 TSRMLS_CC); - zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 248 TSRMLS_CC); + zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); + zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, this_ptr, "read", NULL, 0, _4); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 72, _3); + ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 74, _3); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 393, this_ptr, _2, _5); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 386, this_ptr, _2, _5); zephir_check_call_status(); RETURN_MM(); @@ -130624,20 +131388,20 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, peekBuried) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_temp_parameter(_0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); - zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 261 TSRMLS_CC); + zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 278 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "FOUND")) { RETURN_MM_BOOL(0); } object_init_ex(return_value, phalcon_queue_beanstalk_job_ce); - zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); - zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); + zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 282 TSRMLS_CC); + zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 282 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, this_ptr, "read", NULL, 0, _4); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 72, _3); + ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 74, _3); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 393, this_ptr, _2, _5); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 386, this_ptr, _2, _5); zephir_check_call_status(); RETURN_MM(); @@ -130668,13 +131432,13 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, readYaml) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); ZEPHIR_OBS_VAR(status); - zephir_array_fetch_long(&status, response, 0, PH_NOISY, "phalcon/queue/beanstalk.zep", 290 TSRMLS_CC); + zephir_array_fetch_long(&status, response, 0, PH_NOISY, "phalcon/queue/beanstalk.zep", 307 TSRMLS_CC); if (zephir_fast_count_int(response TSRMLS_CC) > 1) { ZEPHIR_OBS_VAR(numberOfBytes); - zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 293 TSRMLS_CC); + zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 310 TSRMLS_CC); ZEPHIR_CALL_METHOD(&response, this_ptr, "read", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_FUNCTION(&data, "yaml_parse", NULL, 0, response); @@ -130723,13 +131487,13 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, read) { } ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, (length + 2)); - ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 395, connection, &_0); + ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 388, connection, &_0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 396, connection); + ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 389, connection); zephir_check_call_status(); - zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 337 TSRMLS_CC); + zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 354 TSRMLS_CC); if (zephir_is_true(_2)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 338); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 355); return; } ZEPHIR_SINIT_NVAR(_0); @@ -130741,7 +131505,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, read) { ZVAL_LONG(&_0, 16384); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "\r\n", 0); - ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 397, connection, &_0, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 390, connection, &_0, &_3); zephir_check_call_status(); RETURN_MM(); @@ -130773,7 +131537,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, write) { ZEPHIR_CPY_WRT(packet, _0); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, zephir_fast_strlen_ev(packet)); - ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 398, connection, packet, &_1); + ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 391, connection, packet, &_1); zephir_check_call_status(); RETURN_MM(); @@ -131065,6 +131829,315 @@ ZEPHIR_INIT_CLASS(Phalcon_Security_Exception) { +#ifdef HAVE_CONFIG_H +#endif + +#include + +#include +#include +#include + + + +ZEPHIR_INIT_CLASS(Phalcon_Security_Random) { + + ZEPHIR_REGISTER_CLASS(Phalcon\\Security, Random, phalcon, security_random, phalcon_security_random_method_entry, 0); + + return SUCCESS; + +} + +static PHP_METHOD(Phalcon_Security_Random, bytes) { + + zval *len_param = NULL, *handle = NULL, *ret = NULL, *_0 = NULL, _1, _2 = zval_used_for_init, _3; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &len_param); + + if (!len_param) { + len = 16; + } else { + len = zephir_get_intval(len_param); + } + + + if (len <= 0) { + len = 16; + } + if ((zephir_function_exists_ex(SS("\\sodium\\randombytes_buf") TSRMLS_CC) == SUCCESS)) { + ZEPHIR_INIT_VAR(_0); + ZVAL_LONG(_0, len); + ZEPHIR_RETURN_CALL_FUNCTION("\\sodium\\randombytes_buf", NULL, 0, _0); + zephir_check_call_status(); + RETURN_MM(); + } + if ((zephir_function_exists_ex(SS("openssl_random_pseudo_bytes") TSRMLS_CC) == SUCCESS)) { + ZEPHIR_INIT_NVAR(_0); + ZVAL_LONG(_0, len); + ZEPHIR_RETURN_CALL_FUNCTION("openssl_random_pseudo_bytes", NULL, 400, _0); + zephir_check_call_status(); + RETURN_MM(); + } + ZEPHIR_SINIT_VAR(_1); + ZVAL_STRING(&_1, "/dev/urandom", 0); + if ((zephir_file_exists(&_1 TSRMLS_CC) == SUCCESS)) { + ZEPHIR_SINIT_VAR(_2); + ZVAL_STRING(&_2, "/dev/urandom", 0); + ZEPHIR_SINIT_VAR(_3); + ZVAL_STRING(&_3, "rb", 0); + ZEPHIR_CALL_FUNCTION(&handle, "fopen", NULL, 285, &_2, &_3); + zephir_check_call_status(); + if (!ZEPHIR_IS_FALSE_IDENTICAL(handle)) { + ZEPHIR_SINIT_NVAR(_2); + ZVAL_LONG(&_2, 0); + ZEPHIR_CALL_FUNCTION(NULL, "stream_set_read_buffer", NULL, 403, handle, &_2); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_2); + ZVAL_LONG(&_2, len); + ZEPHIR_CALL_FUNCTION(&ret, "fread", NULL, 388, handle, &_2); + zephir_check_call_status(); + zephir_fclose(handle TSRMLS_CC); + if (zephir_fast_strlen_ev(ret) != len) { + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_security_exception_ce, "Unexpected partial read from random device", "phalcon/security/random.zep", 117); + return; + } + RETURN_CCTOR(ret); + } + } + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_security_exception_ce, "No random device", "phalcon/security/random.zep", 124); + return; + +} + +static PHP_METHOD(Phalcon_Security_Random, hex) { + + zval *len_param = NULL, *_0 = NULL, *_1, _2, *_3 = NULL; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &len_param); + + if (!len_param) { + len = 0; + } else { + len = zephir_get_intval(len_param); + } + + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, len); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "bytes", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_SINIT_VAR(_2); + ZVAL_STRING(&_2, "H*", 0); + ZEPHIR_CALL_FUNCTION(&_3, "unpack", NULL, 404, &_2, _0); + zephir_check_call_status(); + Z_SET_ISREF_P(_3); + ZEPHIR_RETURN_CALL_FUNCTION("array_shift", NULL, 121, _3); + Z_UNSET_ISREF_P(_3); + zephir_check_call_status(); + RETURN_MM(); + +} + +static PHP_METHOD(Phalcon_Security_Random, base64) { + + zval *len_param = NULL, *_0 = NULL, *_1; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &len_param); + + if (!len_param) { + len = 0; + } else { + len = zephir_get_intval(len_param); + } + + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, len); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "bytes", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", NULL, 114, _0); + zephir_check_call_status(); + RETURN_MM(); + +} + +static PHP_METHOD(Phalcon_Security_Random, base64Safe) { + + zend_bool padding; + zval *len_param = NULL, *padding_param = NULL, *s = NULL, *_0 = NULL, *_1 = NULL, *_2, _3; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 2, &len_param, &padding_param); + + if (!len_param) { + len = 0; + } else { + len = zephir_get_intval(len_param); + } + if (!padding_param) { + padding = 0; + } else { + padding = zephir_get_boolval(padding_param); + } + + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, len); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "base64", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_INIT_NVAR(_1); + ZVAL_STRING(_1, "#[^a-z0-9_=-]+#i", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_INIT_VAR(_2); + ZVAL_STRING(_2, "", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_FUNCTION(&s, "preg_replace", NULL, 29, _1, _2, _0); + zephir_check_temp_parameter(_1); + zephir_check_temp_parameter(_2); + zephir_check_call_status(); + if (!(padding)) { + ZEPHIR_SINIT_VAR(_3); + ZVAL_STRING(&_3, "=", 0); + zephir_fast_trim(return_value, s, &_3, ZEPHIR_TRIM_BOTH TSRMLS_CC); + RETURN_MM(); + } + RETURN_CCTOR(s); + +} + +static PHP_METHOD(Phalcon_Security_Random, uuid) { + + int ZEPHIR_LAST_CALL_STATUS; + zval *ary = NULL, *_0 = NULL, *_1 = NULL, _2 = zval_used_for_init, *_3 = NULL, *_4, *_5, *_6, *_7; + + ZEPHIR_MM_GROW(); + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, 16); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "bytes", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_SINIT_VAR(_2); + ZVAL_STRING(&_2, "N1a/n1b/n1c/n1d/n1e/N1f", 0); + ZEPHIR_CALL_FUNCTION(&_3, "unpack", NULL, 404, &_2, _0); + zephir_check_call_status(); + ZEPHIR_CALL_FUNCTION(&ary, "array_values", NULL, 215, _3); + zephir_check_call_status(); + zephir_array_fetch_long(&_4, ary, 2, PH_NOISY | PH_READONLY, "phalcon/security/random.zep", 222 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_1); + ZVAL_LONG(_1, ((((int) (zephir_get_numberval(_4)) & 0x0fff)) | 0x4000)); + zephir_array_update_long(&ary, 2, &_1, PH_COPY | PH_SEPARATE, "phalcon/security/random.zep", 222); + zephir_array_fetch_long(&_5, ary, 3, PH_NOISY | PH_READONLY, "phalcon/security/random.zep", 223 TSRMLS_CC); + ZEPHIR_INIT_VAR(_6); + ZVAL_LONG(_6, ((((int) (zephir_get_numberval(_5)) & 0x3fff)) | 0x8000)); + zephir_array_update_long(&ary, 3, &_6, PH_COPY | PH_SEPARATE, "phalcon/security/random.zep", 223); + ZEPHIR_INIT_VAR(_7); + ZVAL_STRING(_7, "%08x-%04x-%04x-%04x-%04x%08x", ZEPHIR_TEMP_PARAM_COPY); + Z_SET_ISREF_P(ary); + ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 379, ary, _7); + zephir_check_temp_parameter(_7); + Z_UNSET_ISREF_P(ary); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_2); + ZVAL_STRING(&_2, "sprintf", 0); + ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, &_2, ary); + zephir_check_call_status(); + RETURN_MM(); + +} + +static PHP_METHOD(Phalcon_Security_Random, number) { + + zephir_fcall_cache_entry *_4 = NULL, *_9 = NULL, *_14 = NULL, *_18 = NULL; + zval *len_param = NULL, *hex = NULL, *bin = NULL, *mask = NULL, *rnd = NULL, *ret = NULL, *first = NULL, _0 = zval_used_for_init, *_1, _2, *_3, *_8 = NULL, _10 = zval_used_for_init, _11 = zval_used_for_init, _12 = zval_used_for_init, *_13 = NULL, _15 = zval_used_for_init, _16 = zval_used_for_init, *_17 = NULL; + int len, ZEPHIR_LAST_CALL_STATUS, _5, _6, _7; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &len_param); + + len = zephir_get_intval(len_param); + + + if (len > 0) { + ZEPHIR_SINIT_VAR(_0); + ZVAL_LONG(&_0, len); + ZEPHIR_CALL_FUNCTION(&hex, "dechex", NULL, 405, &_0); + zephir_check_call_status(); + if (((zephir_fast_strlen_ev(hex) & 1)) == 1) { + ZEPHIR_INIT_VAR(_1); + ZEPHIR_CONCAT_SV(_1, "0", hex); + ZEPHIR_CPY_WRT(hex, _1); + } + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "H*", 0); + ZEPHIR_CALL_FUNCTION(&bin, "pack", NULL, 406, &_0, hex); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_LONG(&_0, 0); + ZEPHIR_SINIT_VAR(_2); + ZVAL_LONG(&_2, 1); + ZEPHIR_INIT_VAR(_3); + zephir_substr(_3, bin, 0 , 1 , 0); + ZEPHIR_CALL_FUNCTION(&mask, "ord", &_4, 132, _3); + zephir_check_call_status(); + _5 = ((int) (zephir_get_numberval(mask)) | (((int) (zephir_get_numberval(mask)) >> 1))); + ZEPHIR_INIT_NVAR(mask); + ZVAL_LONG(mask, _5); + _6 = ((int) (zephir_get_numberval(mask)) | (((int) (zephir_get_numberval(mask)) >> 2))); + ZEPHIR_INIT_NVAR(mask); + ZVAL_LONG(mask, _6); + _7 = ((int) (zephir_get_numberval(mask)) | (((int) (zephir_get_numberval(mask)) >> 4))); + ZEPHIR_INIT_NVAR(mask); + ZVAL_LONG(mask, _7); + do { + ZEPHIR_INIT_NVAR(_8); + ZVAL_LONG(_8, zephir_fast_strlen_ev(bin)); + ZEPHIR_CALL_METHOD(&rnd, this_ptr, "bytes", &_9, 0, _8); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_10); + ZVAL_LONG(&_10, 0); + ZEPHIR_SINIT_NVAR(_11); + ZVAL_LONG(&_11, 1); + ZEPHIR_INIT_NVAR(_8); + zephir_substr(_8, rnd, 0 , 1 , 0); + ZEPHIR_CALL_FUNCTION(&first, "ord", &_4, 132, _8); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_12); + zephir_bitwise_and_function(&_12, first, mask TSRMLS_CC); + ZEPHIR_CALL_FUNCTION(&_13, "chr", &_14, 130, &_12); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_15); + ZVAL_LONG(&_15, 0); + ZEPHIR_SINIT_NVAR(_16); + ZVAL_LONG(&_16, 1); + ZEPHIR_CALL_FUNCTION(&_17, "substr_replace", &_18, 407, rnd, _13, &_15, &_16); + zephir_check_call_status(); + ZEPHIR_CPY_WRT(rnd, _17); + } while (ZEPHIR_LT(bin, rnd)); + ZEPHIR_SINIT_NVAR(_10); + ZVAL_STRING(&_10, "H*", 0); + ZEPHIR_CALL_FUNCTION(&ret, "unpack", NULL, 404, &_10, rnd); + zephir_check_call_status(); + Z_SET_ISREF_P(ret); + ZEPHIR_CALL_FUNCTION(&_13, "array_shift", NULL, 121, ret); + Z_UNSET_ISREF_P(ret); + zephir_check_call_status(); + ZEPHIR_RETURN_CALL_FUNCTION("hexdec", NULL, 408, _13); + zephir_check_call_status(); + RETURN_MM(); + } + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_security_exception_ce, "Require a positive integer > 0", "phalcon/security/random.zep", 269); + return; + +} + + + + #ifdef HAVE_CONFIG_H #endif @@ -131125,7 +132198,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, start) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 54); + ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 55); zephir_check_call_status(); if (!(zephir_is_true(_0))) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_started"), PH_NOISY_CC); @@ -131136,7 +132209,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, start) { _2 = !ZEPHIR_IS_LONG_IDENTICAL(_3, 2); } if (_2) { - ZEPHIR_CALL_FUNCTION(NULL, "session_start", NULL, 55); + ZEPHIR_CALL_FUNCTION(NULL, "session_start", NULL, 56); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_started"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); RETURN_MM_BOOL(1); @@ -131183,7 +132256,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, setName) { zephir_get_strval(name, name_param); - ZEPHIR_CALL_FUNCTION(NULL, "session_name", NULL, 56, name); + ZEPHIR_CALL_FUNCTION(NULL, "session_name", NULL, 57, name); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -131195,16 +132268,38 @@ static PHP_METHOD(Phalcon_Session_Adapter, getName) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("session_name", NULL, 56); + ZEPHIR_RETURN_CALL_FUNCTION("session_name", NULL, 57); zephir_check_call_status(); RETURN_MM(); } +static PHP_METHOD(Phalcon_Session_Adapter, regenerateId) { + + int ZEPHIR_LAST_CALL_STATUS; + zval *deleteOldSession_param = NULL; + zend_bool deleteOldSession; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &deleteOldSession_param); + + if (!deleteOldSession_param) { + deleteOldSession = 1; + } else { + deleteOldSession = zephir_get_boolval(deleteOldSession_param); + } + + + ZEPHIR_CALL_FUNCTION(NULL, "session_regenerate_id", NULL, 58, (deleteOldSession ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_check_call_status(); + RETURN_THIS(); + +} + static PHP_METHOD(Phalcon_Session_Adapter, get) { zend_bool remove; - zval *index_param = NULL, *defaultValue = NULL, *remove_param = NULL, *value, *key, *_0, *_SESSION; + zval *index_param = NULL, *defaultValue = NULL, *remove_param = NULL, *value, *key = NULL, *uniqueId, *_SESSION; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -131222,9 +132317,13 @@ static PHP_METHOD(Phalcon_Session_Adapter, get) { } - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(key); - ZEPHIR_CONCAT_VV(key, _0, index); + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(key); + ZEPHIR_CONCAT_VSV(key, uniqueId, "#", index); + } else { + ZEPHIR_CPY_WRT(key, index); + } ZEPHIR_OBS_VAR(value); if (zephir_array_isset_fetch(&value, _SESSION, key, 0 TSRMLS_CC)) { if (remove) { @@ -131239,8 +132338,8 @@ static PHP_METHOD(Phalcon_Session_Adapter, get) { static PHP_METHOD(Phalcon_Session_Adapter, set) { - int _2; - zval *index_param = NULL, *value, *_SESSION, *_0, *_1; + int _1; + zval *index_param = NULL, *value, *uniqueId, *_SESSION, *_0; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -131250,12 +132349,20 @@ static PHP_METHOD(Phalcon_Session_Adapter, set) { zephir_get_strval(index, index_param); - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_1); - ZEPHIR_CONCAT_VV(_1, _0, index); - _2 = zephir_maybe_separate_zval(&_SESSION); - zephir_array_update_zval(&_SESSION, _1, &value, PH_COPY | PH_SEPARATE); - if (_2) { + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + ZEPHIR_CONCAT_VSV(_0, uniqueId, "#", index); + _1 = zephir_maybe_separate_zval(&_SESSION); + zephir_array_update_zval(&_SESSION, _0, &value, PH_COPY | PH_SEPARATE); + if (_1) { + ZEND_SET_SYMBOL(&EG(symbol_table), "_SESSION", _SESSION); + } + RETURN_MM_NULL(); + } + _1 = zephir_maybe_separate_zval(&_SESSION); + zephir_array_update_zval(&_SESSION, index, &value, PH_COPY | PH_SEPARATE); + if (_1) { ZEND_SET_SYMBOL(&EG(symbol_table), "_SESSION", _SESSION); } ZEPHIR_MM_RESTORE(); @@ -131264,7 +132371,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, set) { static PHP_METHOD(Phalcon_Session_Adapter, has) { - zval *index_param = NULL, *_SESSION, *_0, *_1; + zval *index_param = NULL, *uniqueId, *_SESSION, *_0; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -131274,16 +132381,19 @@ static PHP_METHOD(Phalcon_Session_Adapter, has) { zephir_get_strval(index, index_param); - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_1); - ZEPHIR_CONCAT_VV(_1, _0, index); - RETURN_MM_BOOL(zephir_array_isset(_SESSION, _1)); + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + ZEPHIR_CONCAT_VSV(_0, uniqueId, "#", index); + RETURN_MM_BOOL(zephir_array_isset(_SESSION, _0)); + } + RETURN_MM_BOOL(zephir_array_isset(_SESSION, index)); } static PHP_METHOD(Phalcon_Session_Adapter, remove) { - zval *index_param = NULL, *_0, *_1, *_SESSION; + zval *index_param = NULL, *uniqueId, *_0, *_SESSION; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -131293,10 +132403,14 @@ static PHP_METHOD(Phalcon_Session_Adapter, remove) { zephir_get_strval(index, index_param); - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_1); - ZEPHIR_CONCAT_VV(_1, _0, index); - zephir_array_unset(&_SESSION, _1, PH_SEPARATE); + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + ZEPHIR_CONCAT_VSV(_0, uniqueId, "#", index); + zephir_array_unset(&_SESSION, _0, PH_SEPARATE); + RETURN_MM_NULL(); + } + zephir_array_unset(&_SESSION, index, PH_SEPARATE); ZEPHIR_MM_RESTORE(); } @@ -131307,7 +132421,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, getId) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("session_id", NULL, 57); + ZEPHIR_RETURN_CALL_FUNCTION("session_id", NULL, 59); zephir_check_call_status(); RETURN_MM(); @@ -131325,7 +132439,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, setId) { zephir_get_strval(id, id_param); - ZEPHIR_CALL_FUNCTION(NULL, "session_id", NULL, 57, id); + ZEPHIR_CALL_FUNCTION(NULL, "session_id", NULL, 59, id); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -131341,11 +132455,47 @@ static PHP_METHOD(Phalcon_Session_Adapter, isStarted) { static PHP_METHOD(Phalcon_Session_Adapter, destroy) { int ZEPHIR_LAST_CALL_STATUS; + HashTable *_2; + HashPosition _1; + zval *removeData_param = NULL, *uniqueId, *key = NULL, *_SESSION = NULL, *_0 = NULL, **_3, *_4 = NULL; + zend_bool removeData; ZEPHIR_MM_GROW(); + zephir_get_global(&_SESSION, SS("_SESSION") TSRMLS_CC); + zephir_fetch_params(1, 0, 1, &removeData_param); + if (!removeData_param) { + removeData = 0; + } else { + removeData = zephir_get_boolval(removeData_param); + } + + + if (removeData) { + ZEPHIR_OBS_VAR(uniqueId); + zephir_read_property_this(&uniqueId, this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + zephir_is_iterable(_SESSION, &_2, &_1, 1, 0, "phalcon/session/adapter.zep", 265); + for ( + ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS + ; zephir_hash_move_forward_ex(_2, &_1) + ) { + ZEPHIR_GET_HMKEY(key, _2, _1); + ZEPHIR_GET_HVALUE(_0, _3); + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_VS(_4, uniqueId, "#"); + if (zephir_start_with(key, _4, NULL)) { + zephir_array_unset(&_SESSION, key, PH_SEPARATE); + } + } + } else { + ZEPHIR_INIT_NVAR(_SESSION); + array_init(_SESSION); + } + } zephir_update_property_this(this_ptr, SL("_started"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); - ZEPHIR_RETURN_CALL_FUNCTION("session_destroy", NULL, 58); + ZEPHIR_RETURN_CALL_FUNCTION("session_destroy", NULL, 60); zephir_check_call_status(); RETURN_MM(); @@ -131359,7 +132509,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, status) { ZEPHIR_MM_GROW(); if (!(zephir_is_php_version(50300))) { - ZEPHIR_CALL_FUNCTION(&status, "session_status", NULL, 59); + ZEPHIR_CALL_FUNCTION(&status, "session_status", NULL, 61); zephir_check_call_status(); do { if (ZEPHIR_IS_LONG(status, 0)) { @@ -131487,6 +132637,8 @@ ZEPHIR_DOC_METHOD(Phalcon_Session_AdapterInterface, isStarted); ZEPHIR_DOC_METHOD(Phalcon_Session_AdapterInterface, destroy); +ZEPHIR_DOC_METHOD(Phalcon_Session_AdapterInterface, regenerateId); + @@ -131613,7 +132765,7 @@ static PHP_METHOD(Phalcon_Session_Bag, initialize) { static PHP_METHOD(Phalcon_Session_Bag, destroy) { int ZEPHIR_LAST_CALL_STATUS; - zval *_0, *_1, *_2; + zval *_0, *_1, *_2, *_3; ZEPHIR_MM_GROW(); @@ -131622,9 +132774,12 @@ static PHP_METHOD(Phalcon_Session_Bag, destroy) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "initialize", NULL, 0); zephir_check_call_status(); } - _1 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _1, "remove", NULL, 0, _2); + ZEPHIR_INIT_VAR(_1); + array_init(_1); + zephir_update_property_this(this_ptr, SL("_data"), _1 TSRMLS_CC); + _2 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); + _3 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(NULL, _2, "remove", NULL, 0, _3); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -131825,7 +132980,7 @@ static PHP_METHOD(Phalcon_Session_Bag, __isset) { static PHP_METHOD(Phalcon_Session_Bag, remove) { int ZEPHIR_LAST_CALL_STATUS; - zval *property_param = NULL, *_0, *_1, *_2, *_3, *_4; + zval *property_param = NULL, *data, *_0, *_1; zval *property = NULL; ZEPHIR_MM_GROW(); @@ -131844,15 +132999,15 @@ static PHP_METHOD(Phalcon_Session_Bag, remove) { } - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - if (zephir_array_isset(_0, property)) { - _1 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - zephir_array_unset(&_1, property, PH_SEPARATE); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); - _3 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _2, "set", NULL, 0, _3, _4); + ZEPHIR_OBS_VAR(data); + zephir_read_property_this(&data, this_ptr, SL("_data"), PH_NOISY_CC); + if (zephir_array_isset(data, property)) { + zephir_array_unset(&data, property, PH_SEPARATE); + _0 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(NULL, _0, "set", NULL, 0, _1, data); zephir_check_call_status(); + zephir_update_property_this(this_ptr, SL("_data"), data TSRMLS_CC); RETURN_MM_BOOL(1); } RETURN_MM_BOOL(0); @@ -131918,7 +133073,7 @@ static PHP_METHOD(Phalcon_Session_Bag, getIterator) { } object_init_ex(return_value, zephir_get_internal_ce(SS("arrayiterator") TSRMLS_CC)); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 412, _1); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 411, _1); zephir_check_call_status(); RETURN_MM(); @@ -132206,7 +133361,7 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); ZEPHIR_INIT_VAR(_4); zephir_create_array(_4, 4, 0 TSRMLS_CC); @@ -132214,7 +133369,7 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) { zephir_array_update_string(&_4, SL("client"), &client, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("prefix"), &prefix, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("statsKey"), &statsKey, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, _4); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 312, _1, _4); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_libmemcached"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); @@ -132253,9 +133408,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) { ZEPHIR_INIT_NVAR(_6); ZVAL_STRING(_6, "gc", 1); zephir_array_fast_append(_11, _6); - ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _5, _7, _8, _9, _10, _11); + ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 409, _5, _7, _8, _9, _10, _11); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 411, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 410, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -132431,9 +133586,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 314, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -132472,9 +133627,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) { ZEPHIR_INIT_NVAR(_5); ZVAL_STRING(_5, "gc", 1); zephir_array_fast_append(_10, _5); - ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10); + ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 409, _4, _6, _7, _8, _9, _10); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 411, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 410, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -132648,9 +133803,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 315, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -132689,9 +133844,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct) { ZEPHIR_INIT_NVAR(_5); ZVAL_STRING(_5, "gc", 1); zephir_array_fast_append(_10, _5); - ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10); + ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 409, _4, _6, _7, _8, _9, _10); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_redis_ce, this_ptr, "__construct", &_11, 411, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_redis_ce, this_ptr, "__construct", &_11, 410, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -132932,7 +134087,7 @@ static PHP_METHOD(Phalcon_Tag_Select, selectField) { ZEPHIR_GET_CONSTANT(_6, "PHP_EOL"); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, "", _6); - ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 416, options, using, value, _7); + ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 415, options, using, value, _7); zephir_check_call_status(); zephir_concat_self(&code, _8 TSRMLS_CC); } else { @@ -132941,7 +134096,7 @@ static PHP_METHOD(Phalcon_Tag_Select, selectField) { ZEPHIR_GET_CONSTANT(_6, "PHP_EOL"); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, "", _6); - ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 417, options, value, _7); + ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 416, options, value, _7); zephir_check_call_status(); zephir_concat_self(&code, _8 TSRMLS_CC); } else { @@ -133079,12 +134234,12 @@ static PHP_METHOD(Phalcon_Tag_Select, _optionsFromArray) { ) { ZEPHIR_GET_HMKEY(optionValue, _1, _0); ZEPHIR_GET_HVALUE(optionText, _2); - ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 181, optionValue); + ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 182, optionValue); zephir_check_call_status(); if (Z_TYPE_P(optionText) == IS_ARRAY) { ZEPHIR_INIT_NVAR(_4); ZEPHIR_GET_CONSTANT(_4, "PHP_EOL"); - ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 417, optionText, value, closeOption); + ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 416, optionText, value, closeOption); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_7); ZEPHIR_GET_CONSTANT(_7, "PHP_EOL"); @@ -133478,7 +134633,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct) { - ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_csv_ce, this_ptr, "__construct", &_0, 426, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_csv_ce, this_ptr, "__construct", &_0, 425, options); zephir_check_call_status(); if (!(zephir_array_isset_string(options, SS("content")))) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter 'content' is required", "phalcon/translate/adapter/csv.zep", 43); @@ -133491,7 +134646,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct) { ZVAL_STRING(_3, ";", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_4); ZVAL_STRING(_4, "\"", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_load", NULL, 427, _1, _2, _3, _4); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_load", NULL, 426, _1, _2, _3, _4); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -133513,7 +134668,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Csv, _load) { ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "rb", 0); - ZEPHIR_CALL_FUNCTION(&fileHandler, "fopen", NULL, 292, file, &_0); + ZEPHIR_CALL_FUNCTION(&fileHandler, "fopen", NULL, 285, file, &_0); zephir_check_call_status(); if (Z_TYPE_P(fileHandler) != IS_RESOURCE) { ZEPHIR_INIT_VAR(_1); @@ -133527,7 +134682,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Csv, _load) { return; } while (1) { - ZEPHIR_CALL_FUNCTION(&data, "fgetcsv", &_3, 428, fileHandler, length, delimiter, enclosure); + ZEPHIR_CALL_FUNCTION(&data, "fgetcsv", &_3, 427, fileHandler, length, delimiter, enclosure); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(data)) { break; @@ -133685,7 +134840,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, __construct) { - ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_gettext_ce, this_ptr, "__construct", &_0, 426, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_gettext_ce, this_ptr, "__construct", &_0, 425, options); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, this_ptr, "prepareoptions", NULL, 0, options); zephir_check_call_status(); @@ -133718,22 +134873,22 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, query) { } - ZEPHIR_CALL_FUNCTION(&_0, "func_num_args", NULL, 421); + ZEPHIR_CALL_FUNCTION(&_0, "func_num_args", NULL, 420); zephir_check_call_status(); if (ZEPHIR_GT_LONG(_0, 2)) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 2); - ZEPHIR_CALL_FUNCTION(&domain, "func_get_arg", NULL, 420, &_1); + ZEPHIR_CALL_FUNCTION(&domain, "func_get_arg", NULL, 419, &_1); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(domain); ZVAL_NULL(domain); } if (!(zephir_is_true(domain))) { - ZEPHIR_CALL_FUNCTION(&translation, "gettext", NULL, 429, index); + ZEPHIR_CALL_FUNCTION(&translation, "gettext", NULL, 428, index); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&translation, "dgettext", NULL, 430, domain, index); + ZEPHIR_CALL_FUNCTION(&translation, "dgettext", NULL, 429, domain, index); zephir_check_call_status(); } ZEPHIR_RETURN_CALL_METHOD(this_ptr, "replaceplaceholders", NULL, 0, translation, placeholders); @@ -133831,12 +134986,12 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, nquery) { if (!(domain && Z_STRLEN_P(domain))) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, count); - ZEPHIR_CALL_FUNCTION(&translation, "ngettext", NULL, 431, msgid1, msgid2, &_0); + ZEPHIR_CALL_FUNCTION(&translation, "ngettext", NULL, 430, msgid1, msgid2, &_0); zephir_check_call_status(); } else { ZEPHIR_SINIT_NVAR(_0); ZVAL_LONG(&_0, count); - ZEPHIR_CALL_FUNCTION(&translation, "dngettext", NULL, 432, domain, msgid1, msgid2, &_0); + ZEPHIR_CALL_FUNCTION(&translation, "dngettext", NULL, 431, domain, msgid1, msgid2, &_0); zephir_check_call_status(); } ZEPHIR_RETURN_CALL_METHOD(this_ptr, "replaceplaceholders", NULL, 0, translation, placeholders); @@ -133867,7 +135022,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setDomain) { } - ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 433, domain); + ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 432, domain); zephir_check_call_status(); RETURN_MM(); @@ -133882,7 +135037,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, resetDomain) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getdefaultdomain", NULL, 0); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 433, _0); + ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 432, _0); zephir_check_call_status(); RETURN_MM(); @@ -133944,14 +135099,14 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setDirectory) { ) { ZEPHIR_GET_HMKEY(key, _1, _0); ZEPHIR_GET_HVALUE(value, _2); - ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 434, key, value); + ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 433, key, value); zephir_check_call_status(); } } } else { ZEPHIR_CALL_METHOD(&_4, this_ptr, "getdefaultdomain", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 434, _4, directory); + ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 433, _4, directory); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -133994,7 +135149,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setLocale) { ZEPHIR_INIT_VAR(_0); - ZEPHIR_CALL_FUNCTION(&_1, "func_get_args", NULL, 166); + ZEPHIR_CALL_FUNCTION(&_1, "func_get_args", NULL, 167); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_2); ZVAL_STRING(&_2, "setlocale", 0); @@ -134007,12 +135162,12 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setLocale) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_locale"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_4); ZEPHIR_CONCAT_SV(_4, "LC_ALL=", _3); - ZEPHIR_CALL_FUNCTION(NULL, "putenv", NULL, 435, _4); + ZEPHIR_CALL_FUNCTION(NULL, "putenv", NULL, 434, _4); zephir_check_call_status(); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_locale"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_6); ZVAL_LONG(&_6, 0); - ZEPHIR_CALL_FUNCTION(NULL, "setlocale", NULL, 415, &_6, _5); + ZEPHIR_CALL_FUNCTION(NULL, "setlocale", NULL, 414, &_6, _5); zephir_check_call_status(); RETURN_MM_MEMBER(this_ptr, "_locale"); @@ -134125,7 +135280,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_NativeArray, __construct) { - ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_nativearray_ce, this_ptr, "__construct", &_0, 426, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_nativearray_ce, this_ptr, "__construct", &_0, 425, options); zephir_check_call_status(); ZEPHIR_OBS_VAR(data); if (!(zephir_array_isset_string_fetch(&data, options, SS("content"), 0 TSRMLS_CC))) { @@ -134331,7 +135486,7 @@ static PHP_METHOD(Phalcon_Translate_Interpolator_IndexedArray, replacePlaceholde } if (_0) { Z_SET_ISREF_P(placeholders); - ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 386, placeholders, translation); + ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 379, placeholders, translation); Z_UNSET_ISREF_P(placeholders); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_1); @@ -134552,7 +135707,7 @@ static PHP_METHOD(Phalcon_Validation_Message, __set_state) { zephir_array_fetch_string(&_0, message, SL("_message"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC); zephir_array_fetch_string(&_1, message, SL("_field"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC); zephir_array_fetch_string(&_2, message, SL("_type"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 436, _0, _1, _2); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 435, _0, _1, _2); zephir_check_call_status(); RETURN_MM(); @@ -135166,7 +136321,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) { if (_2) { RETURN_MM_BOOL(1); } - ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 437, value); + ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 436, value); zephir_check_call_status(); if (!(zephir_is_true(_3))) { ZEPHIR_INIT_NVAR(_1); @@ -135195,11 +136350,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Alnum", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -135269,7 +136424,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) { if (_2) { RETURN_MM_BOOL(1); } - ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 438, value); + ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 437, value); zephir_check_call_status(); if (!(zephir_is_true(_3))) { ZEPHIR_INIT_NVAR(_1); @@ -135298,11 +136453,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Alpha", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -135415,11 +136570,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Between, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Between", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -135483,7 +136638,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&valueWith, validation, "getvalue", NULL, 0, fieldWith); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 439, value, valueWith); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 438, value, valueWith); zephir_check_call_status(); if (!(zephir_is_true(_1))) { ZEPHIR_INIT_NVAR(_0); @@ -135522,11 +136677,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZVAL_STRING(_3, "Confirmation", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _2, field, _3); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 435, _2, field, _3); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -135565,12 +136720,12 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, compare) { } ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "utf-8", 0); - ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 194, a, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 195, a, &_3); zephir_check_call_status(); zephir_get_strval(a, _4); ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "utf-8", 0); - ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 194, b, &_3); + ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 195, b, &_3); zephir_check_call_status(); zephir_get_strval(b, _6); } @@ -135637,7 +136792,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) { if (_2) { RETURN_MM_BOOL(1); } - ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 440, value); + ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 439, value); zephir_check_call_status(); if (!(zephir_is_true(_3))) { ZEPHIR_INIT_NVAR(_1); @@ -135666,11 +136821,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Digit", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -135742,7 +136897,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Email, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 274); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_1); @@ -135771,11 +136926,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Email, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "Email", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _5, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -135884,11 +137039,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_ExclusionIn, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_3, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_3, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_4); ZVAL_STRING(_4, "ExclusionIn", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _3, field, _4); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _3, field, _4); zephir_check_temp_parameter(_4); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -136000,11 +137155,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_11); ZVAL_STRING(_11, "FileIniSize", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 436, _9, field, _11); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 435, _9, field, _11); zephir_check_temp_parameter(_11); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -136044,7 +137199,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { _20 = _18; if (!(_20)) { zephir_array_fetch_string(&_21, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 79 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 232, _21); + ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 233, _21); zephir_check_call_status(); _20 = !zephir_is_true(_9); } @@ -136066,11 +137221,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_23); ZVAL_STRING(_23, "FileEmpty", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _22, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -136103,11 +137258,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_23); ZVAL_STRING(_23, "FileValid", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _9, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _9, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -136153,7 +137308,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { zephir_array_fetch_long(&unit, matches, 2, PH_NOISY, "phalcon/validation/validator/file.zep", 115 TSRMLS_CC); } zephir_array_fetch_long(&_28, matches, 1, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _28); + ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 304, _28); zephir_check_call_status(); ZEPHIR_INIT_VAR(_30); zephir_array_fetch(&_31, byteUnits, unit, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC); @@ -136163,9 +137318,9 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { ZEPHIR_INIT_VAR(bytes); mul_function(bytes, _22, _30 TSRMLS_CC); zephir_array_fetch_string(&_33, value, SL("size"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 120 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _33); + ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 304, _33); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 311, bytes); + ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 304, bytes); zephir_check_call_status(); if (ZEPHIR_GT(_22, _34)) { ZEPHIR_INIT_NVAR(_30); @@ -136186,11 +137341,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_30); object_init_ex(_30, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_36); ZVAL_STRING(_36, "FileSize", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 436, _35, field, _36); + ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 435, _35, field, _36); zephir_check_temp_parameter(_36); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _30); @@ -136216,12 +137371,12 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { if ((zephir_function_exists_ex(SS("finfo_open") TSRMLS_CC) == SUCCESS)) { ZEPHIR_SINIT_NVAR(_32); ZVAL_LONG(&_32, 16); - ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 229, &_32); + ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 230, &_32); zephir_check_call_status(); zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 143 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, tmp, _28); + ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 231, tmp, _28); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, tmp); + ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 232, tmp); zephir_check_call_status(); } else { ZEPHIR_OBS_NVAR(mime); @@ -136248,11 +137403,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_23); ZVAL_STRING(_23, "FileType", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _22, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -136276,7 +137431,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } if (_37) { zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 164 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 249, _28); + ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 241, _28); zephir_check_call_status(); ZEPHIR_OBS_VAR(width); zephir_array_fetch_long(&width, tmp, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 165 TSRMLS_CC); @@ -136333,11 +137488,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_23); ZVAL_STRING(_23, "FileMinResolution", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _35, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _35, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -136389,11 +137544,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_23); object_init_ex(_23, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_41, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_41, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_26); ZVAL_STRING(_26, "FileMaxResolution", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 436, _41, field, _26); + ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 435, _41, field, _26); zephir_check_temp_parameter(_26); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _23); @@ -136507,11 +137662,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Identical, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_4); ZVAL_STRING(_4, "Identical", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _4); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _2, field, _4); zephir_check_temp_parameter(_4); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -136608,7 +137763,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) { zephir_check_temp_parameter(_1); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 365, value, domain, strict); + ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 358, value, domain, strict); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_1); @@ -136640,11 +137795,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "InclusionIn", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _5, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -136746,11 +137901,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Numericality, validate) { } ZEPHIR_INIT_NVAR(_5); object_init_ex(_5, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "Numericality", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 436, _6, field, _7); + ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 435, _6, field, _7); zephir_check_temp_parameter(_7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _5); @@ -136839,11 +137994,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_PresenceOf, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZVAL_STRING(_3, "PresenceOf", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _3); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _2, field, _3); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -136955,11 +138110,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Regex, validate) { } ZEPHIR_INIT_NVAR(_4); object_init_ex(_4, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "Regex", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 436, _6, field, _7); + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 435, _6, field, _7); zephir_check_temp_parameter(_7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _4); @@ -137058,7 +138213,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) { zephir_check_call_status(); } if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value); + ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 359, value); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(length); @@ -137089,11 +138244,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "TooLong", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 436, _4, field, _6); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 435, _4, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -137126,11 +138281,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) { } ZEPHIR_INIT_NVAR(_6); object_init_ex(_6, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_8); ZVAL_STRING(_8, "TooShort", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 436, _4, field, _8); + ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 435, _4, field, _8); zephir_check_temp_parameter(_8); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _6); @@ -137267,11 +138422,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "Uniqueness", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _6, field, _7); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 435, _6, field, _7); zephir_check_temp_parameter(_7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -137343,7 +138498,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Url, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 273); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_1); @@ -137372,11 +138527,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Url, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "Url", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _5, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -137453,6 +138608,7 @@ zend_class_entry *phalcon_di_serviceinterface_ce; zend_class_entry *phalcon_escaperinterface_ce; zend_class_entry *phalcon_events_managerinterface_ce; zend_class_entry *phalcon_filterinterface_ce; +zend_class_entry *phalcon_http_cookieinterface_ce; zend_class_entry *phalcon_http_request_fileinterface_ce; zend_class_entry *phalcon_http_requestinterface_ce; zend_class_entry *phalcon_http_response_cookiesinterface_ce; @@ -137516,6 +138672,7 @@ zend_class_entry *phalcon_cache_frontend_data_ce; zend_class_entry *phalcon_di_factorydefault_ce; zend_class_entry *phalcon_mvc_model_transaction_exception_ce; zend_class_entry *phalcon_mvc_router_ce; +zend_class_entry *phalcon_mvc_view_exception_ce; zend_class_entry *phalcon_0__closure_ce; zend_class_entry *phalcon_acl_adapter_memory_ce; zend_class_entry *phalcon_acl_ce; @@ -137714,7 +138871,7 @@ zend_class_entry *phalcon_mvc_view_ce; zend_class_entry *phalcon_mvc_view_engine_php_ce; zend_class_entry *phalcon_mvc_view_engine_volt_ce; zend_class_entry *phalcon_mvc_view_engine_volt_compiler_ce; -zend_class_entry *phalcon_mvc_view_exception_ce; +zend_class_entry *phalcon_mvc_view_engine_volt_exception_ce; zend_class_entry *phalcon_mvc_view_simple_ce; zend_class_entry *phalcon_paginator_adapter_model_ce; zend_class_entry *phalcon_paginator_adapter_nativearray_ce; @@ -137725,6 +138882,7 @@ zend_class_entry *phalcon_queue_beanstalk_job_ce; zend_class_entry *phalcon_registry_ce; zend_class_entry *phalcon_security_ce; zend_class_entry *phalcon_security_exception_ce; +zend_class_entry *phalcon_security_random_ce; zend_class_entry *phalcon_session_adapter_files_ce; zend_class_entry *phalcon_session_adapter_libmemcached_ce; zend_class_entry *phalcon_session_adapter_memcache_ce; @@ -137781,6 +138939,7 @@ PHP_INI_BEGIN() STD_PHP_INI_BOOLEAN("phalcon.orm.exception_on_failed_save", "0", PHP_INI_ALL, OnUpdateBool, orm.exception_on_failed_save, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.enable_literals", "1", PHP_INI_ALL, OnUpdateBool, orm.enable_literals, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.late_state_binding", "0", PHP_INI_ALL, OnUpdateBool, orm.late_state_binding, zend_phalcon_globals, phalcon_globals) + STD_PHP_INI_BOOLEAN("phalcon.orm.enable_implicit_joins", "1", PHP_INI_ALL, OnUpdateBool, orm.enable_implicit_joins, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.cast_on_hydrate", "0", PHP_INI_ALL, OnUpdateBool, orm.cast_on_hydrate, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.ignore_unknown_columns", "0", PHP_INI_ALL, OnUpdateBool, orm.ignore_unknown_columns, zend_phalcon_globals, phalcon_globals) PHP_INI_END() @@ -137846,6 +139005,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_EscaperInterface); ZEPHIR_INIT(Phalcon_Events_ManagerInterface); ZEPHIR_INIT(Phalcon_FilterInterface); + ZEPHIR_INIT(Phalcon_Http_CookieInterface); ZEPHIR_INIT(Phalcon_Http_RequestInterface); ZEPHIR_INIT(Phalcon_Http_Request_FileInterface); ZEPHIR_INIT(Phalcon_Http_ResponseInterface); @@ -137909,6 +139069,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_Di_FactoryDefault); ZEPHIR_INIT(Phalcon_Mvc_Model_Transaction_Exception); ZEPHIR_INIT(Phalcon_Mvc_Router); + ZEPHIR_INIT(Phalcon_Mvc_View_Exception); ZEPHIR_INIT(Phalcon_Acl); ZEPHIR_INIT(Phalcon_Acl_Adapter_Memory); ZEPHIR_INIT(Phalcon_Acl_Exception); @@ -138106,7 +139267,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Php); ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Volt); ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Volt_Compiler); - ZEPHIR_INIT(Phalcon_Mvc_View_Exception); + ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Volt_Exception); ZEPHIR_INIT(Phalcon_Mvc_View_Simple); ZEPHIR_INIT(Phalcon_Paginator_Adapter_Model); ZEPHIR_INIT(Phalcon_Paginator_Adapter_NativeArray); @@ -138117,6 +139278,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_Registry); ZEPHIR_INIT(Phalcon_Security); ZEPHIR_INIT(Phalcon_Security_Exception); + ZEPHIR_INIT(Phalcon_Security_Random); ZEPHIR_INIT(Phalcon_Session); ZEPHIR_INIT(Phalcon_Session_Adapter_Files); ZEPHIR_INIT(Phalcon_Session_Adapter_Libmemcached); @@ -138210,6 +139372,7 @@ static void php_zephir_init_globals(zend_phalcon_globals *phalcon_globals TSRMLS + } static PHP_RINIT_FUNCTION(phalcon) diff --git a/build/32bits/phalcon.zep.h b/build/32bits/phalcon.zep.h index 877bafc5931..c72569af8a9 100644 --- a/build/32bits/phalcon.zep.h +++ b/build/32bits/phalcon.zep.h @@ -2627,6 +2627,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, setOptions); static PHP_METHOD(Phalcon_Session_Adapter, getOptions); static PHP_METHOD(Phalcon_Session_Adapter, setName); static PHP_METHOD(Phalcon_Session_Adapter, getName); +static PHP_METHOD(Phalcon_Session_Adapter, regenerateId); static PHP_METHOD(Phalcon_Session_Adapter, get); static PHP_METHOD(Phalcon_Session_Adapter, set); static PHP_METHOD(Phalcon_Session_Adapter, has); @@ -2653,6 +2654,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setname, 0, 0, 1) ZEND_ARG_INFO(0, name) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_regenerateid, 0, 0, 0) + ZEND_ARG_INFO(0, deleteOldSession) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_get, 0, 0, 1) ZEND_ARG_INFO(0, index) ZEND_ARG_INFO(0, defaultValue) @@ -2676,6 +2681,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setid, 0, 0, 1) ZEND_ARG_INFO(0, id) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_destroy, 0, 0, 0) + ZEND_ARG_INFO(0, removeData) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___get, 0, 0, 1) ZEND_ARG_INFO(0, index) ZEND_END_ARG_INFO() @@ -2700,6 +2709,7 @@ ZEPHIR_INIT_FUNCS(phalcon_session_adapter_method_entry) { PHP_ME(Phalcon_Session_Adapter, getOptions, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, setName, arginfo_phalcon_session_adapter_setname, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, getName, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Session_Adapter, regenerateId, arginfo_phalcon_session_adapter_regenerateid, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, get, arginfo_phalcon_session_adapter_get, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, set, arginfo_phalcon_session_adapter_set, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, has, arginfo_phalcon_session_adapter_has, ZEND_ACC_PUBLIC) @@ -2707,7 +2717,7 @@ ZEPHIR_INIT_FUNCS(phalcon_session_adapter_method_entry) { PHP_ME(Phalcon_Session_Adapter, getId, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, setId, arginfo_phalcon_session_adapter_setid, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, isStarted, NULL, ZEND_ACC_PUBLIC) - PHP_ME(Phalcon_Session_Adapter, destroy, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Session_Adapter, destroy, arginfo_phalcon_session_adapter_destroy, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, status, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, __get, arginfo_phalcon_session_adapter___get, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, __set, arginfo_phalcon_session_adapter___set, ZEND_ACC_PUBLIC) @@ -2742,6 +2752,14 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_remove, 0, 0, 1) ZEND_ARG_INFO(0, index) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_destroy, 0, 0, 0) + ZEND_ARG_INFO(0, removeData) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_regenerateid, 0, 0, 0) + ZEND_ARG_INFO(0, deleteOldSession) +ZEND_END_ARG_INFO() + ZEPHIR_INIT_FUNCS(phalcon_session_adapterinterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, start, NULL) PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, setOptions, arginfo_phalcon_session_adapterinterface_setoptions) @@ -2752,7 +2770,8 @@ ZEPHIR_INIT_FUNCS(phalcon_session_adapterinterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, remove, arginfo_phalcon_session_adapterinterface_remove) PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getId, NULL) PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, isStarted, NULL) - PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, destroy, NULL) + PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, destroy, arginfo_phalcon_session_adapterinterface_destroy) + PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, regenerateId, arginfo_phalcon_session_adapterinterface_regenerateid) PHP_FE_END }; @@ -4594,6 +4613,11 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_di_serviceinterface_resolve, 0, 0, 0) ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 1) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_di_serviceinterface_setparameter, 0, 0, 2) + ZEND_ARG_INFO(0, position) + ZEND_ARG_ARRAY_INFO(0, parameter, 0) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_di_serviceinterface___set_state, 0, 0, 1) ZEND_ARG_ARRAY_INFO(0, attributes, 0) ZEND_END_ARG_INFO() @@ -4606,6 +4630,7 @@ ZEPHIR_INIT_FUNCS(phalcon_di_serviceinterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, setDefinition, arginfo_phalcon_di_serviceinterface_setdefinition) PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, getDefinition, NULL) PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, resolve, arginfo_phalcon_di_serviceinterface_resolve) + PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, setParameter, arginfo_phalcon_di_serviceinterface_setparameter) ZEND_FENTRY(__set_state, NULL, arginfo_phalcon_di_serviceinterface___set_state, ZEND_ACC_STATIC|ZEND_ACC_ABSTRACT|ZEND_ACC_PUBLIC) PHP_FE_END }; @@ -4712,6 +4737,64 @@ ZEPHIR_INIT_FUNCS(phalcon_filterinterface_method_entry) { PHP_FE_END }; +zend_class_entry *phalcon_http_cookieinterface_ce; + +ZEPHIR_INIT_CLASS(Phalcon_Http_CookieInterface); + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setvalue, 0, 0, 1) + ZEND_ARG_INFO(0, value) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_getvalue, 0, 0, 0) + ZEND_ARG_INFO(0, filters) + ZEND_ARG_INFO(0, defaultValue) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_useencryption, 0, 0, 1) + ZEND_ARG_INFO(0, useEncryption) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setexpiration, 0, 0, 1) + ZEND_ARG_INFO(0, expire) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setpath, 0, 0, 1) + ZEND_ARG_INFO(0, path) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setdomain, 0, 0, 1) + ZEND_ARG_INFO(0, domain) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setsecure, 0, 0, 1) + ZEND_ARG_INFO(0, secure) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_sethttponly, 0, 0, 1) + ZEND_ARG_INFO(0, httpOnly) +ZEND_END_ARG_INFO() + +ZEPHIR_INIT_FUNCS(phalcon_http_cookieinterface_method_entry) { + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setValue, arginfo_phalcon_http_cookieinterface_setvalue) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getValue, arginfo_phalcon_http_cookieinterface_getvalue) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, send, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, delete, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, useEncryption, arginfo_phalcon_http_cookieinterface_useencryption) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, isUsingEncryption, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setExpiration, arginfo_phalcon_http_cookieinterface_setexpiration) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getExpiration, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setPath, arginfo_phalcon_http_cookieinterface_setpath) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getName, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getPath, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setDomain, arginfo_phalcon_http_cookieinterface_setdomain) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getDomain, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setSecure, arginfo_phalcon_http_cookieinterface_setsecure) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getSecure, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setHttpOnly, arginfo_phalcon_http_cookieinterface_sethttponly) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getHttpOnly, NULL) + PHP_FE_END +}; + zend_class_entry *phalcon_http_request_fileinterface_ce; ZEPHIR_INIT_CLASS(Phalcon_Http_Request_FileInterface); @@ -5247,12 +5330,6 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_criteriainterface_notinwhere, 0 ZEND_ARG_ARRAY_INFO(0, values, 0) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_criteriainterface_frominput, 0, 0, 3) - ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 0) - ZEND_ARG_INFO(0, modelName) - ZEND_ARG_ARRAY_INFO(0, data, 0) -ZEND_END_ARG_INFO() - ZEPHIR_INIT_FUNCS(phalcon_mvc_model_criteriainterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, setModelName, arginfo_phalcon_mvc_model_criteriainterface_setmodelname) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getModelName, NULL) @@ -5275,7 +5352,6 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_criteriainterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getLimit, NULL) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getOrder, NULL) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getParams, NULL) - ZEND_FENTRY(fromInput, NULL, arginfo_phalcon_mvc_model_criteriainterface_frominput, ZEND_ACC_STATIC|ZEND_ACC_ABSTRACT|ZEND_ACC_PUBLIC) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, execute, NULL) PHP_FE_END }; @@ -6369,6 +6445,11 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_urlinterface_method_entry) { PHP_FE_END }; +zend_class_entry *phalcon_mvc_view_exception_ce; + +ZEPHIR_INIT_CLASS(Phalcon_Mvc_View_Exception); + + zend_class_entry *phalcon_mvc_viewinterface_ce; ZEPHIR_INIT_CLASS(Phalcon_Mvc_ViewInterface); @@ -8134,6 +8215,7 @@ static PHP_METHOD(Phalcon_Cache_Multiple, start); static PHP_METHOD(Phalcon_Cache_Multiple, save); static PHP_METHOD(Phalcon_Cache_Multiple, delete); static PHP_METHOD(Phalcon_Cache_Multiple, exists); +static PHP_METHOD(Phalcon_Cache_Multiple, flush); ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_multiple___construct, 0, 0, 0) ZEND_ARG_INFO(0, backends) @@ -8177,6 +8259,7 @@ ZEPHIR_INIT_FUNCS(phalcon_cache_multiple_method_entry) { PHP_ME(Phalcon_Cache_Multiple, save, arginfo_phalcon_cache_multiple_save, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Cache_Multiple, delete, arginfo_phalcon_cache_multiple_delete, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Cache_Multiple, exists, arginfo_phalcon_cache_multiple_exists, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Cache_Multiple, flush, NULL, ZEND_ACC_PUBLIC) PHP_FE_END }; @@ -9682,11 +9765,11 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setsqlstatement, 0, 0, 1 ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setsqlvariables, 0, 0, 1) - ZEND_ARG_INFO(0, sqlVariables) + ZEND_ARG_ARRAY_INFO(0, sqlVariables, 0) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setsqlbindtypes, 0, 0, 1) - ZEND_ARG_INFO(0, sqlBindTypes) + ZEND_ARG_ARRAY_INFO(0, sqlBindTypes, 0) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setinitialtime, 0, 0, 1) @@ -13544,7 +13627,7 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model___call, 0, 0, 2) ZEND_ARG_INFO(0, arguments) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model___callstatic, 0, 0, 1) +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model___callstatic, 0, 0, 2) ZEND_ARG_INFO(0, method) ZEND_ARG_INFO(0, arguments) ZEND_END_ARG_INFO() @@ -13879,6 +13962,7 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_criteria_frominput, 0, 0, 3) ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 0) ZEND_ARG_INFO(0, modelName) ZEND_ARG_ARRAY_INFO(0, data, 0) + ZEND_ARG_INFO(0, operator) ZEND_END_ARG_INFO() ZEPHIR_INIT_FUNCS(phalcon_mvc_model_criteria_method_entry) { @@ -14723,6 +14807,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, getSql); ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query___construct, 0, 0, 0) ZEND_ARG_INFO(0, phql) ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 1) + ZEND_ARG_INFO(0, options) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query_setdi, 0, 0, 1) @@ -14985,6 +15070,7 @@ ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query_builder_addfrom, 0, 0, 1) ZEND_ARG_INFO(0, model) ZEND_ARG_INFO(0, alias) + ZEND_ARG_INFO(0, with) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query_builder_join, 0, 0, 1) @@ -15164,6 +15250,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Relation, getReferencedModel); static PHP_METHOD(Phalcon_Mvc_Model_Relation, getFields); static PHP_METHOD(Phalcon_Mvc_Model_Relation, getReferencedFields); static PHP_METHOD(Phalcon_Mvc_Model_Relation, getOptions); +static PHP_METHOD(Phalcon_Mvc_Model_Relation, getOption); static PHP_METHOD(Phalcon_Mvc_Model_Relation, isForeignKey); static PHP_METHOD(Phalcon_Mvc_Model_Relation, getForeignKey); static PHP_METHOD(Phalcon_Mvc_Model_Relation, getParams); @@ -15187,6 +15274,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_relation_setintermediaterelatio ZEND_ARG_INFO(0, intermediateReferencedFields) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_relation_getoption, 0, 0, 1) + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO() + ZEPHIR_INIT_FUNCS(phalcon_mvc_model_relation_method_entry) { PHP_ME(Phalcon_Mvc_Model_Relation, __construct, arginfo_phalcon_mvc_model_relation___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR) PHP_ME(Phalcon_Mvc_Model_Relation, setIntermediateRelation, arginfo_phalcon_mvc_model_relation_setintermediaterelation, ZEND_ACC_PUBLIC) @@ -15195,6 +15286,7 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_relation_method_entry) { PHP_ME(Phalcon_Mvc_Model_Relation, getFields, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getReferencedFields, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getOptions, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Mvc_Model_Relation, getOption, arginfo_phalcon_mvc_model_relation_getoption, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, isForeignKey, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getForeignKey, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getParams, NULL, ZEND_ACC_PUBLIC) @@ -16640,9 +16732,9 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_view_engine_volt_compiler_method_entry) { PHP_FE_END }; -zend_class_entry *phalcon_mvc_view_exception_ce; +zend_class_entry *phalcon_mvc_view_engine_volt_exception_ce; -ZEPHIR_INIT_CLASS(Phalcon_Mvc_View_Exception); +ZEPHIR_INIT_CLASS(Phalcon_Mvc_View_Engine_Volt_Exception); zend_class_entry *phalcon_mvc_view_simple_ce; @@ -16847,6 +16939,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, choose); static PHP_METHOD(Phalcon_Queue_Beanstalk, watch); static PHP_METHOD(Phalcon_Queue_Beanstalk, stats); static PHP_METHOD(Phalcon_Queue_Beanstalk, statsTube); +static PHP_METHOD(Phalcon_Queue_Beanstalk, listTubes); static PHP_METHOD(Phalcon_Queue_Beanstalk, peekReady); static PHP_METHOD(Phalcon_Queue_Beanstalk, peekBuried); static PHP_METHOD(Phalcon_Queue_Beanstalk, readStatus); @@ -16897,6 +16990,7 @@ ZEPHIR_INIT_FUNCS(phalcon_queue_beanstalk_method_entry) { PHP_ME(Phalcon_Queue_Beanstalk, watch, arginfo_phalcon_queue_beanstalk_watch, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, stats, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, statsTube, arginfo_phalcon_queue_beanstalk_statstube, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Queue_Beanstalk, listTubes, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, peekReady, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, peekBuried, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, readStatus, NULL, ZEND_ACC_FINAL|ZEND_ACC_PUBLIC) @@ -17130,6 +17224,48 @@ zend_class_entry *phalcon_security_exception_ce; ZEPHIR_INIT_CLASS(Phalcon_Security_Exception); +zend_class_entry *phalcon_security_random_ce; + +ZEPHIR_INIT_CLASS(Phalcon_Security_Random); + +static PHP_METHOD(Phalcon_Security_Random, bytes); +static PHP_METHOD(Phalcon_Security_Random, hex); +static PHP_METHOD(Phalcon_Security_Random, base64); +static PHP_METHOD(Phalcon_Security_Random, base64Safe); +static PHP_METHOD(Phalcon_Security_Random, uuid); +static PHP_METHOD(Phalcon_Security_Random, number); + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_bytes, 0, 0, 0) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_hex, 0, 0, 0) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_base64, 0, 0, 0) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_base64safe, 0, 0, 0) + ZEND_ARG_INFO(0, len) + ZEND_ARG_INFO(0, padding) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_number, 0, 0, 1) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEPHIR_INIT_FUNCS(phalcon_security_random_method_entry) { + PHP_ME(Phalcon_Security_Random, bytes, arginfo_phalcon_security_random_bytes, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, hex, arginfo_phalcon_security_random_hex, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, base64, arginfo_phalcon_security_random_base64, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, base64Safe, arginfo_phalcon_security_random_base64safe, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, uuid, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, number, arginfo_phalcon_security_random_number, ZEND_ACC_PUBLIC) + PHP_FE_END +}; + zend_class_entry *phalcon_session_ce; ZEPHIR_INIT_CLASS(Phalcon_Session); diff --git a/build/32bits/php_phalcon.h b/build/32bits/php_phalcon.h index aed59e8482d..34511ce576f 100644 --- a/build/32bits/php_phalcon.h +++ b/build/32bits/php_phalcon.h @@ -196,7 +196,7 @@ typedef zend_function zephir_fcall_cache_entry; #define PHP_PHALCON_NAME "phalcon" -#define PHP_PHALCON_VERSION "2.0.6" +#define PHP_PHALCON_VERSION "2.0.7" #define PHP_PHALCON_EXTNAME "phalcon" #define PHP_PHALCON_AUTHOR "Phalcon Team and contributors" #define PHP_PHALCON_ZEPVERSION "0.7.1b" @@ -219,6 +219,7 @@ typedef struct _zephir_struct_orm { zend_bool exception_on_failed_save; zend_bool enable_literals; zend_bool late_state_binding; + zend_bool enable_implicit_joins; zend_bool cast_on_hydrate; zend_bool ignore_unknown_columns; } zephir_struct_orm; diff --git a/build/64bits/phalcon.zep.c b/build/64bits/phalcon.zep.c index f03e012a1f9..e17ef2cdf8d 100644 --- a/build/64bits/phalcon.zep.c +++ b/build/64bits/phalcon.zep.c @@ -248,23 +248,23 @@ PHP includes the Zend Engine, freely available at #define PHQL_IDENTIFIER 30 #define PHQL_DOT 31 #define PHQL_AS 32 -#define PHQL_WITH 33 -#define PHQL_INNER 34 -#define PHQL_JOIN 35 -#define PHQL_CROSS 36 -#define PHQL_LEFT 37 -#define PHQL_OUTER 38 -#define PHQL_RIGHT 39 -#define PHQL_FULL 40 -#define PHQL_ON 41 -#define PHQL_INSERT 42 -#define PHQL_INTO 43 -#define PHQL_VALUES 44 -#define PHQL_PARENTHESES_OPEN 45 -#define PHQL_PARENTHESES_CLOSE 46 -#define PHQL_UPDATE 47 -#define PHQL_SET 48 -#define PHQL_DELETE 49 +#define PHQL_INNER 33 +#define PHQL_JOIN 34 +#define PHQL_CROSS 35 +#define PHQL_LEFT 36 +#define PHQL_OUTER 37 +#define PHQL_RIGHT 38 +#define PHQL_FULL 39 +#define PHQL_ON 40 +#define PHQL_INSERT 41 +#define PHQL_INTO 42 +#define PHQL_VALUES 43 +#define PHQL_PARENTHESES_OPEN 44 +#define PHQL_PARENTHESES_CLOSE 45 +#define PHQL_UPDATE 46 +#define PHQL_SET 47 +#define PHQL_DELETE 48 +#define PHQL_WITH 49 #define PHQL_WHERE 50 #define PHQL_ORDER 51 #define PHQL_BY 52 @@ -3765,10 +3765,19 @@ static void zephir_concat_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) #include #include +double zephir_sin(zval *op1 TSRMLS_DC); +double zephir_asin(zval *op1 TSRMLS_DC); +double zephir_tan(zval *op1 TSRMLS_DC); +double zephir_cos(zval *op1 TSRMLS_DC); +double zephir_acos(zval *op1 TSRMLS_DC); +double zephir_sqrt(zval *op1 TSRMLS_DC); + double zephir_floor(zval *op1 TSRMLS_DC); double zephir_ceil(zval *op1 TSRMLS_DC); + static void zephir_round(zval *return_value, zval *op1, zval *op2, zval *op3 TSRMLS_DC); static void zephir_pow(zval *return_value, zval *op1, zval *op2 TSRMLS_DC); + long zephir_mt_rand(long min, long max TSRMLS_DC); #endif @@ -16302,6 +16311,96 @@ double zephir_floor(zval *op1 TSRMLS_DC) return floor(zephir_get_numberval(op1)); } +double zephir_sin(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return sin(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return sin(zephir_get_numberval(op1)); +} + +double zephir_asin(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return asin(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return asin(zephir_get_numberval(op1)); +} + +double zephir_cos(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return cos(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return cos(zephir_get_numberval(op1)); +} + +double zephir_acos(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return acos(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return acos(zephir_get_numberval(op1)); +} + +double zephir_sqrt(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return sqrt(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return sqrt(zephir_get_numberval(op1)); +} + +double zephir_tan(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return tan(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return tan(zephir_get_numberval(op1)); +} + double zephir_ceil(zval *op1 TSRMLS_DC) { @@ -16397,6 +16496,8 @@ static void zephir_pow_function_ex(zval *return_value, zval *zbase, zval *zexp T } #endif + + long zephir_mt_rand(long min, long max TSRMLS_DC) { long number; @@ -17626,7 +17727,7 @@ static PHP_METHOD(phalcon_0__closure, __invoke) { zephir_array_fetch_long(&_0, matches, 1, PH_NOISY | PH_READONLY, "phalcon/text.zep", 272 TSRMLS_CC); ZEPHIR_INIT_VAR(words); zephir_fast_explode_str(words, SL("|"), _0, LONG_MAX TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 442, words); + ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 441, words); zephir_check_call_status(); zephir_array_fetch(&_1, words, _2, PH_NOISY | PH_READONLY, "phalcon/text.zep", 273 TSRMLS_CC); RETURN_CTOR(_1); @@ -17729,7 +17830,7 @@ static PHP_METHOD(Phalcon_Config, offsetExists) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); RETURN_MM_BOOL(zephir_isset_property_zval(this_ptr, index TSRMLS_CC)); @@ -17750,7 +17851,7 @@ static PHP_METHOD(Phalcon_Config, get) { } - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); if (zephir_isset_property_zval(this_ptr, index TSRMLS_CC)) { @@ -17774,7 +17875,7 @@ static PHP_METHOD(Phalcon_Config, offsetGet) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); ZEPHIR_OBS_VAR(_1); @@ -17794,13 +17895,13 @@ static PHP_METHOD(Phalcon_Config, offsetSet) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); if (Z_TYPE_P(value) == IS_ARRAY) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_config_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 21, value); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 22, value); zephir_check_call_status(); zephir_update_property_zval_zval(this_ptr, index, _1 TSRMLS_CC); } else { @@ -17821,7 +17922,7 @@ static PHP_METHOD(Phalcon_Config, offsetUnset) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); zephir_update_property_zval_zval(this_ptr, index, ZEPHIR_GLOBAL(global_null) TSRMLS_CC); @@ -17839,7 +17940,7 @@ static PHP_METHOD(Phalcon_Config, merge) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_merge", NULL, 22, config); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_merge", NULL, 23, config); zephir_check_call_status(); RETURN_MM(); @@ -17856,7 +17957,7 @@ static PHP_METHOD(Phalcon_Config, toArray) { ZEPHIR_INIT_VAR(arrayConfig); array_init(arrayConfig); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, this_ptr); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/config.zep", 180); for ( @@ -17888,7 +17989,7 @@ static PHP_METHOD(Phalcon_Config, count) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, this_ptr); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM_LONG(zephir_fast_count_int(_0 TSRMLS_CC)); @@ -17908,7 +18009,7 @@ static PHP_METHOD(Phalcon_Config, __set_state) { object_init_ex(return_value, phalcon_config_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 21, data); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 22, data); zephir_check_call_status(); RETURN_MM(); @@ -17916,12 +18017,12 @@ static PHP_METHOD(Phalcon_Config, __set_state) { static PHP_METHOD(Phalcon_Config, _merge) { - zephir_fcall_cache_entry *_8 = NULL, *_9 = NULL; + zephir_fcall_cache_entry *_6 = NULL, *_7 = NULL; zend_bool _4, _5; HashTable *_2; HashPosition _1; int ZEPHIR_LAST_CALL_STATUS; - zval *config, *instance = NULL, *key = NULL, *value = NULL, *number = NULL, *_0 = NULL, **_3, *_6 = NULL, *_7 = NULL; + zval *config, *instance = NULL, *key = NULL, *value = NULL, *number = NULL, *localObject = NULL, *_0 = NULL, **_3; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 1, 1, &config, &instance); @@ -17938,39 +18039,40 @@ static PHP_METHOD(Phalcon_Config, _merge) { } ZEPHIR_CALL_METHOD(&number, instance, "count", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, config); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, config); zephir_check_call_status(); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/config.zep", 239); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/config.zep", 245); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) ) { ZEPHIR_GET_HMKEY(key, _2, _1); ZEPHIR_GET_HVALUE(value, _3); - _4 = zephir_isset_property_zval(instance, key TSRMLS_CC); - if (_4) { - _4 = Z_TYPE_P(value) == IS_OBJECT; - } - _5 = _4; - if (_5) { - ZEPHIR_OBS_NVAR(_6); - zephir_read_property_zval(&_6, instance, key, PH_NOISY_CC); - _5 = Z_TYPE_P(_6) == IS_OBJECT; + ZEPHIR_OBS_NVAR(localObject); + if (zephir_fetch_property_zval(&localObject, instance, key, PH_SILENT_CC)) { + _4 = Z_TYPE_P(localObject) == IS_OBJECT; + if (_4) { + _4 = Z_TYPE_P(value) == IS_OBJECT; + } + if (_4) { + _5 = zephir_instance_of_ev(localObject, phalcon_config_ce TSRMLS_CC); + if (_5) { + _5 = zephir_instance_of_ev(value, phalcon_config_ce TSRMLS_CC); + } + if (_5) { + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_merge", &_6, 23, value, localObject); + zephir_check_call_status(); + continue; + } + } } - if (_5) { - ZEPHIR_OBS_NVAR(_7); - zephir_read_property_zval(&_7, instance, key, PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_merge", &_8, 22, value, _7); + if (Z_TYPE_P(key) == IS_LONG) { + ZEPHIR_CALL_FUNCTION(&key, "strval", &_7, 21, number); zephir_check_call_status(); - } else { - if (Z_TYPE_P(key) == IS_LONG) { - ZEPHIR_CALL_FUNCTION(&key, "strval", &_9, 20, number); - zephir_check_call_status(); - ZEPHIR_SEPARATE(number); - zephir_increment(number); - } - zephir_update_property_zval_zval(instance, key, value TSRMLS_CC); + ZEPHIR_SEPARATE(number); + zephir_increment(number); } + zephir_update_property_zval_zval(instance, key, value TSRMLS_CC); } RETVAL_ZVAL(instance, 1, 0); RETURN_MM(); @@ -18196,15 +18298,15 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 1) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (paddingSize - 1)); - ZEPHIR_CALL_FUNCTION(&_4, "str_repeat", &_5, 129, _2, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "str_repeat", &_5, 131, _2, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(padding); ZEPHIR_CONCAT_VV(padding, _4, _6); @@ -18213,11 +18315,11 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 2) { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 129, _2, &_1); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 131, _2, &_1); zephir_check_call_status(); break; } @@ -18238,16 +18340,16 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { _7 = 1; } i = _8; - ZEPHIR_CALL_FUNCTION(&_2, "rand", &_10, 107); + ZEPHIR_CALL_FUNCTION(&_2, "rand", &_10, 109); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 128, _2); + ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 130, _2); zephir_check_call_status(); zephir_concat_self(&padding, _4 TSRMLS_CC); } } ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 130, &_1); zephir_check_call_status(); zephir_concat_self(&padding, _6 TSRMLS_CC); break; @@ -18255,15 +18357,15 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 4) { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 0x80); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (paddingSize - 1)); - ZEPHIR_CALL_FUNCTION(&_6, "str_repeat", &_5, 129, _4, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "str_repeat", &_5, 131, _4, &_1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(padding); ZEPHIR_CONCAT_VV(padding, _2, _6); @@ -18272,11 +18374,11 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 5) { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 129, _2, &_1); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 131, _2, &_1); zephir_check_call_status(); break; } @@ -18285,7 +18387,7 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { ZVAL_STRING(&_1, " ", 0); ZEPHIR_SINIT_VAR(_11); ZVAL_LONG(&_11, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 129, &_1, &_11); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 131, &_1, &_11); zephir_check_call_status(); break; } @@ -18373,18 +18475,18 @@ static PHP_METHOD(Phalcon_Crypt, _cryptUnpadText) { ZVAL_LONG(&_4, 1); ZEPHIR_INIT_VAR(last); zephir_substr(last, text, zephir_get_intval(&_3), 1 , 0); - ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 130, last); + ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 132, last); zephir_check_call_status(); ord = zephir_get_intval(_5); if (ord <= blockSize) { paddingSize = ord; ZEPHIR_SINIT_VAR(_7); ZVAL_LONG(&_7, 0); - ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 128, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 130, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, (paddingSize - 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, _8, &_7); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, _8, &_7); zephir_check_call_status(); ZEPHIR_INIT_VAR(padding); ZEPHIR_CONCAT_VV(padding, _10, last); @@ -18405,18 +18507,18 @@ static PHP_METHOD(Phalcon_Crypt, _cryptUnpadText) { ZVAL_LONG(&_4, 1); ZEPHIR_INIT_NVAR(last); zephir_substr(last, text, zephir_get_intval(&_3), 1 , 0); - ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 130, last); + ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 132, last); zephir_check_call_status(); ord = zephir_get_intval(_5); if (ord <= blockSize) { paddingSize = ord; ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, paddingSize); - ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 128, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 130, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_11, 129, _8, &_7); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_11, 131, _8, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, (length - paddingSize)); @@ -18435,7 +18537,7 @@ static PHP_METHOD(Phalcon_Crypt, _cryptUnpadText) { ZVAL_LONG(&_4, 1); ZEPHIR_INIT_NVAR(last); zephir_substr(last, text, zephir_get_intval(&_3), 1 , 0); - ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 130, last); + ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 132, last); zephir_check_call_status(); paddingSize = zephir_get_intval(_5); break; @@ -18591,7 +18693,7 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) { zephir_read_property_this(&cipher, this_ptr, SL("_cipher"), PH_NOISY_CC); ZEPHIR_OBS_VAR(mode); zephir_read_property_this(&mode, this_ptr, SL("_mode"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 131, cipher, mode); + ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 133, cipher, mode); zephir_check_call_status(); if (ZEPHIR_LT_LONG(ivSize, zephir_fast_strlen_ev(encryptKey))) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 320); @@ -18599,14 +18701,14 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) { } ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 2); - ZEPHIR_CALL_FUNCTION(&iv, "mcrypt_create_iv", NULL, 132, ivSize, &_0); + ZEPHIR_CALL_FUNCTION(&iv, "mcrypt_create_iv", NULL, 134, ivSize, &_0); zephir_check_call_status(); if (Z_TYPE_P(iv) != IS_STRING) { - ZEPHIR_CALL_FUNCTION(&_1, "strval", NULL, 20, iv); + ZEPHIR_CALL_FUNCTION(&_1, "strval", NULL, 21, iv); zephir_check_call_status(); ZEPHIR_CPY_WRT(iv, _1); } - ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 133, cipher, mode); + ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 135, cipher, mode); zephir_check_call_status(); if (Z_TYPE_P(blockSize) != IS_LONG) { _2 = zephir_get_intval(blockSize); @@ -18629,7 +18731,7 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) { } else { ZEPHIR_CPY_WRT(padded, text); } - ZEPHIR_CALL_FUNCTION(&_1, "mcrypt_encrypt", NULL, 134, cipher, encryptKey, padded, mode, iv); + ZEPHIR_CALL_FUNCTION(&_1, "mcrypt_encrypt", NULL, 136, cipher, encryptKey, padded, mode, iv); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, iv, _1); RETURN_MM(); @@ -18680,7 +18782,7 @@ static PHP_METHOD(Phalcon_Crypt, decrypt) { zephir_read_property_this(&cipher, this_ptr, SL("_cipher"), PH_NOISY_CC); ZEPHIR_OBS_VAR(mode); zephir_read_property_this(&mode, this_ptr, SL("_mode"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 131, cipher, mode); + ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 133, cipher, mode); zephir_check_call_status(); ZEPHIR_INIT_VAR(keySize); ZVAL_LONG(keySize, zephir_fast_strlen_ev(decryptKey)); @@ -18700,9 +18802,9 @@ static PHP_METHOD(Phalcon_Crypt, decrypt) { ZVAL_LONG(&_1, 0); ZEPHIR_INIT_VAR(_2); zephir_substr(_2, text, 0 , zephir_get_intval(ivSize), 0); - ZEPHIR_CALL_FUNCTION(&decrypted, "mcrypt_decrypt", NULL, 135, cipher, decryptKey, _0, mode, _2); + ZEPHIR_CALL_FUNCTION(&decrypted, "mcrypt_decrypt", NULL, 137, cipher, decryptKey, _0, mode, _2); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 133, cipher, mode); + ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 135, cipher, mode); zephir_check_call_status(); ZEPHIR_OBS_VAR(paddingType); zephir_read_property_this(&paddingType, this_ptr, SL("_padding"), PH_NOISY_CC); @@ -18759,19 +18861,19 @@ static PHP_METHOD(Phalcon_Crypt, encryptBase64) { if (safe == 1) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "encrypt", &_1, 0, text, key); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_2, "base64_encode", &_3, 112, _0); + ZEPHIR_CALL_FUNCTION(&_2, "base64_encode", &_3, 114, _0); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "+/", 0); ZEPHIR_SINIT_VAR(_5); ZVAL_STRING(&_5, "-_", 0); - ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 53, _2, &_4, &_5); + ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 54, _2, &_4, &_5); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_CALL_METHOD(&_0, this_ptr, "encrypt", &_1, 0, text, key); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", &_3, 112, _0); + ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", &_3, 114, _0); zephir_check_call_status(); RETURN_MM(); @@ -18819,15 +18921,15 @@ static PHP_METHOD(Phalcon_Crypt, decryptBase64) { ZVAL_STRING(&_0, "-_", 0); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "+/", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, text, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, text, &_0, &_1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_3, "base64_decode", &_4, 113, _2); + ZEPHIR_CALL_FUNCTION(&_3, "base64_decode", &_4, 115, _2); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "decrypt", &_5, 0, _3, key); zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_CALL_FUNCTION(&_2, "base64_decode", &_4, 113, text); + ZEPHIR_CALL_FUNCTION(&_2, "base64_decode", &_4, 115, text); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "decrypt", &_5, 0, _2, key); zephir_check_call_status(); @@ -18841,7 +18943,7 @@ static PHP_METHOD(Phalcon_Crypt, getAvailableCiphers) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_algorithms", NULL, 136); + ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_algorithms", NULL, 138); zephir_check_call_status(); RETURN_MM(); @@ -18853,7 +18955,7 @@ static PHP_METHOD(Phalcon_Crypt, getAvailableModes) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_modes", NULL, 137); + ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_modes", NULL, 139); zephir_check_call_status(); RETURN_MM(); @@ -19139,7 +19241,7 @@ static PHP_METHOD(Phalcon_Debug, listenExceptions) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "onUncaughtException", 1); zephir_array_fast_append(_0, _1); - ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _0); + ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 149, _0); zephir_check_call_status(); RETURN_THIS(); @@ -19159,7 +19261,7 @@ static PHP_METHOD(Phalcon_Debug, listenLowSeverity) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "onUncaughtLowSeverity", 1); zephir_array_fast_append(_0, _1); - ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 149, _0); + ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 150, _0); zephir_check_call_status(); ZEPHIR_INIT_VAR(_2); zephir_create_array(_2, 2, 0 TSRMLS_CC); @@ -19167,7 +19269,7 @@ static PHP_METHOD(Phalcon_Debug, listenLowSeverity) { ZEPHIR_INIT_NVAR(_1); ZVAL_STRING(_1, "onUncaughtException", 1); zephir_array_fast_append(_2, _1); - ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _2); + ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 149, _2); zephir_check_call_status(); RETURN_THIS(); @@ -19202,7 +19304,7 @@ static PHP_METHOD(Phalcon_Debug, debugVar) { ZEPHIR_INIT_VAR(_0); zephir_create_array(_0, 3, 0 TSRMLS_CC); zephir_array_fast_append(_0, varz); - ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 150); + ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 151); zephir_check_call_status(); zephir_array_fast_append(_0, _1); ZEPHIR_INIT_VAR(_2); @@ -19242,7 +19344,7 @@ static PHP_METHOD(Phalcon_Debug, _escapeString) { ZVAL_LONG(&_3, 2); ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "utf-8", 0); - ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 151, _0, &_3, &_4); + ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 152, _0, &_3, &_4); zephir_check_call_status(); RETURN_MM(); } @@ -19293,7 +19395,7 @@ static PHP_METHOD(Phalcon_Debug, _getArrayDump) { ) { ZEPHIR_GET_HMKEY(k, _2, _1); ZEPHIR_GET_HVALUE(v, _3); - ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 152, v); + ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 153, v); zephir_check_call_status(); if (zephir_is_true(_4)) { ZEPHIR_INIT_NVAR(varDump); @@ -19310,7 +19412,7 @@ static PHP_METHOD(Phalcon_Debug, _getArrayDump) { if (Z_TYPE_P(v) == IS_ARRAY) { ZEPHIR_INIT_NVAR(_8); ZVAL_LONG(_8, (zephir_get_numberval(n) + 1)); - ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 153, v, _8); + ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 154, v, _8); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVSVS(_10, "[", k, "] => Array(", _6, ")"); @@ -19351,7 +19453,7 @@ static PHP_METHOD(Phalcon_Debug, _getVarDump) { - ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 152, variable); + ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 153, variable); zephir_check_call_status(); if (zephir_is_true(_0)) { if (Z_TYPE_P(variable) == IS_BOOL) { @@ -19385,7 +19487,7 @@ static PHP_METHOD(Phalcon_Debug, _getVarDump) { } } if (Z_TYPE_P(variable) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 153, variable); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 154, variable); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "Array(", _1, ")"); RETURN_MM(); @@ -19406,7 +19508,7 @@ static PHP_METHOD(Phalcon_Debug, getMajorVersion) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 154); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 155); zephir_check_call_status(); ZEPHIR_INIT_VAR(parts); zephir_fast_explode_str(parts, SL(" "), _0, LONG_MAX TSRMLS_CC); @@ -19425,7 +19527,7 @@ static PHP_METHOD(Phalcon_Debug, getVersion) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmajorversion", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 154); + ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 155); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "
Phalcon Framework ", _1, "
"); RETURN_MM(); @@ -19517,9 +19619,9 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) { } else { ZEPHIR_INIT_VAR(classReflection); object_init_ex(classReflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, classReflection, "__construct", NULL, 62, className); + ZEPHIR_CALL_METHOD(NULL, classReflection, "__construct", NULL, 64, className); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 155); + ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 156); zephir_check_call_status(); if (zephir_is_true(_8)) { ZEPHIR_INIT_VAR(_9); @@ -19552,9 +19654,9 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) { if ((zephir_function_exists(functionName TSRMLS_CC) == SUCCESS)) { ZEPHIR_INIT_VAR(functionReflection); object_init_ex(functionReflection, zephir_get_internal_ce(SS("reflectionfunction") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 156, functionName); + ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 157, functionName); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 157); + ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 158); zephir_check_call_status(); if (zephir_is_true(_8)) { ZEPHIR_SINIT_NVAR(_4); @@ -19615,7 +19717,7 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) { ZEPHIR_OBS_VAR(showFiles); zephir_read_property_this(&showFiles, this_ptr, SL("_showFiles"), PH_NOISY_CC); if (zephir_is_true(showFiles)) { - ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 158, filez); + ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 159, filez); zephir_check_call_status(); ZEPHIR_INIT_VAR(numberLines); ZVAL_LONG(numberLines, zephir_fast_count_int(lines TSRMLS_CC)); @@ -19698,7 +19800,7 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) { ZVAL_LONG(&_23, 2); ZEPHIR_SINIT_NVAR(_25); ZVAL_STRING(&_25, "UTF-8", 0); - ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_26, 151, _21, &_23, &_25); + ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_26, 152, _21, &_23, &_25); zephir_check_call_status(); zephir_concat_self(&html, _8 TSRMLS_CC); } @@ -19722,7 +19824,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) { - ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 159); + ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 160); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_1); zephir_bitwise_and_function(&_1, _0, severity TSRMLS_CC); @@ -19731,7 +19833,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) { object_init_ex(_2, zephir_get_internal_ce(SS("errorexception") TSRMLS_CC)); ZEPHIR_INIT_VAR(_3); ZVAL_LONG(_3, 0); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 160, message, _3, severity, file, line); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 161, message, _3, severity, file, line); zephir_check_call_status(); zephir_throw_exception_debug(_2, "phalcon/debug.zep", 566 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -19756,10 +19858,10 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) { - ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 161); + ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 162); zephir_check_call_status(); if (ZEPHIR_GT_LONG(obLevel, 0)) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); } _0 = zephir_fetch_static_property_ce(phalcon_debug_ce, SL("_isActive") TSRMLS_CC); @@ -19823,7 +19925,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) { ) { ZEPHIR_GET_HMKEY(n, _11, _10); ZEPHIR_GET_HVALUE(traceItem, _12); - ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 162, n, traceItem); + ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 163, n, traceItem); zephir_check_call_status(); zephir_concat_self(&html, _13 TSRMLS_CC); } @@ -19842,7 +19944,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) { ZEPHIR_CONCAT_SVSVS(_18, "
"); zephir_concat_self(&html, _18 TSRMLS_CC); } else { - ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 163, value, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 164, value, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_18); ZEPHIR_CONCAT_SVSVS(_18, ""); @@ -19868,7 +19970,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) { zephir_concat_self_str(&html, SL("
Memory
Usage", _13, "
", keyRequest, "", value, "
", keyRequest, "", _13, "
") TSRMLS_CC); zephir_concat_self_str(&html, SL("
") TSRMLS_CC); zephir_concat_self_str(&html, SL("") TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 164); + ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 165); zephir_check_call_status(); zephir_is_iterable(_13, &_25, &_24, 0, 0, "phalcon/debug.zep", 694); for ( @@ -19883,7 +19985,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) { } zephir_concat_self_str(&html, SL("
#Path
") TSRMLS_CC); zephir_concat_self_str(&html, SL("
") TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 165, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 166, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_27); ZEPHIR_CONCAT_SVS(_27, ""); @@ -20018,7 +20120,7 @@ static PHP_METHOD(Phalcon_Di, set) { ZEPHIR_INIT_VAR(service); object_init_ex(service, phalcon_di_service_ce); - ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 61, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 63, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_services"), name, service TSRMLS_CC); RETURN_CCTOR(service); @@ -20051,7 +20153,7 @@ static PHP_METHOD(Phalcon_Di, setShared) { object_init_ex(service, phalcon_di_service_ce); ZEPHIR_SINIT_VAR(_0); ZVAL_BOOL(&_0, 1); - ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 61, name, definition, &_0); + ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 63, name, definition, &_0); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_services"), name, service TSRMLS_CC); RETURN_CCTOR(service); @@ -20119,7 +20221,7 @@ static PHP_METHOD(Phalcon_Di, attempt) { if (!(zephir_array_isset(_0, name))) { ZEPHIR_INIT_VAR(service); object_init_ex(service, phalcon_di_service_ce); - ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 61, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 63, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_services"), name, service TSRMLS_CC); RETURN_CCTOR(service); @@ -20287,7 +20389,7 @@ static PHP_METHOD(Phalcon_Di, get) { ZEPHIR_CONCAT_SVS(_3, "Service '", name, "' wasn't found in the dependency injection container"); ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/di.zep", 229 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/di.zep", 230 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -20296,9 +20398,9 @@ static PHP_METHOD(Phalcon_Di, get) { if (zephir_is_php_version(50600)) { ZEPHIR_INIT_VAR(reflection); object_init_ex(reflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 62, name); + ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 64, name); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&instance, reflection, "newinstanceargs", NULL, 63, parameters); + ZEPHIR_CALL_METHOD(&instance, reflection, "newinstanceargs", NULL, 65, parameters); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(instance); @@ -20309,9 +20411,9 @@ static PHP_METHOD(Phalcon_Di, get) { if (zephir_is_php_version(50600)) { ZEPHIR_INIT_NVAR(reflection); object_init_ex(reflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 62, name); + ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 64, name); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 64); + ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 66); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(instance); @@ -20323,9 +20425,9 @@ static PHP_METHOD(Phalcon_Di, get) { if (zephir_is_php_version(50600)) { ZEPHIR_INIT_NVAR(reflection); object_init_ex(reflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 62, name); + ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 64, name); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 64); + ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 66); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(instance); @@ -20577,7 +20679,7 @@ static PHP_METHOD(Phalcon_Di, __call) { ZVAL_LONG(&_0, 3); ZEPHIR_INIT_VAR(_1); zephir_substr(_1, method, 3 , 0, ZEPHIR_SUBSTR_NO_LENGTH); - ZEPHIR_CALL_FUNCTION(&possibleService, "lcfirst", &_2, 65, _1); + ZEPHIR_CALL_FUNCTION(&possibleService, "lcfirst", &_2, 67, _1); zephir_check_call_status(); if (zephir_array_isset(services, possibleService)) { if (zephir_fast_count_int(arguments TSRMLS_CC)) { @@ -20597,7 +20699,7 @@ static PHP_METHOD(Phalcon_Di, __call) { ZVAL_LONG(&_0, 3); ZEPHIR_INIT_NVAR(_1); zephir_substr(_1, method, 3 , 0, ZEPHIR_SUBSTR_NO_LENGTH); - ZEPHIR_CALL_FUNCTION(&_4, "lcfirst", &_2, 65, _1); + ZEPHIR_CALL_FUNCTION(&_4, "lcfirst", &_2, 67, _1); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, this_ptr, "set", NULL, 0, _4, definition); zephir_check_call_status(); @@ -20610,7 +20712,7 @@ static PHP_METHOD(Phalcon_Di, __call) { ZEPHIR_CONCAT_SVS(_5, "Call to undefined method or service '", method, "'"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _5); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/di.zep", 427 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/di.zep", 428 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -21646,13 +21748,13 @@ static PHP_METHOD(Phalcon_Escaper, detectEncoding) { ; zephir_hash_move_forward_ex(_3, &_2) ) { ZEPHIR_GET_HVALUE(charset, _4); - ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 178, str, charset, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 179, str, charset, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); if (zephir_is_true(_5)) { RETURN_CCTOR(charset); } } - ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 178, str); + ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 179, str); zephir_check_call_status(); RETURN_MM(); @@ -21674,11 +21776,11 @@ static PHP_METHOD(Phalcon_Escaper, normalizeEncoding) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_escaper_exception_ce, "Extension 'mbstring' is required", "phalcon/escaper.zep", 128); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 179, str); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 180, str); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "UTF-32", 0); - ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, str, &_1, _0); + ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 181, str, &_1, _0); zephir_check_call_status(); RETURN_MM(); @@ -21698,7 +21800,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeHtml) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_htmlQuoteType"), PH_NOISY_CC); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC); - ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, text, _0, _1); + ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 182, text, _0, _1); zephir_check_call_status(); RETURN_MM(); @@ -21719,7 +21821,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeHtmlAttr) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 3); - ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, attribute, &_1, _0); + ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 182, attribute, &_1, _0); zephir_check_call_status(); RETURN_MM(); @@ -21737,7 +21839,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeCss) { zephir_get_strval(css, css_param); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, css); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 183, css); zephir_check_call_status(); zephir_escape_css(return_value, _0); RETURN_MM(); @@ -21756,7 +21858,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeJs) { zephir_get_strval(js, js_param); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, js); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 183, js); zephir_check_call_status(); zephir_escape_js(return_value, _0); RETURN_MM(); @@ -21775,7 +21877,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeUrl) { zephir_get_strval(url, url_param); - ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 183, url); + ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 184, url); zephir_check_call_status(); RETURN_MM(); @@ -22054,16 +22156,16 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { if (ZEPHIR_IS_STRING(filter, "email")) { ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "FILTER_SANITIZE_EMAIL", 0); - ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 191, &_3); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, _4); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, _4); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "int")) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 519); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, &_3); zephir_check_call_status(); RETURN_MM(); } @@ -22073,14 +22175,14 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { if (ZEPHIR_IS_STRING(filter, "absint")) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, zephir_get_intval(value)); - ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 192, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 193, &_3); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "string")) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 513); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, &_3); zephir_check_call_status(); RETURN_MM(); } @@ -22090,7 +22192,7 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { add_assoc_long_ex(_2, SS("flags"), 4096); ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 520); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3, _2); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, &_3, _2); zephir_check_call_status(); RETURN_MM(); } @@ -22102,7 +22204,7 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { ZVAL_STRING(_6, "/[^A-Za-z0-9]/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_FUNCTION("preg_replace", NULL, 28, _6, _7, value); + ZEPHIR_RETURN_CALL_FUNCTION("preg_replace", NULL, 29, _6, _7, value); zephir_check_temp_parameter(_6); zephir_check_temp_parameter(_7); zephir_check_call_status(); @@ -22113,13 +22215,13 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "striptags")) { - ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 193, value); + ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 194, value); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "lower")) { if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, value); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 195, value); zephir_check_call_status(); RETURN_MM(); } @@ -22128,7 +22230,7 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { } if (ZEPHIR_IS_STRING(filter, "upper")) { if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, value); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 196, value); zephir_check_call_status(); RETURN_MM(); } @@ -22909,7 +23011,7 @@ static PHP_METHOD(Phalcon_Loader, register) { ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "autoLoad", 1); zephir_array_fast_append(_1, _2); - ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 293, _1); + ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 286, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_registered"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } @@ -22933,7 +23035,7 @@ static PHP_METHOD(Phalcon_Loader, unregister) { ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "autoLoad", 1); zephir_array_fast_append(_1, _2); - ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 294, _1); + ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 287, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_registered"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } @@ -23041,7 +23143,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) { zephir_check_temp_parameter(_9); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath); + ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 288, filePath); zephir_check_call_status(); if (zephir_is_true(_11)) { if (Z_TYPE_P(eventsManager) == IS_OBJECT) { @@ -23112,7 +23214,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) { zephir_check_temp_parameter(_9); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath); + ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 288, filePath); zephir_check_call_status(); if (zephir_is_true(_11)) { if (Z_TYPE_P(eventsManager) == IS_OBJECT) { @@ -23170,7 +23272,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) { zephir_check_temp_parameter(_9); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath); + ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 288, filePath); zephir_check_call_status(); if (zephir_is_true(_11)) { if (Z_TYPE_P(eventsManager) == IS_OBJECT) { @@ -23423,7 +23525,7 @@ static PHP_METHOD(Phalcon_Registry, next) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 399, _0); + ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 392, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -23439,7 +23541,7 @@ static PHP_METHOD(Phalcon_Registry, key) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 400, _0); + ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 393, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); RETURN_MM(); @@ -23455,7 +23557,7 @@ static PHP_METHOD(Phalcon_Registry, rewind) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 401, _0); + ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 394, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -23471,7 +23573,7 @@ static PHP_METHOD(Phalcon_Registry, valid) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 400, _0); + ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 393, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); RETURN_MM_BOOL(Z_TYPE_P(_1) != IS_NULL); @@ -23487,7 +23589,7 @@ static PHP_METHOD(Phalcon_Registry, current) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 402, _0); + ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 395, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); RETURN_MM(); @@ -23516,7 +23618,7 @@ static PHP_METHOD(Phalcon_Registry, __set) { } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 403, key, value); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 396, key, value); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -23544,7 +23646,7 @@ static PHP_METHOD(Phalcon_Registry, __get) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 404, key); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 397, key); zephir_check_call_status(); RETURN_MM(); @@ -23572,7 +23674,7 @@ static PHP_METHOD(Phalcon_Registry, __isset) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 405, key); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 398, key); zephir_check_call_status(); RETURN_MM(); @@ -23600,7 +23702,7 @@ static PHP_METHOD(Phalcon_Registry, __unset) { } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 406, key); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 399, key); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -23756,9 +23858,9 @@ static PHP_METHOD(Phalcon_Security, getSaltBytes) { ZEPHIR_INIT_NVAR(safeBytes); ZEPHIR_INIT_NVAR(_1); ZVAL_LONG(_1, numberBytes); - ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 407, _1); + ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 400, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "base64_encode", &_5, 112, _2); + ZEPHIR_CALL_FUNCTION(&_4, "base64_encode", &_5, 114, _2); zephir_check_call_status(); zephir_filter_alphanum(safeBytes, _4); if (!(zephir_is_true(safeBytes))) { @@ -23848,7 +23950,7 @@ static PHP_METHOD(Phalcon_Security, hash) { } ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SVSV(_3, "$", variant, "$", saltBytes); - ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3); + ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 401, password, _3); zephir_check_call_status(); RETURN_MM(); } @@ -23871,11 +23973,11 @@ static PHP_METHOD(Phalcon_Security, hash) { ZVAL_STRING(&_5, "%02s", 0); ZEPHIR_SINIT_VAR(_6); ZVAL_LONG(&_6, workFactor); - ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 187, &_5, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 188, &_5, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVSVSV(_3, "$2", variant, "$", _7, "$", saltBytes); - ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3); + ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 401, password, _3); zephir_check_call_status(); RETURN_MM(); } while(0); @@ -23915,7 +24017,7 @@ static PHP_METHOD(Phalcon_Security, checkHash) { RETURN_MM_BOOL(0); } } - ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 408, password, passwordHash); + ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 401, password, passwordHash); zephir_check_call_status(); zephir_get_strval(_2, _1); ZEPHIR_CPY_WRT(cryptedHash, _2); @@ -23979,9 +24081,9 @@ static PHP_METHOD(Phalcon_Security, getTokenKey) { ZEPHIR_INIT_VAR(safeBytes); ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, numberBytes); - ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 407, _1); + ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 400, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_3, "base64_encode", NULL, 112, _2); + ZEPHIR_CALL_FUNCTION(&_3, "base64_encode", NULL, 114, _2); zephir_check_call_status(); zephir_filter_alphanum(safeBytes, _3); ZEPHIR_INIT_NVAR(_1); @@ -24021,9 +24123,9 @@ static PHP_METHOD(Phalcon_Security, getToken) { } ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, numberBytes); - ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 407, _0); + ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 400, _0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "base64_encode", NULL, 112, token); + ZEPHIR_CALL_FUNCTION(&_1, "base64_encode", NULL, 114, token); zephir_check_call_status(); ZEPHIR_CPY_WRT(token, _1); ZEPHIR_INIT_NVAR(_0); @@ -24194,7 +24296,7 @@ static PHP_METHOD(Phalcon_Security, computeHmac) { } - ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 409, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 402, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); if (!(zephir_is_true(hmac))) { ZEPHIR_INIT_VAR(_0); @@ -24985,7 +25087,7 @@ static PHP_METHOD(Phalcon_Tag, colorField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "color", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25005,7 +25107,7 @@ static PHP_METHOD(Phalcon_Tag, textField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "text", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25025,7 +25127,7 @@ static PHP_METHOD(Phalcon_Tag, numericField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "number", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25045,7 +25147,7 @@ static PHP_METHOD(Phalcon_Tag, rangeField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "range", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25065,7 +25167,7 @@ static PHP_METHOD(Phalcon_Tag, emailField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "email", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25085,7 +25187,7 @@ static PHP_METHOD(Phalcon_Tag, dateField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "date", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25105,7 +25207,7 @@ static PHP_METHOD(Phalcon_Tag, dateTimeField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "datetime", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25125,7 +25227,7 @@ static PHP_METHOD(Phalcon_Tag, dateTimeLocalField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "datetime-local", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25145,7 +25247,7 @@ static PHP_METHOD(Phalcon_Tag, monthField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "month", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25165,7 +25267,7 @@ static PHP_METHOD(Phalcon_Tag, timeField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "time", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25185,7 +25287,7 @@ static PHP_METHOD(Phalcon_Tag, weekField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "week", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25205,7 +25307,7 @@ static PHP_METHOD(Phalcon_Tag, passwordField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "password", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25225,7 +25327,7 @@ static PHP_METHOD(Phalcon_Tag, hiddenField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "hidden", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25245,7 +25347,7 @@ static PHP_METHOD(Phalcon_Tag, fileField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "file", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25265,7 +25367,7 @@ static PHP_METHOD(Phalcon_Tag, searchField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "search", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25285,7 +25387,7 @@ static PHP_METHOD(Phalcon_Tag, telField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "tel", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25305,7 +25407,7 @@ static PHP_METHOD(Phalcon_Tag, urlField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "url", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25325,7 +25427,7 @@ static PHP_METHOD(Phalcon_Tag, checkField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "checkbox", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 413, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25345,7 +25447,7 @@ static PHP_METHOD(Phalcon_Tag, radioField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "radio", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 413, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25367,7 +25469,7 @@ static PHP_METHOD(Phalcon_Tag, imageInput) { ZVAL_STRING(_1, "image", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters, _2); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25389,7 +25491,7 @@ static PHP_METHOD(Phalcon_Tag, submitButton) { ZVAL_STRING(_1, "submit", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters, _2); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25410,7 +25512,7 @@ static PHP_METHOD(Phalcon_Tag, selectStatic) { } - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 207, parameters, data); zephir_check_call_status(); RETURN_MM(); @@ -25430,7 +25532,7 @@ static PHP_METHOD(Phalcon_Tag, select) { } - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 207, parameters, data); zephir_check_call_status(); RETURN_MM(); @@ -25934,20 +26036,20 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) { ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "iconv", 0); - ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", &_2, 126, &_0); + ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", &_2, 128, &_0); zephir_check_call_status(); if (zephir_is_true(_1)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "en_US.UTF-8", 0); - ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 415, &_0, &_3); + ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 414, &_0, &_3); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "UTF-8", 0); ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "ASCII//TRANSLIT", 0); - ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 378, &_0, &_3, text); + ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 371, &_0, &_3, text); zephir_check_call_status(); zephir_get_strval(text, _5); } @@ -25985,7 +26087,7 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) { ZVAL_STRING(_11, "/[^a-zA-Z0-9\\/_|+ -]/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_12); ZVAL_STRING(_12, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&friendly, "preg_replace", &_13, 28, _11, _12, text); + ZEPHIR_CALL_FUNCTION(&friendly, "preg_replace", &_13, 29, _11, _12, text); zephir_check_temp_parameter(_11); zephir_check_temp_parameter(_12); zephir_check_call_status(); @@ -25996,7 +26098,7 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) { } ZEPHIR_INIT_NVAR(_11); ZVAL_STRING(_11, "/[\\/_|+ -]+/", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_5, "preg_replace", &_13, 28, _11, separator, friendly); + ZEPHIR_CALL_FUNCTION(&_5, "preg_replace", &_13, 29, _11, separator, friendly); zephir_check_temp_parameter(_11); zephir_check_call_status(); ZEPHIR_CPY_WRT(friendly, _5); @@ -26005,12 +26107,12 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) { ZEPHIR_CPY_WRT(friendly, _11); ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "iconv", 0); - ZEPHIR_CALL_FUNCTION(&_5, "extension_loaded", &_2, 126, &_3); + ZEPHIR_CALL_FUNCTION(&_5, "extension_loaded", &_2, 128, &_3); zephir_check_call_status(); if (zephir_is_true(_5)) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 0); - ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 415, &_3, locale); + ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 414, &_3, locale); zephir_check_call_status(); } RETURN_CCTOR(friendly); @@ -26378,13 +26480,13 @@ static PHP_METHOD(Phalcon_Text, random) { ZVAL_STRING(&_0, "a", 0); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "z", 0); - ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "A", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "Z", 0); - ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_INIT_VAR(pool); zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC); @@ -26395,13 +26497,13 @@ static PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "a", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "f", 0); - ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(pool); zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC); @@ -26412,7 +26514,7 @@ static PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); break; } @@ -26421,7 +26523,7 @@ static PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 1); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); break; } @@ -26429,21 +26531,21 @@ static PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "a", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "z", 0); - ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "A", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "Z", 0); - ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 419, _2, _4, _5); + ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 418, _2, _4, _5); zephir_check_call_status(); break; } while(0); @@ -26547,7 +26649,7 @@ static PHP_METHOD(Phalcon_Text, lower) { if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, str, encoding); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 195, str, encoding); zephir_check_call_status(); RETURN_MM(); } @@ -26595,7 +26697,7 @@ static PHP_METHOD(Phalcon_Text, upper) { if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, str, encoding); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 196, str, encoding); zephir_check_call_status(); RETURN_MM(); } @@ -26620,7 +26722,7 @@ static PHP_METHOD(Phalcon_Text, reduceSlashes) { ZVAL_STRING(_0, "#(?funcs->dtor(_0 TSRMLS_CC); @@ -36378,7 +36504,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_File, __construct) { return; } } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_file_ce, this_ptr, "__construct", &_5, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_file_ce, this_ptr, "__construct", &_5, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -36570,7 +36696,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_File, delete) { ZEPHIR_INIT_VAR(cacheFile); ZEPHIR_CONCAT_VVV(cacheFile, cacheDir, _1, _2); if ((zephir_file_exists(cacheFile TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("unlink", NULL, 104, cacheFile); + ZEPHIR_RETURN_CALL_FUNCTION("unlink", NULL, 106, cacheFile); zephir_check_call_status(); RETURN_MM(); } @@ -36603,7 +36729,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_File, queryKeys) { } ZEPHIR_INIT_VAR(_2); object_init_ex(_2, spl_ce_DirectoryIterator); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 105, cacheDir); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 107, cacheDir); zephir_check_call_status(); _1 = zephir_get_iterator(_2 TSRMLS_CC); _1->funcs->rewind(_1 TSRMLS_CC); @@ -36859,7 +36985,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_File, flush) { } ZEPHIR_INIT_VAR(_2); object_init_ex(_2, spl_ce_DirectoryIterator); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 105, cacheDir); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 107, cacheDir); zephir_check_call_status(); _1 = zephir_get_iterator(_2 TSRMLS_CC); _1->funcs->rewind(_1 TSRMLS_CC); @@ -36881,7 +37007,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_File, flush) { _4 = zephir_start_with(key, prefix, NULL); } if (_4) { - ZEPHIR_CALL_FUNCTION(&_5, "unlink", &_6, 104, cacheFile); + ZEPHIR_CALL_FUNCTION(&_5, "unlink", &_6, 106, cacheFile); zephir_check_call_status(); if (!(zephir_is_true(_5))) { RETURN_MM_BOOL(0); @@ -36989,7 +37115,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Libmemcached, __construct) { ZVAL_STRING(_1, "_PHCM", 1); zephir_array_update_string(&options, SL("statsKey"), &_1, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_libmemcached_ce, this_ptr, "__construct", &_2, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_libmemcached_ce, this_ptr, "__construct", &_2, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -37553,7 +37679,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Memcache, __construct) { ZVAL_STRING(_0, "_PHCM", 1); zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_memcache_ce, this_ptr, "__construct", &_1, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_memcache_ce, this_ptr, "__construct", &_1, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -38374,7 +38500,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Memory, serialize) { ZEPHIR_OBS_VAR(_1); zephir_read_property_this(&_1, this_ptr, SL("_frontend"), PH_NOISY_CC); zephir_array_update_string(&_0, SL("frontend"), &_1, PH_COPY | PH_SEPARATE); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -38390,7 +38516,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Memory, unserialize) { - ZEPHIR_CALL_FUNCTION(&unserialized, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&unserialized, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(unserialized) != IS_ARRAY) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(zend_exception_get_default(TSRMLS_C), "Unserialized data must be an array", "phalcon/cache/backend/memory.zep", 295); @@ -38455,7 +38581,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, __construct) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "The parameter 'collection' is required", "phalcon/cache/backend/mongo.zep", 79); return; } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_mongo_ce, this_ptr, "__construct", &_0, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_mongo_ce, this_ptr, "__construct", &_0, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -38555,7 +38681,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, get) { zephir_time(_2); zephir_array_update_string(&_1, SL("$gt"), &_2, PH_COPY | PH_SEPARATE); zephir_array_update_string(&conditions, SL("time"), &_1, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&document, _3, "findone", NULL, 0, conditions); zephir_check_call_status(); @@ -38644,7 +38770,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, save) { } else { ZEPHIR_CPY_WRT(ttl, lifetime); } - ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_0); zephir_time(_0); @@ -38703,7 +38829,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, delete) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 1, 0 TSRMLS_CC); @@ -38713,7 +38839,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, delete) { zephir_array_update_string(&_1, SL("key"), &_3, PH_COPY | PH_SEPARATE); ZEPHIR_CALL_METHOD(NULL, _0, "remove", NULL, 0, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "rand", NULL, 107); + ZEPHIR_CALL_FUNCTION(&_4, "rand", NULL, 109); zephir_check_call_status(); if (zephir_safe_mod_long_long(zephir_get_intval(_4), 100 TSRMLS_CC) == 0) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "gc", NULL, 0); @@ -38759,7 +38885,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, queryKeys) { zephir_time(_0); zephir_array_update_string(&_2, SL("$gt"), &_0, PH_COPY | PH_SEPARATE); zephir_array_update_string(&conditions, SL("time"), &_2, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 1, 0 TSRMLS_CC); @@ -38817,7 +38943,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, exists) { ZEPHIR_CONCAT_VV(lastKey, _0, keyName); } if (zephir_is_true(lastKey)) { - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 2, 0 TSRMLS_CC); @@ -38844,7 +38970,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, gc) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 1, 0 TSRMLS_CC); @@ -38879,7 +39005,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, increment) { ZEPHIR_INIT_VAR(prefixedKey); ZEPHIR_CONCAT_VV(prefixedKey, _0, keyName); zephir_update_property_this(this_ptr, SL("_lastKey"), prefixedKey TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_2); zephir_create_array(_2, 1, 0 TSRMLS_CC); @@ -38930,7 +39056,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, decrement) { ZEPHIR_INIT_VAR(prefixedKey); ZEPHIR_CONCAT_VV(prefixedKey, _0, keyName); zephir_update_property_this(this_ptr, SL("_lastKey"), prefixedKey TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_2); zephir_create_array(_2, 1, 0 TSRMLS_CC); @@ -38969,11 +39095,11 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, flush) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _0, "remove", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "rand", NULL, 107); + ZEPHIR_CALL_FUNCTION(&_1, "rand", NULL, 109); zephir_check_call_status(); if (zephir_safe_mod_long_long(zephir_get_intval(_1), 100 TSRMLS_CC) == 0) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "gc", NULL, 0); @@ -39057,7 +39183,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Redis, __construct) { ZVAL_STRING(_0, "_PHCR", 1); zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_redis_ce, this_ptr, "__construct", &_3, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_redis_ce, this_ptr, "__construct", &_3, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -39075,8 +39201,10 @@ static PHP_METHOD(Phalcon_Cache_Backend_Redis, _connect) { zephir_read_property_this(&options, this_ptr, SL("_options"), PH_NOISY_CC); ZEPHIR_INIT_VAR(redis); object_init_ex(redis, zephir_get_internal_ce(SS("redis") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, redis, "__construct", NULL, 0); - zephir_check_call_status(); + if (zephir_has_constructor(redis TSRMLS_CC)) { + ZEPHIR_CALL_METHOD(NULL, redis, "__construct", NULL, 0); + zephir_check_call_status(); + } ZEPHIR_OBS_VAR(host); _0 = !(zephir_array_isset_string_fetch(&host, options, SS("host"), 0 TSRMLS_CC)); if (!(_0)) { @@ -39615,7 +39743,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, __construct) { ZVAL_STRING(_0, "_PHCX", 1); zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_xcache_ce, this_ptr, "__construct", &_1, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_xcache_ce, this_ptr, "__construct", &_1, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -39640,7 +39768,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, get) { ZEPHIR_INIT_VAR(prefixedKey); ZEPHIR_CONCAT_SVV(prefixedKey, "_PHCX", _0, keyName); zephir_update_property_this(this_ptr, SL("_lastKey"), prefixedKey TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&cachedContent, "xcache_get", NULL, 81, prefixedKey); + ZEPHIR_CALL_FUNCTION(&cachedContent, "xcache_get", NULL, 83, prefixedKey); zephir_check_call_status(); if (!(zephir_is_true(cachedContent))) { RETURN_MM_NULL(); @@ -39718,10 +39846,10 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, save) { ZEPHIR_CPY_WRT(tt1, lifetime); } if (zephir_is_numeric(cachedContent)) { - ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 82, lastKey, cachedContent, tt1); + ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 84, lastKey, cachedContent, tt1); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 82, lastKey, preparedContent, tt1); + ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 84, lastKey, preparedContent, tt1); zephir_check_call_status(); } ZEPHIR_CALL_METHOD(&isBuffering, frontend, "isbuffering", NULL, 0); @@ -39743,14 +39871,14 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, save) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Unexpected inconsistency in options", "phalcon/cache/backend/xcache.zep", 169); return; } - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) != IS_ARRAY) { ZEPHIR_INIT_NVAR(keys); array_init(keys); } zephir_array_update_zval(&keys, lastKey, &tt1, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", &_1, 82, specialKey, keys); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", &_1, 84, specialKey, keys); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -39776,14 +39904,14 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, delete) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Unexpected inconsistency in options", "phalcon/cache/backend/xcache.zep", 199); return; } - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) != IS_ARRAY) { ZEPHIR_INIT_NVAR(keys); array_init(keys); } zephir_array_unset(&keys, prefixedKey, PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, specialKey, keys); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, specialKey, keys); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -39820,7 +39948,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, queryKeys) { } ZEPHIR_INIT_VAR(retval); array_init(retval); - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) == IS_ARRAY) { ZEPHIR_INIT_VAR(_1); @@ -39869,7 +39997,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, exists) { ZEPHIR_CONCAT_SVV(lastKey, "_PHCX", _0, keyName); } if (zephir_is_true(lastKey)) { - ZEPHIR_RETURN_CALL_FUNCTION("xcache_isset", NULL, 108, lastKey); + ZEPHIR_RETURN_CALL_FUNCTION("xcache_isset", NULL, 110, lastKey); zephir_check_call_status(); RETURN_MM(); } @@ -39908,14 +40036,14 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, increment) { if ((zephir_function_exists_ex(SS("xcache_inc") TSRMLS_CC) == SUCCESS)) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, value); - ZEPHIR_CALL_FUNCTION(&newVal, "xcache_inc", NULL, 109, lastKey, &_1); + ZEPHIR_CALL_FUNCTION(&newVal, "xcache_inc", NULL, 111, lastKey, &_1); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 81, lastKey); + ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 83, lastKey); zephir_check_call_status(); ZEPHIR_INIT_NVAR(newVal); ZVAL_LONG(newVal, (zephir_get_numberval(origVal) - value)); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, lastKey, newVal); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, lastKey, newVal); zephir_check_call_status(); } RETURN_CCTOR(newVal); @@ -39953,14 +40081,14 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, decrement) { if ((zephir_function_exists_ex(SS("xcache_dec") TSRMLS_CC) == SUCCESS)) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, value); - ZEPHIR_CALL_FUNCTION(&newVal, "xcache_dec", NULL, 110, lastKey, &_1); + ZEPHIR_CALL_FUNCTION(&newVal, "xcache_dec", NULL, 112, lastKey, &_1); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 81, lastKey); + ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 83, lastKey); zephir_check_call_status(); ZEPHIR_INIT_NVAR(newVal); ZVAL_LONG(newVal, (zephir_get_numberval(origVal) - value)); - ZEPHIR_CALL_FUNCTION(&success, "xcache_set", NULL, 82, lastKey, newVal); + ZEPHIR_CALL_FUNCTION(&success, "xcache_set", NULL, 84, lastKey, newVal); zephir_check_call_status(); } RETURN_CCTOR(newVal); @@ -39985,7 +40113,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, flush) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Unexpected inconsistency in options", "phalcon/cache/backend/xcache.zep", 350); return; } - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) == IS_ARRAY) { ZEPHIR_INIT_VAR(_1); @@ -39997,10 +40125,10 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, flush) { ZEPHIR_GET_HMKEY(key, _3, _2); ZEPHIR_GET_HVALUE(_1, _4); zephir_array_unset(&keys, key, PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_unset", &_5, 111, key); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_unset", &_5, 113, key); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, specialKey, keys); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, specialKey, keys); zephir_check_call_status(); } RETURN_MM_BOOL(1); @@ -40098,7 +40226,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Base64, beforeStore) { - ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", NULL, 112, data); + ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", NULL, 114, data); zephir_check_call_status(); RETURN_MM(); @@ -40114,7 +40242,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Base64, afterRetrieve) { - ZEPHIR_RETURN_CALL_FUNCTION("base64_decode", NULL, 113, data); + ZEPHIR_RETURN_CALL_FUNCTION("base64_decode", NULL, 115, data); zephir_check_call_status(); RETURN_MM(); @@ -40211,7 +40339,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Data, beforeStore) { - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, data); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, data); zephir_check_call_status(); RETURN_MM(); @@ -40227,7 +40355,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Data, afterRetrieve) { - ZEPHIR_RETURN_CALL_FUNCTION("unserialize", NULL, 72, data); + ZEPHIR_RETURN_CALL_FUNCTION("unserialize", NULL, 74, data); zephir_check_call_status(); RETURN_MM(); @@ -40322,7 +40450,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Igbinary, beforeStore) { - ZEPHIR_RETURN_CALL_FUNCTION("igbinary_serialize", NULL, 114, data); + ZEPHIR_RETURN_CALL_FUNCTION("igbinary_serialize", NULL, 116, data); zephir_check_call_status(); RETURN_MM(); @@ -40338,7 +40466,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Igbinary, afterRetrieve) { - ZEPHIR_RETURN_CALL_FUNCTION("igbinary_unserialize", NULL, 115, data); + ZEPHIR_RETURN_CALL_FUNCTION("igbinary_unserialize", NULL, 117, data); zephir_check_call_status(); RETURN_MM(); @@ -40603,7 +40731,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Output, start) { ZEPHIR_MM_GROW(); zephir_update_property_this(this_ptr, SL("_buffering"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -40618,7 +40746,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Output, getContent) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_buffering"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_contents", NULL, 117); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_contents", NULL, 119); zephir_check_call_status(); RETURN_MM(); } @@ -40635,7 +40763,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Output, stop) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_buffering"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); } zephir_update_property_this(this_ptr, SL("_buffering"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); @@ -41025,7 +41153,7 @@ static PHP_METHOD(Phalcon_Cli_Console, setArgument) { } if (_0) { Z_SET_ISREF_P(arguments); - ZEPHIR_CALL_FUNCTION(NULL, "array_shift", &_1, 119, arguments); + ZEPHIR_CALL_FUNCTION(NULL, "array_shift", &_1, 121, arguments); Z_UNSET_ISREF_P(arguments); zephir_check_call_status(); } @@ -41040,7 +41168,7 @@ static PHP_METHOD(Phalcon_Cli_Console, setArgument) { ZVAL_STRING(&_5, "--", 0); ZEPHIR_SINIT_NVAR(_6); ZVAL_LONG(&_6, 2); - ZEPHIR_CALL_FUNCTION(&_7, "strncmp", &_8, 120, arg, &_5, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "strncmp", &_8, 122, arg, &_5, &_6); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_7, 0)) { ZEPHIR_SINIT_NVAR(_5); @@ -41077,7 +41205,7 @@ static PHP_METHOD(Phalcon_Cli_Console, setArgument) { ZVAL_STRING(&_12, "-", 0); ZEPHIR_SINIT_NVAR(_13); ZVAL_LONG(&_13, 1); - ZEPHIR_CALL_FUNCTION(&_15, "strncmp", &_8, 120, arg, &_12, &_13); + ZEPHIR_CALL_FUNCTION(&_15, "strncmp", &_8, 122, arg, &_12, &_13); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_15, 0)) { ZEPHIR_SINIT_NVAR(_12); @@ -41095,21 +41223,21 @@ static PHP_METHOD(Phalcon_Cli_Console, setArgument) { } if (str) { ZEPHIR_INIT_NVAR(_9); - ZEPHIR_CALL_CE_STATIC(&_7, phalcon_cli_router_route_ce, "getdelimiter", &_16, 121); + ZEPHIR_CALL_CE_STATIC(&_7, phalcon_cli_router_route_ce, "getdelimiter", &_16, 123); zephir_check_call_status(); zephir_fast_join(_9, _7, args TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_arguments"), _9 TSRMLS_CC); } else { if (zephir_fast_count_int(args TSRMLS_CC)) { Z_SET_ISREF_P(args); - ZEPHIR_CALL_FUNCTION(&_15, "array_shift", &_1, 119, args); + ZEPHIR_CALL_FUNCTION(&_15, "array_shift", &_1, 121, args); Z_UNSET_ISREF_P(args); zephir_check_call_status(); zephir_array_update_string(&handleArgs, SL("task"), &_15, PH_COPY | PH_SEPARATE); } if (zephir_fast_count_int(args TSRMLS_CC)) { Z_SET_ISREF_P(args); - ZEPHIR_CALL_FUNCTION(&_7, "array_shift", &_1, 119, args); + ZEPHIR_CALL_FUNCTION(&_7, "array_shift", &_1, 121, args); Z_UNSET_ISREF_P(args); zephir_check_call_status(); zephir_array_update_string(&handleArgs, SL("action"), &_7, PH_COPY | PH_SEPARATE); @@ -41167,7 +41295,7 @@ static PHP_METHOD(Phalcon_Cli_Dispatcher, __construct) { ZEPHIR_INIT_VAR(_0); array_init(_0); zephir_update_property_this(this_ptr, SL("_options"), _0 TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_cli_dispatcher_ce, this_ptr, "__construct", &_1, 122); + ZEPHIR_CALL_PARENT(NULL, phalcon_cli_dispatcher_ce, this_ptr, "__construct", &_1, 124); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -41402,7 +41530,7 @@ static PHP_METHOD(Phalcon_Cli_Router, __construct) { add_assoc_long_ex(_1, SS("task"), 1); ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "#^(?::delimiter)?([a-zA-Z0-9\\_\\-]+)[:delimiter]{0,1}$#", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 123, _2, _1); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 125, _2, _1); zephir_check_temp_parameter(_2); zephir_check_call_status(); zephir_array_append(&routes, _0, PH_SEPARATE, "phalcon/cli/router.zep", 90); @@ -41415,7 +41543,7 @@ static PHP_METHOD(Phalcon_Cli_Router, __construct) { add_assoc_long_ex(_4, SS("params"), 3); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "#^(?::delimiter)?([a-zA-Z0-9\\_\\-]+):delimiter([a-zA-Z0-9\\.\\_]+)(:delimiter.*)*$#", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 123, _5, _4); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 125, _5, _4); zephir_check_temp_parameter(_5); zephir_check_call_status(); zephir_array_append(&routes, _2, PH_SEPARATE, "phalcon/cli/router.zep", 96); @@ -41702,7 +41830,7 @@ static PHP_METHOD(Phalcon_Cli_Router, handle) { ZEPHIR_INIT_VAR(strParams); zephir_substr(strParams, _15, 1 , 0, ZEPHIR_SUBSTR_NO_LENGTH); if (zephir_is_true(strParams)) { - ZEPHIR_CALL_CE_STATIC(&_17, phalcon_cli_router_route_ce, "getdelimiter", &_18, 121); + ZEPHIR_CALL_CE_STATIC(&_17, phalcon_cli_router_route_ce, "getdelimiter", &_18, 123); zephir_check_call_status(); ZEPHIR_INIT_NVAR(params); zephir_fast_explode(params, _17, strParams, LONG_MAX TSRMLS_CC); @@ -41758,7 +41886,7 @@ static PHP_METHOD(Phalcon_Cli_Router, add) { ZEPHIR_INIT_VAR(route); object_init_ex(route, phalcon_cli_router_route_ce); - ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 123, pattern, paths); + ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 125, pattern, paths); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_routes"), route TSRMLS_CC); RETURN_CCTOR(route); @@ -42788,7 +42916,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Ini, __construct) { } - ZEPHIR_CALL_FUNCTION(&iniConfig, "parse_ini_file", NULL, 124, filePath, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&iniConfig, "parse_ini_file", NULL, 126, filePath, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(iniConfig)) { ZEPHIR_INIT_VAR(_0); @@ -42838,7 +42966,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Ini, __construct) { zephir_array_update_zval(&config, section, &directives, PH_COPY | PH_SEPARATE); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_ini_ce, this_ptr, "__construct", &_12, 21, config); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_ini_ce, this_ptr, "__construct", &_12, 22, config); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -42885,7 +43013,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Ini, _parseIniString) { zephir_substr(_3, path, zephir_get_intval(&_2), 0, ZEPHIR_SUBSTR_NO_LENGTH); zephir_get_strval(path, _3); zephir_create_array(return_value, 1, 0 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "_parseinistring", NULL, 125, path, value); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "_parseinistring", NULL, 127, path, value); zephir_check_call_status(); zephir_array_update_zval(&return_value, key, &_4, PH_COPY); RETURN_MM(); @@ -42941,7 +43069,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Json, __construct) { ZEPHIR_INIT_VAR(_2); zephir_file_get_contents(_2, filePath TSRMLS_CC); zephir_json_decode(_1, &(_1), _2, zephir_get_intval(ZEPHIR_GLOBAL(global_true)) TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_json_ce, this_ptr, "__construct", &_0, 21, _1); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_json_ce, this_ptr, "__construct", &_0, 22, _1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -42996,7 +43124,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Php, __construct) { if (zephir_require_zval_ret(&_1, filePath TSRMLS_CC) == FAILURE) { RETURN_MM_NULL(); } - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_php_ce, this_ptr, "__construct", &_0, 21, _1); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_php_ce, this_ptr, "__construct", &_0, 22, _1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -43057,7 +43185,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Yaml, __construct) { ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "yaml", 0); - ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", NULL, 126, &_0); + ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", NULL, 128, &_0); zephir_check_call_status(); if (!(zephir_is_true(_1))) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_config_exception_ce, "Yaml extension not loaded", "phalcon/config/adapter/yaml.zep", 62); @@ -43069,11 +43197,11 @@ static PHP_METHOD(Phalcon_Config_Adapter_Yaml, __construct) { ZEPHIR_INIT_VAR(_3); ZVAL_LONG(_3, ndocs); Z_SET_ISREF_P(_3); - ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 127, filePath, _2, _3, callbacks); + ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 129, filePath, _2, _3, callbacks); Z_UNSET_ISREF_P(_3); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 127, filePath); + ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 129, filePath); zephir_check_call_status(); } if (ZEPHIR_IS_FALSE_IDENTICAL(yamlConfig)) { @@ -43089,7 +43217,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Yaml, __construct) { ZEPHIR_MM_RESTORE(); return; } - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_yaml_ce, this_ptr, "__construct", &_6, 21, yamlConfig); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_yaml_ce, this_ptr, "__construct", &_6, 22, yamlConfig); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -45708,7 +45836,7 @@ static PHP_METHOD(Phalcon_Db_Column, __set_state) { zephir_array_update_string(&definition, SL("bindType"), &bindType, PH_COPY | PH_SEPARATE); } object_init_ex(return_value, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 140, columnName, definition); zephir_check_call_status(); RETURN_MM(); @@ -46036,7 +46164,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getColumnList) { ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(column, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlcolumn", &_4, 29, column, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlcolumn", &_4, 30, column, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_append(&columns, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 158); } @@ -46164,17 +46292,17 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpression) { } do { if (ZEPHIR_IS_STRING(type, "scalar")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionscalar", NULL, 30, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionscalar", NULL, 31, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "object")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionobject", NULL, 31, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionobject", NULL, 32, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "qualified")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionqualified", NULL, 32, expression, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionqualified", NULL, 33, expression, escapeChar); zephir_check_call_status(); RETURN_MM(); } @@ -46223,34 +46351,34 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpression) { RETURN_CTOR(_0); } if (ZEPHIR_IS_STRING(type, "binary-op")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionbinaryoperations", NULL, 33, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionbinaryoperations", NULL, 34, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "unary-op")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionunaryoperations", NULL, 34, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionunaryoperations", NULL, 35, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "parentheses")) { zephir_array_fetch_string(&_0, expression, SL("left"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 305 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_6, this_ptr, "getsqlexpression", NULL, 35, _0, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_6, this_ptr, "getsqlexpression", NULL, 36, _0, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "(", _6, ")"); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "functionCall")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionfunctioncall", NULL, 36, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionfunctioncall", NULL, 37, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "list")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionlist", NULL, 37, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionlist", NULL, 38, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "all")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionall", NULL, 38, expression, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionall", NULL, 39, expression, escapeChar); zephir_check_call_status(); RETURN_MM(); } @@ -46262,17 +46390,17 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpression) { RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "cast")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncastvalue", NULL, 39, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncastvalue", NULL, 40, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "convert")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionconvertvalue", NULL, 40, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionconvertvalue", NULL, 41, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "case")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncase", NULL, 41, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncase", NULL, 42, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } @@ -46318,7 +46446,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlTable) { zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", NULL, 42, table, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", NULL, 43, table, escapeChar); zephir_check_call_status(); RETURN_MM(); @@ -46364,12 +46492,12 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { zephir_array_isset_string_fetch(&bindCounts, definition, SS("bindCounts"), 0 TSRMLS_CC); ZEPHIR_OBS_VAR(escapeChar); zephir_read_property_this(&escapeChar, this_ptr, SL("_escapeChar"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 43, columns, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 44, columns, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SV(_1, " ", _0); zephir_concat_self(&sql, _1 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "getsqlexpressionfrom", NULL, 44, tables, escapeChar); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "getsqlexpressionfrom", NULL, 45, tables, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SV(_3, " ", _2); @@ -46381,7 +46509,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { } if (_4) { zephir_array_fetch_string(&_6, definition, SL("joins"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 429 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionjoins", NULL, 45, _6, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionjoins", NULL, 46, _6, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -46393,7 +46521,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { _8 = zephir_is_true(where); } if (_8) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionwhere", NULL, 46, where, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionwhere", NULL, 47, where, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -46405,7 +46533,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { _9 = zephir_is_true(groupBy); } if (_9) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressiongroupby", NULL, 47, groupBy, escapeChar); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressiongroupby", NULL, 48, groupBy, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -46417,7 +46545,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { _10 = zephir_is_true(having); } if (_10) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionhaving", NULL, 48, having, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionhaving", NULL, 49, having, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -46429,7 +46557,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { _11 = zephir_is_true(orderBy); } if (_11) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionorderby", NULL, 49, orderBy, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionorderby", NULL, 50, orderBy, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -46445,7 +46573,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { zephir_create_array(_13, 2, 0 TSRMLS_CC); zephir_array_update_string(&_13, SL("sql"), &sql, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_13, SL("value"), &limit, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&sql, this_ptr, "getsqlexpressionlimit", NULL, 50, _13, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&sql, this_ptr, "getsqlexpressionlimit", NULL, 51, _13, escapeChar, bindCounts); zephir_check_call_status(); } _14 = zephir_array_isset_string_fetch(&forUpdate, definition, SS("forUpdate"), 1 TSRMLS_CC); @@ -46581,7 +46709,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionScalar) { if (zephir_array_isset_string(expression, SS("column"))) { zephir_array_fetch_string(&_0, expression, SL("column"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 525 TSRMLS_CC); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlcolumn", NULL, 29, _0); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlcolumn", NULL, 30, _0); zephir_check_call_status(); RETURN_MM(); } @@ -46708,7 +46836,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionBinaryOperations) { ZEPHIR_CALL_METHOD(&left, this_ptr, "getsqlexpression", &_1, 0, _0, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_2, expression, SL("right"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 583 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 35, _2, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 36, _2, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_3, expression, SL("op"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 585 TSRMLS_CC); ZEPHIR_CONCAT_VSVSV(return_value, left, " ", _3, " ", right); @@ -46751,7 +46879,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionUnaryOperations) { ZEPHIR_OBS_VAR(right); if (zephir_array_isset_string_fetch(&right, expression, SS("right"), 0 TSRMLS_CC)) { zephir_array_fetch_string(&_2, expression, SL("op"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 606 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getsqlexpression", &_1, 35, right, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getsqlexpression", &_1, 36, right, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_VSV(return_value, _2, " ", _0); RETURN_MM(); @@ -46955,7 +47083,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionCastValue) { ZEPHIR_CALL_METHOD(&left, this_ptr, "getsqlexpression", &_1, 0, _0, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_2, expression, SL("right"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 693 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 35, _2, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 36, _2, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "CAST(", left, " AS ", right, ")"); RETURN_MM(); @@ -46990,7 +47118,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionConvertValue) { ZEPHIR_CALL_METHOD(&left, this_ptr, "getsqlexpression", &_1, 0, _0, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_2, expression, SL("right"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 706 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 35, _2, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 36, _2, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "CONVERT(", left, " USING ", right, ")"); RETURN_MM(); @@ -47038,17 +47166,17 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionCase) { zephir_array_fetch_string(&_7, whenClause, SL("type"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 721 TSRMLS_CC); if (ZEPHIR_IS_STRING(_7, "when")) { zephir_array_fetch_string(&_9, whenClause, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 723 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 35, _9, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 36, _9, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_11, whenClause, SL("then"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 725 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_10, this_ptr, "getsqlexpression", &_2, 35, _11, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "getsqlexpression", &_2, 36, _11, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SVSV(_12, " WHEN ", _8, " THEN ", _10); zephir_concat_self(&sql, _12 TSRMLS_CC); } else { zephir_array_fetch_string(&_9, whenClause, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 727 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 35, _9, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 36, _9, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SV(_12, " ELSE ", _8); @@ -47089,7 +47217,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionFrom) { ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(table, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqltable", &_4, 51, table, escapeChar); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqltable", &_4, 52, table, escapeChar); zephir_check_call_status(); zephir_array_append(&tables, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 746); } @@ -47156,7 +47284,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionJoins) { ; zephir_hash_move_forward_ex(_6, &_5) ) { ZEPHIR_GET_HVALUE(condition, _7); - ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_4, 35, condition, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_4, 36, condition, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_append(&joinCondition, _8, PH_SEPARATE, "phalcon/db/dialect.zep", 779); } @@ -47177,7 +47305,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionJoins) { zephir_concat_self_str(&joinType, SL(" ") TSRMLS_CC); } zephir_array_fetch_string(&_11, join, SL("source"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 792 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&joinTable, this_ptr, "getsqltable", &_12, 51, _11, escapeChar); + ZEPHIR_CALL_METHOD(&joinTable, this_ptr, "getsqltable", &_12, 52, _11, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_13); ZEPHIR_CONCAT_SVSVSV(_13, " ", joinType, "JOIN ", joinTable, " ON ", joinCondition); @@ -47415,7 +47543,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionLimit) { _3 = Z_TYPE_P(offset) == IS_ARRAY; } if (_3) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getsqlexpression", &_2, 35, offset, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getsqlexpression", &_2, 36, offset, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CPY_WRT(offset, _4); } @@ -47467,7 +47595,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, prepareColumnAlias) { if (!ZEPHIR_IS_STRING(alias, "")) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", NULL, 42, alias, escapeChar); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", NULL, 43, alias, escapeChar); zephir_check_call_status(); ZEPHIR_CONCAT_VSV(return_value, qualified, " AS ", _0); RETURN_MM(); @@ -47517,18 +47645,18 @@ static PHP_METHOD(Phalcon_Db_Dialect, prepareTable) { } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", &_1, 42, table, escapeChar); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", &_1, 43, table, escapeChar); zephir_check_call_status(); zephir_get_strval(table, _0); if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 42, schema, escapeChar); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 43, schema, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_VSV(_3, _2, ".", table); zephir_get_strval(table, _3); } if (!ZEPHIR_IS_STRING(alias, "")) { - ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 42, alias, escapeChar); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 43, alias, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_VSV(_3, table, " AS ", _2); @@ -47576,11 +47704,11 @@ static PHP_METHOD(Phalcon_Db_Dialect, prepareQualified) { if (!ZEPHIR_IS_STRING(domain, "")) { ZEPHIR_INIT_VAR(_0); ZEPHIR_CONCAT_VSV(_0, domain, ".", column); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 42, _0, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 43, _0, escapeChar); zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 42, column, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 43, column, escapeChar); zephir_check_call_status(); RETURN_MM(); @@ -47890,19 +48018,19 @@ static PHP_METHOD(Phalcon_Db_Profiler, startProfile) { ZEPHIR_CALL_METHOD(NULL, activeProfile, "__construct", NULL, 0); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 144, sqlStatement); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 145, sqlStatement); zephir_check_call_status(); if (Z_TYPE_P(sqlVariables) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 145, sqlVariables); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 146, sqlVariables); zephir_check_call_status(); } if (Z_TYPE_P(sqlBindTypes) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 146, sqlBindTypes); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 147, sqlBindTypes); zephir_check_call_status(); } ZEPHIR_INIT_VAR(_0); zephir_microtime(_0, ZEPHIR_GLOBAL(global_true) TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 147, _0); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 148, _0); zephir_check_call_status(); if ((zephir_method_exists_ex(this_ptr, SS("beforestartprofile") TSRMLS_CC) == SUCCESS)) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "beforestartprofile", NULL, 0, activeProfile); @@ -48397,7 +48525,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo, __construct) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "connect", NULL, 0, descriptor); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_ce, this_ptr, "__construct", &_0, 24, descriptor); + ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_ce, this_ptr, "__construct", &_0, 25, descriptor); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -48571,7 +48699,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo, executePrepared) { if (ZEPHIR_IS_LONG(type, 1)) { ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 10); - ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_5, 25, value, &_4); + ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_5, 26, value, &_4); zephir_check_call_status(); break; } @@ -48723,7 +48851,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo, query) { zephir_check_call_status(); } object_init_ex(return_value, phalcon_db_result_pdo_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 26, this_ptr, statement, sqlStatement, bindParams, bindTypes); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 27, this_ptr, statement, sqlStatement, bindParams, bindTypes); zephir_check_call_status(); RETURN_MM(); } @@ -48904,7 +49032,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo, convertBoundParams) { ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, setOrder); Z_SET_ISREF_P(matches); - ZEPHIR_CALL_FUNCTION(&_1, "preg_match_all", NULL, 27, bindPattern, sql, matches, _0); + ZEPHIR_CALL_FUNCTION(&_1, "preg_match_all", NULL, 28, bindPattern, sql, matches, _0); Z_UNSET_ISREF_P(matches); zephir_check_call_status(); if (zephir_is_true(_1)) { @@ -48933,7 +49061,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo, convertBoundParams) { } ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "?", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&boundSql, "preg_replace", NULL, 28, bindPattern, _0, sql); + ZEPHIR_CALL_FUNCTION(&boundSql, "preg_replace", NULL, 29, bindPattern, _0, sql); zephir_check_temp_parameter(_0); zephir_check_call_status(); } else { @@ -49521,7 +49649,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Mysql, describeColumns) { zephir_array_fetch_long(&columnName, field, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/mysql.zep", 324 TSRMLS_CC); ZEPHIR_INIT_NVAR(_7); object_init_ex(_7, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_15, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_15, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter/pdo/mysql.zep", 325); ZEPHIR_CPY_WRT(oldColumn, columnName); @@ -49579,7 +49707,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Oracle, connect) { ZEPHIR_OBS_NVAR(descriptor); zephir_read_property_this(&descriptor, this_ptr, SL("_descriptor"), PH_NOISY_CC); } - ZEPHIR_CALL_PARENT(&status, phalcon_db_adapter_pdo_oracle_ce, this_ptr, "connect", &_0, 139, descriptor); + ZEPHIR_CALL_PARENT(&status, phalcon_db_adapter_pdo_oracle_ce, this_ptr, "connect", &_0, 141, descriptor); zephir_check_call_status(); ZEPHIR_OBS_VAR(startup); if (zephir_array_isset_string_fetch(&startup, descriptor, SS("startup"), 0 TSRMLS_CC)) { @@ -49753,7 +49881,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Oracle, describeColumns) { zephir_array_fetch_long(&columnName, field, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/oracle.zep", 194 TSRMLS_CC); ZEPHIR_INIT_NVAR(_8); object_init_ex(_8, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _8, "__construct", &_11, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _8, "__construct", &_11, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _8, PH_SEPARATE, "phalcon/db/adapter/pdo/oracle.zep", 199); ZEPHIR_CPY_WRT(oldColumn, columnName); @@ -49888,7 +50016,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, connect) { zephir_array_update_string(&descriptor, SL("password"), &ZEPHIR_GLOBAL(global_null), PH_COPY | PH_SEPARATE); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_postgresql_ce, this_ptr, "connect", &_3, 139, descriptor); + ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_postgresql_ce, this_ptr, "connect", &_3, 141, descriptor); zephir_check_call_status(); if (!(ZEPHIR_IS_EMPTY(schema))) { ZEPHIR_INIT_VAR(sql); @@ -50108,7 +50236,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, describeColumns) { ZVAL_STRING(_8, "/^'|'?::[[:alnum:][:space:]]+$/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_9); ZVAL_STRING(_9, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_15, "preg_replace", &_16, 28, _8, _9, _14); + ZEPHIR_CALL_FUNCTION(&_15, "preg_replace", &_16, 29, _8, _9, _14); zephir_check_temp_parameter(_8); zephir_check_temp_parameter(_9); zephir_check_call_status(); @@ -50116,7 +50244,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, describeColumns) { zephir_array_fetch_string(&_17, definition, SL("default"), PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/postgresql.zep", 305 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_18); ZVAL_STRING(&_18, "null", 0); - ZEPHIR_CALL_FUNCTION(&_19, "strcasecmp", &_20, 140, _17, &_18); + ZEPHIR_CALL_FUNCTION(&_19, "strcasecmp", &_20, 19, _17, &_18); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_19, 0)) { zephir_array_update_string(&definition, SL("default"), &ZEPHIR_GLOBAL(global_null), PH_COPY | PH_SEPARATE); @@ -50125,7 +50253,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, describeColumns) { zephir_array_fetch_long(&columnName, field, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/postgresql.zep", 313 TSRMLS_CC); ZEPHIR_INIT_NVAR(_7); object_init_ex(_7, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter/pdo/postgresql.zep", 314); ZEPHIR_CPY_WRT(oldColumn, columnName); @@ -50418,7 +50546,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, connect) { return; } zephir_array_update_string(&descriptor, SL("dsn"), &dbname, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_sqlite_ce, this_ptr, "connect", &_0, 139, descriptor); + ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_sqlite_ce, this_ptr, "connect", &_0, 141, descriptor); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -50616,7 +50744,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, describeColumns) { zephir_array_fetch_long(&_13, field, 4, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/sqlite.zep", 279 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "null", 0); - ZEPHIR_CALL_FUNCTION(&_15, "strcasecmp", &_16, 140, _13, &_14); + ZEPHIR_CALL_FUNCTION(&_15, "strcasecmp", &_16, 19, _13, &_14); zephir_check_call_status(); _9 = !ZEPHIR_IS_LONG(_15, 0); if (_9) { @@ -50629,7 +50757,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, describeColumns) { ZVAL_STRING(_7, "/^'|'$/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_8); ZVAL_STRING(_8, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_19, "preg_replace", &_20, 28, _7, _8, _18); + ZEPHIR_CALL_FUNCTION(&_19, "preg_replace", &_20, 29, _7, _8, _18); zephir_check_temp_parameter(_7); zephir_check_temp_parameter(_8); zephir_check_call_status(); @@ -50638,7 +50766,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, describeColumns) { zephir_array_fetch_long(&columnName, field, 1, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/sqlite.zep", 286 TSRMLS_CC); ZEPHIR_INIT_NVAR(_7); object_init_ex(_7, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter/pdo/sqlite.zep", 287); ZEPHIR_CPY_WRT(oldColumn, columnName); @@ -51093,7 +51221,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) { ZEPHIR_GET_HVALUE(value, _7); ZEPHIR_SINIT_NVAR(_8); ZVAL_STRING(&_8, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_9, 141, value, &_8); + ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_9, 142, value, &_8); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "\"", _0, "\", "); @@ -51111,7 +51239,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) { } else { ZEPHIR_SINIT_NVAR(_10); ZVAL_STRING(&_10, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_9, 141, typeValues, &_10); + ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_9, 142, typeValues, &_10); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, "(\"", _2, "\")"); @@ -51170,7 +51298,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 142, defaultValue, &_3); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\""); @@ -51247,7 +51375,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 142, defaultValue, &_3); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\""); @@ -51363,7 +51491,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 43, _4); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 44, _4); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSVS(_1, "`", _2, "` (", _3, ")"); @@ -51460,7 +51588,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addPrimaryKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 44, _2); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD PRIMARY KEY (", _1, ")"); RETURN_MM(); @@ -51546,7 +51674,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 43, _3); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 44, _3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_5, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); @@ -51556,7 +51684,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_8, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 43, _8); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 44, _8); zephir_check_call_status(); ZEPHIR_INIT_VAR(sql); ZEPHIR_CONCAT_SVSVSVSVSVS(sql, "ALTER TABLE ", _0, " ADD FOREIGN KEY `", _1, "`(", _2, ") REFERENCES ", _4, "(", _7, ")"); @@ -51707,7 +51835,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_NVAR(_6); ZVAL_STRING(&_6, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 142, defaultValue, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\""); @@ -51745,7 +51873,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) { ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_13, 43, _4); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_13, 44, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(indexSql); ZEPHIR_CONCAT_SVS(indexSql, "PRIMARY KEY (", _3, ")"); @@ -51754,13 +51882,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { if (!(ZEPHIR_IS_EMPTY(indexType))) { ZEPHIR_CALL_METHOD(&_14, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_13, 43, _14); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_13, 44, _14); zephir_check_call_status(); ZEPHIR_CONCAT_VSVSVS(indexSql, indexType, " KEY `", indexName, "` (", _7, ")"); } else { ZEPHIR_CALL_METHOD(&_15, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_14, this_ptr, "getcolumnlist", &_13, 43, _15); + ZEPHIR_CALL_METHOD(&_14, this_ptr, "getcolumnlist", &_13, 44, _15); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(indexSql, "KEY `", indexName, "` (", _14, ")"); } @@ -51780,13 +51908,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_13, 43, _7); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_13, 44, _7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_14, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_13, 43, _19); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_13, 44, _19); zephir_check_call_status(); ZEPHIR_INIT_NVAR(referenceSql); ZEPHIR_CONCAT_SVSVSSVSVS(referenceSql, "CONSTRAINT `", _3, "` FOREIGN KEY (", _4, ")", " REFERENCES `", _14, "`(", _15, ")"); @@ -53016,14 +53144,14 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, viewExists) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, viewName); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_VIEWS WHERE VIEW_NAME='", _0, "' AND OWNER='", _2, "'"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, viewName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_VIEWS WHERE VIEW_NAME='", _0, "'"); RETURN_MM(); @@ -53049,7 +53177,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, listViews) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT VIEW_NAME FROM ALL_VIEWS WHERE OWNER='", _0, "' ORDER BY VIEW_NAME"); RETURN_MM(); @@ -53088,14 +53216,14 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, tableExists) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, tableName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, tableName); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_TABLES WHERE TABLE_NAME='", _0, "' AND OWNER = '", _2, "'"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, tableName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, tableName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_TABLES WHERE TABLE_NAME='", _0, "'"); RETURN_MM(); @@ -53132,14 +53260,14 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeColumns) { if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schema); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT TC.COLUMN_NAME, TC.DATA_TYPE, TC.DATA_LENGTH, TC.DATA_PRECISION, TC.DATA_SCALE, TC.NULLABLE, C.CONSTRAINT_TYPE, TC.DATA_DEFAULT, CC.POSITION FROM ALL_TAB_COLUMNS TC LEFT JOIN (ALL_CONS_COLUMNS CC JOIN ALL_CONSTRAINTS C ON (CC.CONSTRAINT_NAME = C.CONSTRAINT_NAME AND CC.TABLE_NAME = C.TABLE_NAME AND CC.OWNER = C.OWNER AND C.CONSTRAINT_TYPE = 'P')) ON TC.TABLE_NAME = CC.TABLE_NAME AND TC.COLUMN_NAME = CC.COLUMN_NAME WHERE TC.TABLE_NAME = '", _0, "' AND TC.OWNER = '", _2, "' ORDER BY TC.COLUMN_ID"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT TC.COLUMN_NAME, TC.DATA_TYPE, TC.DATA_LENGTH, TC.DATA_PRECISION, TC.DATA_SCALE, TC.NULLABLE, C.CONSTRAINT_TYPE, TC.DATA_DEFAULT, CC.POSITION FROM ALL_TAB_COLUMNS TC LEFT JOIN (ALL_CONS_COLUMNS CC JOIN ALL_CONSTRAINTS C ON (CC.CONSTRAINT_NAME = C.CONSTRAINT_NAME AND CC.TABLE_NAME = C.TABLE_NAME AND CC.OWNER = C.OWNER AND C.CONSTRAINT_TYPE = 'P')) ON TC.TABLE_NAME = CC.TABLE_NAME AND TC.COLUMN_NAME = CC.COLUMN_NAME WHERE TC.TABLE_NAME = '", _0, "' ORDER BY TC.COLUMN_ID"); RETURN_MM(); @@ -53165,7 +53293,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, listTables) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT TABLE_NAME, OWNER FROM ALL_TABLES WHERE OWNER='", _0, "' ORDER BY OWNER, TABLE_NAME"); RETURN_MM(); @@ -53204,14 +53332,14 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeIndexes) { if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schema); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT I.TABLE_NAME, 0 AS C0, I.INDEX_NAME, IC.COLUMN_POSITION, IC.COLUMN_NAME FROM ALL_INDEXES I JOIN ALL_IND_COLUMNS IC ON I.INDEX_NAME = IC.INDEX_NAME WHERE I.TABLE_NAME = '", _0, "' AND IC.INDEX_OWNER = '", _2, "'"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT I.TABLE_NAME, 0 AS C0, I.INDEX_NAME, IC.COLUMN_POSITION, IC.COLUMN_NAME FROM ALL_INDEXES I JOIN ALL_IND_COLUMNS IC ON I.INDEX_NAME = IC.INDEX_NAME WHERE I.TABLE_NAME = '", _0, "'"); RETURN_MM(); @@ -53250,15 +53378,15 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeReferences) { ZEPHIR_INIT_VAR(sql); ZVAL_STRING(sql, "SELECT AC.TABLE_NAME, CC.COLUMN_NAME, AC.CONSTRAINT_NAME, AC.R_OWNER, RCC.TABLE_NAME R_TABLE_NAME, RCC.COLUMN_NAME R_COLUMN_NAME FROM ALL_CONSTRAINTS AC JOIN ALL_CONS_COLUMNS CC ON AC.CONSTRAINT_NAME = CC.CONSTRAINT_NAME JOIN ALL_CONS_COLUMNS RCC ON AC.R_OWNER = RCC.OWNER AND AC.R_CONSTRAINT_NAME = RCC.CONSTRAINT_NAME WHERE AC.CONSTRAINT_TYPE='R' ", 1); if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, schema); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SVSVS(_3, "AND AC.OWNER='", _0, "' AND AC.TABLE_NAME = '", _2, "'"); zephir_concat_self(&sql, _3 TSRMLS_CC); } else { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVS(_3, "AND AC.TABLE_NAME = '", _0, "'"); @@ -53354,11 +53482,11 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, prepareTable) { } - ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 142, table); + ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 143, table); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_3, phalcon_text_ce, "upper", &_2, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_3, phalcon_text_ce, "upper", &_2, 143, schema); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_PARENT(phalcon_db_dialect_oracle_ce, this_ptr, "preparetable", &_0, 143, _1, _3, alias, escapeChar); + ZEPHIR_RETURN_CALL_PARENT(phalcon_db_dialect_oracle_ce, this_ptr, "preparetable", &_0, 144, _1, _3, alias, escapeChar); zephir_check_call_status(); RETURN_MM(); @@ -53527,7 +53655,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, getColumnDefinition) { ZEPHIR_GET_HVALUE(value, _4); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_6, 141, value, &_5); + ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_6, 142, value, &_5); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "\"", _0, "\", "); @@ -53545,7 +53673,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, getColumnDefinition) { } else { ZEPHIR_SINIT_NVAR(_7); ZVAL_STRING(&_7, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_10, "addcslashes", &_6, 141, typeValues, &_7); + ZEPHIR_CALL_FUNCTION(&_10, "addcslashes", &_6, 142, typeValues, &_7); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, "(\"", _10, "\")"); @@ -53607,7 +53735,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 142, defaultValue, &_4); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\""); @@ -53739,7 +53867,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) { zephir_check_call_status(); ZEPHIR_SINIT_VAR(_11); ZVAL_STRING(&_11, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_12, "addcslashes", NULL, 141, defaultValue, &_11); + ZEPHIR_CALL_FUNCTION(&_12, "addcslashes", NULL, 142, defaultValue, &_11); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_VSVSVS(_9, sqlAlterTable, " ALTER COLUMN \"", _8, "\" SET DEFAULT \"", _12, "\""); @@ -53859,7 +53987,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addIndex) { zephir_concat_self(&sql, _1 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 43, _5); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 44, _5); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZEPHIR_CONCAT_SVS(_6, " (", _4, ")"); @@ -53953,7 +54081,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 44, _2); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _1, ")"); RETURN_MM(); @@ -54039,13 +54167,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 43, _3); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 44, _3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_4, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_6, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", NULL, 43, _6); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", NULL, 44, _6); zephir_check_call_status(); ZEPHIR_INIT_VAR(sql); ZEPHIR_CONCAT_SVSVSVSSVSVS(sql, "ALTER TABLE ", _0, " ADD CONSTRAINT \"", _1, "\" FOREIGN KEY (", _2, ")", " REFERENCES \"", _4, "\" (", _5, ")"); @@ -54120,12 +54248,12 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropForeignKey) { static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { - zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_16 = NULL; - HashTable *_1, *_14, *_23; - HashPosition _0, _13, _22; + zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL; + HashTable *_1, *_13, *_21; + HashPosition _0, _12, _20; int ZEPHIR_LAST_CALL_STATUS; zval *definition = NULL; - zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, *_10 = NULL, *_11 = NULL, *_12 = NULL, **_15, *_17 = NULL, *_18 = NULL, *_19 = NULL, *_20 = NULL, *_21 = NULL, **_24, *_25 = NULL; + zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, *_10 = NULL, *_11 = NULL, **_14, *_15 = NULL, *_16 = NULL, *_17 = NULL, *_18 = NULL, *_19 = NULL, **_22, *_23, *_24 = NULL; zval *tableName = NULL, *schemaName = NULL; ZEPHIR_MM_GROW(); @@ -54198,7 +54326,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_NVAR(_6); ZVAL_STRING(&_6, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 142, defaultValue, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\""); @@ -54223,22 +54351,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 381); } if (!(ZEPHIR_IS_EMPTY(primaryColumns))) { - ZEPHIR_INIT_VAR(_12); - zephir_fast_join_str(_12, SL(","), primaryColumns TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 44, primaryColumns); + zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); - ZEPHIR_CONCAT_SVS(_9, "PRIMARY KEY (", _12, ")"); + ZEPHIR_CONCAT_SVS(_9, "PRIMARY KEY (", _3, ")"); zephir_array_append(&createLines, _9, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 384); } ZEPHIR_INIT_VAR(indexSqlAfterCreate); ZVAL_STRING(indexSqlAfterCreate, "", 1); ZEPHIR_OBS_VAR(indexes); if (zephir_array_isset_string_fetch(&indexes, definition, SS("indexes"), 0 TSRMLS_CC)) { - zephir_is_iterable(indexes, &_14, &_13, 0, 0, "phalcon/db/dialect/postgresql.zep", 418); + zephir_is_iterable(indexes, &_13, &_12, 0, 0, "phalcon/db/dialect/postgresql.zep", 418); for ( - ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS - ; zephir_hash_move_forward_ex(_14, &_13) + ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS + ; zephir_hash_move_forward_ex(_13, &_12) ) { - ZEPHIR_GET_HVALUE(index, _15); + ZEPHIR_GET_HVALUE(index, _14); ZEPHIR_CALL_METHOD(&indexName, index, "getname", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0); @@ -54248,7 +54376,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) { ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_16, 43, _4); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 44, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(indexSql); ZEPHIR_CONCAT_SVS(indexSql, "CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _3, ")"); @@ -54256,25 +54384,25 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { if (!(ZEPHIR_IS_EMPTY(indexType))) { ZEPHIR_CALL_METHOD(&_10, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_16, 43, _10); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 44, _10); zephir_check_call_status(); ZEPHIR_INIT_NVAR(indexSql); ZEPHIR_CONCAT_SVSVSVS(indexSql, "CONSTRAINT \"", indexName, "\" ", indexType, " (", _7, ")"); } else { ZEPHIR_CALL_METHOD(&_11, index, "getname", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_17, this_ptr, "preparetable", NULL, 143, tableName, schemaName); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "preparetable", NULL, 144, tableName, schemaName); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_18); - ZEPHIR_CONCAT_SVSV(_18, "CREATE INDEX \"", _11, "\" ON ", _17); - zephir_concat_self(&indexSqlAfterCreate, _18 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_20, index, "getcolumns", NULL, 0); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SVSV(_16, "CREATE INDEX \"", _11, "\" ON ", _15); + zephir_concat_self(&indexSqlAfterCreate, _16 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_18, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_19, this_ptr, "getcolumnlist", &_16, 43, _20); + ZEPHIR_CALL_METHOD(&_17, this_ptr, "getcolumnlist", NULL, 44, _18); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_21); - ZEPHIR_CONCAT_SVS(_21, " (", _19, ");"); - zephir_concat_self(&indexSqlAfterCreate, _21 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_19); + ZEPHIR_CONCAT_SVS(_19, " (", _17, ");"); + zephir_concat_self(&indexSqlAfterCreate, _19 TSRMLS_CC); } } if (!(ZEPHIR_IS_EMPTY(indexSql))) { @@ -54284,64 +54412,64 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { } ZEPHIR_OBS_VAR(references); if (zephir_array_isset_string_fetch(&references, definition, SS("references"), 0 TSRMLS_CC)) { - zephir_is_iterable(references, &_23, &_22, 0, 0, "phalcon/db/dialect/postgresql.zep", 443); + zephir_is_iterable(references, &_21, &_20, 0, 0, "phalcon/db/dialect/postgresql.zep", 443); for ( - ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS - ; zephir_hash_move_forward_ex(_23, &_22) + ; zephir_hash_get_current_data_ex(_21, (void**) &_22, &_20) == SUCCESS + ; zephir_hash_move_forward_ex(_21, &_20) ) { - ZEPHIR_GET_HVALUE(reference, _24); + ZEPHIR_GET_HVALUE(reference, _22); ZEPHIR_CALL_METHOD(&_3, reference, "getname", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_16, 43, _7); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 44, _7); zephir_check_call_status(); ZEPHIR_INIT_NVAR(referenceSql); ZEPHIR_CONCAT_SVSVS(referenceSql, "CONSTRAINT \"", _3, "\" FOREIGN KEY (", _4, ") REFERENCES "); ZEPHIR_CALL_METHOD(&_11, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_10, this_ptr, "preparetable", NULL, 143, _11, schemaName); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "preparetable", NULL, 144, _11, schemaName); zephir_check_call_status(); zephir_concat_self(&referenceSql, _10 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0); + ZEPHIR_CALL_METHOD(&_17, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_17, this_ptr, "getcolumnlist", &_16, 43, _19); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", NULL, 44, _17); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); - ZEPHIR_CONCAT_SVS(_9, " (", _17, ")"); + ZEPHIR_CONCAT_SVS(_9, " (", _15, ")"); zephir_concat_self(&referenceSql, _9 TSRMLS_CC); ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0); zephir_check_call_status(); if (!(ZEPHIR_IS_EMPTY(onDelete))) { - ZEPHIR_INIT_LNVAR(_18); - ZEPHIR_CONCAT_SV(_18, " ON DELETE ", onDelete); - zephir_concat_self(&referenceSql, _18 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SV(_16, " ON DELETE ", onDelete); + zephir_concat_self(&referenceSql, _16 TSRMLS_CC); } ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0); zephir_check_call_status(); if (!(ZEPHIR_IS_EMPTY(onUpdate))) { - ZEPHIR_INIT_LNVAR(_21); - ZEPHIR_CONCAT_SV(_21, " ON UPDATE ", onUpdate); - zephir_concat_self(&referenceSql, _21 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_19); + ZEPHIR_CONCAT_SV(_19, " ON UPDATE ", onUpdate); + zephir_concat_self(&referenceSql, _19 TSRMLS_CC); } zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 441); } } - ZEPHIR_INIT_NVAR(_12); - zephir_fast_join_str(_12, SL(",\n\t"), createLines TSRMLS_CC); + ZEPHIR_INIT_VAR(_23); + zephir_fast_join_str(_23, SL(",\n\t"), createLines TSRMLS_CC); ZEPHIR_INIT_LNVAR(_9); - ZEPHIR_CONCAT_VS(_9, _12, "\n)"); + ZEPHIR_CONCAT_VS(_9, _23, "\n)"); zephir_concat_self(&sql, _9 TSRMLS_CC); if (zephir_array_isset_string(definition, SS("options"))) { ZEPHIR_CALL_METHOD(&_3, this_ptr, "_gettableoptions", NULL, 0, definition); zephir_check_call_status(); - ZEPHIR_INIT_VAR(_25); - ZEPHIR_CONCAT_SV(_25, " ", _3); - zephir_concat_self(&sql, _25 TSRMLS_CC); + ZEPHIR_INIT_VAR(_24); + ZEPHIR_CONCAT_SV(_24, " ", _3); + zephir_concat_self(&sql, _24 TSRMLS_CC); } - ZEPHIR_INIT_LNVAR(_25); - ZEPHIR_CONCAT_SV(_25, ";", indexSqlAfterCreate); - zephir_concat_self(&sql, _25 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_24); + ZEPHIR_CONCAT_SV(_24, ";", indexSqlAfterCreate); + zephir_concat_self(&sql, _24 TSRMLS_CC); RETURN_CCTOR(sql); } @@ -54892,7 +55020,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, getColumnDefinition) { ZEPHIR_GET_HVALUE(value, _5); ZEPHIR_SINIT_NVAR(_6); ZVAL_STRING(&_6, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_7, 141, value, &_6); + ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_7, 142, value, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "\"", _0, "\", "); @@ -54910,7 +55038,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, getColumnDefinition) { } else { ZEPHIR_SINIT_NVAR(_8); ZVAL_STRING(&_8, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_7, 141, typeValues, &_8); + ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_7, 142, typeValues, &_8); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVS(_10, "(\"", _2, "\")"); @@ -54972,7 +55100,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 142, defaultValue, &_4); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\""); @@ -55136,7 +55264,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addIndex) { } ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 43, _2); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 44, _2); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_VS(_1, _0, ")"); @@ -55841,13 +55969,17 @@ ZEPHIR_INIT_CLASS(Phalcon_Db_Profiler_Item) { static PHP_METHOD(Phalcon_Db_Profiler_Item, setSqlStatement) { - zval *sqlStatement; + zval *sqlStatement_param = NULL; + zval *sqlStatement = NULL; - zephir_fetch_params(0, 1, 0, &sqlStatement); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &sqlStatement_param); + zephir_get_strval(sqlStatement, sqlStatement_param); zephir_update_property_this(this_ptr, SL("_sqlStatement"), sqlStatement TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -55860,13 +55992,17 @@ static PHP_METHOD(Phalcon_Db_Profiler_Item, getSqlStatement) { static PHP_METHOD(Phalcon_Db_Profiler_Item, setSqlVariables) { - zval *sqlVariables; + zval *sqlVariables_param = NULL; + zval *sqlVariables = NULL; - zephir_fetch_params(0, 1, 0, &sqlVariables); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &sqlVariables_param); + zephir_get_arrval(sqlVariables, sqlVariables_param); zephir_update_property_this(this_ptr, SL("_sqlVariables"), sqlVariables TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -55879,13 +56015,17 @@ static PHP_METHOD(Phalcon_Db_Profiler_Item, getSqlVariables) { static PHP_METHOD(Phalcon_Db_Profiler_Item, setSqlBindTypes) { - zval *sqlBindTypes; + zval *sqlBindTypes_param = NULL; + zval *sqlBindTypes = NULL; - zephir_fetch_params(0, 1, 0, &sqlBindTypes); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &sqlBindTypes_param); + zephir_get_arrval(sqlBindTypes, sqlBindTypes_param); zephir_update_property_this(this_ptr, SL("_sqlBindTypes"), sqlBindTypes TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -55898,13 +56038,17 @@ static PHP_METHOD(Phalcon_Db_Profiler_Item, getSqlBindTypes) { static PHP_METHOD(Phalcon_Db_Profiler_Item, setInitialTime) { - zval *initialTime; + zval *initialTime_param = NULL, *_0; + double initialTime; - zephir_fetch_params(0, 1, 0, &initialTime); + zephir_fetch_params(0, 1, 0, &initialTime_param); + initialTime = zephir_get_doubleval(initialTime_param); - zephir_update_property_this(this_ptr, SL("_initialTime"), initialTime TSRMLS_CC); + ZEPHIR_INIT_ZVAL_NREF(_0); + ZVAL_DOUBLE(_0, initialTime); + zephir_update_property_this(this_ptr, SL("_initialTime"), _0 TSRMLS_CC); } @@ -55917,13 +56061,17 @@ static PHP_METHOD(Phalcon_Db_Profiler_Item, getInitialTime) { static PHP_METHOD(Phalcon_Db_Profiler_Item, setFinalTime) { - zval *finalTime; + zval *finalTime_param = NULL, *_0; + double finalTime; - zephir_fetch_params(0, 1, 0, &finalTime); + zephir_fetch_params(0, 1, 0, &finalTime_param); + finalTime = zephir_get_doubleval(finalTime_param); - zephir_update_property_this(this_ptr, SL("_finalTime"), finalTime TSRMLS_CC); + ZEPHIR_INIT_ZVAL_NREF(_0); + ZVAL_DOUBLE(_0, finalTime); + zephir_update_property_this(this_ptr, SL("_finalTime"), _0 TSRMLS_CC); } @@ -56425,7 +56573,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, all) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "variables", 1); zephir_array_fast_append(_0, _1); - ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 166); + ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 167); zephir_check_call_status(); ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, _0, _2); zephir_check_call_status(); @@ -56576,7 +56724,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { add_assoc_long_ex(_1, SS(":count"), zephir_fast_count_int(variable TSRMLS_CC)); ZEPHIR_SINIT_VAR(_5); ZVAL_STRING(&_5, "Array (:count) (\n", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); zephir_concat_self(&output, _2 TSRMLS_CC); zephir_is_iterable(variable, &_8, &_7, 0, 0, "phalcon/debug/dump.zep", 154); @@ -56588,7 +56736,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZEPHIR_GET_HVALUE(value, _9); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -56601,7 +56749,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_12, SL(":key"), &key, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "[:key] => ", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _10, _13); @@ -56625,7 +56773,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 167, value, _3, &_5); + ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 168, value, _3, &_5); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); @@ -56635,7 +56783,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab - 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_CONCAT_VVS(return_value, output, _10, ")"); RETURN_MM(); @@ -56654,10 +56802,10 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":class"), &_3, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Object :class", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); zephir_concat_self(&output, _2 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 168, variable); + ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 169, variable); zephir_check_call_status(); if (zephir_is_true(_13)) { ZEPHIR_INIT_NVAR(_12); @@ -56668,19 +56816,19 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_check_temp_parameter(_3); zephir_check_call_status(); zephir_array_update_string(&_12, SL(":style"), &_18, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 168, variable); + ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 169, variable); zephir_check_call_status(); zephir_array_update_string(&_12, SL(":parent"), &_18, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, " extends :parent", 0); - ZEPHIR_CALL_FUNCTION(&_18, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_18, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); zephir_concat_self(&output, _18 TSRMLS_CC); } zephir_concat_self_str(&output, SL(" (\n") TSRMLS_CC); _22 = zephir_fetch_nproperty_this(this_ptr, SL("_detailed"), PH_NOISY_CC); if (!(zephir_is_true(_22))) { - ZEPHIR_CALL_FUNCTION(&_10, "get_object_vars", NULL, 23, variable); + ZEPHIR_CALL_FUNCTION(&_10, "get_object_vars", NULL, 24, variable); zephir_check_call_status(); zephir_is_iterable(_10, &_24, &_23, 0, 0, "phalcon/debug/dump.zep", 171); for ( @@ -56691,7 +56839,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZEPHIR_GET_HVALUE(value, _25); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_13, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_13, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 3, 0 TSRMLS_CC); @@ -56705,7 +56853,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { add_assoc_stringl_ex(_12, SS(":type"), SL("public"), 1); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:key (:type) = ", 0); - ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _13, _26); @@ -56714,7 +56862,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5); + ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 168, value, _3, &_5); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); @@ -56724,7 +56872,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } else { do { Z_SET_ISREF_P(variable); - ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 169, variable); + ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 170, variable); Z_UNSET_ISREF_P(variable); zephir_check_call_status(); if (!(zephir_is_true(attr))) { @@ -56740,9 +56888,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZEPHIR_INIT_NVAR(_3); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "\\x00", 0); - ZEPHIR_CALL_FUNCTION(&_10, "ord", &_29, 130, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "ord", &_29, 132, &_5); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_13, "chr", &_30, 128, _10); + ZEPHIR_CALL_FUNCTION(&_13, "chr", &_30, 130, _10); zephir_check_call_status(); zephir_fast_explode(_3, _13, key, LONG_MAX TSRMLS_CC); ZEPHIR_CPY_WRT(key, _3); @@ -56759,7 +56907,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 3, 0 TSRMLS_CC); @@ -56770,14 +56918,14 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_check_call_status(); zephir_array_update_string(&_12, SL(":style"), &_26, PH_COPY | PH_SEPARATE); Z_SET_ISREF_P(key); - ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 170, key); + ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 171, key); Z_UNSET_ISREF_P(key); zephir_check_call_status(); zephir_array_update_string(&_12, SL(":key"), &_26, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_12, SL(":type"), &type, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:key (:type) = ", 0); - ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _18, _26); @@ -56786,7 +56934,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5); + ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 168, value, _3, &_5); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); @@ -56794,11 +56942,11 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_concat_self(&output, _20 TSRMLS_CC); } while (zephir_is_true(attr)); } - ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 171, variable); + ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 172, variable); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 3, 0 TSRMLS_CC); @@ -56814,7 +56962,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { add_assoc_long_ex(_12, SS(":count"), zephir_fast_count_int(attr TSRMLS_CC)); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, ":class methods: (:count) (\n", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _10, _13); @@ -56825,7 +56973,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { if (zephir_fast_in_array(_3, _33 TSRMLS_CC)) { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); ZEPHIR_CONCAT_VS(_20, _18, "[already listed]\n"); @@ -56843,7 +56991,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { if (ZEPHIR_IS_STRING(value, "__construct")) { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -56856,7 +57004,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_12, SL(":method"), &value, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:method(); [constructor]\n", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _10, _13); @@ -56864,7 +57012,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } else { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_FUNCTION(&_26, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_26, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_38); zephir_create_array(_38, 2, 0 TSRMLS_CC); @@ -56877,7 +57025,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_38, SL(":method"), &value, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:method();\n", 0); - ZEPHIR_CALL_FUNCTION(&_27, "strtr", &_6, 53, &_5, _38); + ZEPHIR_CALL_FUNCTION(&_27, "strtr", &_6, 54, &_5, _38); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_39); ZEPHIR_CONCAT_VV(_39, _26, _27); @@ -56886,7 +57034,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); ZEPHIR_CONCAT_VS(_20, _18, ")\n"); @@ -56894,7 +57042,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab - 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_CONCAT_VVS(return_value, output, _10, ")"); RETURN_MM(); @@ -56911,12 +57059,12 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Integer (:var)", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); } - ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 172, variable); + ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 173, variable); zephir_check_call_status(); if (zephir_is_true(_2)) { ZEPHIR_INIT_NVAR(_1); @@ -56930,7 +57078,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Float (:var)", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _13); RETURN_MM(); @@ -56948,7 +57096,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Numeric string (:length) \":var\"", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -56967,14 +57115,14 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_LONG(&_5, 4); ZEPHIR_SINIT_VAR(_40); ZVAL_STRING(&_40, "utf-8", 0); - ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 151, variable, &_5, &_40); + ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 152, variable, &_5, &_40); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_26, "nl2br", NULL, 173, _2); + ZEPHIR_CALL_FUNCTION(&_26, "nl2br", NULL, 174, _2); zephir_check_call_status(); zephir_array_update_string(&_1, SL(":var"), &_26, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "String (:length) \":var\"", 0); - ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _26); RETURN_MM(); @@ -56999,7 +57147,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &_14, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Boolean (:var)", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -57015,7 +57163,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":style"), &_2, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "NULL", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -57031,7 +57179,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "(:var)", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -57069,7 +57217,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, variable) { zephir_array_update_string(&_0, SL(":output"), &_1, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "
:output
", 0); - ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 53, &_3, _0); + ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 54, &_3, _0); zephir_check_call_status(); RETURN_MM(); @@ -57087,7 +57235,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, variables) { ZEPHIR_INIT_VAR(output); ZVAL_STRING(output, "", 1); - ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 166); + ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 167); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/debug/dump.zep", 290); for ( @@ -57196,7 +57344,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_ce, this_ptr, "__construct", &_0, 73); + ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_ce, this_ptr, "__construct", &_0, 75); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 21, 0 TSRMLS_CC); @@ -57208,7 +57356,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Router", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_VAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57221,7 +57369,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Dispatcher", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57234,7 +57382,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Url", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57247,7 +57395,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57260,7 +57408,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\MetaData\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57273,7 +57421,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Http\\Response", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57286,7 +57434,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Http\\Response\\Cookies", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57299,7 +57447,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Http\\Request", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57312,7 +57460,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Filter", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57325,7 +57473,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Escaper", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57338,7 +57486,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Security", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57351,7 +57499,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Crypt", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57364,7 +57512,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Annotations\\Adapter\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57377,7 +57525,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Flash\\Direct", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57390,7 +57538,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Flash\\Session", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57403,7 +57551,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Tag", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57416,7 +57564,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Session\\Adapter\\Files", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57427,7 +57575,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_3, "sessionBag", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_4); ZVAL_STRING(_4, "Phalcon\\Session\\Bag", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57440,7 +57588,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Events\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57448,12 +57596,12 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZEPHIR_INIT_NVAR(_2); object_init_ex(_2, phalcon_di_service_ce); ZEPHIR_INIT_NVAR(_3); - ZVAL_STRING(_3, "transactions", ZEPHIR_TEMP_PARAM_COPY); + ZVAL_STRING(_3, "transactionManager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_4); ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Transaction\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57466,7 +57614,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Assets\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57846,7 +57994,7 @@ static PHP_METHOD(Phalcon_Di_Service, resolve) { ZEPHIR_CALL_METHOD(NULL, builder, "__construct", NULL, 0); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 175, dependencyInjector, definition, parameters); + ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 176, dependencyInjector, definition, parameters); zephir_check_call_status(); } else { found = 0; @@ -57969,7 +58117,7 @@ static PHP_METHOD(Phalcon_Di_Service, __set_state) { return; } object_init_ex(return_value, phalcon_di_service_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 61, name, definition, shared); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 63, name, definition, shared); zephir_check_call_status(); RETURN_MM(); @@ -58009,6 +58157,8 @@ ZEPHIR_DOC_METHOD(Phalcon_Di_ServiceInterface, getDefinition); ZEPHIR_DOC_METHOD(Phalcon_Di_ServiceInterface, resolve); +ZEPHIR_DOC_METHOD(Phalcon_Di_ServiceInterface, setParameter); + ZEPHIR_DOC_METHOD(Phalcon_Di_ServiceInterface, __set_state); @@ -58042,7 +58192,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 174); + ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 175); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 10, 0 TSRMLS_CC); @@ -58054,7 +58204,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\CLI\\Router", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_VAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58067,7 +58217,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\CLI\\Dispatcher", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58080,7 +58230,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58093,7 +58243,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\MetaData\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58106,7 +58256,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Filter", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58119,7 +58269,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Escaper", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58132,7 +58282,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Annotations\\Adapter\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58145,7 +58295,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Security", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58158,7 +58308,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Events\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58171,7 +58321,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Transaction\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58344,7 +58494,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, _buildParameters) { ) { ZEPHIR_GET_HMKEY(position, _1, _0); ZEPHIR_GET_HVALUE(argument, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 176, dependencyInjector, position, argument); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 177, dependencyInjector, position, argument); zephir_check_call_status(); zephir_array_append(&buildArguments, _3, PH_SEPARATE, "phalcon/di/service/builder.zep", 117); } @@ -58389,7 +58539,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { } else { ZEPHIR_OBS_VAR(arguments); if (zephir_array_isset_string_fetch(&arguments, definition, SS("arguments"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 178, dependencyInjector, arguments); zephir_check_call_status(); ZEPHIR_INIT_NVAR(instance); ZEPHIR_LAST_CALL_STATUS = zephir_create_instance_params(instance, className, _0 TSRMLS_CC); @@ -58410,7 +58560,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "Setter injection parameters must be an array", "phalcon/di/service/builder.zep", 181); return; } - zephir_is_iterable(paramCalls, &_3, &_2, 0, 0, "phalcon/di/service/builder.zep", 235); + zephir_is_iterable(paramCalls, &_3, &_2, 0, 0, "phalcon/di/service/builder.zep", 233); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -58459,7 +58609,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { } if (zephir_fast_count_int(arguments TSRMLS_CC)) { ZEPHIR_INIT_NVAR(_5); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 178, dependencyInjector, arguments); zephir_check_call_status(); ZEPHIR_CALL_USER_FUNC_ARRAY(_5, methodCall, _0); zephir_check_call_status(); @@ -58474,14 +58624,14 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_OBS_NVAR(paramCalls); if (zephir_array_isset_string_fetch(¶mCalls, definition, SS("properties"), 0 TSRMLS_CC)) { if (Z_TYPE_P(instance) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "The definition has properties injection parameters but the constructor didn't return an instance", "phalcon/di/service/builder.zep", 243); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "The definition has properties injection parameters but the constructor didn't return an instance", "phalcon/di/service/builder.zep", 241); return; } if (Z_TYPE_P(paramCalls) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "Setter injection parameters must be an array", "phalcon/di/service/builder.zep", 247); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "Setter injection parameters must be an array", "phalcon/di/service/builder.zep", 245); return; } - zephir_is_iterable(paramCalls, &_9, &_8, 0, 0, "phalcon/di/service/builder.zep", 282); + zephir_is_iterable(paramCalls, &_9, &_8, 0, 0, "phalcon/di/service/builder.zep", 279); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) @@ -58495,7 +58645,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_CONCAT_SV(_6, "Property must be an array on position ", propertyPosition); ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_11, "phalcon/di/service/builder.zep", 259 TSRMLS_CC); + zephir_throw_exception_debug(_11, "phalcon/di/service/builder.zep", 257 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -58507,7 +58657,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_CONCAT_SV(_6, "The property name is required on position ", propertyPosition); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 266 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 264 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -58519,11 +58669,11 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_CONCAT_SV(_6, "The property value is required on position ", propertyPosition); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 273 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 271 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 176, dependencyInjector, propertyPosition, propertyValue); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 177, dependencyInjector, propertyPosition, propertyValue); zephir_check_call_status(); zephir_update_property_zval_zval(instance, propertyName, _0 TSRMLS_CC); } @@ -58588,13 +58738,17 @@ ZEPHIR_INIT_CLASS(Phalcon_Events_Event) { static PHP_METHOD(Phalcon_Events_Event, setType) { - zval *type; + zval *type_param = NULL; + zval *type = NULL; - zephir_fetch_params(0, 1, 0, &type); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &type_param); + zephir_get_strval(type, type_param); zephir_update_property_this(this_ptr, SL("_type"), type TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -58827,7 +58981,7 @@ static PHP_METHOD(Phalcon_Events_Manager, attach) { } ZEPHIR_INIT_VAR(_2); ZVAL_LONG(_2, 1); - ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 184, _2); + ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 185, _2); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_events"), eventType, priorityQueue TSRMLS_CC); } else { @@ -58837,7 +58991,7 @@ static PHP_METHOD(Phalcon_Events_Manager, attach) { if (Z_TYPE_P(priorityQueue) == IS_OBJECT) { ZEPHIR_INIT_NVAR(_2); ZVAL_LONG(_2, priority); - ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 185, handler, _2); + ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 186, handler, _2); zephir_check_call_status(); } else { zephir_array_append(&priorityQueue, handler, PH_SEPARATE, "phalcon/events/manager.zep", 82); @@ -58886,7 +59040,7 @@ static PHP_METHOD(Phalcon_Events_Manager, detach) { } ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 1); - ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 184, _1); + ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 185, _1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_1); ZVAL_LONG(_1, 3); @@ -58908,13 +59062,13 @@ static PHP_METHOD(Phalcon_Events_Manager, detach) { if (!ZEPHIR_IS_IDENTICAL(_5, handler)) { zephir_array_fetch_string(&_6, data, SL("data"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC); zephir_array_fetch_string(&_7, data, SL("priority"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 185, _6, _7); + ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 186, _6, _7); zephir_check_call_status(); } } zephir_update_property_array(this_ptr, SL("_events"), eventType, newPriorityQueue TSRMLS_CC); } else { - ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 186, handler, priorityQueue, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 187, handler, priorityQueue, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); if (!ZEPHIR_IS_FALSE_IDENTICAL(key)) { zephir_array_unset(&priorityQueue, key, PH_SEPARATE); @@ -59070,7 +59224,7 @@ static PHP_METHOD(Phalcon_Events_Manager, fireQueue) { zephir_get_class(_1, queue, 0 TSRMLS_CC); ZEPHIR_SINIT_VAR(_2); ZVAL_STRING(&_2, "Unexpected value type: expected object of type SplPriorityQueue, %s given", 0); - ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 187, &_2, _1); + ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 188, &_2, _1); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); @@ -59283,9 +59437,9 @@ static PHP_METHOD(Phalcon_Events_Manager, fire) { if (_3) { ZEPHIR_INIT_NVAR(event); object_init_ex(event, phalcon_events_event_ce); - ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 189, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event); + ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 190, fireEvents, event); zephir_check_call_status(); } } @@ -59299,10 +59453,10 @@ static PHP_METHOD(Phalcon_Events_Manager, fire) { if (Z_TYPE_P(event) == IS_NULL) { ZEPHIR_INIT_NVAR(event); object_init_ex(event, phalcon_events_event_ce); - ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 189, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event); + ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 190, fireEvents, event); zephir_check_call_status(); } } @@ -59515,7 +59669,7 @@ static PHP_METHOD(Phalcon_Flash_Direct, output) { } } if (remove) { - ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 196); + ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 197); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -59788,7 +59942,7 @@ static PHP_METHOD(Phalcon_Flash_Session, output) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 196); + ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 197); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -59806,7 +59960,7 @@ static PHP_METHOD(Phalcon_Flash_Session, clear) { ZVAL_BOOL(_0, 1); ZEPHIR_CALL_METHOD(NULL, this_ptr, "_getsessionmessages", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 196); + ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 197); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -60932,7 +61086,7 @@ static PHP_METHOD(Phalcon_Forms_Form, isValid) { } else { ZEPHIR_INIT_NVAR(validation); object_init_ex(validation, phalcon_validation_ce); - ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 210, preparedValidators); + ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 211, preparedValidators); zephir_check_call_status(); } ZEPHIR_CALL_METHOD(&filters, element, "getfilters", NULL, 0); @@ -60940,10 +61094,10 @@ static PHP_METHOD(Phalcon_Forms_Form, isValid) { if (Z_TYPE_P(filters) == IS_ARRAY) { ZEPHIR_CALL_METHOD(&_2, element, "getname", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 211, _2, filters); + ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 212, _2, filters); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 212, data, entity); + ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 213, data, entity); zephir_check_call_status(); if (zephir_fast_count_int(elementMessages TSRMLS_CC)) { ZEPHIR_CALL_METHOD(&_14, element, "getname", NULL, 0); @@ -61006,7 +61160,7 @@ static PHP_METHOD(Phalcon_Forms_Form, getMessages) { ; zephir_hash_move_forward_ex(_2, &_1) ) { ZEPHIR_GET_HVALUE(elementMessages, _3); - ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 213, elementMessages); + ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 214, elementMessages); zephir_check_call_status(); } } @@ -61476,7 +61630,7 @@ static PHP_METHOD(Phalcon_Forms_Form, rewind) { ZVAL_LONG(_0, 0); zephir_update_property_this(this_ptr, SL("_position"), _0 TSRMLS_CC); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_elements"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 214, _0); + ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 215, _0); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_elementsIndexed"), _1 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -61568,7 +61722,7 @@ static PHP_METHOD(Phalcon_Forms_Manager, create) { } ZEPHIR_INIT_VAR(form); object_init_ex(form, phalcon_forms_form_ce); - ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 215, entity); + ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 216, entity); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_forms"), name, form TSRMLS_CC); RETURN_CCTOR(form); @@ -61677,7 +61831,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Check, render) { ZVAL_BOOL(_2, 1); ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 197, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 198, _1); zephir_check_call_status(); RETURN_MM(); @@ -61722,7 +61876,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Date, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 198, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 199, _1); zephir_check_call_status(); RETURN_MM(); @@ -61767,7 +61921,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Email, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 199, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 200, _1); zephir_check_call_status(); RETURN_MM(); @@ -61812,7 +61966,7 @@ static PHP_METHOD(Phalcon_Forms_Element_File, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 200, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 201, _1); zephir_check_call_status(); RETURN_MM(); @@ -61857,7 +62011,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Hidden, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 201, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 202, _1); zephir_check_call_status(); RETURN_MM(); @@ -61902,7 +62056,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Numeric, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 202, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 203, _1); zephir_check_call_status(); RETURN_MM(); @@ -61947,7 +62101,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Password, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 203, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 204, _1); zephir_check_call_status(); RETURN_MM(); @@ -61994,7 +62148,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Radio, render) { ZVAL_BOOL(_2, 1); ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 204, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 205, _1); zephir_check_call_status(); RETURN_MM(); @@ -62045,7 +62199,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Select, __construct) { zephir_update_property_this(this_ptr, SL("_optionsValues"), options TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 205, name, attributes); + ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 206, name, attributes); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -62073,14 +62227,29 @@ static PHP_METHOD(Phalcon_Forms_Element_Select, getOptions) { static PHP_METHOD(Phalcon_Forms_Element_Select, addOption) { - zval *option; + HashTable *_1; + HashPosition _0; + zval *option, *key = NULL, *value = NULL, **_2; - zephir_fetch_params(0, 1, 0, &option); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &option); - zephir_update_property_array_append(this_ptr, SL("_optionsValues"), option TSRMLS_CC); - RETURN_THISW(); + if (Z_TYPE_P(option) == IS_ARRAY) { + zephir_is_iterable(option, &_1, &_0, 0, 0, "phalcon/forms/element/select.zep", 85); + for ( + ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS + ; zephir_hash_move_forward_ex(_1, &_0) + ) { + ZEPHIR_GET_HMKEY(key, _1, _0); + ZEPHIR_GET_HVALUE(value, _2); + zephir_update_property_array(this_ptr, SL("_optionsValues"), key, value TSRMLS_CC); + } + } else { + zephir_update_property_array_append(this_ptr, SL("_optionsValues"), option TSRMLS_CC); + } + RETURN_THIS(); } @@ -62101,7 +62270,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Select, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); _2 = zephir_fetch_nproperty_this(this_ptr, SL("_optionsValues"), PH_NOISY_CC); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, _1, _2); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 207, _1, _2); zephir_check_call_status(); RETURN_MM(); @@ -62146,7 +62315,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Submit, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 207, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 208, _1); zephir_check_call_status(); RETURN_MM(); @@ -62191,7 +62360,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Text, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 208, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 209, _1); zephir_check_call_status(); RETURN_MM(); @@ -62236,7 +62405,7 @@ static PHP_METHOD(Phalcon_Forms_Element_TextArea, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 209, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 210, _1); zephir_check_call_status(); RETURN_MM(); @@ -62284,6 +62453,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Http_Cookie) { zend_declare_property_bool(phalcon_http_cookie_ce, SL("_httpOnly"), 1, ZEND_ACC_PROTECTED TSRMLS_CC); + zend_class_implements(phalcon_http_cookie_ce TSRMLS_CC, 1, phalcon_http_cookieinterface_ce); zend_class_implements(phalcon_http_cookie_ce TSRMLS_CC, 1, phalcon_di_injectionawareinterface_ce); return SUCCESS; @@ -62516,16 +62686,20 @@ static PHP_METHOD(Phalcon_Http_Cookie, send) { zephir_check_temp_parameter(_1); zephir_check_call_status(); ZEPHIR_CPY_WRT(session, _0); - ZEPHIR_INIT_VAR(_2); - ZEPHIR_CONCAT_SV(_2, "_PHCOOKIE_", name); - ZEPHIR_CALL_METHOD(NULL, session, "set", NULL, 0, _2, definition); + ZEPHIR_CALL_METHOD(&_0, session, "isstarted", NULL, 0); zephir_check_call_status(); + if (zephir_is_true(_0)) { + ZEPHIR_INIT_VAR(_2); + ZEPHIR_CONCAT_SV(_2, "_PHCOOKIE_", name); + ZEPHIR_CALL_METHOD(NULL, session, "set", NULL, 0, _2, definition); + zephir_check_call_status(); + } } _3 = zephir_fetch_nproperty_this(this_ptr, SL("_useEncryption"), PH_NOISY_CC); if (zephir_is_true(_3)) { if (!(ZEPHIR_IS_EMPTY(value))) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "A dependency injection object is required to access the 'filter' service", "phalcon/http/cookie.zep", 258); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "A dependency injection object is required to access the 'filter' service", "phalcon/http/cookie.zep", 260); return; } ZEPHIR_INIT_NVAR(_1); @@ -62543,7 +62717,7 @@ static PHP_METHOD(Phalcon_Http_Cookie, send) { } else { ZEPHIR_CPY_WRT(encryptValue, value); } - ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, encryptValue, expire, path, domain, secure, httpOnly); + ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 217, name, encryptValue, expire, path, domain, secure, httpOnly); zephir_check_call_status(); RETURN_THIS(); @@ -62552,7 +62726,7 @@ static PHP_METHOD(Phalcon_Http_Cookie, send) { static PHP_METHOD(Phalcon_Http_Cookie, restore) { int ZEPHIR_LAST_CALL_STATUS; - zval *dependencyInjector, *expire, *domain, *path, *secure, *httpOnly, *session = NULL, *definition = NULL, *_0, *_1, *_2, *_3; + zval *dependencyInjector, *expire, *domain, *path, *secure, *httpOnly, *session = NULL, *definition = NULL, *_0, *_1, *_2 = NULL, *_3, *_4; ZEPHIR_MM_GROW(); @@ -62566,26 +62740,30 @@ static PHP_METHOD(Phalcon_Http_Cookie, restore) { ZEPHIR_CALL_METHOD(&session, dependencyInjector, "getshared", NULL, 0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_3); - ZEPHIR_CONCAT_SV(_3, "_PHCOOKIE_", _2); - ZEPHIR_CALL_METHOD(&definition, session, "get", NULL, 0, _3); + ZEPHIR_CALL_METHOD(&_2, session, "isstarted", NULL, 0); zephir_check_call_status(); - if (Z_TYPE_P(definition) == IS_ARRAY) { - if (zephir_array_isset_string_fetch(&expire, definition, SS("expire"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_expire"), expire TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&domain, definition, SS("domain"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_domain"), domain TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&path, definition, SS("path"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_path"), path TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&secure, definition, SS("secure"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_secure"), secure TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&httpOnly, definition, SS("httpOnly"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_httpOnly"), httpOnly TSRMLS_CC); + if (zephir_is_true(_2)) { + _3 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); + ZEPHIR_INIT_VAR(_4); + ZEPHIR_CONCAT_SV(_4, "_PHCOOKIE_", _3); + ZEPHIR_CALL_METHOD(&definition, session, "get", NULL, 0, _4); + zephir_check_call_status(); + if (Z_TYPE_P(definition) == IS_ARRAY) { + if (zephir_array_isset_string_fetch(&expire, definition, SS("expire"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_expire"), expire TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&domain, definition, SS("domain"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_domain"), domain TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&path, definition, SS("path"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_path"), path TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&secure, definition, SS("secure"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_secure"), secure TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&httpOnly, definition, SS("httpOnly"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_httpOnly"), httpOnly TSRMLS_CC); + } } } } @@ -62621,17 +62799,21 @@ static PHP_METHOD(Phalcon_Http_Cookie, delete) { zephir_check_temp_parameter(_2); zephir_check_call_status(); ZEPHIR_CPY_WRT(session, _1); - ZEPHIR_INIT_VAR(_3); - ZEPHIR_CONCAT_SV(_3, "_PHCOOKIE_", name); - ZEPHIR_CALL_METHOD(NULL, session, "remove", NULL, 0, _3); + ZEPHIR_CALL_METHOD(&_1, session, "isstarted", NULL, 0); zephir_check_call_status(); + if (zephir_is_true(_1)) { + ZEPHIR_INIT_VAR(_3); + ZEPHIR_CONCAT_SV(_3, "_PHCOOKIE_", name); + ZEPHIR_CALL_METHOD(NULL, session, "remove", NULL, 0, _3); + zephir_check_call_status(); + } } zephir_update_property_this(this_ptr, SL("_value"), ZEPHIR_GLOBAL(global_null) TSRMLS_CC); ZEPHIR_INIT_NVAR(_2); zephir_time(_2); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, (zephir_get_numberval(_2) - 691200)); - ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly); + ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 217, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -62895,6 +63077,60 @@ static PHP_METHOD(Phalcon_Http_Cookie, __toString) { +#ifdef HAVE_CONFIG_H +#endif + +#include + +#include + + + +ZEPHIR_INIT_CLASS(Phalcon_Http_CookieInterface) { + + ZEPHIR_REGISTER_INTERFACE(Phalcon\\Http, CookieInterface, phalcon, http_cookieinterface, phalcon_http_cookieinterface_method_entry); + + return SUCCESS; + +} + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setValue); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getValue); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, send); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, delete); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, useEncryption); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, isUsingEncryption); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setExpiration); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getExpiration); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setPath); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getName); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getPath); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setDomain); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getDomain); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setSecure); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getSecure); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setHttpOnly); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getHttpOnly); + + + + #ifdef HAVE_CONFIG_H #endif @@ -62988,7 +63224,7 @@ static PHP_METHOD(Phalcon_Http_Request, get) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -63039,7 +63275,7 @@ static PHP_METHOD(Phalcon_Http_Request, getPost) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -63097,12 +63333,12 @@ static PHP_METHOD(Phalcon_Http_Request, getPut) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getrawbody", NULL, 0); zephir_check_call_status(); Z_SET_ISREF_P(put); - ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 218, _0, put); + ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 219, _0, put); Z_UNSET_ISREF_P(put); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_putCache"), put TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -63153,7 +63389,7 @@ static PHP_METHOD(Phalcon_Http_Request, getQuery) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -63435,7 +63671,7 @@ static PHP_METHOD(Phalcon_Http_Request, getHeader) { ZVAL_STRING(&_0, "-", 0); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "_", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, header, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, header, &_0, &_1); zephir_check_call_status(); ZEPHIR_INIT_VAR(name); zephir_fast_strtoupper(name, _2); @@ -63590,7 +63826,7 @@ static PHP_METHOD(Phalcon_Http_Request, getServerAddress) { } ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "localhost", 0); - ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 219, &_0); + ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 220, &_0); zephir_check_call_status(); RETURN_MM(); @@ -63781,7 +64017,7 @@ static PHP_METHOD(Phalcon_Http_Request, isMethod) { } - ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); if (Z_TYPE_P(methods) == IS_STRING) { _0 = strict; @@ -63853,7 +64089,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPost) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "POST")); @@ -63866,7 +64102,7 @@ static PHP_METHOD(Phalcon_Http_Request, isGet) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "GET")); @@ -63879,7 +64115,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPut) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PUT")); @@ -63892,7 +64128,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPatch) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PATCH")); @@ -63905,7 +64141,7 @@ static PHP_METHOD(Phalcon_Http_Request, isHead) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "HEAD")); @@ -63918,7 +64154,7 @@ static PHP_METHOD(Phalcon_Http_Request, isDelete) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "DELETE")); @@ -63931,7 +64167,7 @@ static PHP_METHOD(Phalcon_Http_Request, isOptions) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "OPTIONS")); @@ -63979,7 +64215,7 @@ static PHP_METHOD(Phalcon_Http_Request, hasFiles) { } } if (Z_TYPE_P(error) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 222, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); numberFiles += zephir_get_numberval(_4); } @@ -64023,7 +64259,7 @@ static PHP_METHOD(Phalcon_Http_Request, hasFileHelper) { } } if (Z_TYPE_P(value) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 222, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); numberFiles += zephir_get_numberval(_4); } @@ -64072,7 +64308,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) { zephir_array_fetch_string(&_6, input, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC); zephir_array_fetch_string(&_7, input, SL("size"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC); zephir_array_fetch_string(&_8, input, SL("error"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 222, _4, _5, _6, _7, _8, prefix); + ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 223, _4, _5, _6, _7, _8, prefix); zephir_check_call_status(); zephir_is_iterable(smoothInput, &_11, &_10, 0, 0, "phalcon/http/request.zep", 714); for ( @@ -64106,7 +64342,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) { ZEPHIR_INIT_NVAR(_16); object_init_ex(_16, phalcon_http_request_file_ce); zephir_array_fetch_string(&_17, file, SL("key"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 711 TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, dataFile, _17); + ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 224, dataFile, _17); zephir_check_call_status(); zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 711); } @@ -64120,7 +64356,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) { if (_13) { ZEPHIR_INIT_NVAR(_16); object_init_ex(_16, phalcon_http_request_file_ce); - ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, input, prefix); + ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 224, input, prefix); zephir_check_call_status(); zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 716); } @@ -64193,7 +64429,7 @@ static PHP_METHOD(Phalcon_Http_Request, smoothFiles) { zephir_array_fetch(&_7, tmp_names, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC); zephir_array_fetch(&_8, sizes, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC); zephir_array_fetch(&_9, errors, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 222, _5, _6, _7, _8, _9, p); + ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 223, _5, _6, _7, _8, _9, p); zephir_check_call_status(); zephir_is_iterable(parentFiles, &_12, &_11, 0, 0, "phalcon/http/request.zep", 755); for ( @@ -64247,7 +64483,7 @@ static PHP_METHOD(Phalcon_Http_Request, getHeaders) { ZVAL_STRING(&_8, " ", 0); zephir_fast_str_replace(&_4, &_7, &_8, _6 TSRMLS_CC); zephir_fast_strtolower(_3, _4); - ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3); + ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 225, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_10); ZEPHIR_SINIT_NVAR(_11); @@ -64266,7 +64502,7 @@ static PHP_METHOD(Phalcon_Http_Request, getHeaders) { ZVAL_STRING(&_7, " ", 0); zephir_fast_str_replace(&_4, &_5, &_7, name TSRMLS_CC); zephir_fast_strtolower(_3, _4); - ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3); + ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 225, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_6); ZEPHIR_SINIT_NVAR(_8); @@ -64341,7 +64577,7 @@ static PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) { ZVAL_LONG(&_2, -1); ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 1); - ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 225, &_1, _0, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 226, &_1, _0, &_2, &_3); zephir_check_call_status(); zephir_is_iterable(_4, &_7, &_6, 0, 0, "phalcon/http/request.zep", 827); for ( @@ -64359,7 +64595,7 @@ static PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) { ZVAL_LONG(&_2, -1); ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 1); - ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 225, &_1, _9, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 226, &_1, _9, &_2, &_3); zephir_check_call_status(); zephir_is_iterable(_10, &_12, &_11, 0, 0, "phalcon/http/request.zep", 824); for ( @@ -64490,7 +64726,7 @@ static PHP_METHOD(Phalcon_Http_Request, getAcceptableContent) { ZVAL_STRING(_0, "HTTP_ACCEPT", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 227, _0, _1); zephir_check_temp_parameter(_0); zephir_check_temp_parameter(_1); zephir_check_call_status(); @@ -64509,7 +64745,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestAccept) { zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 228, _0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -64527,7 +64763,7 @@ static PHP_METHOD(Phalcon_Http_Request, getClientCharsets) { ZVAL_STRING(_0, "HTTP_ACCEPT_CHARSET", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 227, _0, _1); zephir_check_temp_parameter(_0); zephir_check_temp_parameter(_1); zephir_check_call_status(); @@ -64546,7 +64782,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestCharset) { zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 228, _0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -64564,7 +64800,7 @@ static PHP_METHOD(Phalcon_Http_Request, getLanguages) { ZVAL_STRING(_0, "HTTP_ACCEPT_LANGUAGE", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 227, _0, _1); zephir_check_temp_parameter(_0); zephir_check_temp_parameter(_1); zephir_check_call_status(); @@ -64583,7 +64819,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestLanguage) { zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 228, _0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -64637,7 +64873,7 @@ static PHP_METHOD(Phalcon_Http_Request, getDigestAuth) { ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 2); Z_SET_ISREF_P(matches); - ZEPHIR_CALL_FUNCTION(&_2, "preg_match_all", NULL, 27, _0, digest, matches, _1); + ZEPHIR_CALL_FUNCTION(&_2, "preg_match_all", NULL, 28, _0, digest, matches, _1); zephir_check_temp_parameter(_0); Z_UNSET_ISREF_P(matches); zephir_check_call_status(); @@ -64903,7 +65139,7 @@ static PHP_METHOD(Phalcon_Http_Response, setStatusCode) { if (_4) { ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "HTTP/", 0); - ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 234, key, &_5); + ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 235, key, &_5); zephir_check_call_status(); _4 = zephir_is_true(_6); } @@ -65330,7 +65566,7 @@ static PHP_METHOD(Phalcon_Http_Response, redirect) { if (_0) { ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "://", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 234, location, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 235, location, &_1); zephir_check_call_status(); _0 = zephir_is_true(_2); } @@ -65550,7 +65786,7 @@ static PHP_METHOD(Phalcon_Http_Response, send) { _1 = (zephir_fast_strlen_ev(file)) ? 1 : 0; } if (_1) { - ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 235, file); + ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 236, file); zephir_check_call_status(); } } @@ -65790,12 +66026,12 @@ static PHP_METHOD(Phalcon_Http_Request_File, __construct) { zephir_update_property_this(this_ptr, SL("_name"), name TSRMLS_CC); ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "PATHINFO_EXTENSION", 0); - ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 228, &_0); + ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 229, &_0); zephir_check_call_status(); if (zephir_is_true(_1)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_LONG(&_0, 4); - ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 69, name, &_0); + ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 71, name, &_0); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_extension"), _2 TSRMLS_CC); } @@ -65856,15 +66092,15 @@ static PHP_METHOD(Phalcon_Http_Request_File, getRealType) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 16); - ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 229, &_0); + ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 230, &_0); zephir_check_call_status(); if (Z_TYPE_P(finfo) != IS_RESOURCE) { RETURN_MM_STRING("", 1); } _1 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, finfo, _1); + ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 231, finfo, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, finfo); + ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 232, finfo); zephir_check_call_status(); RETURN_CCTOR(mime); @@ -65882,7 +66118,7 @@ static PHP_METHOD(Phalcon_Http_Request_File, isUploadedFile) { zephir_check_call_status(); _0 = Z_TYPE_P(tmp) == IS_STRING; if (_0) { - ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 232, tmp); + ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 233, tmp); zephir_check_call_status(); _0 = zephir_is_true(_1); } @@ -65913,7 +66149,7 @@ static PHP_METHOD(Phalcon_Http_Request_File, moveTo) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC); - ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 233, _0, destination); + ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 234, _0, destination); zephir_check_call_status(); RETURN_MM(); @@ -66028,12 +66264,14 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, isUsingEncryption) { static PHP_METHOD(Phalcon_Http_Response_Cookies, set) { + zval *_3; + zend_bool secure, httpOnly; int expire, ZEPHIR_LAST_CALL_STATUS; - zval *name_param = NULL, *value = NULL, *expire_param = NULL, *path_param = NULL, *secure = NULL, *domain_param = NULL, *httpOnly = NULL, *cookie = NULL, *encryption, *dependencyInjector, *response = NULL, *_0, *_1 = NULL, *_2; + zval *name_param = NULL, *value = NULL, *expire_param = NULL, *path_param = NULL, *secure_param = NULL, *domain_param = NULL, *httpOnly_param = NULL, *cookie = NULL, *encryption, *dependencyInjector, *response = NULL, *_0, *_1, *_2 = NULL, *_4 = NULL, *_5; zval *name = NULL, *path = NULL, *domain = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 6, &name_param, &value, &expire_param, &path_param, &secure, &domain_param, &httpOnly); + zephir_fetch_params(1, 1, 6, &name_param, &value, &expire_param, &path_param, &secure_param, &domain_param, &httpOnly_param); if (unlikely(Z_TYPE_P(name_param) != IS_STRING && Z_TYPE_P(name_param) != IS_NULL)) { zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'name' must be a string") TSRMLS_CC); @@ -66060,8 +66298,10 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, set) { } else { zephir_get_strval(path, path_param); } - if (!secure) { - secure = ZEPHIR_GLOBAL(global_null); + if (!secure_param) { + secure = 0; + } else { + secure = zephir_get_boolval(secure_param); } if (!domain_param) { ZEPHIR_INIT_VAR(domain); @@ -66079,8 +66319,10 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, set) { ZVAL_EMPTY_STRING(domain); } } - if (!httpOnly) { - httpOnly = ZEPHIR_GLOBAL(global_null); + if (!httpOnly_param) { + httpOnly = 0; + } else { + httpOnly = zephir_get_boolval(httpOnly_param); } @@ -66089,48 +66331,64 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, set) { ZEPHIR_OBS_VAR(cookie); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_cookies"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&cookie, _0, name, 0 TSRMLS_CC))) { - ZEPHIR_INIT_NVAR(cookie); - object_init_ex(cookie, phalcon_http_cookie_ce); - ZEPHIR_INIT_VAR(_1); - ZVAL_LONG(_1, expire); - ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name, value, _1, path, secure, domain, httpOnly); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); + ZEPHIR_INIT_VAR(_3); + zephir_create_array(_3, 7, 0 TSRMLS_CC); + zephir_array_fast_append(_3, name); + zephir_array_fast_append(_3, value); + ZEPHIR_INIT_VAR(_4); + ZVAL_LONG(_4, expire); + zephir_array_fast_append(_3, _4); + zephir_array_fast_append(_3, path); + ZEPHIR_INIT_NVAR(_4); + ZVAL_BOOL(_4, secure); + zephir_array_fast_append(_3, _4); + zephir_array_fast_append(_3, domain); + ZEPHIR_INIT_NVAR(_4); + ZVAL_BOOL(_4, httpOnly); + zephir_array_fast_append(_3, _4); + ZEPHIR_INIT_NVAR(_4); + ZVAL_STRING(_4, "Phalcon\\Http\\Cookie", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&_2, _1, "get", NULL, 0, _4, _3); + zephir_check_temp_parameter(_4); zephir_check_call_status(); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, _2); + ZEPHIR_CPY_WRT(cookie, _2); + _5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 0, _5); zephir_check_call_status(); if (zephir_is_true(encryption)) { - ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption); + ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 0, encryption); zephir_check_call_status(); } zephir_update_property_array(this_ptr, SL("_cookies"), name, cookie TSRMLS_CC); } else { - ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 239, value); + ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 0, value); zephir_check_call_status(); - ZEPHIR_INIT_NVAR(_1); - ZVAL_LONG(_1, expire); - ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 240, _1); + ZEPHIR_INIT_NVAR(_4); + ZVAL_LONG(_4, expire); + ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 0, _4); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 241, path); + ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 0, path); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 242, secure); + ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 0, (secure ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 243, domain); + ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 0, domain); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 244, httpOnly); + ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 0, (httpOnly ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_registered"), PH_NOISY_CC); - if (ZEPHIR_IS_FALSE_IDENTICAL(_2)) { + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_registered"), PH_NOISY_CC); + if (ZEPHIR_IS_FALSE_IDENTICAL(_1)) { ZEPHIR_OBS_VAR(dependencyInjector); zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_cookie_exception_ce, "A dependency injection object is required to access the 'response' service", "phalcon/http/response/cookies.zep", 138); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_cookie_exception_ce, "A dependency injection object is required to access the 'response' service", "phalcon/http/response/cookies.zep", 130); return; } - ZEPHIR_INIT_NVAR(_1); - ZVAL_STRING(_1, "response", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&response, dependencyInjector, "getshared", NULL, 0, _1); - zephir_check_temp_parameter(_1); + ZEPHIR_INIT_NVAR(_4); + ZVAL_STRING(_4, "response", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&response, dependencyInjector, "getshared", NULL, 0, _4); + zephir_check_temp_parameter(_4); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, response, "setcookies", NULL, 0, this_ptr); zephir_check_call_status(); @@ -66142,7 +66400,8 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, set) { static PHP_METHOD(Phalcon_Http_Response_Cookies, get) { int ZEPHIR_LAST_CALL_STATUS; - zval *name_param = NULL, *dependencyInjector, *encryption, *cookie = NULL, *_0; + zval *_3; + zval *name_param = NULL, *dependencyInjector, *encryption, *cookie = NULL, *_0, *_1, *_2 = NULL, *_4; zval *name = NULL; ZEPHIR_MM_GROW(); @@ -66166,19 +66425,25 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, get) { if (zephir_array_isset_fetch(&cookie, _0, name, 0 TSRMLS_CC)) { RETURN_CCTOR(cookie); } - ZEPHIR_INIT_NVAR(cookie); - object_init_ex(cookie, phalcon_http_cookie_ce); - ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); + ZEPHIR_INIT_VAR(_3); + zephir_create_array(_3, 1, 0 TSRMLS_CC); + zephir_array_fast_append(_3, name); + ZEPHIR_INIT_VAR(_4); + ZVAL_STRING(_4, "Phalcon\\Http\\Cookie", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&_2, _1, "get", NULL, 0, _4, _3); + zephir_check_temp_parameter(_4); zephir_check_call_status(); + ZEPHIR_CPY_WRT(cookie, _2); ZEPHIR_OBS_VAR(dependencyInjector); zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) { - ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 0, dependencyInjector); zephir_check_call_status(); ZEPHIR_OBS_VAR(encryption); zephir_read_property_this(&encryption, this_ptr, SL("_useEncryption"), PH_NOISY_CC); if (zephir_is_true(encryption)) { - ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption); + ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 0, encryption); zephir_check_call_status(); } } @@ -66262,11 +66527,11 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, send) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 54); + ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 55); zephir_check_call_status(); if (!(zephir_is_true(_0))) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_cookies"), PH_NOISY_CC); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/cookies.zep", 243); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/cookies.zep", 236); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -66381,41 +66646,53 @@ ZEPHIR_INIT_CLASS(Phalcon_Http_Response_Headers) { static PHP_METHOD(Phalcon_Http_Response_Headers, set) { - zval *name, *value; + zval *name_param = NULL, *value_param = NULL; + zval *name = NULL, *value = NULL; - zephir_fetch_params(0, 2, 0, &name, &value); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 2, 0, &name_param, &value_param); + zephir_get_strval(name, name_param); + zephir_get_strval(value, value_param); zephir_update_property_array(this_ptr, SL("_headers"), name, value TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } static PHP_METHOD(Phalcon_Http_Response_Headers, get) { - zval *name, *headers, *headerValue; + zval *name_param = NULL, *headers, *headerValue; + zval *name = NULL; - zephir_fetch_params(0, 1, 0, &name); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &name_param); + zephir_get_strval(name, name_param); headers = zephir_fetch_nproperty_this(this_ptr, SL("_headers"), PH_NOISY_CC); if (zephir_array_isset_fetch(&headerValue, headers, name, 1 TSRMLS_CC)) { - RETURN_CTORW(headerValue); + RETURN_CTOR(headerValue); } - RETURN_BOOL(0); + RETURN_MM_BOOL(0); } static PHP_METHOD(Phalcon_Http_Response_Headers, setRaw) { - zval *header; + zval *header_param = NULL; + zval *header = NULL; - zephir_fetch_params(0, 1, 0, &header); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &header_param); + zephir_get_strval(header, header_param); zephir_update_property_array(this_ptr, SL("_headers"), header, ZEPHIR_GLOBAL(global_null) TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -66448,11 +66725,11 @@ static PHP_METHOD(Phalcon_Http_Response_Headers, send) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 54); + ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 55); zephir_check_call_status(); if (!(zephir_is_true(_0))) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_headers"), PH_NOISY_CC); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/headers.zep", 98); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/headers.zep", 90); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -66462,10 +66739,10 @@ static PHP_METHOD(Phalcon_Http_Response_Headers, send) { if (!(ZEPHIR_IS_EMPTY(value))) { ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_VSV(_5, header, ": ", value); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, _5, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 237, _5, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, header, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 237, header, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); } } @@ -66519,14 +66796,14 @@ static PHP_METHOD(Phalcon_Http_Response_Headers, __set_state) { } ZEPHIR_OBS_VAR(dataHeaders); if (zephir_array_isset_string_fetch(&dataHeaders, data, SS("_headers"), 0 TSRMLS_CC)) { - zephir_is_iterable(dataHeaders, &_1, &_0, 0, 0, "phalcon/http/response/headers.zep", 130); + zephir_is_iterable(dataHeaders, &_1, &_0, 0, 0, "phalcon/http/response/headers.zep", 122); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HMKEY(key, _1, _0); ZEPHIR_GET_HVALUE(value, _2); - ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 246, key, value); + ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 238, key, value); zephir_check_call_status(); } } @@ -66815,7 +67092,7 @@ static PHP_METHOD(Phalcon_Image_Adapter, resize) { zephir_round(_8, &_9, NULL, NULL TSRMLS_CC); ZEPHIR_INIT_VAR(_10); ZVAL_LONG(_10, 1); - ZEPHIR_CALL_FUNCTION(&_11, "max", &_12, 66, _8, _10); + ZEPHIR_CALL_FUNCTION(&_11, "max", &_12, 68, _8, _10); zephir_check_call_status(); width = zephir_get_intval(_11); ZEPHIR_INIT_NVAR(_10); @@ -66824,7 +67101,7 @@ static PHP_METHOD(Phalcon_Image_Adapter, resize) { zephir_round(_10, &_13, NULL, NULL TSRMLS_CC); ZEPHIR_INIT_VAR(_14); ZVAL_LONG(_14, 1); - ZEPHIR_CALL_FUNCTION(&_15, "max", &_12, 66, _10, _14); + ZEPHIR_CALL_FUNCTION(&_15, "max", &_12, 68, _10, _14); zephir_check_call_status(); height = zephir_get_intval(_15); ZEPHIR_INIT_NVAR(_14); @@ -67150,23 +67427,19 @@ static PHP_METHOD(Phalcon_Image_Adapter, watermark) { static PHP_METHOD(Phalcon_Image_Adapter, text) { zend_bool _0; - int offsetX, offsetY, opacity, size, ZEPHIR_LAST_CALL_STATUS; - zval *text_param = NULL, *offsetX_param = NULL, *offsetY_param = NULL, *opacity_param = NULL, *color_param = NULL, *size_param = NULL, *fontfile_param = NULL, *colors = NULL, _1, _2, *_3, _4 = zval_used_for_init, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8, *_9, *_10, *_11, *_12; + int opacity, size, ZEPHIR_LAST_CALL_STATUS; + zval *text_param = NULL, *offsetX = NULL, *offsetY = NULL, *opacity_param = NULL, *color_param = NULL, *size_param = NULL, *fontfile_param = NULL, *colors = NULL, _1, _2, *_3, _4 = zval_used_for_init, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8, *_9, *_10; zval *text = NULL, *color = NULL, *fontfile = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 6, &text_param, &offsetX_param, &offsetY_param, &opacity_param, &color_param, &size_param, &fontfile_param); + zephir_fetch_params(1, 1, 6, &text_param, &offsetX, &offsetY, &opacity_param, &color_param, &size_param, &fontfile_param); zephir_get_strval(text, text_param); - if (!offsetX_param) { - offsetX = 0; - } else { - offsetX = zephir_get_intval(offsetX_param); + if (!offsetX) { + offsetX = ZEPHIR_GLOBAL(global_false); } - if (!offsetY_param) { - offsetY = 0; - } else { - offsetY = zephir_get_intval(offsetY_param); + if (!offsetY) { + offsetY = ZEPHIR_GLOBAL(global_false); } if (!opacity_param) { opacity = 100; @@ -67194,8 +67467,10 @@ static PHP_METHOD(Phalcon_Image_Adapter, text) { if (opacity < 0) { opacity = 0; - } else if (opacity > 100) { - opacity = 100; + } else { + if (opacity > 100) { + opacity = 100; + } } _0 = zephir_fast_strlen_ev(color) > 1; if (_0) { @@ -67219,7 +67494,7 @@ static PHP_METHOD(Phalcon_Image_Adapter, text) { ZVAL_STRING(_5, "/./", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "$0$0", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 28, _5, _6, color); + ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 29, _5, _6, color); zephir_check_temp_parameter(_5); zephir_check_temp_parameter(_6); zephir_check_call_status(); @@ -67227,24 +67502,20 @@ static PHP_METHOD(Phalcon_Image_Adapter, text) { } ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 2); - ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 67, color, &_4); + ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 69, color, &_4); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_STRING(&_4, "hexdec", 0); - ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 68, &_4, _7); + ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 70, &_4, _7); zephir_check_call_status(); - zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 333 TSRMLS_CC); - zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 333 TSRMLS_CC); - zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 333 TSRMLS_CC); + zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 335 TSRMLS_CC); + zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 335 TSRMLS_CC); + zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 335 TSRMLS_CC); ZEPHIR_INIT_NVAR(_5); - ZVAL_LONG(_5, offsetX); + ZVAL_LONG(_5, opacity); ZEPHIR_INIT_NVAR(_6); - ZVAL_LONG(_6, offsetY); - ZEPHIR_INIT_VAR(_11); - ZVAL_LONG(_11, opacity); - ZEPHIR_INIT_VAR(_12); - ZVAL_LONG(_12, size); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_text", NULL, 0, text, _5, _6, _11, _8, _9, _10, _12, fontfile); + ZVAL_LONG(_6, size); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_text", NULL, 0, text, offsetX, offsetY, _5, _8, _9, _10, _6, fontfile); zephir_check_call_status(); RETURN_THIS(); @@ -67306,7 +67577,7 @@ static PHP_METHOD(Phalcon_Image_Adapter, background) { ZVAL_STRING(_5, "/./", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "$0$0", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 28, _5, _6, color); + ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 29, _5, _6, color); zephir_check_temp_parameter(_5); zephir_check_temp_parameter(_6); zephir_check_call_status(); @@ -67314,15 +67585,15 @@ static PHP_METHOD(Phalcon_Image_Adapter, background) { } ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 2); - ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 67, color, &_4); + ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 69, color, &_4); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_STRING(&_4, "hexdec", 0); - ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 68, &_4, _7); + ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 70, &_4, _7); zephir_check_call_status(); - zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 364 TSRMLS_CC); - zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 364 TSRMLS_CC); - zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 364 TSRMLS_CC); + zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 366 TSRMLS_CC); + zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 366 TSRMLS_CC); + zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 366 TSRMLS_CC); ZEPHIR_INIT_NVAR(_5); ZVAL_LONG(_5, opacity); ZEPHIR_CALL_METHOD(NULL, this_ptr, "_background", NULL, 0, _8, _9, _10, _5); @@ -67444,7 +67715,7 @@ static PHP_METHOD(Phalcon_Image_Adapter, render) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 4); - ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 69, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 71, _0, &_1); zephir_check_call_status(); zephir_get_strval(_3, _2); ZEPHIR_CPY_WRT(ext, _3); @@ -67580,13 +67851,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, check) { ZVAL_NULL(version); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "GD_VERSION", 0); - ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 228, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 229, &_1); zephir_check_call_status(); if (zephir_is_true(_2)) { ZEPHIR_INIT_NVAR(version); ZEPHIR_GET_CONSTANT(version, "GD_VERSION"); } else { - ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 247); + ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 239); zephir_check_call_status(); ZEPHIR_INIT_VAR(matches); ZVAL_NULL(matches); @@ -67604,7 +67875,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, check) { ZVAL_STRING(&_5, "2.0.1", 0); ZEPHIR_SINIT_VAR(_6); ZVAL_STRING(&_6, ">=", 0); - ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 248, version, &_5, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 240, version, &_5, &_6); zephir_check_call_status(); if (!(zephir_is_true(_7))) { ZEPHIR_INIT_NVAR(_3); @@ -67666,11 +67937,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); if ((zephir_file_exists(_1 TSRMLS_CC) == SUCCESS)) { _2 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_3, "realpath", NULL, 60, _2); + ZEPHIR_CALL_FUNCTION(&_3, "realpath", NULL, 62, _2); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_realpath"), _3 TSRMLS_CC); _4 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 249, _4); + ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 241, _4); zephir_check_call_status(); if (zephir_is_true(imageinfo)) { zephir_array_fetch_long(&_5, imageinfo, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 77 TSRMLS_CC); @@ -67686,35 +67957,35 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { do { if (ZEPHIR_IS_LONG(_9, 1)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 250, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 242, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 2)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 251, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 243, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 3)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 252, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 244, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 15)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 253, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 245, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 16)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 254, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 246, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; @@ -67739,7 +68010,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { } while(0); _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _10, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 247, _10, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); } else { _16 = !width; @@ -67762,14 +68033,14 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { ZVAL_LONG(&_17, width); ZEPHIR_SINIT_VAR(_18); ZVAL_LONG(&_18, height); - ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 256, &_17, &_18); + ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 248, &_17, &_18); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _3 TSRMLS_CC); _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _4, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, _4, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _9, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 247, _9, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); zephir_update_property_this(this_ptr, SL("_realpath"), _10 TSRMLS_CC); @@ -67808,7 +68079,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION"); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "5.5.0", 0); - ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 240, _0, &_1); zephir_check_call_status(); if (ZEPHIR_LT_LONG(_2, 0)) { ZEPHIR_OBS_VAR(pre_width); @@ -67856,11 +68127,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZVAL_LONG(&_14, 0); ZEPHIR_SINIT_VAR(_15); ZVAL_LONG(&_15, 0); - ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 258, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11); + ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 250, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11); zephir_check_call_status(); if (zephir_is_true(_16)) { _17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _17); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 251, _17); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); } @@ -67884,17 +68155,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZVAL_LONG(&_15, width); ZEPHIR_SINIT_VAR(_21); ZVAL_LONG(&_21, height); - ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 260, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height); + ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 252, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height); zephir_check_call_status(); if (zephir_is_true(_16)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _10); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 251, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 261, image); + ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _22 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 262, image); + ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _24 TSRMLS_CC); } @@ -67904,16 +68175,16 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZVAL_LONG(&_6, width); ZEPHIR_SINIT_NVAR(_12); ZVAL_LONG(&_12, height); - ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 263, _3, &_6, &_12); + ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 255, _3, &_6, &_12); zephir_check_call_status(); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _5); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 251, _5); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 261, image); + ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 262, image); + ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _22 TSRMLS_CC); } @@ -67940,7 +68211,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) { ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION"); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "5.5.0", 0); - ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 240, _0, &_1); zephir_check_call_status(); if (ZEPHIR_LT_LONG(_2, 0)) { ZEPHIR_INIT_VAR(_3); @@ -67966,17 +68237,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) { ZVAL_LONG(&_11, width); ZEPHIR_SINIT_VAR(_12); ZVAL_LONG(&_12, height); - ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 260, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12); + ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 252, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12); zephir_check_call_status(); if (zephir_is_true(_13)) { _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 251, _14); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 261, image); + ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 262, image); + ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _18 TSRMLS_CC); } @@ -67996,16 +68267,16 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) { ZVAL_LONG(_3, height); zephir_array_update_string(&rect, SL("height"), &_3, PH_COPY | PH_SEPARATE); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 264, _5, rect); + ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 256, _5, rect); zephir_check_call_status(); _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 251, _14); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 261, image); + ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _13 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 262, image); + ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _16 TSRMLS_CC); } @@ -68033,20 +68304,20 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) { ZVAL_LONG(&_3, 0); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, 127); - ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 265, _0, &_1, &_2, &_3, &_4); + ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 257, _0, &_1, &_2, &_3, &_4); zephir_check_call_status(); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (360 - degrees)); ZEPHIR_SINIT_NVAR(_2); ZVAL_LONG(&_2, 1); - ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 266, _5, &_1, transparent, &_2); + ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 258, _5, &_1, transparent, &_2); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 247, image, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 261, image); + ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 253, image); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 262, image); + ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 254, image); zephir_check_call_status(); _6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); @@ -68059,11 +68330,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) { ZVAL_LONG(&_4, 0); ZEPHIR_SINIT_VAR(_7); ZVAL_LONG(&_7, 100); - ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 267, _6, image, &_1, &_2, &_3, &_4, width, height, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 259, _6, image, &_1, &_2, &_3, &_4, width, height, &_7); zephir_check_call_status(); if (zephir_is_true(_8)) { _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _9); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _9); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_width"), width TSRMLS_CC); @@ -68089,7 +68360,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION"); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "5.5.0", 0); - ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 240, _0, &_1); zephir_check_call_status(); if (ZEPHIR_LT_LONG(_2, 0)) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); @@ -68117,7 +68388,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { ZVAL_LONG(&_11, 0); ZEPHIR_SINIT_NVAR(_12); ZVAL_LONG(&_12, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, &_12, _8); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, image, _6, &_1, &_9, &_10, &_11, &_12, _8); zephir_check_call_status(); } } else { @@ -68141,18 +68412,18 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { ZVAL_LONG(&_11, ((zephir_get_numberval(_7) - x) - 1)); ZEPHIR_SINIT_NVAR(_12); ZVAL_LONG(&_12, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, _8, &_12); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, image, _6, &_1, &_9, &_10, &_11, _8, &_12); zephir_check_call_status(); } } _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _5); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _5); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 261, image); + ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _14 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 262, image); + ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _15 TSRMLS_CC); } else { @@ -68160,13 +68431,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _3, &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 261, _3, &_1); zephir_check_call_status(); } else { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 2); - ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _4, &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 261, _4, &_1); zephir_check_call_status(); } } @@ -68189,7 +68460,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) { ZEPHIR_INIT_VAR(_0); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, (-18 + ((amount * 0.08)))); - ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 193, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 2); @@ -68238,15 +68509,15 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) { ZVAL_LONG(&_6, (amount - 8)); ZEPHIR_SINIT_VAR(_7); ZVAL_LONG(&_7, 0); - ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 270, _5, matrix, &_6, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 262, _5, matrix, &_6, &_7); zephir_check_call_status(); if (zephir_is_true(_8)) { _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 261, _9); + ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 253, _9); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _10 TSRMLS_CC); _11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 262, _11); + ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 254, _11); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _12 TSRMLS_CC); } @@ -68272,7 +68543,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZEPHIR_INIT_VAR(_0); ZEPHIR_SINIT_VAR(_1); ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127))); - ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 193, &_1); zephir_check_call_status(); zephir_round(_0, _2, NULL, NULL TSRMLS_CC); opacity = zephir_get_intval(_0); @@ -68298,7 +68569,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_11, 0); ZEPHIR_SINIT_VAR(_12); ZVAL_LONG(&_12, 0); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, _7, &_1, &_10, &_11, &_12, _8, _9); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, reflection, _7, &_1, &_10, &_11, &_12, _8, _9); zephir_check_call_status(); offset = 0; while (1) { @@ -68339,7 +68610,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_21, src_y); ZEPHIR_SINIT_NVAR(_22); ZVAL_LONG(&_22, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, line, _18, &_11, &_12, &_20, &_21, _19, &_22); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, line, _18, &_11, &_12, &_20, &_21, _19, &_22); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_11); ZVAL_LONG(&_11, 4); @@ -68351,7 +68622,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_21, 0); ZEPHIR_SINIT_NVAR(_22); ZVAL_LONG(&_22, dst_opacity); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 271, line, &_11, &_12, &_20, &_21, &_22); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 263, line, &_11, &_12, &_20, &_21, &_22); zephir_check_call_status(); _24 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_11); @@ -68364,18 +68635,18 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_21, 0); ZEPHIR_SINIT_NVAR(_22); ZVAL_LONG(&_22, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, line, &_11, &_12, &_20, &_21, _24, &_22); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, reflection, line, &_11, &_12, &_20, &_21, _24, &_22); zephir_check_call_status(); offset++; } _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _14); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), reflection TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 261, reflection); + ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 253, reflection); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _25 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 262, reflection); + ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 254, reflection); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _26 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -68397,21 +68668,21 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZEPHIR_CALL_METHOD(&_0, watermark, "render", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 272, _0); + ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 264, _0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, overlay, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 247, overlay, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, overlay); + ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 253, overlay); zephir_check_call_status(); width = zephir_get_intval(_1); - ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, overlay); + ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 254, overlay); zephir_check_call_status(); height = zephir_get_intval(_2); if (opacity < 100) { ZEPHIR_INIT_VAR(_3); ZEPHIR_SINIT_VAR(_4); ZVAL_DOUBLE(&_4, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127))); - ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 192, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 193, &_4); zephir_check_call_status(); zephir_round(_3, _5, NULL, NULL TSRMLS_CC); opacity = zephir_get_intval(_3); @@ -68423,11 +68694,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZVAL_LONG(&_7, 127); ZEPHIR_SINIT_VAR(_8); ZVAL_LONG(&_8, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, overlay, &_4, &_6, &_7, &_8); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 257, overlay, &_4, &_6, &_7, &_8); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 3); - ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 273, overlay, &_4); + ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 265, overlay, &_4); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 0); @@ -68437,11 +68708,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZVAL_LONG(&_7, width); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, height); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 274, overlay, &_4, &_6, &_7, &_8, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 266, overlay, &_4, &_6, &_7, &_8, color); zephir_check_call_status(); } _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _9, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, _9, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_4); @@ -68456,10 +68727,10 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZVAL_LONG(&_11, width); ZEPHIR_SINIT_VAR(_12); ZVAL_LONG(&_12, height); - ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 268, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12); + ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 260, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12); zephir_check_call_status(); if (zephir_is_true(_5)) { - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, overlay); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, overlay); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -68491,7 +68762,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZEPHIR_INIT_VAR(_0); ZEPHIR_SINIT_VAR(_1); ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127))); - ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 193, &_1); zephir_check_call_status(); zephir_round(_0, _2, NULL, NULL TSRMLS_CC); opacity = zephir_get_intval(_0); @@ -68500,7 +68771,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_1, size); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, 0); - ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 275, &_1, &_4, fontfile, text); + ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 267, &_1, &_4, fontfile, text); zephir_check_call_status(); if (zephir_array_isset_long(space, 0)) { ZEPHIR_OBS_VAR(_5); @@ -68534,12 +68805,12 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { } ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (s4 - s0)); - ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 193, &_1); zephir_check_call_status(); width = (zephir_get_numberval(_12) + 10); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (s5 - s1)); - ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 193, &_1); zephir_check_call_status(); height = (zephir_get_numberval(_13) + 10); if (offsetX < 0) { @@ -68559,7 +68830,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_15, b); ZEPHIR_SINIT_VAR(_16); ZVAL_LONG(&_16, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 257, _14, &_1, &_4, &_15, &_16); zephir_check_call_status(); angle = 0; _18 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -68571,17 +68842,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_15, offsetX); ZEPHIR_SINIT_NVAR(_16); ZVAL_LONG(&_16, offsetY); - ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 276, _18, &_1, &_4, &_15, &_16, color, fontfile, text); + ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 268, _18, &_1, &_4, &_15, &_16, color, fontfile, text); zephir_check_call_status(); } else { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, size); - ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 277, &_1); + ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 269, &_1); zephir_check_call_status(); width = (zephir_get_intval(_12) * zephir_fast_strlen_ev(text)); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, size); - ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 278, &_1); + ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 270, &_1); zephir_check_call_status(); height = zephir_get_intval(_13); if (offsetX < 0) { @@ -68601,7 +68872,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_15, b); ZEPHIR_SINIT_NVAR(_16); ZVAL_LONG(&_16, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 257, _14, &_1, &_4, &_15, &_16); zephir_check_call_status(); _19 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); @@ -68610,7 +68881,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_4, offsetX); ZEPHIR_SINIT_NVAR(_15); ZVAL_LONG(&_15, offsetY); - ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 279, _19, &_1, &_4, &_15, text, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 271, _19, &_1, &_4, &_15, text, color); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -68631,22 +68902,22 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZEPHIR_CALL_METHOD(&_0, mask, "render", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 272, _0); + ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 264, _0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, maskImage); + ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 253, maskImage); zephir_check_call_status(); mask_width = zephir_get_intval(_1); - ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, maskImage); + ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 254, maskImage); zephir_check_call_status(); mask_height = zephir_get_intval(_2); alpha = 127; - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, maskImage, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 247, maskImage, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _4 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); ZEPHIR_CALL_METHOD(&newimage, this_ptr, "_create", NULL, 0, _4, _5); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, newimage, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 247, newimage, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_6); ZVAL_LONG(&_6, 0); @@ -68656,13 +68927,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_8, 0); ZEPHIR_SINIT_VAR(_9); ZVAL_LONG(&_9, alpha); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, &_6, &_7, &_8, &_9); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 257, newimage, &_6, &_7, &_8, &_9); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_6); ZVAL_LONG(&_6, 0); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, 0); - ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 280, newimage, &_6, &_7, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 272, newimage, &_6, &_7, color); zephir_check_call_status(); _11 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _12 = !ZEPHIR_IS_LONG(_11, mask_width); @@ -68673,7 +68944,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { if (_12) { _14 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _15 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 256, _14, _15); + ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 248, _14, _15); zephir_check_call_status(); _16 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _17 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); @@ -68689,9 +68960,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_18, mask_width); ZEPHIR_SINIT_VAR(_19); ZVAL_LONG(&_19, mask_height); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 260, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 252, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 251, maskImage); zephir_check_call_status(); ZEPHIR_CPY_WRT(maskImage, tempImage); } @@ -68711,9 +68982,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_6, x); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, y); - ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, maskImage, &_6, &_7); + ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 273, maskImage, &_6, &_7); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, maskImage, index); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 274, maskImage, index); zephir_check_call_status(); if (zephir_array_isset_string(color, SS("red"))) { zephir_array_fetch_string(&_23, color, SL("red"), PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 431 TSRMLS_CC); @@ -68726,10 +68997,10 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_7, x); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, y); - ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, _16, &_7, &_8); + ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 273, _16, &_7, &_8); zephir_check_call_status(); _17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, _17, index); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 274, _17, index); zephir_check_call_status(); ZEPHIR_OBS_NVAR(r); zephir_array_fetch_string(&r, color, SL("red"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC); @@ -68739,22 +69010,22 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { zephir_array_fetch_string(&b, color, SL("blue"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, alpha); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, r, g, b, &_7); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 257, newimage, r, g, b, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, x); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, y); - ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 283, newimage, &_7, &_8, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 275, newimage, &_7, &_8, color); zephir_check_call_status(); y++; } x++; } _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 251, _14); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 251, maskImage); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), newimage TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -68788,9 +69059,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) { ZVAL_LONG(&_4, b); ZEPHIR_SINIT_VAR(_5); ZVAL_LONG(&_5, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, background, &_2, &_3, &_4, &_5); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 257, background, &_2, &_3, &_4, &_5); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, background, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, background, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); @@ -68803,11 +69074,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) { ZVAL_LONG(&_4, 0); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, 0); - ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 268, background, _6, &_2, &_3, &_4, &_5, _7, _8); + ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 260, background, _6, &_2, &_3, &_4, &_5, _7, _8); zephir_check_call_status(); if (zephir_is_true(_9)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _10); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), background TSRMLS_CC); } @@ -68835,7 +69106,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _blur) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 7); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 271, _0, &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 263, _0, &_1); zephir_check_call_status(); i++; } @@ -68874,7 +69145,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) { ZVAL_LONG(&_3, x1); ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, y1); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 281, _2, &_3, &_4); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 273, _2, &_3, &_4); zephir_check_call_status(); x2 = (x + amount); y2 = (y + amount); @@ -68887,7 +69158,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) { ZVAL_LONG(&_7, x2); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, y2); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 274, _6, &_3, &_4, &_7, &_8, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 266, _6, &_3, &_4, &_7, &_8, color); zephir_check_call_status(); y += amount; } @@ -68900,9 +69171,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) { static PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) { zend_bool _8; - zephir_fcall_cache_entry *_3 = NULL, *_6 = NULL; + zephir_fcall_cache_entry *_4 = NULL, *_6 = NULL; int quality, ZEPHIR_LAST_CALL_STATUS; - zval *file_param = NULL, *quality_param = NULL, *ext, _0 = zval_used_for_init, *_1 = NULL, *_2 = NULL, *_4, *_5 = NULL, *_7, *_9 = NULL, *_10 = NULL, *_11, *_12; + zval *file_param = NULL, *quality_param = NULL, *ext = NULL, _0 = zval_used_for_init, *_1, *_2 = NULL, *_3 = NULL, *_5 = NULL, *_7, *_9 = NULL, *_10 = NULL, *_11; zval *file = NULL; ZEPHIR_MM_GROW(); @@ -68914,112 +69185,118 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 4); - ZEPHIR_CALL_FUNCTION(&_1, "pathinfo", NULL, 69, file, &_0); + ZEPHIR_CALL_FUNCTION(&ext, "pathinfo", NULL, 71, file, &_0); zephir_check_call_status(); - ZEPHIR_INIT_VAR(ext); - zephir_fast_strtolower(ext, _1); + if (!(zephir_is_true(ext))) { + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&ext, "image_type_to_extension", NULL, 276, _1, ZEPHIR_GLOBAL(global_false)); + zephir_check_call_status(); + } + ZEPHIR_INIT_VAR(_2); + zephir_fast_strtolower(_2, ext); + ZEPHIR_CPY_WRT(ext, _2); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_3, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); - if (ZEPHIR_IS_LONG(_2, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 1); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 285, _4); + if (ZEPHIR_IS_LONG(_3, 0)) { + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 1); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _5 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 279, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); _8 = ZEPHIR_IS_LONG(_5, 0); if (!(_8)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); _8 = ZEPHIR_IS_LONG(_9, 0); } if (_8) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 2); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 2); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_LONG(&_0, quality); - ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _7, file, &_0); + ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 280, _7, file, &_0); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "png", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_5, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 3); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 3); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 281, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "wbmp", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_5, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 15); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 15); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 282, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "xbm", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_5, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 16); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 16); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 283, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } + ZEPHIR_INIT_NVAR(_2); + object_init_ex(_2, phalcon_image_exception_ce); ZEPHIR_INIT_VAR(_11); - object_init_ex(_11, phalcon_image_exception_ce); - ZEPHIR_INIT_VAR(_12); - ZEPHIR_CONCAT_SVS(_12, "Installed GD does not support '", ext, "' images"); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", NULL, 9, _12); + ZEPHIR_CONCAT_SVS(_11, "Installed GD does not support '", ext, "' images"); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _11); zephir_check_call_status(); - zephir_throw_exception_debug(_11, "phalcon/image/adapter/gd.zep", 537 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/image/adapter/gd.zep", 544 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -69043,29 +69320,29 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) { ZEPHIR_INIT_VAR(_0); zephir_fast_strtolower(_0, ext); zephir_get_strval(ext, _0); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_2, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _4); + ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 279, _4); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG(_6, 0); if (!(_7)) { ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG(_8, 0); } @@ -69073,45 +69350,45 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, quality); - ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _4, ZEPHIR_GLOBAL(global_null), &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 280, _4, ZEPHIR_GLOBAL(global_null), &_1); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "png", 0); - ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_9, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _4); + ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 281, _4); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "wbmp", 0); - ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_10, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _4); + ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 282, _4); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "xbm", 0); - ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_11, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _4, ZEPHIR_GLOBAL(global_null)); + ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 283, _4, ZEPHIR_GLOBAL(global_null)); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } @@ -69121,7 +69398,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) { ZEPHIR_CONCAT_SVS(_13, "Installed GD does not support '", ext, "' images"); ZEPHIR_CALL_METHOD(NULL, _12, "__construct", NULL, 9, _13); zephir_check_call_status(); - zephir_throw_exception_debug(_12, "phalcon/image/adapter/gd.zep", 565 TSRMLS_CC); + zephir_throw_exception_debug(_12, "phalcon/image/adapter/gd.zep", 572 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -69143,11 +69420,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _create) { ZVAL_LONG(&_0, width); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, height); - ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 256, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 248, &_0, &_1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, image, ZEPHIR_GLOBAL(global_false)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, image, ZEPHIR_GLOBAL(global_false)); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 247, image, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); RETURN_CCTOR(image); @@ -69163,7 +69440,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __destruct) { ZEPHIR_OBS_VAR(image); zephir_read_property_this(&image, this_ptr, SL("_image"), PH_NOISY_CC); if (Z_TYPE_P(image) == IS_RESOURCE) { - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, image); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, image); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -69216,12 +69493,12 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, check) { } ZEPHIR_SINIT_VAR(_2); ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0); - ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 228, &_2); + ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 229, &_2); zephir_check_call_status(); if (zephir_is_true(_3)) { ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0); - ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_2); + ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 191, &_2); zephir_check_call_status(); zephir_update_static_property_ce(phalcon_image_adapter_imagick_ce, SL("_version"), &_4 TSRMLS_CC); } @@ -69280,7 +69557,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, __construct) { _2 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); if ((zephir_file_exists(_2 TSRMLS_CC) == SUCCESS)) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_4, "realpath", NULL, 60, _3); + ZEPHIR_CALL_FUNCTION(&_4, "realpath", NULL, 62, _3); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_realpath"), _4 TSRMLS_CC); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -69306,7 +69583,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, __construct) { _12 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_13); ZVAL_STRING(&_13, "Imagick::ALPHACHANNEL_SET", 0); - ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 190, &_13); + ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 191, &_13); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _12, "setimagealphachannel", NULL, 0, _14); zephir_check_call_status(); @@ -69778,7 +70055,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { while (1) { ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::COMPOSITE_DSTOUT", 0); - ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, 0); @@ -69792,11 +70069,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { } ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::EVALUATE_MULTIPLY", 0); - ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::CHANNEL_ALPHA", 0); - ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, opacity); @@ -69839,7 +70116,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::ALPHACHANNEL_SET", 0); - ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, image, "setimagealphachannel", &_25, 0, _9); zephir_check_call_status(); @@ -69856,7 +70133,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { _30 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::COMPOSITE_SRC", 0); - ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, 0); @@ -69886,7 +70163,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { while (1) { ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::COMPOSITE_OVER", 0); - ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 191, &_14); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); ZEPHIR_INIT_NVAR(_3); @@ -69968,7 +70245,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _watermark) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_4); ZVAL_STRING(&_4, "Imagick::COMPOSITE_OVER", 0); - ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 190, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 191, &_4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_1); ZVAL_LONG(_1, offsetX); @@ -69997,17 +70274,18 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _watermark) { static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) { - zephir_fcall_cache_entry *_6 = NULL, *_8 = NULL; - int offsetX, offsetY, opacity, r, g, b, size, ZEPHIR_LAST_CALL_STATUS; - zval *text_param = NULL, *offsetX_param = NULL, *offsetY_param = NULL, *opacity_param = NULL, *r_param = NULL, *g_param = NULL, *b_param = NULL, *size_param = NULL, *fontfile_param = NULL, *draw, *color = NULL, *pixel, *gravity = NULL, _0 = zval_used_for_init, _1, _2, _3, *_4 = NULL, *_5 = NULL, *_7 = NULL, *_9, *_10, *_11 = NULL, *_12 = NULL, *_13; + zephir_fcall_cache_entry *_7 = NULL; + zend_bool _6; + int opacity, r, g, b, size, x, y, ZEPHIR_LAST_CALL_STATUS; + zval *text_param = NULL, *offsetX = NULL, *offsetY = NULL, *opacity_param = NULL, *r_param = NULL, *g_param = NULL, *b_param = NULL, *size_param = NULL, *fontfile_param = NULL, *draw, *color = NULL, *gravity = NULL, _0 = zval_used_for_init, _1, _2, _3, *_4, *_5 = NULL, *_8, *_9, *_10, *_11 = NULL; zval *text = NULL, *fontfile = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 9, 0, &text_param, &offsetX_param, &offsetY_param, &opacity_param, &r_param, &g_param, &b_param, &size_param, &fontfile_param); + zephir_fetch_params(1, 9, 0, &text_param, &offsetX, &offsetY, &opacity_param, &r_param, &g_param, &b_param, &size_param, &fontfile_param); zephir_get_strval(text, text_param); - offsetX = zephir_get_intval(offsetX_param); - offsetY = zephir_get_intval(offsetY_param); + ZEPHIR_SEPARATE_PARAM(offsetX); + ZEPHIR_SEPARATE_PARAM(offsetY); opacity = zephir_get_intval(opacity_param); r = zephir_get_intval(r_param); g = zephir_get_intval(g_param); @@ -70031,76 +70309,210 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) { ZVAL_LONG(&_2, g); ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, b); - ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 188, &_0, &_1, &_2, &_3); zephir_check_call_status(); - ZEPHIR_INIT_VAR(pixel); - object_init_ex(pixel, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC)); - if (zephir_has_constructor(pixel TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(NULL, pixel, "__construct", NULL, 0, color); + ZEPHIR_INIT_VAR(_4); + object_init_ex(_4, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC)); + if (zephir_has_constructor(_4 TSRMLS_CC)) { + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 0, color); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, draw, "setfillcolor", NULL, 0, pixel); + ZEPHIR_CALL_METHOD(NULL, draw, "setfillcolor", NULL, 0, _4); zephir_check_call_status(); if (fontfile && Z_STRLEN_P(fontfile)) { ZEPHIR_CALL_METHOD(NULL, draw, "setfont", NULL, 0, fontfile); zephir_check_call_status(); } if (size) { - ZEPHIR_INIT_VAR(_4); - ZVAL_LONG(_4, size); - ZEPHIR_CALL_METHOD(NULL, draw, "setfontsize", NULL, 0, _4); + ZEPHIR_INIT_VAR(_5); + ZVAL_LONG(_5, size); + ZEPHIR_CALL_METHOD(NULL, draw, "setfontsize", NULL, 0, _5); zephir_check_call_status(); } if (opacity) { - ZEPHIR_INIT_NVAR(_4); - ZVAL_LONG(_4, opacity); - ZEPHIR_CALL_METHOD(NULL, draw, "setfillopacity", NULL, 0, _4); - zephir_check_call_status(); - } - if (offsetX < 0) { - ZEPHIR_SINIT_NVAR(_0); - ZVAL_LONG(&_0, offsetX); - ZEPHIR_CALL_FUNCTION(&_5, "abs", &_6, 192, &_0); - zephir_check_call_status(); - offsetX = zephir_get_numberval(_5); - if (offsetY < 0) { - ZEPHIR_SINIT_NVAR(_0); - ZVAL_LONG(&_0, offsetY); - ZEPHIR_CALL_FUNCTION(&_7, "abs", &_6, 192, &_0); - zephir_check_call_status(); - offsetY = zephir_get_numberval(_7); - ZEPHIR_SINIT_NVAR(_0); - ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); - ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0); - zephir_check_call_status(); + ZEPHIR_INIT_NVAR(_5); + ZVAL_LONG(_5, opacity); + ZEPHIR_CALL_METHOD(NULL, draw, "setfillopacity", NULL, 0, _5); + zephir_check_call_status(); + } + ZEPHIR_INIT_VAR(gravity); + ZVAL_NULL(gravity); + if (Z_TYPE_P(offsetX) == IS_BOOL) { + if (Z_TYPE_P(offsetY) == IS_BOOL) { + ZEPHIR_INIT_NVAR(offsetX); + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, 0); + _6 = zephir_is_true(offsetX); + if (_6) { + _6 = zephir_is_true(offsetY); + } + if (_6) { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + if (zephir_is_true(offsetX)) { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_EAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + if (zephir_is_true(offsetY)) { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_CENTER", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } } else { - ZEPHIR_SINIT_NVAR(_0); - ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0); - ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0); - zephir_check_call_status(); + if (Z_TYPE_P(offsetY) == IS_LONG) { + y = zephir_get_intval(offsetY); + if (zephir_is_true(offsetX)) { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } else { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } + } + } else { + if (Z_TYPE_P(offsetX) == IS_LONG) { + x = zephir_get_intval(offsetX); + if (zephir_is_true(offsetX)) { + if (Z_TYPE_P(offsetY) == IS_BOOL) { + if (zephir_is_true(offsetY)) { + ZEPHIR_INIT_NVAR(offsetY); + if (x < 0) { + ZEPHIR_INIT_NVAR(offsetX); + ZVAL_LONG(offsetX, (x * -1)); + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } else { + ZEPHIR_INIT_NVAR(offsetY); + if (x < 0) { + ZEPHIR_INIT_NVAR(offsetX); + ZVAL_LONG(offsetX, (x * -1)); + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_EAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_WEST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } else { + if (Z_TYPE_P(offsetY) == IS_LONG) { + x = zephir_get_intval(offsetX); + y = zephir_get_intval(offsetY); + if (x < 0) { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, (x * -1)); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, (x * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } else { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHWEST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHWEST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } + } + } } } ZEPHIR_CALL_METHOD(NULL, draw, "setgravity", NULL, 0, gravity); zephir_check_call_status(); - _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_INIT_NVAR(_4); - ZVAL_LONG(_4, 0); - ZEPHIR_CALL_METHOD(NULL, _9, "setiteratorindex", NULL, 0, _4); + _8 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); + ZEPHIR_INIT_NVAR(_5); + ZVAL_LONG(_5, 0); + ZEPHIR_CALL_METHOD(NULL, _8, "setiteratorindex", NULL, 0, _5); zephir_check_call_status(); while (1) { - _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_INIT_NVAR(_4); - ZVAL_LONG(_4, offsetX); - ZEPHIR_INIT_NVAR(_11); - ZVAL_LONG(_11, offsetY); - ZEPHIR_INIT_NVAR(_12); - ZVAL_LONG(_12, 0); - ZEPHIR_CALL_METHOD(NULL, _10, "annotateimage", NULL, 0, draw, _4, _11, _12, text); + _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); + ZEPHIR_INIT_NVAR(_5); + ZVAL_LONG(_5, 0); + ZEPHIR_CALL_METHOD(NULL, _9, "annotateimage", NULL, 0, draw, offsetX, offsetY, _5, text); zephir_check_call_status(); - _13 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(&_5, _13, "nextimage", NULL, 0); + _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(&_11, _10, "nextimage", NULL, 0); zephir_check_call_status(); - if (ZEPHIR_IS_FALSE_IDENTICAL(_5)) { + if (ZEPHIR_IS_FALSE_IDENTICAL(_11)) { break; } } @@ -70145,7 +70557,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _mask) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Imagick::COMPOSITE_DSTIN", 0); - ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 190, &_5); + ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 191, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_2); ZVAL_LONG(_2, 0); @@ -70154,7 +70566,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _mask) { ZEPHIR_CALL_METHOD(&ret, _4, "compositeimage", NULL, 0, mask, _6, _2, _8); zephir_check_call_status(); if (!ZEPHIR_IS_TRUE_IDENTICAL(ret)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 453); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 531); return; } _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -70195,7 +70607,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { ZVAL_LONG(&_2, g); ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, b); - ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 188, &_0, &_1, &_2, &_3); zephir_check_call_status(); ZEPHIR_INIT_VAR(pixel1); object_init_ex(pixel1, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC)); @@ -70234,7 +70646,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { if (!(zephir_is_true(_9))) { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::ALPHACHANNEL_SET", 0); - ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, background, "setimagealphachannel", &_13, 0, _11); zephir_check_call_status(); @@ -70243,11 +70655,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::EVALUATE_MULTIPLY", 0); - ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::CHANNEL_ALPHA", 0); - ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_4); ZVAL_LONG(_4, opacity); @@ -70261,7 +70673,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { _20 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::COMPOSITE_DISSOLVE", 0); - ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_4); ZVAL_LONG(_4, 0); @@ -70270,7 +70682,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { ZEPHIR_CALL_METHOD(&ret, background, "compositeimage", &_23, 0, _20, _21, _4, _22); zephir_check_call_status(); if (!ZEPHIR_IS_TRUE_IDENTICAL(ret)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 492); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 570); return; } _24 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -70387,7 +70799,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 4); - ZEPHIR_CALL_FUNCTION(&ext, "pathinfo", NULL, 69, file, &_0); + ZEPHIR_CALL_FUNCTION(&ext, "pathinfo", NULL, 71, file, &_0); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_CALL_METHOD(NULL, _1, "setformat", NULL, 0, ext); @@ -70407,7 +70819,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { zephir_update_property_this(this_ptr, SL("_mime"), _7 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_9, 140, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_9, 19, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_8, 0)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -70415,7 +70827,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "w", 0); - ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 292, file, &_0); + ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 285, file, &_0); zephir_check_call_status(); _11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_CALL_METHOD(NULL, _11, "writeimagesfile", NULL, 0, fp); @@ -70425,13 +70837,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { } else { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_12, "strcasecmp", &_9, 140, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_12, "strcasecmp", &_9, 19, ext, &_0); zephir_check_call_status(); _13 = ZEPHIR_IS_LONG(_12, 0); if (!(_13)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_14, "strcasecmp", &_9, 140, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_14, "strcasecmp", &_9, 19, ext, &_0); zephir_check_call_status(); _13 = ZEPHIR_IS_LONG(_14, 0); } @@ -70439,7 +70851,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::COMPRESSION_JPEG", 0); - ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 191, &_0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _10, "setimagecompression", NULL, 0, _15); zephir_check_call_status(); @@ -70490,7 +70902,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _render) { zephir_update_property_this(this_ptr, SL("_mime"), _2 TSRMLS_CC); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_4, "strcasecmp", &_5, 140, extension, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "strcasecmp", &_5, 19, extension, &_3); zephir_check_call_status(); if (ZEPHIR_IS_LONG_IDENTICAL(_4, 0)) { ZEPHIR_CALL_METHOD(NULL, image, "optimizeimagelayers", NULL, 0); @@ -70498,20 +70910,20 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _render) { } else { ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_6, "strcasecmp", &_5, 140, extension, &_3); + ZEPHIR_CALL_FUNCTION(&_6, "strcasecmp", &_5, 19, extension, &_3); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG_IDENTICAL(_6, 0); if (!(_7)) { ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_5, 140, extension, &_3); + ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_5, 19, extension, &_3); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG_IDENTICAL(_8, 0); } if (_7) { ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "Imagick::COMPRESSION_JPEG", 0); - ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 190, &_3); + ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 191, &_3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, image, "setimagecompression", NULL, 0, _9); zephir_check_call_status(); @@ -71094,7 +71506,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter, log) { if (zephir_is_true(_3)) { ZEPHIR_INIT_VAR(_4); object_init_ex(_4, phalcon_logger_item_ce); - ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 52, toggledMessage, toggledType, timestamp, context); + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 53, toggledMessage, toggledType, timestamp, context); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_queue"), _4 TSRMLS_CC); } else { @@ -71285,7 +71697,7 @@ static PHP_METHOD(Phalcon_Logger_Formatter, interpolate) { ZEPHIR_CONCAT_SVS(_4, "{", key, "}"); zephir_array_update_zval(&replace, _4, &value, PH_COPY | PH_SEPARATE); } - ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 53, message, replace); + ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 54, message, replace); zephir_check_call_status(); RETURN_MM(); } @@ -71910,7 +72322,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, __construct) { ZEPHIR_INIT_NVAR(mode); ZVAL_STRING(mode, "ab", 1); } - ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 292, name, mode); + ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 285, name, mode); zephir_check_call_status(); if (Z_TYPE_P(handler) != IS_RESOURCE) { ZEPHIR_INIT_VAR(_0); @@ -71942,7 +72354,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, getFormatter) { if (Z_TYPE_P(_0) != IS_OBJECT) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_logger_formatter_line_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 289); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC); } @@ -72022,7 +72434,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, __wakeup) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_logger_exception_ce, "Logger must be opened in append or write mode", "phalcon/logger/adapter/file.zep", 152); return; } - ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 292, path, mode); + ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 285, path, mode); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_fileHandler"), _1 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -72107,15 +72519,15 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) { if (!ZEPHIR_IS_TRUE_IDENTICAL(_1)) { ZEPHIR_SINIT_VAR(_2); ZVAL_STRING(&_2, "X-Wf-Protocol-1: http://meta.wildfirehq.org/Protocol/JsonStream/0.2", 0); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, &_2); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "X-Wf-1-Plugin-1: http://meta.firephp.org/Wildfire/Plugin/FirePHP/Library-FirePHPCore/0.3", 0); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, &_2); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "X-Wf-Structure-1: http://meta.firephp.org/Wildfire/Structure/FirePHP/FirebugConsole/0.1", 0); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, &_2); zephir_check_call_status(); zephir_update_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_initialized"), &(ZEPHIR_GLOBAL(global_true)) TSRMLS_CC); } @@ -72129,7 +72541,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_LONG(&_2, 4500); - ZEPHIR_CALL_FUNCTION(&chunk, "str_split", NULL, 67, format, &_2); + ZEPHIR_CALL_FUNCTION(&chunk, "str_split", NULL, 69, format, &_2); zephir_check_call_status(); zephir_is_iterable(chunk, &_8, &_7, 0, 0, "phalcon/logger/adapter/firephp.zep", 102); for ( @@ -72145,7 +72557,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) { if (zephir_array_isset_long(chunk, (zephir_get_numberval(key) + 1))) { zephir_concat_self_str(&content, SL("|\\") TSRMLS_CC); } - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, content); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, content); zephir_check_call_status(); _10 = zephir_fetch_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_index") TSRMLS_CC); ZEPHIR_INIT_ZVAL_NREF(_11); @@ -72223,7 +72635,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Stream, __construct) { ZEPHIR_INIT_NVAR(mode); ZVAL_STRING(mode, "ab", 1); } - ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 292, name, mode); + ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 285, name, mode); zephir_check_call_status(); if (!(zephir_is_true(stream))) { ZEPHIR_INIT_VAR(_0); @@ -72253,7 +72665,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Stream, getFormatter) { if (Z_TYPE_P(_0) != IS_OBJECT) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_logger_formatter_line_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 289); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC); } @@ -72355,7 +72767,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, __construct) { ZEPHIR_INIT_NVAR(facility); ZVAL_LONG(facility, 8); } - ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 297, name, option, facility); + ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 290, name, option, facility); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_opened"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } @@ -72415,7 +72827,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, logInternal) { } zephir_array_fetch_long(&_3, appliedFormat, 0, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC); zephir_array_fetch_long(&_4, appliedFormat, 1, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 298, _3, _4); + ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 291, _3, _4); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -72430,7 +72842,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, close) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_opened"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 299); + ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 292); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -72587,15 +72999,15 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Firephp, format) { ZVAL_STRING(&_3, "5.3.6", 0); ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "<", 0); - ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 248, _1, &_3, &_4); + ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 240, _1, &_3, &_4); zephir_check_call_status(); if (!(zephir_is_true(_0))) { param = (2) ? 1 : 0; } - ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 150, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 151, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); Z_SET_ISREF_P(backtrace); - ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 170, backtrace); + ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 171, backtrace); Z_UNSET_ISREF_P(backtrace); zephir_check_call_status(); if (zephir_array_isset_string(lastTrace, SS("file"))) { @@ -72766,13 +73178,17 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, getDateFormat) { static PHP_METHOD(Phalcon_Logger_Formatter_Line, setDateFormat) { - zval *dateFormat; + zval *dateFormat_param = NULL; + zval *dateFormat = NULL; - zephir_fetch_params(0, 1, 0, &dateFormat); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &dateFormat_param); + zephir_get_strval(dateFormat, dateFormat_param); zephir_update_property_this(this_ptr, SL("_dateFormat"), dateFormat TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -72785,13 +73201,17 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, getFormat) { static PHP_METHOD(Phalcon_Logger_Formatter_Line, setFormat) { - zval *format; + zval *format_param = NULL; + zval *format = NULL; - zephir_fetch_params(0, 1, 0, &format); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &format_param); + zephir_get_strval(format, format_param); zephir_update_property_this(this_ptr, SL("_format"), format TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -72842,7 +73262,7 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, format) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dateFormat"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_2); ZVAL_LONG(&_2, timestamp); - ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 300, _1, &_2); + ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 293, _1, &_2); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "%date%", 0); @@ -73896,7 +74316,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, _getResultset) { } ZEPHIR_INIT_VAR(collections); array_init(collections); - ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 301, documentsCursor); + ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 294, documentsCursor); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/collection.zep", 440); for ( @@ -74359,7 +74779,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, save) { zephir_update_property_this(this_ptr, SL("_errorMessages"), _1 TSRMLS_CC); ZEPHIR_OBS_VAR(disableEvents); zephir_read_static_property_ce(&disableEvents, phalcon_mvc_collection_ce, SL("_disableEvents") TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 302, dependencyInjector, disableEvents, exists); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 295, dependencyInjector, disableEvents, exists); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(_2)) { RETURN_MM_BOOL(0); @@ -74388,7 +74808,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, save) { } else { success = 0; } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 303, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 296, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists); zephir_check_call_status(); RETURN_MM(); @@ -74806,7 +75226,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, toArray) { zephir_check_call_status(); ZEPHIR_INIT_VAR(data); array_init(data); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, this_ptr); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/collection.zep", 1244); for ( @@ -74838,7 +75258,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, serialize) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "toarray", NULL, 0); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -74869,7 +75289,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, unserialize) { } - ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(attributes) == IS_ARRAY) { ZEPHIR_CALL_CE_STATIC(&dependencyInjector, phalcon_di_ce, "getdefault", &_0, 1); @@ -75717,7 +76137,7 @@ static PHP_METHOD(Phalcon_Mvc_Micro, mount) { if (zephir_is_true(_0)) { ZEPHIR_INIT_VAR(lazyHandler); object_init_ex(lazyHandler, phalcon_mvc_micro_lazyloader_ce); - ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 304, mainHandler); + ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 297, mainHandler); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(lazyHandler, mainHandler); @@ -75866,11 +76286,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, setService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 305, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 298, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -75903,11 +76323,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, hasService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 306, serviceName); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 299, serviceName); zephir_check_call_status(); RETURN_MM(); @@ -75940,11 +76360,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, getService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 307, serviceName); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 300, serviceName); zephir_check_call_status(); RETURN_MM(); @@ -75965,11 +76385,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, getSharedService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 308, serviceName); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 301, serviceName); zephir_check_call_status(); RETURN_MM(); @@ -76533,7 +76953,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __construct) { zephir_check_call_status(); } if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 135); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 134); return; } zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); @@ -76545,7 +76965,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __construct) { zephir_check_call_status(); ZEPHIR_CPY_WRT(modelsManager, _1); if (Z_TYPE_P(modelsManager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 146); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 145); return; } } @@ -76623,7 +77043,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getModelsMetaData) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _0); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 215); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 214); return; } ZEPHIR_INIT_VAR(_2); @@ -76633,7 +77053,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getModelsMetaData) { zephir_check_call_status(); ZEPHIR_CPY_WRT(metaData, _1); if (Z_TYPE_P(metaData) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsMetadata' is not valid", "phalcon/mvc/model.zep", 223); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsMetadata' is not valid", "phalcon/mvc/model.zep", 222); return; } zephir_update_property_this(this_ptr, SL("_modelsMetaData"), metaData TSRMLS_CC); @@ -76947,7 +77367,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, assign) { if (Z_TYPE_P(dataColumnMap) == IS_ARRAY) { ZEPHIR_INIT_VAR(dataMapped); array_init(dataMapped); - zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 437); + zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 436); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -76976,7 +77396,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, assign) { } ZEPHIR_CALL_METHOD(&_3, metaData, "getattributes", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(_3, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 489); + zephir_is_iterable(_3, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 488); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -76992,7 +77412,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, assign) { ZEPHIR_CONCAT_SVS(_8, "Column '", attribute, "' doesn\\'t make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_9, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_7, "phalcon/mvc/model.zep", 459 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model.zep", 458 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -77060,7 +77480,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { ZVAL_LONG(_0, dirtyState); ZEPHIR_CALL_METHOD(NULL, instance, "setdirtystate", NULL, 0, _0); zephir_check_call_status(); - zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 589); + zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 588); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -77081,7 +77501,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model.zep", 532 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model.zep", 531 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -77097,12 +77517,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { _6 = Z_TYPE_P(value) != IS_NULL; } if (_6) { - zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 544 TSRMLS_CC); + zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 543 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_7, 0)) { ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, 10); - ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_9, 25, value, &_8); + ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_9, 26, value, &_8); zephir_check_call_status(); break; } @@ -77121,7 +77541,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { } while(0); } else { - zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 565 TSRMLS_CC); + zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 564 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_7, 0) || ZEPHIR_IS_LONG(_7, 9) || ZEPHIR_IS_LONG(_7, 3) || ZEPHIR_IS_LONG(_7, 7) || ZEPHIR_IS_LONG(_7, 8)) { ZEPHIR_INIT_NVAR(castValue); @@ -77134,7 +77554,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { } ZEPHIR_OBS_NVAR(attributeName); - zephir_array_fetch_long(&attributeName, attribute, 0, PH_NOISY, "phalcon/mvc/model.zep", 581 TSRMLS_CC); + zephir_array_fetch_long(&attributeName, attribute, 0, PH_NOISY, "phalcon/mvc/model.zep", 580 TSRMLS_CC); zephir_update_property_zval_zval(instance, attributeName, castValue TSRMLS_CC); } } @@ -77179,7 +77599,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMapHydrate) { ZEPHIR_INIT_VAR(hydrateObject); object_init(hydrateObject); } - zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 663); + zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 662); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -77197,7 +77617,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMapHydrate) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 642 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 641 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -77253,7 +77673,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResult) { ZVAL_LONG(_0, dirtyState); ZEPHIR_CALL_METHOD(NULL, instance, "setdirtystate", NULL, 0, _0); zephir_check_call_status(); - zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 710); + zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 709); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -77261,7 +77681,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResult) { ZEPHIR_GET_HMKEY(key, _2, _1); ZEPHIR_GET_HVALUE(value, _3); if (Z_TYPE_P(key) != IS_STRING) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid key in array data provided to dumpResult()", "phalcon/mvc/model.zep", 702); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid key in array data provided to dumpResult()", "phalcon/mvc/model.zep", 701); return; } zephir_update_property_zval_zval(instance, key, value TSRMLS_CC); @@ -77300,7 +77720,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, find) { ZEPHIR_INIT_VAR(params); array_init(params); if (Z_TYPE_P(parameters) != IS_NULL) { - zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 756); + zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 755); } } else { ZEPHIR_CPY_WRT(params, parameters); @@ -77375,7 +77795,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, findFirst) { ZEPHIR_INIT_VAR(params); array_init(params); if (Z_TYPE_P(parameters) != IS_NULL) { - zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 843); + zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 842); } } else { ZEPHIR_CPY_WRT(params, parameters); @@ -77459,12 +77879,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, query) { ZEPHIR_CALL_METHOD(NULL, criteria, "__construct", NULL, 0); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 309, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 302, dependencyInjector); zephir_check_call_status(); } ZEPHIR_INIT_NVAR(_2); zephir_get_called_class(_2 TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, _2); + ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 303, _2); zephir_check_call_status(); RETURN_CCTOR(criteria); @@ -77682,7 +78102,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _groupResult) { ZEPHIR_INIT_VAR(params); array_init(params); if (Z_TYPE_P(parameters) != IS_NULL) { - zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 1092); + zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 1093); } } else { ZEPHIR_CPY_WRT(params, parameters); @@ -77690,7 +78110,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _groupResult) { ZEPHIR_OBS_VAR(groupColumn); if (!(zephir_array_isset_string_fetch(&groupColumn, params, SS("column"), 0 TSRMLS_CC))) { ZEPHIR_INIT_NVAR(groupColumn); - ZVAL_LONG(groupColumn, '*'); + ZVAL_STRING(groupColumn, "*", 1); } ZEPHIR_OBS_VAR(distinctColumn); if (zephir_array_isset_string_fetch(&distinctColumn, params, SS("distinct"), 0 TSRMLS_CC)) { @@ -77998,7 +78418,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, validate) { if (ZEPHIR_IS_FALSE_IDENTICAL(_0)) { ZEPHIR_CALL_METHOD(&_1, validator, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1392); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1393); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -78050,7 +78470,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getMessages) { ZEPHIR_INIT_VAR(filtered); array_init(filtered); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_errorMessages"), PH_NOISY_CC); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1458); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1459); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -78059,7 +78479,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getMessages) { ZEPHIR_CALL_METHOD(&_5, message, "getfield", NULL, 0); zephir_check_call_status(); if (ZEPHIR_IS_EQUAL(_5, filter)) { - zephir_array_append(&filtered, message, PH_SEPARATE, "phalcon/mvc/model.zep", 1455); + zephir_array_append(&filtered, message, PH_SEPARATE, "phalcon/mvc/model.zep", 1456); } } RETURN_CCTOR(filtered); @@ -78086,7 +78506,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { zephir_check_call_status(); if (zephir_fast_count_int(belongsTo TSRMLS_CC)) { error = 0; - zephir_is_iterable(belongsTo, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1601); + zephir_is_iterable(belongsTo, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1602); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -78099,7 +78519,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { if (Z_TYPE_P(foreignKey) == IS_ARRAY) { if (zephir_array_isset_string(foreignKey, SS("action"))) { ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1502 TSRMLS_CC); + zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1503 TSRMLS_CC); action = zephir_get_intval(_4); } } @@ -78118,7 +78538,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { ZEPHIR_CALL_METHOD(&referencedFields, relation, "getreferencedfields", NULL, 0); zephir_check_call_status(); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1538); + zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1539); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) @@ -78127,11 +78547,11 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { ZEPHIR_GET_HVALUE(field, _9); ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, field, PH_SILENT_CC); - zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1531 TSRMLS_CC); + zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1532 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVSV(_11, "[", _10, "] = ?", position); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1531); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1532); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1532); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1533); if (Z_TYPE_P(value) == IS_NULL) { numberNull++; } @@ -78142,15 +78562,15 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { zephir_fetch_property_zval(&value, this_ptr, fields, PH_SILENT_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVS(_11, "[", referencedFields, "] = ?0"); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1543); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1544); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1544); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1545); if (Z_TYPE_P(value) == IS_NULL) { validateWithNulls = 1; } } ZEPHIR_OBS_NVAR(extraConditions); if (zephir_array_isset_string_fetch(&extraConditions, foreignKey, SS("conditions"), 0 TSRMLS_CC)) { - zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1555); + zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1556); } if (validateWithNulls) { ZEPHIR_OBS_NVAR(allowNulls); @@ -78232,7 +78652,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { ZEPHIR_CALL_METHOD(&relations, manager, "gethasoneandhasmany", NULL, 0, this_ptr); zephir_check_call_status(); if (zephir_fast_count_int(relations TSRMLS_CC)) { - zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1715); + zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1716); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -78245,7 +78665,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { if (Z_TYPE_P(foreignKey) == IS_ARRAY) { if (zephir_array_isset_string(foreignKey, SS("action"))) { ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1654 TSRMLS_CC); + zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1655 TSRMLS_CC); action = zephir_get_intval(_4); } } @@ -78263,7 +78683,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { ZEPHIR_INIT_NVAR(bindParams); array_init(bindParams); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1682); + zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1683); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) @@ -78272,23 +78692,23 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { ZEPHIR_GET_HVALUE(field, _9); ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, field, PH_SILENT_CC); - zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1679 TSRMLS_CC); + zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1680 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVSV(_11, "[", _10, "] = ?", position); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1679); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1680); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1680); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1681); } } else { ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, fields, PH_SILENT_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVS(_11, "[", referencedFields, "] = ?0"); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1684); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1685); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1685); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1686); } ZEPHIR_OBS_NVAR(extraConditions); if (zephir_array_isset_string_fetch(&extraConditions, foreignKey, SS("conditions"), 0 TSRMLS_CC)) { - zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1692); + zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1693); } ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -78329,7 +78749,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { zephir_check_call_status(); if (zephir_fast_count_int(relations TSRMLS_CC)) { error = 0; - zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1834); + zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1835); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -78342,7 +78762,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { if (Z_TYPE_P(foreignKey) == IS_ARRAY) { if (zephir_array_isset_string(foreignKey, SS("action"))) { ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1762 TSRMLS_CC); + zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1763 TSRMLS_CC); action = zephir_get_intval(_4); } } @@ -78360,7 +78780,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { ZEPHIR_INIT_NVAR(bindParams); array_init(bindParams); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/mvc/model.zep", 1794); + zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/mvc/model.zep", 1795); for ( ; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS ; zephir_hash_move_forward_ex(_7, &_6) @@ -78369,23 +78789,23 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { ZEPHIR_GET_HVALUE(field, _8); ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, field, PH_SILENT_CC); - zephir_array_fetch(&_9, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1790 TSRMLS_CC); + zephir_array_fetch(&_9, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1791 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVSV(_10, "[", _9, "] = ?", position); - zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1790); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1791); + zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1791); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1792); } } else { ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, fields, PH_SILENT_CC); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVS(_10, "[", referencedFields, "] = ?0"); - zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1796); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1797); + zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1797); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1798); } ZEPHIR_OBS_NVAR(extraConditions); if (zephir_array_isset_string_fetch(&extraConditions, foreignKey, SS("conditions"), 0 TSRMLS_CC)) { - zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1804); + zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1805); } ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -78509,7 +78929,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSave) { ZEPHIR_CALL_METHOD(&emptyStringValues, metaData, "getemptystringattributes", NULL, 0, this_ptr); zephir_check_call_status(); error = 0; - zephir_is_iterable(notNull, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 2000); + zephir_is_iterable(notNull, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 2001); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -78526,7 +78946,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSave) { ZEPHIR_CONCAT_SVS(_7, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 1936 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 1937 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -78746,7 +79166,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_INIT_NVAR(columnMap); ZVAL_NULL(columnMap); } - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 2184); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 2185); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -78762,7 +79182,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2138 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2139 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -78788,23 +79208,23 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Column '", field, "' have not defined a bind data type"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2162 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2163 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2165); - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2165); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2165); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2166); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2166); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2166); } else { if (zephir_array_isset(defaultValues, field)) { ZEPHIR_CALL_METHOD(&_8, connection, "getdefaultvalue", &_9, 0); zephir_check_call_status(); - zephir_array_append(&values, _8, PH_SEPARATE, "phalcon/mvc/model.zep", 2170); + zephir_array_append(&values, _8, PH_SEPARATE, "phalcon/mvc/model.zep", 2171); } else { - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2172); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2173); } - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2175); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2175); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2176); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2176); } } } @@ -78816,7 +79236,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { zephir_check_call_status(); useExplicitIdentity = zephir_get_boolval(_8); if (useExplicitIdentity) { - zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2193); + zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2194); } if (Z_TYPE_P(columnMap) == IS_ARRAY) { ZEPHIR_OBS_NVAR(attributeField); @@ -78827,7 +79247,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Identity column '", identityField, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2201 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2202 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -78842,12 +79262,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { } if (_6) { if (useExplicitIdentity) { - zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2214); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2214); + zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2215); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2215); } } else { if (!(useExplicitIdentity)) { - zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2222); + zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2223); } ZEPHIR_OBS_NVAR(bindType); if (!(zephir_array_isset_fetch(&bindType, bindDataTypes, identityField, 0 TSRMLS_CC))) { @@ -78857,17 +79277,17 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Identity column '", identityField, "' isn\\'t part of the table columns"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2229 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2230 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2232); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2232); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2233); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2233); } } else { if (useExplicitIdentity) { - zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2236); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2236); + zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2237); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2237); } } } @@ -78957,7 +79377,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_INIT_NVAR(columnMap); ZVAL_NULL(columnMap); } - zephir_is_iterable(nonPrimary, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 2436); + zephir_is_iterable(nonPrimary, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 2437); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -78972,7 +79392,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CONCAT_SVS(_6, "Column '", field, "' have not defined a bind data type"); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2335 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2336 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -78985,7 +79405,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CONCAT_SVS(_6, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2343 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2344 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -78995,9 +79415,9 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_OBS_NVAR(value); if (zephir_fetch_property_zval(&value, this_ptr, attributeField, PH_SILENT_CC)) { if (!(useDynamicUpdate)) { - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2359); - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2359); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2360); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2360); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2360); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2361); } else { ZEPHIR_OBS_NVAR(snapshotValue); if (!(zephir_array_isset_fetch(&snapshotValue, snapshot, attributeField, 0 TSRMLS_CC))) { @@ -79019,9 +79439,9 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { break; } if (ZEPHIR_IS_LONG(bindType, 3) || ZEPHIR_IS_LONG(bindType, 7)) { - ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 311, snapshotValue); + ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 304, snapshotValue); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 311, value); + ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 304, value); zephir_check_call_status(); changed = !ZEPHIR_IS_IDENTICAL(_1, _9); break; @@ -79039,15 +79459,15 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { } } if (changed) { - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2422); - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2422); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2423); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2423); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2423); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2424); } } } else { - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2428); - zephir_array_append(&values, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2428); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2428); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2429); + zephir_array_append(&values, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2429); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2429); } } } @@ -79064,12 +79484,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CALL_METHOD(&primaryKeys, metaData, "getprimarykeyattributes", NULL, 0, this_ptr); zephir_check_call_status(); if (!(zephir_fast_count_int(primaryKeys TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 2455); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 2456); return; } ZEPHIR_INIT_NVAR(uniqueParams); array_init(uniqueParams); - zephir_is_iterable(primaryKeys, &_13, &_12, 0, 0, "phalcon/mvc/model.zep", 2478); + zephir_is_iterable(primaryKeys, &_13, &_12, 0, 0, "phalcon/mvc/model.zep", 2479); for ( ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS ; zephir_hash_move_forward_ex(_13, &_12) @@ -79084,7 +79504,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CONCAT_SVS(_6, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2466 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2467 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79093,9 +79513,9 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { } ZEPHIR_OBS_NVAR(value); if (zephir_fetch_property_zval(&value, this_ptr, attributeField, PH_SILENT_CC)) { - zephir_array_append(&uniqueParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2473); + zephir_array_append(&uniqueParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2474); } else { - zephir_array_append(&uniqueParams, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2475); + zephir_array_append(&uniqueParams, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2476); } } } @@ -79132,7 +79552,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmodelsmanager", NULL, 0); zephir_check_call_status(); ZEPHIR_CPY_WRT(manager, _0); - zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2584); + zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2585); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -79149,7 +79569,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { if (Z_TYPE_P(record) != IS_OBJECT) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_5, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects can be stored as part of belongs-to relations", "phalcon/mvc/model.zep", 2533); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects can be stored as part of belongs-to relations", "phalcon/mvc/model.zep", 2534); return; } ZEPHIR_CALL_METHOD(&columns, relation, "getfields", NULL, 0); @@ -79161,7 +79581,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { if (Z_TYPE_P(columns) == IS_ARRAY) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_6, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2542); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2543); return; } ZEPHIR_CALL_METHOD(&_0, record, "save", NULL, 0); @@ -79169,7 +79589,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { if (!(zephir_is_true(_0))) { ZEPHIR_CALL_METHOD(&_7, record, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_7, &_9, &_8, 0, 0, "phalcon/mvc/model.zep", 2571); + zephir_is_iterable(_7, &_9, &_8, 0, 0, "phalcon/mvc/model.zep", 2572); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) @@ -79216,7 +79636,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmodelsmanager", NULL, 0); zephir_check_call_status(); ZEPHIR_CPY_WRT(manager, _0); - zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2772); + zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2773); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -79239,7 +79659,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (_5) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_6, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects/arrays can be stored as part of has-many/has-one/has-many-to-many relations", "phalcon/mvc/model.zep", 2623); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects/arrays can be stored as part of has-many/has-one/has-many-to-many relations", "phalcon/mvc/model.zep", 2624); return; } ZEPHIR_CALL_METHOD(&columns, relation, "getfields", NULL, 0); @@ -79251,7 +79671,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (Z_TYPE_P(columns) == IS_ARRAY) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_7, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2632); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2633); return; } if (Z_TYPE_P(record) == IS_OBJECT) { @@ -79271,7 +79691,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CONCAT_SVS(_10, "The column '", columns, "' needs to be present in the model"); ZEPHIR_CALL_METHOD(NULL, _9, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2646 TSRMLS_CC); + zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2647 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79286,7 +79706,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CALL_METHOD(&intermediateReferencedFields, relation, "getintermediatereferencedfields", NULL, 0); zephir_check_call_status(); } - zephir_is_iterable(relatedRecords, &_14, &_13, 0, 0, "phalcon/mvc/model.zep", 2761); + zephir_is_iterable(relatedRecords, &_14, &_13, 0, 0, "phalcon/mvc/model.zep", 2762); for ( ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS ; zephir_hash_move_forward_ex(_14, &_13) @@ -79301,7 +79721,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (!(zephir_is_true(_12))) { ZEPHIR_CALL_METHOD(&_16, recordAfter, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_16, &_18, &_17, 0, 0, "phalcon/mvc/model.zep", 2703); + zephir_is_iterable(_16, &_18, &_17, 0, 0, "phalcon/mvc/model.zep", 2704); for ( ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS ; zephir_hash_move_forward_ex(_18, &_17) @@ -79334,7 +79754,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (!(zephir_is_true(_16))) { ZEPHIR_CALL_METHOD(&_23, intermediateModel, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_23, &_25, &_24, 0, 0, "phalcon/mvc/model.zep", 2755); + zephir_is_iterable(_23, &_25, &_24, 0, 0, "phalcon/mvc/model.zep", 2756); for ( ; zephir_hash_get_current_data_ex(_25, (void**) &_26, &_24) == SUCCESS ; zephir_hash_move_forward_ex(_25, &_24) @@ -79363,7 +79783,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CONCAT_SVSVS(_10, "There are no defined relations for the model '", className, "' using alias '", name, "'"); ZEPHIR_CALL_METHOD(NULL, _9, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2764 TSRMLS_CC); + zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2765 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79458,9 +79878,9 @@ static PHP_METHOD(Phalcon_Mvc_Model, save) { ZEPHIR_INIT_NVAR(_4); object_init_ex(_4, phalcon_mvc_model_validationfailed_ce); _3 = zephir_fetch_nproperty_this(this_ptr, SL("_errorMessages"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 312, this_ptr, _3); + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 305, this_ptr, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 2877 TSRMLS_CC); + zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 2878 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79478,11 +79898,6 @@ static PHP_METHOD(Phalcon_Mvc_Model, save) { ZVAL_LONG(_3, 0); zephir_update_property_this(this_ptr, SL("_dirtyState"), _3 TSRMLS_CC); } - if (ZEPHIR_GLOBAL(orm).events) { - ZEPHIR_CALL_METHOD(&_2, this_ptr, "_postsave", NULL, 0, success, exists); - zephir_check_call_status(); - ZEPHIR_CPY_WRT(success, _2); - } if (Z_TYPE_P(related) == IS_ARRAY) { if (ZEPHIR_IS_FALSE_IDENTICAL(success)) { ZEPHIR_INIT_NVAR(_1); @@ -79494,6 +79909,11 @@ static PHP_METHOD(Phalcon_Mvc_Model, save) { zephir_check_call_status(); } } + if (ZEPHIR_GLOBAL(orm).events) { + ZEPHIR_CALL_METHOD(&_2, this_ptr, "_postsave", NULL, 0, success, exists); + zephir_check_call_status(); + ZEPHIR_CPY_WRT(success, _2); + } if (ZEPHIR_IS_FALSE_IDENTICAL(success)) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "_canceloperation", NULL, 0); zephir_check_call_status(); @@ -79652,10 +80072,10 @@ static PHP_METHOD(Phalcon_Mvc_Model, delete) { ZVAL_NULL(columnMap); } if (!(zephir_fast_count_int(primaryKeys TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 3061); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 3062); return; } - zephir_is_iterable(primaryKeys, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 3102); + zephir_is_iterable(primaryKeys, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 3103); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -79669,7 +80089,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, delete) { ZEPHIR_CONCAT_SVS(_7, "Column '", primaryKey, "' have not defined a bind data type"); ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3073 TSRMLS_CC); + zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3074 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79682,7 +80102,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, delete) { ZEPHIR_CONCAT_SVS(_7, "Column '", primaryKey, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3081 TSRMLS_CC); + zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3082 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79697,17 +80117,17 @@ static PHP_METHOD(Phalcon_Mvc_Model, delete) { ZEPHIR_CONCAT_SVS(_7, "Cannot delete the record because the primary key attribute: '", attributeField, "' wasn't set"); ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3091 TSRMLS_CC); + zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3092 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 3097); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 3098); ZEPHIR_CALL_METHOD(&_2, writeConnection, "escapeidentifier", &_9, 0, primaryKey); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_VS(_7, _2, " = ?"); - zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model.zep", 3098); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 3099); + zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model.zep", 3099); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 3100); } if (ZEPHIR_GLOBAL(orm).events) { zephir_update_property_this(this_ptr, SL("_skipped"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); @@ -79783,7 +80203,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, refresh) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC); if (!ZEPHIR_IS_LONG(_0, 0)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3177); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3178); return; } ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0); @@ -79808,7 +80228,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, refresh) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "_exists", NULL, 0, metaData, readConnection, table); zephir_check_call_status(); if (!(zephir_is_true(_1))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3199); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3200); return; } ZEPHIR_OBS_NVAR(uniqueKey); @@ -79817,14 +80237,14 @@ static PHP_METHOD(Phalcon_Mvc_Model, refresh) { ZEPHIR_OBS_VAR(uniqueParams); zephir_read_property_this(&uniqueParams, this_ptr, SL("_uniqueParams"), PH_NOISY_CC); if (Z_TYPE_P(uniqueParams) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3207); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3208); return; } ZEPHIR_INIT_VAR(fields); array_init(fields); ZEPHIR_CALL_METHOD(&_1, metaData, "getattributes", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3221); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3222); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -79833,7 +80253,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, refresh) { ZEPHIR_INIT_NVAR(_5); zephir_create_array(_5, 1, 0 TSRMLS_CC); zephir_array_fast_append(_5, attribute); - zephir_array_append(&fields, _5, PH_SEPARATE, "phalcon/mvc/model.zep", 3215); + zephir_array_append(&fields, _5, PH_SEPARATE, "phalcon/mvc/model.zep", 3216); } ZEPHIR_CALL_METHOD(&dialect, readConnection, "getdialect", NULL, 0); zephir_check_call_status(); @@ -79948,7 +80368,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, skipAttributes) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3302); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3303); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -79983,7 +80403,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, skipAttributesOnCreate) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3333); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3334); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -80016,7 +80436,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, skipAttributesOnUpdate) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3362); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3363); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -80049,7 +80469,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, allowEmptyStringValues) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3391); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3392); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -80262,7 +80682,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) { if (Z_TYPE_P(columnMap) == IS_ARRAY) { ZEPHIR_INIT_VAR(snapshot); array_init(snapshot); - zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3605); + zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3606); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -80281,7 +80701,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3586 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3587 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -80298,7 +80718,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3595 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3596 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -80351,12 +80771,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_OBS_VAR(snapshot); zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC); if (Z_TYPE_P(snapshot) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3644); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3645); return; } _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC); if (!ZEPHIR_IS_LONG(_0, 0)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3651); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3652); return; } ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0); @@ -80378,7 +80798,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3683 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3684 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80390,7 +80810,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3687 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3688 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80403,7 +80823,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not defined on the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3695 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3696 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80415,14 +80835,14 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_3, "The field '", fieldName, "' was not found in the snapshot"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3702 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3703 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } RETURN_MM_BOOL(!ZEPHIR_IS_EQUAL(value, originalValue)); } ZEPHIR_INIT_NVAR(_1); - zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3738); + zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3739); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -80457,12 +80877,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) { ZEPHIR_OBS_VAR(snapshot); zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC); if (Z_TYPE_P(snapshot) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3751); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3752); return; } _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC); if (!ZEPHIR_IS_LONG(_0, 0)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3758); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3759); return; } ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0); @@ -80478,7 +80898,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) { ZEPHIR_INIT_VAR(changed); array_init(changed); ZEPHIR_INIT_VAR(_1); - zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3812); + zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3813); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -80486,17 +80906,17 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) { ZEPHIR_GET_HMKEY(name, _3, _2); ZEPHIR_GET_HVALUE(_1, _4); if (!(zephir_array_isset(snapshot, name))) { - zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3791); + zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3792); continue; } ZEPHIR_OBS_NVAR(value); if (!(zephir_fetch_property_zval(&value, this_ptr, name, PH_SILENT_CC))) { - zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3799); + zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3800); continue; } - zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3806 TSRMLS_CC); + zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3807 TSRMLS_CC); if (!ZEPHIR_IS_EQUAL(value, _5)) { - zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3807); + zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3808); continue; } } @@ -80553,7 +80973,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getRelated) { ZEPHIR_CONCAT_SVSVS(_3, "There is no defined relations for the model '", className, "' using alias '", alias, "'"); ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3854 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3855 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80691,7 +81111,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __call) { ZEPHIR_CONCAT_SVSVS(_2, "The method '", method, "' doesn't exist on model '", modelName, "'"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3946 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3947 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -80702,16 +81122,13 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { zval *_6, *_7; zend_class_entry *_5, *_8; int ZEPHIR_LAST_CALL_STATUS; - zval *method_param = NULL, *arguments = NULL, *extraMethod = NULL, *type = NULL, *modelName, *value, *model, *attributes = NULL, *field = NULL, *extraMethodFirst = NULL, *metaData = NULL, _0 = zval_used_for_init, *_1 = NULL, *_2 = NULL, *_4 = NULL; + zval *method_param = NULL, *arguments, *extraMethod = NULL, *type = NULL, *modelName, *value, *model, *attributes = NULL, *field = NULL, *extraMethodFirst = NULL, *metaData = NULL, _0 = zval_used_for_init, *_1 = NULL, *_2 = NULL, *_4 = NULL; zval *method = NULL, *_3; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 1, &method_param, &arguments); + zephir_fetch_params(1, 2, 0, &method_param, &arguments); zephir_get_strval(method, method_param); - if (!arguments) { - arguments = ZEPHIR_GLOBAL(global_null); - } ZEPHIR_INIT_VAR(extraMethod); @@ -80753,7 +81170,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { ZEPHIR_CONCAT_SVSVS(_2, "The static method '", method, "' doesn't exist on model '", modelName, "'"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3997 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3998 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80765,7 +81182,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { ZEPHIR_CONCAT_SVS(_3, "The static method '", method, "' requires one argument"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4001 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4002 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80788,7 +81205,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { if (zephir_array_isset(attributes, extraMethod)) { ZEPHIR_CPY_WRT(field, extraMethod); } else { - ZEPHIR_CALL_FUNCTION(&extraMethodFirst, "lcfirst", NULL, 65, extraMethod); + ZEPHIR_CALL_FUNCTION(&extraMethodFirst, "lcfirst", NULL, 67, extraMethod); zephir_check_call_status(); if (zephir_array_isset(attributes, extraMethodFirst)) { ZEPHIR_CPY_WRT(field, extraMethodFirst); @@ -80802,7 +81219,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { ZEPHIR_CONCAT_SVS(_2, "Cannot resolve attribute '", extraMethod, "' in the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4035 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4036 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80861,7 +81278,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __set) { zephir_check_call_status(); ZEPHIR_INIT_VAR(related); array_init(related); - zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4099); + zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4100); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -80870,7 +81287,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __set) { ZEPHIR_GET_HVALUE(item, _3); if (Z_TYPE_P(item) == IS_OBJECT) { if (zephir_instance_of_ev(item, phalcon_mvc_modelinterface_ce TSRMLS_CC)) { - zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4086); + zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4087); } } else { ZEPHIR_INIT_NVAR(lowerKey); @@ -81020,7 +81437,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, serialize) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "toarray", NULL, 0); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -81051,13 +81468,13 @@ static PHP_METHOD(Phalcon_Mvc_Model, unserialize) { } - ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(attributes) == IS_ARRAY) { ZEPHIR_CALL_CE_STATIC(&dependencyInjector, phalcon_di_ce, "getdefault", &_0, 1); zephir_check_call_status(); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4223); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4224); return; } zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); @@ -81068,13 +81485,13 @@ static PHP_METHOD(Phalcon_Mvc_Model, unserialize) { zephir_check_call_status(); ZEPHIR_CPY_WRT(manager, _1); if (Z_TYPE_P(manager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4236); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4237); return; } zephir_update_property_this(this_ptr, SL("_modelsManager"), manager TSRMLS_CC); ZEPHIR_CALL_METHOD(NULL, manager, "initialize", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4255); + zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4256); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -81094,7 +81511,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, dump) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 23, this_ptr); + ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM(); @@ -81124,7 +81541,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, toArray) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_0, metaData, "getattributes", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4319); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4320); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -81140,7 +81557,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, toArray) { ZEPHIR_CONCAT_SVS(_5, "Column '", attribute, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _4, "__construct", &_6, 9, _5); zephir_check_call_status(); - zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4297 TSRMLS_CC); + zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4298 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -81452,7 +81869,7 @@ static PHP_METHOD(Phalcon_Mvc_Router, __construct) { add_assoc_long_ex(_1, SS("controller"), 1); ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "#^/([\\w0-9\\_\\-]+)[/]{0,1}$#u", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 74, _2, _1); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 76, _2, _1); zephir_check_temp_parameter(_2); zephir_check_call_status(); zephir_array_append(&routes, _0, PH_SEPARATE, "phalcon/mvc/router.zep", 120); @@ -81465,7 +81882,7 @@ static PHP_METHOD(Phalcon_Mvc_Router, __construct) { add_assoc_long_ex(_4, SS("params"), 3); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "#^/([\\w0-9\\_\\-]+)/([\\w0-9\\.\\_]+)(/.*)*$#u", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 74, _5, _4); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 76, _5, _4); zephir_check_temp_parameter(_5); zephir_check_call_status(); zephir_array_append(&routes, _2, PH_SEPARATE, "phalcon/mvc/router.zep", 126); @@ -81990,7 +82407,7 @@ static PHP_METHOD(Phalcon_Mvc_Router, handle) { ZEPHIR_OBS_VAR(notFoundPaths); zephir_read_property_this(¬FoundPaths, this_ptr, SL("_notFoundPaths"), PH_NOISY_CC); if (Z_TYPE_P(notFoundPaths) != IS_NULL) { - ZEPHIR_CALL_CE_STATIC(&parts, phalcon_mvc_router_route_ce, "getroutepaths", &_20, 75, notFoundPaths); + ZEPHIR_CALL_CE_STATIC(&parts, phalcon_mvc_router_route_ce, "getroutepaths", &_20, 77, notFoundPaths); zephir_check_call_status(); ZEPHIR_INIT_NVAR(routeFound); ZVAL_BOOL(routeFound, 1); @@ -82103,7 +82520,7 @@ static PHP_METHOD(Phalcon_Mvc_Router, add) { ZEPHIR_INIT_VAR(route); object_init_ex(route, phalcon_mvc_router_route_ce); - ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 74, pattern, paths, httpMethods); + ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 76, pattern, paths, httpMethods); zephir_check_call_status(); do { if (ZEPHIR_IS_LONG(position, 1)) { @@ -82890,11 +83307,11 @@ static PHP_METHOD(Phalcon_Mvc_Url, getBasePath) { static PHP_METHOD(Phalcon_Mvc_Url, get) { - unsigned char _10, _12; + unsigned char _10, _12, _15; int ZEPHIR_LAST_CALL_STATUS; - zend_bool _0, _1, _11; + zend_bool _0, _1, _11, _13, _14; zval *strUri = NULL, *_9 = NULL; - zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_13; + zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_16; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 0, 4, &uri, &args, &local, &baseUri); @@ -83011,19 +83428,33 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) { _12 = ZEPHIR_STRING_OFFSET(strUri, 1); _11 = _12 != '/'; } - ZEPHIR_INIT_NVAR(uri); if (_11) { ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 1); ZEPHIR_INIT_NVAR(_3); zephir_substr(_3, strUri, 1 , 0, ZEPHIR_SUBSTR_NO_LENGTH); + ZEPHIR_INIT_NVAR(uri); ZEPHIR_CONCAT_VV(uri, baseUri, _3); } else { - ZEPHIR_CONCAT_VV(uri, baseUri, strUri); + _13 = ZEPHIR_IS_STRING(baseUri, "/"); + if (_13) { + _13 = zephir_fast_strlen_ev(strUri) == 1; + } + _14 = _13; + if (_14) { + _15 = ZEPHIR_STRING_OFFSET(strUri, 0); + _14 = _15 == '/'; + } + if (_14) { + ZEPHIR_CPY_WRT(uri, baseUri); + } else { + ZEPHIR_INIT_NVAR(uri); + ZEPHIR_CONCAT_VV(uri, baseUri, strUri); + } } } if (zephir_is_true(args)) { - ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 369, args); + ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 362, args); zephir_check_call_status(); _0 = Z_TYPE_P(queryString) == IS_STRING; if (_0) { @@ -83039,9 +83470,9 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) { ZEPHIR_CONCAT_SV(_7, "&", queryString); zephir_concat_self(&uri, _7 TSRMLS_CC); } else { - ZEPHIR_INIT_VAR(_13); - ZEPHIR_CONCAT_SV(_13, "?", queryString); - zephir_concat_self(&uri, _13 TSRMLS_CC); + ZEPHIR_INIT_VAR(_16); + ZEPHIR_CONCAT_SV(_16, "?", queryString); + zephir_concat_self(&uri, _16 TSRMLS_CC); } } } @@ -83645,7 +84076,7 @@ static PHP_METHOD(Phalcon_Mvc_View, start) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_content"), ZEPHIR_GLOBAL(global_null) TSRMLS_CC); RETURN_THIS(); @@ -83674,7 +84105,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _loadTemplateEngines) { if (Z_TYPE_P(registeredEngines) != IS_ARRAY) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_mvc_view_engine_php_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 370, this_ptr, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 363, this_ptr, dependencyInjector); zephir_check_call_status(); zephir_array_update_string(&engines, SL(".phtml"), &_1, PH_COPY | PH_SEPARATE); } else { @@ -83982,7 +84413,7 @@ static PHP_METHOD(Phalcon_Mvc_View, render) { zephir_update_property_this(this_ptr, SL("_currentRenderLevel"), _0 TSRMLS_CC); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_disabled"), PH_NOISY_CC); if (!ZEPHIR_IS_FALSE(_0)) { - ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 117); + ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 119); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_content"), _1 TSRMLS_CC); RETURN_MM_BOOL(0); @@ -84042,7 +84473,7 @@ static PHP_METHOD(Phalcon_Mvc_View, render) { RETURN_MM_BOOL(0); } } - ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 117); + ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 119); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_content"), _1 TSRMLS_CC); mustClean = 1; @@ -84221,11 +84652,11 @@ static PHP_METHOD(Phalcon_Mvc_View, getPartial) { } - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, this_ptr, "partial", NULL, 0, partialPath, params); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 284); zephir_check_call_status(); RETURN_MM(); @@ -84350,7 +84781,7 @@ static PHP_METHOD(Phalcon_Mvc_View, getRender) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, view, "render", NULL, 0, controllerName, actionName); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(view, "getcontent", NULL, 0); zephir_check_call_status(); @@ -84364,7 +84795,7 @@ static PHP_METHOD(Phalcon_Mvc_View, finish) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); RETURN_THIS(); @@ -85123,7 +85554,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection_Document, toArray) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 23, this_ptr); + ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM(); @@ -85806,7 +86237,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection_Behavior_Timestampable, notify) { ZVAL_NULL(timestamp); ZEPHIR_OBS_VAR(format); if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format); + ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 293, format); zephir_check_call_status(); } else { ZEPHIR_OBS_VAR(generator); @@ -87250,9 +87681,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, betweenWhere) { ZEPHIR_INIT_VAR(nextHiddenParam); ZVAL_LONG(nextHiddenParam, (zephir_get_numberval(hiddenParam) + 1)); ZEPHIR_INIT_VAR(minimumKey); - ZEPHIR_CONCAT_SV(minimumKey, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(minimumKey, "ACP", hiddenParam); ZEPHIR_INIT_VAR(maximumKey); - ZEPHIR_CONCAT_SV(maximumKey, "AP", nextHiddenParam); + ZEPHIR_CONCAT_SV(maximumKey, "ACP", nextHiddenParam); ZEPHIR_INIT_VAR(_0); ZEPHIR_CONCAT_VSVSVS(_0, expr, " BETWEEN :", minimumKey, ": AND :", maximumKey, ":"); ZEPHIR_INIT_VAR(_1); @@ -87296,9 +87727,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, notBetweenWhere) { ZEPHIR_INIT_VAR(nextHiddenParam); ZVAL_LONG(nextHiddenParam, (zephir_get_numberval(hiddenParam) + 1)); ZEPHIR_INIT_VAR(minimumKey); - ZEPHIR_CONCAT_SV(minimumKey, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(minimumKey, "ACP", hiddenParam); ZEPHIR_INIT_VAR(maximumKey); - ZEPHIR_CONCAT_SV(maximumKey, "AP", nextHiddenParam); + ZEPHIR_CONCAT_SV(maximumKey, "ACP", nextHiddenParam); ZEPHIR_INIT_VAR(_0); ZEPHIR_CONCAT_VSVSVS(_0, expr, " NOT BETWEEN :", minimumKey, ": AND :", maximumKey, ":"); ZEPHIR_INIT_VAR(_1); @@ -87347,17 +87778,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, inWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 451); + zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 450); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(value, _2); ZEPHIR_INIT_NVAR(key); - ZEPHIR_CONCAT_SV(key, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(key, "ACP", hiddenParam); ZEPHIR_INIT_NVAR(queryKey); ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":"); - zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 442); + zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 441); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); ZEPHIR_SEPARATE(hiddenParam); zephir_increment(hiddenParam); @@ -87406,17 +87837,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, notInWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 488); + zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 487); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(value, _2); ZEPHIR_INIT_NVAR(key); - ZEPHIR_CONCAT_SV(key, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(key, "ACP", hiddenParam); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVS(_3, ":", key, ":"); - zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 478); + zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 477); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); ZEPHIR_SEPARATE(hiddenParam); zephir_increment(hiddenParam); @@ -87751,11 +88182,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { zend_class_entry *_2; int ZEPHIR_LAST_CALL_STATUS; zval *data = NULL; - zval *modelName = NULL; - zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *attribute = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *columnMap = NULL, *_0 = NULL, *_1 = NULL, **_5, *_8 = NULL, *_9 = NULL; + zval *modelName = NULL, *operator = NULL, *_10; + zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *operator_param = NULL, *attribute = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *columnMap = NULL, *_0 = NULL, *_1 = NULL, **_5, *_8 = NULL, *_9 = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 3, 0, &dependencyInjector, &modelName_param, &data_param); + zephir_fetch_params(1, 3, 1, &dependencyInjector, &modelName_param, &data_param, &operator_param); if (unlikely(Z_TYPE_P(modelName_param) != IS_STRING && Z_TYPE_P(modelName_param) != IS_NULL)) { zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'modelName' must be a string") TSRMLS_CC); @@ -87770,6 +88201,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } data = data_param; + if (!operator_param) { + ZEPHIR_INIT_VAR(operator); + ZVAL_STRING(operator, "AND", 1); + } else { + if (unlikely(Z_TYPE_P(operator_param) != IS_STRING && Z_TYPE_P(operator_param) != IS_NULL)) { + zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'operator' must be a string") TSRMLS_CC); + RETURN_MM_NULL(); + } + + if (likely(Z_TYPE_P(operator_param) == IS_STRING)) { + zephir_get_strval(operator, operator_param); + } else { + ZEPHIR_INIT_VAR(operator); + ZVAL_EMPTY_STRING(operator); + } + } ZEPHIR_INIT_VAR(conditions); @@ -87794,7 +88241,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { zephir_check_call_status(); ZEPHIR_INIT_VAR(bind); array_init(bind); - zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 732); + zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 731); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -87807,7 +88254,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } if (_6) { ZEPHIR_OBS_NVAR(attribute); - zephir_array_fetch(&attribute, columnMap, field, PH_NOISY, "phalcon/mvc/model/criteria.zep", 709 TSRMLS_CC); + zephir_array_fetch(&attribute, columnMap, field, PH_NOISY, "phalcon/mvc/model/criteria.zep", 708 TSRMLS_CC); } else { ZEPHIR_CPY_WRT(attribute, field); } @@ -87821,7 +88268,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { if (ZEPHIR_IS_LONG(type, 2)) { ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] LIKE :", field, ":"); - zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 721); + zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 720); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, "%", value, "%"); zephir_array_update_zval(&bind, field, &_9, PH_COPY | PH_SEPARATE); @@ -87829,7 +88276,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] = :", field, ":"); - zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 728); + zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 727); zephir_array_update_zval(&bind, field, &value, PH_COPY | PH_SEPARATE); } } @@ -87843,13 +88290,15 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } if (zephir_fast_count_int(conditions TSRMLS_CC)) { ZEPHIR_INIT_NVAR(_0); - zephir_fast_join_str(_0, SL(" AND "), conditions TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 313, _0); + ZEPHIR_INIT_VAR(_10); + ZEPHIR_CONCAT_SVS(_10, " ", operator, " "); + zephir_fast_join(_0, _10, conditions TSRMLS_CC); + ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 306, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 314, bind); + ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 307, bind); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, modelName); + ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 303, modelName); zephir_check_call_status(); RETURN_CCTOR(criteria); @@ -87866,7 +88315,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, execute) { ZEPHIR_CALL_METHOD(&model, this_ptr, "getmodelname", NULL, 0); zephir_check_call_status(); if (Z_TYPE_P(model) != IS_STRING) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 756); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 755); return; } ZEPHIR_CALL_METHOD(&_0, this_ptr, "getparams", NULL, 0); @@ -87940,8 +88389,6 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, getOrder); ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, getParams); -ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, fromInput); - ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, execute); @@ -88871,7 +89318,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasOne) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 1); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _1, referencedModel, fields, referencedFields, options); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -88948,7 +89395,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addBelongsTo) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 0); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _1, referencedModel, fields, referencedFields, options); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -89026,7 +89473,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasMany) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, 2); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _0, referencedModel, fields, referencedFields, options); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -89123,9 +89570,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasManyToMany) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, 4); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _0, referencedModel, fields, referencedFields, options); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 316, intermediateFields, intermediateModel, intermediateReferencedFields); + ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 309, intermediateFields, intermediateModel, intermediateReferencedFields); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -89423,7 +89870,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { ZEPHIR_INIT_VAR(findParams); array_init(findParams); if (Z_TYPE_P(findParamsOne) == IS_ARRAY) { - zephir_is_iterable(findParamsOne, &_3, &_2, 0, 0, "phalcon/mvc/model/manager.zep", 1140); + zephir_is_iterable(findParamsOne, &_3, &_2, 0, 0, "phalcon/mvc/model/manager.zep", 1137); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -89436,12 +89883,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } if (_5) { if (!(zephir_array_isset_long(findParams, 0))) { - zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1131); + zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1128); } else { - zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1133 TSRMLS_CC); + zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1130 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSV(_1, "(", _6, ") AND ", value); - zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1133); + zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1130); } continue; } @@ -89455,7 +89902,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } } if (Z_TYPE_P(findParamsTwo) == IS_ARRAY) { - zephir_is_iterable(findParamsTwo, &_8, &_7, 0, 0, "phalcon/mvc/model/manager.zep", 1174); + zephir_is_iterable(findParamsTwo, &_8, &_7, 0, 0, "phalcon/mvc/model/manager.zep", 1171); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) @@ -89468,12 +89915,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } if (_5) { if (!(zephir_array_isset_long(findParams, 0))) { - zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1152); + zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1149); } else { - zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1154 TSRMLS_CC); + zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1151 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSV(_1, "(", _6, ") AND ", value); - zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1154); + zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1151); } continue; } @@ -89489,7 +89936,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } else { if (Z_TYPE_P(value) == IS_ARRAY) { ZEPHIR_INIT_NVAR(_11); - zephir_array_fetch(&_6, findParams, key, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1166 TSRMLS_CC); + zephir_array_fetch(&_6, findParams, key, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1163 TSRMLS_CC); zephir_fast_array_merge(_11, &(_6), &(value) TSRMLS_CC); zephir_array_update_zval(&findParams, key, &_11, PH_COPY | PH_SEPARATE); } @@ -89501,12 +89948,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } else { if (Z_TYPE_P(findParamsTwo) == IS_STRING) { if (!(zephir_array_isset_long(findParams, 0))) { - zephir_array_update_long(&findParams, 0, &findParamsTwo, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1177); + zephir_array_update_long(&findParams, 0, &findParamsTwo, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1174); } else { - zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1179 TSRMLS_CC); + zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1176 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSV(_1, "(", _6, ") AND ", findParamsTwo); - zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1179); + zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1176); } } } @@ -89564,12 +90011,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { if (Z_TYPE_P(fields) != IS_ARRAY) { ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVSVS(_1, "[", intermediateModel, "].[", intermediateFields, "] = :APR0:"); - zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1230); + zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1227); ZEPHIR_CALL_METHOD(&_2, record, "readattribute", NULL, 0, fields); zephir_check_call_status(); zephir_array_update_string(&placeholders, SL("APR0"), &_2, PH_COPY | PH_SEPARATE); } else { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1233); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1230); return; } ZEPHIR_INIT_VAR(joinConditions); @@ -89581,12 +90028,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSVSVSVS(_1, "[", intermediateModel, "].[", intermediateFields, "] = [", referencedModel, "].[", _2, "]"); - zephir_array_append(&joinConditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1243); + zephir_array_append(&joinConditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1240); } else { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1245); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1242); return; } - ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 317, extraParameters, parameters); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 310, extraParameters, parameters); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&builder, this_ptr, "createbuilder", NULL, 0, _2); zephir_check_call_status(); @@ -89615,7 +90062,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "[", _6, "] = :APR0:"); - zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1272); + zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1269); ZEPHIR_CALL_METHOD(&_7, record, "readattribute", NULL, 0, fields); zephir_check_call_status(); zephir_array_update_string(&placeholders, SL("APR0"), &_7, PH_COPY | PH_SEPARATE); @@ -89624,17 +90071,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_6, relation, "getreferencedfields", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_6, &_9, &_8, 0, 0, "phalcon/mvc/model/manager.zep", 1284); + zephir_is_iterable(_6, &_9, &_8, 0, 0, "phalcon/mvc/model/manager.zep", 1281); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) ) { ZEPHIR_GET_HMKEY(refPosition, _9, _8); ZEPHIR_GET_HVALUE(field, _10); - zephir_array_fetch(&_11, referencedFields, refPosition, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1281 TSRMLS_CC); + zephir_array_fetch(&_11, referencedFields, refPosition, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1278 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SVSVS(_12, "[", _11, "] = :APR", refPosition, ":"); - zephir_array_append(&conditions, _12, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1281); + zephir_array_append(&conditions, _12, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1278); ZEPHIR_CALL_METHOD(&_7, record, "readattribute", &_13, 0, field); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); @@ -89651,10 +90098,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { ZEPHIR_CALL_METHOD(&_2, record, "getdi", NULL, 0); zephir_check_call_status(); zephir_array_update_string(&findParams, SL("di"), &_2, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 317, findParams, parameters); + ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 310, findParams, parameters); zephir_check_call_status(); if (Z_TYPE_P(extraParameters) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 317, findArguments, extraParameters); + ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 310, findArguments, extraParameters); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(findParams, findArguments); @@ -89673,7 +90120,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { ZVAL_STRING(retrieveMethod, "find", 1); break; } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown relation type", "phalcon/mvc/model/manager.zep", 1320); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown relation type", "phalcon/mvc/model/manager.zep", 1317); return; } while(0); @@ -89849,8 +90296,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getBelongsToRecords) { RETURN_MM_BOOL(0); } ZEPHIR_OBS_VAR(relations); - zephir_array_fetch(&relations, belongsTo, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1407 TSRMLS_CC); - zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1408 TSRMLS_CC); + zephir_array_fetch(&relations, belongsTo, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1404 TSRMLS_CC); + zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1405 TSRMLS_CC); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getrelationrecords", NULL, 0, _2, method, record, parameters); zephir_check_call_status(); RETURN_MM(); @@ -89908,8 +90355,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getHasManyRecords) { RETURN_MM_BOOL(0); } ZEPHIR_OBS_VAR(relations); - zephir_array_fetch(&relations, hasMany, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1437 TSRMLS_CC); - zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1438 TSRMLS_CC); + zephir_array_fetch(&relations, hasMany, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1434 TSRMLS_CC); + zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1435 TSRMLS_CC); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getrelationrecords", NULL, 0, _2, method, record, parameters); zephir_check_call_status(); RETURN_MM(); @@ -89967,8 +90414,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getHasOneRecords) { RETURN_MM_BOOL(0); } ZEPHIR_OBS_VAR(relations); - zephir_array_fetch(&relations, hasOne, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1467 TSRMLS_CC); - zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1468 TSRMLS_CC); + zephir_array_fetch(&relations, hasOne, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1464 TSRMLS_CC); + zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1465 TSRMLS_CC); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getrelationrecords", NULL, 0, _2, method, record, parameters); zephir_check_call_status(); RETURN_MM(); @@ -90115,13 +90562,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelations) { if (Z_TYPE_P(belongsTo) == IS_ARRAY) { ZEPHIR_OBS_VAR(relations); if (zephir_array_isset_fetch(&relations, belongsTo, entityName, 0 TSRMLS_CC)) { - zephir_is_iterable(relations, &_1, &_0, 0, 0, "phalcon/mvc/model/manager.zep", 1567); + zephir_is_iterable(relations, &_1, &_0, 0, 0, "phalcon/mvc/model/manager.zep", 1564); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(relation, _2); - zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1565); + zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1562); } } } @@ -90129,13 +90576,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelations) { if (Z_TYPE_P(hasMany) == IS_ARRAY) { ZEPHIR_OBS_NVAR(relations); if (zephir_array_isset_fetch(&relations, hasMany, entityName, 0 TSRMLS_CC)) { - zephir_is_iterable(relations, &_4, &_3, 0, 0, "phalcon/mvc/model/manager.zep", 1579); + zephir_is_iterable(relations, &_4, &_3, 0, 0, "phalcon/mvc/model/manager.zep", 1576); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) ) { ZEPHIR_GET_HVALUE(relation, _5); - zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1577); + zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1574); } } } @@ -90143,13 +90590,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelations) { if (Z_TYPE_P(hasOne) == IS_ARRAY) { ZEPHIR_OBS_NVAR(relations); if (zephir_array_isset_fetch(&relations, hasOne, entityName, 0 TSRMLS_CC)) { - zephir_is_iterable(relations, &_7, &_6, 0, 0, "phalcon/mvc/model/manager.zep", 1591); + zephir_is_iterable(relations, &_7, &_6, 0, 0, "phalcon/mvc/model/manager.zep", 1588); for ( ; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS ; zephir_hash_move_forward_ex(_7, &_6) ) { ZEPHIR_GET_HVALUE(relation, _8); - zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1589); + zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1586); } } } @@ -90246,7 +90693,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, createQuery) { ZEPHIR_OBS_VAR(dependencyInjector); zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1648); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1645); return; } ZEPHIR_INIT_VAR(_1); @@ -90296,7 +90743,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, executeQuery) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _0); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1668); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1665); return; } ZEPHIR_INIT_VAR(_2); @@ -90341,7 +90788,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, createBuilder) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _0); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1700); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1697); return; } ZEPHIR_INIT_VAR(_2); @@ -90414,7 +90861,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getNamespaceAlias) { ZEPHIR_CONCAT_SVS(_2, "Namespace alias '", alias, "' is not registered"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/manager.zep", 1735 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/manager.zep", 1732 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -91684,7 +92131,7 @@ static void phalcon_orm_singlequotes(zval *return_value, zval *str TSRMLS_DC) { if (Z_TYPE_P(str) != IS_STRING) { RETURN_ZVAL(str, 1, 0); - } + } marker = Z_STRVAL_P(str); @@ -91709,10 +92156,10 @@ static void phalcon_orm_singlequotes(zval *return_value, zval *str TSRMLS_DC) { if (escaped_str.len) { RETURN_STRINGL(escaped_str.c, escaped_str.len, 0); - } else { - smart_str_free(&escaped_str); - RETURN_EMPTY_STRING(); } + + smart_str_free(&escaped_str); + RETURN_EMPTY_STRING(); } @@ -91770,6 +92217,8 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_Query) { zend_declare_property_null(phalcon_mvc_model_query_ce, SL("_bindTypes"), ZEND_ACC_PROTECTED TSRMLS_CC); + zend_declare_property_null(phalcon_mvc_model_query_ce, SL("_enableImplicitJoins"), ZEND_ACC_PROTECTED TSRMLS_CC); + zend_declare_property_null(phalcon_mvc_model_query_ce, SL("_irPhqlCache"), ZEND_ACC_STATIC|ZEND_ACC_PROTECTED TSRMLS_CC); zend_declare_class_constant_long(phalcon_mvc_model_query_ce, SL("TYPE_SELECT"), 309 TSRMLS_CC); @@ -91788,11 +92237,12 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_Query) { static PHP_METHOD(Phalcon_Mvc_Model_Query, __construct) { + zend_bool _0; int ZEPHIR_LAST_CALL_STATUS; - zval *phql = NULL, *dependencyInjector = NULL; + zval *phql = NULL, *dependencyInjector = NULL, *options = NULL, *enableImplicitJoins; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 0, 2, &phql, &dependencyInjector); + zephir_fetch_params(1, 0, 3, &phql, &dependencyInjector, &options); if (!phql) { phql = ZEPHIR_GLOBAL(global_null); @@ -91800,6 +92250,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, __construct) { if (!dependencyInjector) { dependencyInjector = ZEPHIR_GLOBAL(global_null); } + if (!options) { + options = ZEPHIR_GLOBAL(global_null); + } if (Z_TYPE_P(phql) != IS_NULL) { @@ -91809,6 +92262,16 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, __construct) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdi", NULL, 0, dependencyInjector); zephir_check_call_status(); } + _0 = Z_TYPE_P(options) == IS_ARRAY; + if (_0) { + ZEPHIR_OBS_VAR(enableImplicitJoins); + _0 = zephir_array_isset_string_fetch(&enableImplicitJoins, options, SS("enable_implicit_joins"), 0 TSRMLS_CC); + } + if (_0) { + zephir_update_property_this(this_ptr, SL("_enableImplicitJoins"), (ZEPHIR_IS_TRUE(enableImplicitJoins)) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); + } else { + zephir_update_property_this(this_ptr, SL("_enableImplicitJoins"), (ZEPHIR_GLOBAL(orm).enable_implicit_joins) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); + } ZEPHIR_MM_RESTORE(); } @@ -91829,7 +92292,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, setDI) { zephir_check_temp_parameter(_0); zephir_check_call_status(); if (Z_TYPE_P(manager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsManager' is invalid", "phalcon/mvc/model/query.zep", 137); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsManager' is invalid", "phalcon/mvc/model/query.zep", 147); return; } ZEPHIR_INIT_NVAR(_0); @@ -91838,7 +92301,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, setDI) { zephir_check_temp_parameter(_0); zephir_check_call_status(); if (Z_TYPE_P(metaData) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsMetaData' is invalid", "phalcon/mvc/model/query.zep", 142); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsMetaData' is invalid", "phalcon/mvc/model/query.zep", 152); return; } zephir_update_property_this(this_ptr, SL("_manager"), manager TSRMLS_CC); @@ -91894,7 +92357,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_OBS_VAR(columnName); - zephir_array_fetch_string(&columnName, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 186 TSRMLS_CC); + zephir_array_fetch_string(&columnName, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 196 TSRMLS_CC); ZEPHIR_OBS_VAR(sqlColumnAliases); zephir_read_property_this(&sqlColumnAliases, this_ptr, SL("_sqlColumnAliases"), PH_NOISY_CC); if (zephir_array_isset(sqlColumnAliases, columnName)) { @@ -91918,7 +92381,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Unknown model or alias '", columnDomain, "' (11), when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 212 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 222 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -91934,7 +92397,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "There is no model related to model or alias '", columnDomain, "', when executing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 229 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 239 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -91954,7 +92417,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSVSV(_2, "Column '", columnName, "' doesn't belong to the model or alias '", columnDomain, "', when executing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 239 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 249 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -91966,7 +92429,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_INIT_VAR(hasModel); ZVAL_BOOL(hasModel, 0); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); - zephir_is_iterable(_1, &_4, &_3, 0, 0, "phalcon/mvc/model/query.zep", 269); + zephir_is_iterable(_1, &_4, &_3, 0, 0, "phalcon/mvc/model/query.zep", 279); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -91984,7 +92447,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "The column '", columnName, "' is ambiguous, when preparing: ", _8); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 260 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 270 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -91999,14 +92462,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Column '", columnName, "' doesn't belong to any of the selected models (1), when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 270 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 280 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_VAR(models); zephir_read_property_this(&models, this_ptr, SL("_models"), PH_NOISY_CC); if (Z_TYPE_P(models) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The models list was not loaded correctly", "phalcon/mvc/model/query.zep", 278); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The models list was not loaded correctly", "phalcon/mvc/model/query.zep", 288); return; } ZEPHIR_INIT_VAR(className); @@ -92020,7 +92483,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Can't obtain model's source from models list: '", className, "', when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 286 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 296 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -92041,7 +92504,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Column '", columnName, "' doesn't belong to any of the selected models (3), when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 303 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 313 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -92071,13 +92534,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCallArgument) { - zephir_array_fetch_string(&_0, argument, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 326 TSRMLS_CC); + zephir_array_fetch_string(&_0, argument, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 336 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 352)) { zephir_create_array(return_value, 1, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("all"), 1); RETURN_MM(); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 323, argument); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 316, argument); zephir_check_call_status(); RETURN_MM(); @@ -92101,8 +92564,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) { ZEPHIR_INIT_VAR(whenClauses); array_init(whenClauses); - zephir_array_fetch_string(&_0, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 340 TSRMLS_CC); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 355); + zephir_array_fetch_string(&_0, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 350 TSRMLS_CC); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 365); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -92112,30 +92575,30 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) { ZEPHIR_INIT_NVAR(_4); zephir_create_array(_4, 3, 0 TSRMLS_CC); add_assoc_stringl_ex(_4, SS("type"), SL("when"), 1); - zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 344 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6); + zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 354 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _6); zephir_check_call_status(); zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE); - zephir_array_fetch_string(&_8, whenExpr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 345 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _8); + zephir_array_fetch_string(&_8, whenExpr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 355 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _8); zephir_check_call_status(); zephir_array_update_string(&_4, SL("then"), &_5, PH_COPY | PH_SEPARATE); - zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 346); + zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 356); } else { ZEPHIR_INIT_NVAR(_4); zephir_create_array(_4, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(_4, SS("type"), SL("else"), 1); - zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 350 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6); + zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 360 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _6); zephir_check_call_status(); zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE); - zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 351); + zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 361); } } zephir_create_array(return_value, 3, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("case"), 1); - zephir_array_fetch_string(&_6, expr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 357 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6); + zephir_array_fetch_string(&_6, expr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 367 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _6); zephir_check_call_status(); zephir_array_update_string(&return_value, SL("expr"), &_5, PH_COPY | PH_SEPARATE); zephir_array_update_string(&return_value, SL("when-clauses"), &whenClauses, PH_COPY | PH_SEPARATE); @@ -92169,19 +92632,19 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { ZEPHIR_INIT_VAR(functionArgs); if (zephir_array_isset_long(arguments, 0)) { array_init(functionArgs); - zephir_is_iterable(arguments, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 383); + zephir_is_iterable(arguments, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 393); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(argument, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, argument); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 317, argument); zephir_check_call_status(); - zephir_array_append(&functionArgs, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 381); + zephir_array_append(&functionArgs, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 391); } } else { zephir_create_array(functionArgs, 1, 0 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, arguments); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 317, arguments); zephir_check_call_status(); zephir_array_fast_append(functionArgs, _3); } @@ -92189,7 +92652,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { zephir_create_array(return_value, 4, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("functionCall"), 1); ZEPHIR_OBS_VAR(_5); - zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 391 TSRMLS_CC); + zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 401 TSRMLS_CC); zephir_array_update_string(&return_value, SL("name"), &_5, PH_COPY | PH_SEPARATE); zephir_array_update_string(&return_value, SL("arguments"), &functionArgs, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_6); @@ -92200,7 +92663,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { zephir_create_array(return_value, 3, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("functionCall"), 1); ZEPHIR_OBS_NVAR(_5); - zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 398 TSRMLS_CC); + zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 408 TSRMLS_CC); zephir_array_update_string(&return_value, SL("name"), &_5, PH_COPY | PH_SEPARATE); zephir_array_update_string(&return_value, SL("arguments"), &functionArgs, PH_COPY | PH_SEPARATE); RETURN_MM(); @@ -92209,7 +92672,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { zephir_create_array(return_value, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("functionCall"), 1); ZEPHIR_OBS_NVAR(_5); - zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 407 TSRMLS_CC); + zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 417 TSRMLS_CC); zephir_array_update_string(&return_value, SL("name"), &_5, PH_COPY | PH_SEPARATE); RETURN_MM(); @@ -92244,12 +92707,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { if (!ZEPHIR_IS_LONG(exprType, 409)) { ZEPHIR_OBS_VAR(exprLeft); if (zephir_array_isset_string_fetch(&exprLeft, expr, SS("left"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 323, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 316, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } ZEPHIR_OBS_VAR(exprRight); if (zephir_array_isset_string_fetch(&exprRight, expr, SS("right"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 323, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 316, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } } @@ -92327,7 +92790,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { break; } if (ZEPHIR_IS_LONG(exprType, 355)) { - ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 325, expr); + ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 318, expr); zephir_check_call_status(); break; } @@ -92414,7 +92877,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("literal"), 1); ZEPHIR_OBS_VAR(_2); - zephir_array_fetch_string(&_2, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 525 TSRMLS_CC); + zephir_array_fetch_string(&_2, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 535 TSRMLS_CC); zephir_array_update_string(&exprReturn, SL("value"), &_2, PH_COPY | PH_SEPARATE); break; } @@ -92434,9 +92897,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { } if (ZEPHIR_IS_LONG(exprType, 260)) { ZEPHIR_OBS_VAR(value); - zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 537 TSRMLS_CC); + zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 547 TSRMLS_CC); if (quoting == 1) { - if (zephir_memnstr_str(value, SL("'"), "phalcon/mvc/model/query.zep", 542)) { + if (zephir_memnstr_str(value, SL("'"), "phalcon/mvc/model/query.zep", 552)) { ZEPHIR_INIT_VAR(escapedValue); phalcon_orm_singlequotes(escapedValue, value TSRMLS_CC); } else { @@ -92458,7 +92921,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("placeholder"), 1); ZEPHIR_INIT_VAR(_3); - zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 555 TSRMLS_CC); + zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 565 TSRMLS_CC); ZEPHIR_SINIT_VAR(_5); ZVAL_STRING(&_5, "?", 0); ZEPHIR_SINIT_VAR(_6); @@ -92471,7 +92934,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_INIT_NVAR(exprReturn); zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("placeholder"), 1); - zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 559 TSRMLS_CC); + zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 569 TSRMLS_CC); ZEPHIR_INIT_VAR(_7); ZEPHIR_CONCAT_SV(_7, ":", _4); zephir_array_update_string(&exprReturn, SL("value"), &_7, PH_COPY | PH_SEPARATE); @@ -92479,14 +92942,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { } if (ZEPHIR_IS_LONG(exprType, 277)) { ZEPHIR_OBS_NVAR(value); - zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 563 TSRMLS_CC); - if (zephir_memnstr_str(value, SL(":"), "phalcon/mvc/model/query.zep", 564)) { + zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 573 TSRMLS_CC); + if (zephir_memnstr_str(value, SL(":"), "phalcon/mvc/model/query.zep", 574)) { ZEPHIR_INIT_VAR(valueParts); zephir_fast_explode_str(valueParts, SL(":"), value, LONG_MAX TSRMLS_CC); ZEPHIR_OBS_VAR(name); - zephir_array_fetch_long(&name, valueParts, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 567 TSRMLS_CC); + zephir_array_fetch_long(&name, valueParts, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 577 TSRMLS_CC); ZEPHIR_OBS_VAR(bindType); - zephir_array_fetch_long(&bindType, valueParts, 1, PH_NOISY, "phalcon/mvc/model/query.zep", 568 TSRMLS_CC); + zephir_array_fetch_long(&bindType, valueParts, 1, PH_NOISY, "phalcon/mvc/model/query.zep", 578 TSRMLS_CC); do { if (ZEPHIR_IS_STRING(bindType, "str")) { ZEPHIR_INIT_NVAR(_3); @@ -92570,7 +93033,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_7, "Bind value is required for array type placeholder: ", name); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 607 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 617 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -92581,7 +93044,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_10, "Bind type requires an array in placeholder: ", name); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 611 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 621 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -92592,7 +93055,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_10, "At least one value must be bound in placeholder: ", name); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 615 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 625 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -92612,7 +93075,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_10, "Unknown bind type: ", bindType); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 627 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 637 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -92767,17 +93230,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("literal"), 1); ZEPHIR_OBS_NVAR(_2); - zephir_array_fetch_string(&_2, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 700 TSRMLS_CC); + zephir_array_fetch_string(&_2, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 710 TSRMLS_CC); zephir_array_update_string(&exprReturn, SL("value"), &_2, PH_COPY | PH_SEPARATE); break; } if (ZEPHIR_IS_LONG(exprType, 350)) { - ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 326, expr); + ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 319, expr); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(exprType, 409)) { - ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 327, expr); + ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 320, expr); zephir_check_call_status(); break; } @@ -92787,7 +93250,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { add_assoc_stringl_ex(exprReturn, SS("type"), SL("select"), 1); ZEPHIR_INIT_NVAR(_3); ZVAL_BOOL(_3, 1); - ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 328, expr, _3); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 321, expr, _3); zephir_check_call_status(); zephir_array_update_string(&exprReturn, SL("value"), &_12, PH_COPY | PH_SEPARATE); break; @@ -92798,7 +93261,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_7, "Unknown expression type ", exprType); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 716 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 726 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -92806,29 +93269,29 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { RETURN_CCTOR(exprReturn); } if (zephir_array_isset_string(expr, SS("domain"))) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 325, expr); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 318, expr); zephir_check_call_status(); RETURN_MM(); } if (zephir_array_isset_long(expr, 0)) { ZEPHIR_INIT_VAR(listItems); array_init(listItems); - zephir_is_iterable(expr, &_14, &_13, 0, 0, "phalcon/mvc/model/query.zep", 737); + zephir_is_iterable(expr, &_14, &_13, 0, 0, "phalcon/mvc/model/query.zep", 747); for ( ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS ; zephir_hash_move_forward_ex(_14, &_13) ) { ZEPHIR_GET_HVALUE(exprListItem, _15); - ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 323, exprListItem); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 316, exprListItem); zephir_check_call_status(); - zephir_array_append(&listItems, _12, PH_SEPARATE, "phalcon/mvc/model/query.zep", 735); + zephir_array_append(&listItems, _12, PH_SEPARATE, "phalcon/mvc/model/query.zep", 745); } zephir_create_array(return_value, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("list"), 1); zephir_array_fast_append(return_value, listItems); RETURN_MM(); } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown expression", "phalcon/mvc/model/query.zep", 740); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown expression", "phalcon/mvc/model/query.zep", 750); return; } @@ -92836,10 +93299,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSelectColumn) { int ZEPHIR_LAST_CALL_STATUS; + zephir_fcall_cache_entry *_5 = NULL; HashTable *_2; HashPosition _1; - zval *column_param = NULL, *sqlColumns, *columnType, *sqlAliases, *modelName = NULL, *source = NULL, *columnDomain, *sqlColumnAlias = NULL, *preparedAlias = NULL, *sqlExprColumn = NULL, *sqlAliasesModels, *sqlColumn, *columnData, *balias, *_0, **_3, *_5 = NULL, *_6 = NULL; - zval *column = NULL, *_4 = NULL; + zval *column_param = NULL, *sqlColumns, *columnType, *sqlAliases, *modelName = NULL, *source = NULL, *columnDomain, *sqlColumnAlias = NULL, *preparedAlias = NULL, *sqlExprColumn = NULL, *sqlAliasesModels, *sqlColumn = NULL, *columnData, *balias, *eager, *_0, **_3, *_4 = NULL, *_6, *_7 = NULL, *_8 = NULL, *_9; + zval *column = NULL; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 1, 0, &column_param); @@ -92850,95 +93314,119 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSelectColumn) { ZEPHIR_OBS_VAR(columnType); if (!(zephir_array_isset_string_fetch(&columnType, column, SS("type"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 757); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 764); return; } ZEPHIR_INIT_VAR(sqlColumns); array_init(sqlColumns); + ZEPHIR_OBS_VAR(eager); + zephir_array_isset_string_fetch(&eager, column, SS("eager"), 0 TSRMLS_CC); if (ZEPHIR_IS_LONG(columnType, 352)) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_models"), PH_NOISY_CC); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 773); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 794); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) ) { ZEPHIR_GET_HMKEY(modelName, _2, _1); ZEPHIR_GET_HVALUE(source, _3); - ZEPHIR_INIT_NVAR(_4); - zephir_create_array(_4, 3, 0 TSRMLS_CC); - add_assoc_stringl_ex(_4, SS("type"), SL("object"), 1); - zephir_array_update_string(&_4, SL("model"), &modelName, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_4, SL("column"), &source, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 771); + ZEPHIR_INIT_NVAR(sqlColumn); + zephir_create_array(sqlColumn, 4, 0 TSRMLS_CC); + add_assoc_stringl_ex(sqlColumn, SS("type"), SL("object"), 1); + zephir_array_update_string(&sqlColumn, SL("model"), &modelName, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlColumn, SL("column"), &source, PH_COPY | PH_SEPARATE); + ZEPHIR_CALL_FUNCTION(&_4, "lcfirst", &_5, 67, modelName); + zephir_check_call_status(); + zephir_array_update_string(&sqlColumn, SL("balias"), &_4, PH_COPY | PH_SEPARATE); + if (Z_TYPE_P(eager) != IS_NULL) { + zephir_array_update_string(&sqlColumn, SL("eager"), &eager, PH_COPY | PH_SEPARATE); + zephir_array_fetch_string(&_6, column, SL("eagerType"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 789 TSRMLS_CC); + zephir_array_update_string(&sqlColumn, SL("eagerType"), &_6, PH_COPY | PH_SEPARATE); + } + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 792); } RETURN_CCTOR(sqlColumns); } if (!(zephir_array_isset_string(column, SS("column")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 777); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 798); return; } if (ZEPHIR_IS_LONG(columnType, 353)) { ZEPHIR_OBS_VAR(sqlAliases); zephir_read_property_this(&sqlAliases, this_ptr, SL("_sqlAliases"), PH_NOISY_CC); ZEPHIR_OBS_VAR(columnDomain); - zephir_array_fetch_string(&columnDomain, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 790 TSRMLS_CC); + zephir_array_fetch_string(&columnDomain, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 811 TSRMLS_CC); ZEPHIR_OBS_VAR(source); if (!(zephir_array_isset_fetch(&source, sqlAliases, columnDomain, 0 TSRMLS_CC))) { - ZEPHIR_INIT_VAR(_5); - object_init_ex(_5, phalcon_mvc_model_exception_ce); + ZEPHIR_INIT_VAR(_7); + object_init_ex(_7, phalcon_mvc_model_exception_ce); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_6); - ZEPHIR_CONCAT_SVSV(_6, "Unknown model or alias '", columnDomain, "' (2), when preparing: ", _0); - ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 9, _6); + ZEPHIR_INIT_VAR(_8); + ZEPHIR_CONCAT_SVSV(_8, "Unknown model or alias '", columnDomain, "' (2), when preparing: ", _0); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", NULL, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 793 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 814 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_CPY_WRT(sqlColumnAlias, source); + ZEPHIR_OBS_VAR(preparedAlias); + zephir_array_isset_string_fetch(&preparedAlias, column, SS("balias"), 0 TSRMLS_CC); ZEPHIR_OBS_VAR(sqlAliasesModels); zephir_read_property_this(&sqlAliasesModels, this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch(&modelName, sqlAliasesModels, columnDomain, PH_NOISY, "phalcon/mvc/model/query.zep", 805 TSRMLS_CC); - if (ZEPHIR_IS_EQUAL(columnDomain, modelName)) { - ZEPHIR_CALL_FUNCTION(&preparedAlias, "lcfirst", NULL, 65, modelName); - zephir_check_call_status(); - } else { - ZEPHIR_CPY_WRT(preparedAlias, columnDomain); + zephir_array_fetch(&modelName, sqlAliasesModels, columnDomain, PH_NOISY, "phalcon/mvc/model/query.zep", 828 TSRMLS_CC); + if (Z_TYPE_P(preparedAlias) != IS_STRING) { + if (ZEPHIR_IS_EQUAL(columnDomain, modelName)) { + ZEPHIR_CALL_FUNCTION(&preparedAlias, "lcfirst", &_5, 67, modelName); + zephir_check_call_status(); + } else { + ZEPHIR_CPY_WRT(preparedAlias, columnDomain); + } } - ZEPHIR_INIT_NVAR(_4); - zephir_create_array(_4, 4, 0 TSRMLS_CC); - add_assoc_stringl_ex(_4, SS("type"), SL("object"), 1); - zephir_array_update_string(&_4, SL("model"), &modelName, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_4, SL("column"), &sqlColumnAlias, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_4, SL("balias"), &preparedAlias, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 824); + ZEPHIR_INIT_NVAR(sqlColumn); + zephir_create_array(sqlColumn, 4, 0 TSRMLS_CC); + add_assoc_stringl_ex(sqlColumn, SS("type"), SL("object"), 1); + zephir_array_update_string(&sqlColumn, SL("model"), &modelName, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlColumn, SL("column"), &sqlColumnAlias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlColumn, SL("balias"), &preparedAlias, PH_COPY | PH_SEPARATE); + if (Z_TYPE_P(eager) != IS_NULL) { + zephir_array_update_string(&sqlColumn, SL("eager"), &eager, PH_COPY | PH_SEPARATE); + zephir_array_fetch_string(&_6, column, SL("eagerType"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 854 TSRMLS_CC); + zephir_array_update_string(&sqlColumn, SL("eagerType"), &_6, PH_COPY | PH_SEPARATE); + } + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 857); RETURN_CCTOR(sqlColumns); } if (ZEPHIR_IS_LONG(columnType, 354)) { - ZEPHIR_INIT_VAR(sqlColumn); + ZEPHIR_INIT_NVAR(sqlColumn); zephir_create_array(sqlColumn, 1, 0 TSRMLS_CC); add_assoc_stringl_ex(sqlColumn, SS("type"), SL("scalar"), 1); ZEPHIR_OBS_VAR(columnData); - zephir_array_fetch_string(&columnData, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 838 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 323, columnData); + zephir_array_fetch_string(&columnData, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 871 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 316, columnData); zephir_check_call_status(); ZEPHIR_OBS_VAR(balias); if (zephir_array_isset_string_fetch(&balias, sqlExprColumn, SS("balias"), 0 TSRMLS_CC)) { zephir_array_update_string(&sqlColumn, SL("balias"), &balias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&sqlColumn, SL("sqlAlias"), &balias, PH_COPY | PH_SEPARATE); } + if (Z_TYPE_P(eager) != IS_NULL) { + zephir_array_update_string(&sqlColumn, SL("eager"), &eager, PH_COPY | PH_SEPARATE); + zephir_array_fetch_string(&_9, column, SL("eagerType"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 884 TSRMLS_CC); + zephir_array_update_string(&sqlColumn, SL("eagerType"), &_9, PH_COPY | PH_SEPARATE); + } zephir_array_update_string(&sqlColumn, SL("column"), &sqlExprColumn, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 850); + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 888); RETURN_CCTOR(sqlColumns); } - ZEPHIR_INIT_NVAR(_5); - object_init_ex(_5, phalcon_mvc_model_exception_ce); - ZEPHIR_INIT_LNVAR(_6); - ZEPHIR_CONCAT_SV(_6, "Unknown type of column ", columnType); - ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 9, _6); + ZEPHIR_INIT_NVAR(_7); + object_init_ex(_7, phalcon_mvc_model_exception_ce); + ZEPHIR_INIT_LNVAR(_8); + ZEPHIR_CONCAT_SV(_8, "Unknown type of column ", columnType); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", NULL, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 855 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 893 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -92956,7 +93444,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getTable) { ZEPHIR_OBS_VAR(modelName); if (!(zephir_array_isset_string_fetch(&modelName, qualifiedName, SS("name"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 870); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 908); return; } ZEPHIR_CALL_METHOD(&model, manager, "load", NULL, 0, modelName); @@ -92987,17 +93475,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoin) { ZEPHIR_OBS_VAR(qualified); if (zephir_array_isset_string_fetch(&qualified, join, SS("qualified"), 0 TSRMLS_CC)) { - zephir_array_fetch_string(&_0, qualified, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 897 TSRMLS_CC); + zephir_array_fetch_string(&_0, qualified, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 932 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 355)) { ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_string(&modelName, qualified, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 899 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 901)) { + zephir_array_fetch_string(&modelName, qualified, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 934 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 936)) { ZEPHIR_INIT_VAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_2, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 903 TSRMLS_CC); + zephir_array_fetch_long(&_2, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 938 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_1, manager, "getnamespacealias", NULL, 0, _2); zephir_check_call_status(); - zephir_array_fetch_long(&_3, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 903 TSRMLS_CC); + zephir_array_fetch_long(&_3, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 938 TSRMLS_CC); ZEPHIR_INIT_VAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _1, "\\", _3); } else { @@ -93019,7 +93507,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoin) { RETURN_MM(); } } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 921); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 956); return; } @@ -93036,7 +93524,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoinType) { ZEPHIR_OBS_VAR(type); if (!(zephir_array_isset_string_fetch(&type, join, SS("type"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 935); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 970); return; } do { @@ -93064,7 +93552,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoinType) { ZEPHIR_CONCAT_SVSV(_2, "Unknown join type ", type, ", when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 956 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 991 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -93114,7 +93602,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_long_ex(_2, SS("type"), 355); zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_2, SL("name"), &fields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _2); zephir_check_call_status(); zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_4); @@ -93122,14 +93610,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _4); zephir_check_call_status(); zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE); zephir_array_fast_append(sqlJoinConditions, _0); } else { ZEPHIR_INIT_VAR(sqlJoinPartialConditions); array_init(sqlJoinPartialConditions); - zephir_is_iterable(fields, &_6, &_5, 0, 0, "phalcon/mvc/model/query.zep", 1044); + zephir_is_iterable(fields, &_6, &_5, 0, 0, "phalcon/mvc/model/query.zep", 1079); for ( ; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS ; zephir_hash_move_forward_ex(_6, &_5) @@ -93145,7 +93633,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { ZEPHIR_CONCAT_SVSVSV(_10, "The number of fields must be equal to the number of referenced fields in join ", modelAlias, "-", joinAlias, ", when preparing: ", _9); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 1020 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 1055 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -93158,7 +93646,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_long_ex(_2, SS("type"), 355); zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_2, SL("name"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _2); zephir_check_call_status(); zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_NVAR(_4); @@ -93166,10 +93654,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("name"), &referencedField, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _4); zephir_check_call_status(); zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlJoinPartialConditions, _0, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1041); + zephir_array_append(&sqlJoinPartialConditions, _0, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1076); } } zephir_create_array(return_value, 3, 0 TSRMLS_CC); @@ -93219,7 +93707,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { ZEPHIR_CALL_METHOD(&referencedModelName, relation, "getreferencedmodel", NULL, 0); zephir_check_call_status(); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1169); + zephir_is_iterable(fields, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1204); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -93234,12 +93722,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { ZEPHIR_CONCAT_SVSVSV(_5, "The number of fields must be equal to the number of referenced fields in join ", modelAlias, "-", joinAlias, ", when preparing: ", _4); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_6, 9, _5); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 1140 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 1175 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_NVAR(intermediateField); - zephir_array_fetch(&intermediateField, intermediateFields, position, PH_NOISY, "phalcon/mvc/model/query.zep", 1146 TSRMLS_CC); + zephir_array_fetch(&intermediateField, intermediateFields, position, PH_NOISY, "phalcon/mvc/model/query.zep", 1181 TSRMLS_CC); ZEPHIR_INIT_NVAR(sqlEqualsJoinCondition); zephir_create_array(sqlEqualsJoinCondition, 4, 0 TSRMLS_CC); add_assoc_stringl_ex(sqlEqualsJoinCondition, SS("type"), SL("binary-op"), 1); @@ -93249,7 +93737,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_long_ex(_8, SS("type"), 355); zephir_array_update_string(&_8, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_8, SL("name"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _8); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _8); zephir_check_call_status(); zephir_array_update_string(&sqlEqualsJoinCondition, SL("left"), &_7, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_NVAR(_10); @@ -93257,7 +93745,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_stringl_ex(_10, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_10, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_10, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _10); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _10); zephir_check_call_status(); zephir_array_update_string(&sqlEqualsJoinCondition, SL("right"), &_7, PH_COPY | PH_SEPARATE); } @@ -93279,7 +93767,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_long_ex(_12, SS("type"), 355); zephir_array_update_string(&_12, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_12, SL("name"), &fields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _12); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _12); zephir_check_call_status(); zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_13); @@ -93287,7 +93775,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_stringl_ex(_13, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_13, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_13, SL("name"), &intermediateFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _13); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _13); zephir_check_call_status(); zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE); zephir_array_fast_append(_10, _11); @@ -93308,7 +93796,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_long_ex(_14, SS("type"), 355); zephir_array_update_string(&_14, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_14, SL("name"), &intermediateReferencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _14); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _14); zephir_check_call_status(); zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_15); @@ -93316,7 +93804,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_stringl_ex(_15, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_15, SL("domain"), &referencedModelName, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_15, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _15); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _15); zephir_check_call_status(); zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE); zephir_array_fast_append(_10, _11); @@ -93329,12 +93817,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { - zval *_28 = NULL, *_29 = NULL; - zephir_fcall_cache_entry *_3 = NULL, *_4 = NULL, *_8 = NULL, *_13 = NULL, *_20 = NULL, *_21 = NULL, *_23 = NULL, *_24 = NULL; + zval *_17 = NULL, *_18 = NULL, *_40 = NULL; + zephir_fcall_cache_entry *_3 = NULL, *_4 = NULL, *_8 = NULL, *_13 = NULL, *_31 = NULL, *_32 = NULL, *_35 = NULL, *_36 = NULL; int ZEPHIR_LAST_CALL_STATUS; - HashTable *_1, *_10, *_15, *_18, *_26; - HashPosition _0, _9, _14, _17, _25; - zval *select, *models, *sqlAliases, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *modelsInstances, *fromModels = NULL, *sqlJoins, *joinModels, *joinSources, *joinTypes, *joinPreCondition, *joinPrepared, *manager = NULL, *selectJoins = NULL, *joinItem = NULL, *joins, *joinData = NULL, *schema = NULL, *source = NULL, *model = NULL, *realModelName = NULL, *completeSource = NULL, *joinType = NULL, *aliasExpr = NULL, *alias = NULL, *joinAliasName = NULL, *joinExpr = NULL, *fromModelName = NULL, *joinAlias = NULL, *joinModel = NULL, *joinSource = NULL, *preCondition = NULL, *modelNameAlias = NULL, *relation = NULL, *relations = NULL, *modelAlias = NULL, *sqlJoin = NULL, *sqlJoinItem = NULL, **_2, *_5 = NULL, *_6, *_7 = NULL, **_11, *_12 = NULL, **_16, **_19, *_22 = NULL, **_27; + HashTable *_1, *_10, *_15, *_20, *_26, *_29, *_38; + HashPosition _0, _9, _14, _19, _25, _28, _37; + zval *select, *models, *sqlAliases, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *modelsInstances, *fromModels = NULL, *sqlJoins, *joinModels, *joinSources, *joinTypes, *joinPreCondition, *joinPrepared, *manager, *selectJoins = NULL, *joinItem = NULL, *joins, *joinData = NULL, *schema = NULL, *source = NULL, *model = NULL, *realModelName = NULL, *completeSource = NULL, *joinType = NULL, *aliasExpr = NULL, *alias = NULL, *joinAliasName = NULL, *joinExpr = NULL, *fromModelName = NULL, *joinAlias = NULL, *joinModel = NULL, *joinSource = NULL, *preCondition = NULL, *modelNameAlias = NULL, *relation = NULL, *relations = NULL, *modelAlias = NULL, *sqlJoin = NULL, *sqlJoinItem = NULL, *selectTables = NULL, *tables, *tableItem = NULL, **_2, *_5 = NULL, *_6, *_7 = NULL, **_11, *_12 = NULL, **_16, **_21, *_22, *_23 = NULL, *_24 = NULL, **_27, **_30, *_33 = NULL, *_34, **_39; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 1, 0, &select); @@ -93368,8 +93856,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { array_init(joinPrepared); ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tables); + zephir_array_fetch_string(&tables, select, SL("tables"), PH_NOISY, "phalcon/mvc/model/query.zep", 1295 TSRMLS_CC); + if (!(zephir_array_isset_long(tables, 0))) { + ZEPHIR_INIT_VAR(selectTables); + zephir_create_array(selectTables, 1, 0 TSRMLS_CC); + zephir_array_fast_append(selectTables, tables); + } else { + ZEPHIR_CPY_WRT(selectTables, tables); + } ZEPHIR_OBS_VAR(joins); - zephir_array_fetch_string(&joins, select, SL("joins"), PH_NOISY, "phalcon/mvc/model/query.zep", 1260 TSRMLS_CC); + zephir_array_fetch_string(&joins, select, SL("joins"), PH_NOISY, "phalcon/mvc/model/query.zep", 1302 TSRMLS_CC); if (!(zephir_array_isset_long(joins, 0))) { ZEPHIR_INIT_VAR(selectJoins); zephir_create_array(selectJoins, 1, 0 TSRMLS_CC); @@ -93377,32 +93874,32 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { } else { ZEPHIR_CPY_WRT(selectJoins, joins); } - zephir_is_iterable(selectJoins, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1409); + zephir_is_iterable(selectJoins, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1451); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(joinItem, _2); - ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 329, manager, joinItem); + ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 322, manager, joinItem); zephir_check_call_status(); ZEPHIR_OBS_NVAR(source); - zephir_array_fetch_string(&source, joinData, SL("source"), PH_NOISY, "phalcon/mvc/model/query.zep", 1273 TSRMLS_CC); + zephir_array_fetch_string(&source, joinData, SL("source"), PH_NOISY, "phalcon/mvc/model/query.zep", 1315 TSRMLS_CC); ZEPHIR_OBS_NVAR(schema); - zephir_array_fetch_string(&schema, joinData, SL("schema"), PH_NOISY, "phalcon/mvc/model/query.zep", 1274 TSRMLS_CC); + zephir_array_fetch_string(&schema, joinData, SL("schema"), PH_NOISY, "phalcon/mvc/model/query.zep", 1316 TSRMLS_CC); ZEPHIR_OBS_NVAR(model); - zephir_array_fetch_string(&model, joinData, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 1275 TSRMLS_CC); + zephir_array_fetch_string(&model, joinData, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 1317 TSRMLS_CC); ZEPHIR_OBS_NVAR(realModelName); - zephir_array_fetch_string(&realModelName, joinData, SL("modelName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1276 TSRMLS_CC); + zephir_array_fetch_string(&realModelName, joinData, SL("modelName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1318 TSRMLS_CC); ZEPHIR_INIT_NVAR(completeSource); zephir_create_array(completeSource, 2, 0 TSRMLS_CC); zephir_array_fast_append(completeSource, source); zephir_array_fast_append(completeSource, schema); - ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 330, joinItem); + ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 323, joinItem); zephir_check_call_status(); ZEPHIR_OBS_NVAR(aliasExpr); if (zephir_array_isset_string_fetch(&aliasExpr, joinItem, SS("alias"), 0 TSRMLS_CC)) { ZEPHIR_OBS_NVAR(alias); - zephir_array_fetch_string(&alias, aliasExpr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1289 TSRMLS_CC); + zephir_array_fetch_string(&alias, aliasExpr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1331 TSRMLS_CC); if (zephir_array_isset(joinModels, alias)) { ZEPHIR_INIT_NVAR(_5); object_init_ex(_5, phalcon_mvc_model_exception_ce); @@ -93411,11 +93908,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { ZEPHIR_CONCAT_SVSV(_7, "Cannot use '", alias, "' as join alias because it was already used, when preparing: ", _6); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1295 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1337 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1301); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1343); zephir_array_update_zval(&joinTypes, alias, &joinType, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliases, alias, &alias, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&joinModels, alias, &realModelName, PH_COPY | PH_SEPARATE); @@ -93434,7 +93931,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { ZEPHIR_CONCAT_SVSV(_7, "Cannot use '", realModelName, "' as join alias because it was already used, when preparing: ", _6); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1354 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1396 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -93456,7 +93953,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), sqlModelsAliases TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), sqlAliasesModelsInstances TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_modelsInstances"), modelsInstances TSRMLS_CC); - zephir_is_iterable(joinPrepared, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 1429); + zephir_is_iterable(joinPrepared, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 1471); for ( ; zephir_hash_get_current_data_ex(_10, (void**) &_11, &_9) == SUCCESS ; zephir_hash_move_forward_ex(_10, &_9) @@ -93465,102 +93962,141 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { ZEPHIR_GET_HVALUE(joinItem, _11); ZEPHIR_OBS_NVAR(joinExpr); if (zephir_array_isset_string_fetch(&joinExpr, joinItem, SS("conditions"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 323, joinExpr); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 316, joinExpr); zephir_check_call_status(); zephir_array_update_zval(&joinPreCondition, joinAliasName, &_12, PH_COPY | PH_SEPARATE); } } - ZEPHIR_OBS_NVAR(manager); - zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); - ZEPHIR_INIT_NVAR(_5); - zephir_is_iterable(fromModels, &_15, &_14, 0, 0, "phalcon/mvc/model/query.zep", 1537); + _6 = zephir_fetch_nproperty_this(this_ptr, SL("_enableImplicitJoins"), PH_NOISY_CC); + if (!(zephir_is_true(_6))) { + ZEPHIR_INIT_NVAR(_5); + zephir_is_iterable(joinPrepared, &_15, &_14, 0, 0, "phalcon/mvc/model/query.zep", 1482); + for ( + ; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS + ; zephir_hash_move_forward_ex(_15, &_14) + ) { + ZEPHIR_GET_HMKEY(joinAliasName, _15, _14); + ZEPHIR_GET_HVALUE(_5, _16); + ZEPHIR_OBS_NVAR(joinType); + zephir_array_fetch(&joinType, joinTypes, joinAliasName, PH_NOISY, "phalcon/mvc/model/query.zep", 1473 TSRMLS_CC); + ZEPHIR_OBS_NVAR(joinSource); + zephir_array_fetch(&joinSource, joinSources, joinAliasName, PH_NOISY, "phalcon/mvc/model/query.zep", 1474 TSRMLS_CC); + ZEPHIR_OBS_NVAR(preCondition); + zephir_array_fetch(&preCondition, joinPreCondition, joinAliasName, PH_NOISY, "phalcon/mvc/model/query.zep", 1475 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_17); + zephir_create_array(_17, 3, 0 TSRMLS_CC); + zephir_array_update_string(&_17, SL("type"), &joinType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_17, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_18); + zephir_create_array(_18, 1, 0 TSRMLS_CC); + zephir_array_fast_append(_18, preCondition); + zephir_array_update_string(&_17, SL("conditions"), &_18, PH_COPY | PH_SEPARATE); + zephir_array_append(&sqlJoins, _17, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1480); + } + RETURN_CCTOR(sqlJoins); + } + ZEPHIR_INIT_NVAR(fromModels); + array_init(fromModels); + zephir_is_iterable(selectTables, &_20, &_19, 0, 0, "phalcon/mvc/model/query.zep", 1496); for ( - ; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS - ; zephir_hash_move_forward_ex(_15, &_14) + ; zephir_hash_get_current_data_ex(_20, (void**) &_21, &_19) == SUCCESS + ; zephir_hash_move_forward_ex(_20, &_19) + ) { + ZEPHIR_GET_HVALUE(tableItem, _21); + zephir_array_fetch_string(&_22, tableItem, SL("qualifiedName"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1490 TSRMLS_CC); + ZEPHIR_OBS_NVAR(_23); + zephir_array_fetch_string(&_23, _22, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1490 TSRMLS_CC); + zephir_array_update_zval(&fromModels, _23, &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE); + } + ZEPHIR_INIT_VAR(_24); + zephir_is_iterable(fromModels, &_26, &_25, 0, 0, "phalcon/mvc/model/query.zep", 1602); + for ( + ; zephir_hash_get_current_data_ex(_26, (void**) &_27, &_25) == SUCCESS + ; zephir_hash_move_forward_ex(_26, &_25) ) { - ZEPHIR_GET_HMKEY(fromModelName, _15, _14); - ZEPHIR_GET_HVALUE(_5, _16); - zephir_is_iterable(joinModels, &_18, &_17, 0, 0, "phalcon/mvc/model/query.zep", 1535); + ZEPHIR_GET_HMKEY(fromModelName, _26, _25); + ZEPHIR_GET_HVALUE(_24, _27); + zephir_is_iterable(joinModels, &_29, &_28, 0, 0, "phalcon/mvc/model/query.zep", 1600); for ( - ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS - ; zephir_hash_move_forward_ex(_18, &_17) + ; zephir_hash_get_current_data_ex(_29, (void**) &_30, &_28) == SUCCESS + ; zephir_hash_move_forward_ex(_29, &_28) ) { - ZEPHIR_GET_HMKEY(joinAlias, _18, _17); - ZEPHIR_GET_HVALUE(joinModel, _19); + ZEPHIR_GET_HMKEY(joinAlias, _29, _28); + ZEPHIR_GET_HVALUE(joinModel, _30); ZEPHIR_OBS_NVAR(joinSource); - zephir_array_fetch(&joinSource, joinSources, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1438 TSRMLS_CC); + zephir_array_fetch(&joinSource, joinSources, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1503 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinType); - zephir_array_fetch(&joinType, joinTypes, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1443 TSRMLS_CC); + zephir_array_fetch(&joinType, joinTypes, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1508 TSRMLS_CC); ZEPHIR_OBS_NVAR(preCondition); if (!(zephir_array_isset_fetch(&preCondition, joinPreCondition, joinAlias, 0 TSRMLS_CC))) { ZEPHIR_OBS_NVAR(modelNameAlias); - zephir_array_fetch(&modelNameAlias, sqlAliasesModels, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1453 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&relation, manager, "getrelationbyalias", &_20, 0, fromModelName, modelNameAlias); + zephir_array_fetch(&modelNameAlias, sqlAliasesModels, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1518 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&relation, manager, "getrelationbyalias", &_31, 0, fromModelName, modelNameAlias); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(relation)) { - ZEPHIR_CALL_METHOD(&relations, manager, "getrelationsbetween", &_21, 0, fromModelName, modelNameAlias); + ZEPHIR_CALL_METHOD(&relations, manager, "getrelationsbetween", &_32, 0, fromModelName, modelNameAlias); zephir_check_call_status(); if (Z_TYPE_P(relations) == IS_ARRAY) { if (zephir_fast_count_int(relations TSRMLS_CC) != 1) { - ZEPHIR_INIT_NVAR(_22); - object_init_ex(_22, phalcon_mvc_model_exception_ce); - _6 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); + ZEPHIR_INIT_NVAR(_33); + object_init_ex(_33, phalcon_mvc_model_exception_ce); + _34 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); ZEPHIR_INIT_LNVAR(_7); - ZEPHIR_CONCAT_SVSVSV(_7, "There is more than one relation between models '", fromModelName, "' and '", joinModel, "', the join must be done using an alias, when preparing: ", _6); - ZEPHIR_CALL_METHOD(NULL, _22, "__construct", &_8, 9, _7); + ZEPHIR_CONCAT_SVSVSV(_7, "There is more than one relation between models '", fromModelName, "' and '", joinModel, "', the join must be done using an alias, when preparing: ", _34); + ZEPHIR_CALL_METHOD(NULL, _33, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_22, "phalcon/mvc/model/query.zep", 1471 TSRMLS_CC); + zephir_throw_exception_debug(_33, "phalcon/mvc/model/query.zep", 1536 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_NVAR(relation); - zephir_array_fetch_long(&relation, relations, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 1477 TSRMLS_CC); + zephir_array_fetch_long(&relation, relations, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 1542 TSRMLS_CC); } } if (Z_TYPE_P(relation) == IS_OBJECT) { ZEPHIR_OBS_NVAR(modelAlias); - zephir_array_fetch(&modelAlias, sqlModelsAliases, fromModelName, PH_NOISY, "phalcon/mvc/model/query.zep", 1489 TSRMLS_CC); + zephir_array_fetch(&modelAlias, sqlModelsAliases, fromModelName, PH_NOISY, "phalcon/mvc/model/query.zep", 1554 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_12, relation, "isthrough", NULL, 0); zephir_check_call_status(); if (!(zephir_is_true(_12))) { - ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_23, 331, joinType, joinSource, modelAlias, joinAlias, relation); + ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_35, 324, joinType, joinSource, modelAlias, joinAlias, relation); zephir_check_call_status(); } else { - ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_24, 332, joinType, joinSource, modelAlias, joinAlias, relation); + ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_36, 325, joinType, joinSource, modelAlias, joinAlias, relation); zephir_check_call_status(); } if (zephir_array_isset_long(sqlJoin, 0)) { - zephir_is_iterable(sqlJoin, &_26, &_25, 0, 0, "phalcon/mvc/model/query.zep", 1507); + zephir_is_iterable(sqlJoin, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 1572); for ( - ; zephir_hash_get_current_data_ex(_26, (void**) &_27, &_25) == SUCCESS - ; zephir_hash_move_forward_ex(_26, &_25) + ; zephir_hash_get_current_data_ex(_38, (void**) &_39, &_37) == SUCCESS + ; zephir_hash_move_forward_ex(_38, &_37) ) { - ZEPHIR_GET_HVALUE(sqlJoinItem, _27); - zephir_array_append(&sqlJoins, sqlJoinItem, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1505); + ZEPHIR_GET_HVALUE(sqlJoinItem, _39); + zephir_array_append(&sqlJoins, sqlJoinItem, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1570); } } else { - zephir_array_append(&sqlJoins, sqlJoin, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1508); + zephir_array_append(&sqlJoins, sqlJoin, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1573); } } else { - ZEPHIR_INIT_NVAR(_28); - zephir_create_array(_28, 3, 0 TSRMLS_CC); - zephir_array_update_string(&_28, SL("type"), &joinType, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_28, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); - ZEPHIR_INIT_NVAR(_22); - array_init(_22); - zephir_array_update_string(&_28, SL("conditions"), &_22, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlJoins, _28, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1520); + ZEPHIR_INIT_NVAR(_17); + zephir_create_array(_17, 3, 0 TSRMLS_CC); + zephir_array_update_string(&_17, SL("type"), &joinType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_17, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_33); + array_init(_33); + zephir_array_update_string(&_17, SL("conditions"), &_33, PH_COPY | PH_SEPARATE); + zephir_array_append(&sqlJoins, _17, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1585); } } else { - ZEPHIR_INIT_NVAR(_28); - zephir_create_array(_28, 3, 0 TSRMLS_CC); - zephir_array_update_string(&_28, SL("type"), &joinType, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_28, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); - ZEPHIR_INIT_NVAR(_29); - zephir_create_array(_29, 1, 0 TSRMLS_CC); - zephir_array_fast_append(_29, preCondition); - zephir_array_update_string(&_28, SL("conditions"), &_29, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlJoins, _28, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1532); + ZEPHIR_INIT_NVAR(_18); + zephir_create_array(_18, 3, 0 TSRMLS_CC); + zephir_array_update_string(&_18, SL("type"), &joinType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_18, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_40); + zephir_create_array(_40, 1, 0 TSRMLS_CC); + zephir_array_fast_append(_40, preCondition); + zephir_array_update_string(&_18, SL("conditions"), &_40, PH_COPY | PH_SEPARATE); + zephir_array_append(&sqlJoins, _18, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1597); } } } @@ -93590,14 +94126,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getOrderClause) { } ZEPHIR_INIT_VAR(orderParts); array_init(orderParts); - zephir_is_iterable(orderColumns, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1578); + zephir_is_iterable(orderColumns, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1643); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(orderItem, _2); - zephir_array_fetch_string(&_3, orderItem, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1560 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 323, _3); + zephir_array_fetch_string(&_3, orderItem, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1625 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 316, _3); zephir_check_call_status(); if (zephir_array_isset_string_fetch(&orderSort, orderItem, SS("sort"), 1 TSRMLS_CC)) { ZEPHIR_INIT_NVAR(orderPartSort); @@ -93619,7 +94155,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getOrderClause) { zephir_create_array(orderPartSort, 1, 0 TSRMLS_CC); zephir_array_fast_append(orderPartSort, orderPartExpr); } - zephir_array_append(&orderParts, orderPartSort, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1575); + zephir_array_append(&orderParts, orderPartSort, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1640); } RETURN_CCTOR(orderParts); @@ -93644,19 +94180,19 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getGroupClause) { ZEPHIR_INIT_VAR(groupParts); if (zephir_array_isset_long(group, 0)) { array_init(groupParts); - zephir_is_iterable(group, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1596); + zephir_is_iterable(group, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1661); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(groupItem, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, groupItem); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 316, groupItem); zephir_check_call_status(); - zephir_array_append(&groupParts, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1594); + zephir_array_append(&groupParts, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1659); } } else { zephir_create_array(groupParts, 1, 0 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, group); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 316, group); zephir_check_call_status(); zephir_array_fast_append(groupParts, _3); } @@ -93682,13 +94218,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getLimitClause) { ZEPHIR_OBS_VAR(number); if (zephir_array_isset_string_fetch(&number, limitClause, SS("number"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, number); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 316, number); zephir_check_call_status(); zephir_array_update_string(&limit, SL("number"), &_0, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(offset); if (zephir_array_isset_string_fetch(&offset, limitClause, SS("offset"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, offset); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 316, offset); zephir_check_call_status(); zephir_array_update_string(&limit, SL("offset"), &_0, PH_COPY | PH_SEPARATE); } @@ -93698,12 +94234,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getLimitClause) { static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { - zval *_30 = NULL; - zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_11 = NULL, *_25 = NULL, *_31 = NULL; - HashTable *_1, *_23, *_27; - HashPosition _0, _22, _26; - int position, ZEPHIR_LAST_CALL_STATUS; - zval *ast = NULL, *merge = NULL, *sqlModels, *sqlTables, *sqlAliases, *sqlColumns, *select = NULL, *tables, *columns, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *models, *modelsInstances, *selectedModels = NULL, *manager, *metaData, *selectedModel = NULL, *qualifiedName = NULL, *modelName = NULL, *nsAlias = NULL, *realModelName = NULL, *model = NULL, *schema = NULL, *source = NULL, *completeSource = NULL, *alias = NULL, *joins, *sqlJoins = NULL, *selectColumns = NULL, *sqlColumnAliases, *column = NULL, *sqlColumn = NULL, *sqlSelect, *distinct, *having, *where, *groupBy, *order, *limit, **_2, *_3 = NULL, *_4, *_6, *_7 = NULL, *_9, *_10 = NULL, *_12, *_13, *_14, *_15, *_16, *_17, *_18, *_19, *_20, *_21, **_24, **_28, _29 = zval_used_for_init, *_32 = NULL; + zval *_19 = NULL, *_20 = NULL, *_21 = NULL; + zval *_16 = NULL; + zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_11 = NULL, *_17 = NULL, *_18 = NULL, *_32 = NULL, *_36 = NULL, *_40 = NULL; + HashTable *_1, *_13, *_34, *_38; + HashPosition _0, _12, _33, _37; + int position, number, ZEPHIR_LAST_CALL_STATUS; + zval *ast = NULL, *merge = NULL, *sqlModels, *sqlTables, *sqlAliases, *sqlColumns, *select = NULL, *tables, *columns, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *models, *modelsInstances, *selectedModels = NULL, *manager, *metaData, *selectedModel = NULL, *qualifiedName = NULL, *modelName = NULL, *nsAlias = NULL, *realModelName = NULL, *model = NULL, *schema = NULL, *source = NULL, *completeSource = NULL, *alias = NULL, *joins, *sqlJoins = NULL, *selectColumns = NULL, *sqlColumnAliases, *column = NULL, *sqlColumn = NULL, *sqlSelect, *distinct, *having, *where, *groupBy, *order, *limit, *tempModels, *tempModelsInstances, *tempSqlAliases, *tempSqlModelsAliases, *tempSqlAliasesModelsInstances, *tempSqlAliasesModels, *with = NULL, *withs = NULL, *withItem = NULL, *automaticJoins, *relation = NULL, *joinAlias = NULL, *relationModel = NULL, *bestAlias = NULL, *eagerType = NULL, **_2, *_3 = NULL, *_4, *_6, *_7 = NULL, *_9, *_10 = NULL, **_14, _15 = zval_used_for_init, *_22, *_23, *_24, *_25, *_26, *_27, *_28, *_29, *_30, *_31, **_35, **_39, *_41 = NULL; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 0, 2, &ast, &merge); @@ -93734,22 +94271,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } ZEPHIR_OBS_VAR(tables); if (!(zephir_array_isset_string_fetch(&tables, select, SS("tables"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1648); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1716); return; } ZEPHIR_OBS_VAR(columns); if (!(zephir_array_isset_string_fetch(&columns, select, SS("columns"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1652); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1720); return; } ZEPHIR_INIT_VAR(sqlModels); array_init(sqlModels); ZEPHIR_INIT_VAR(sqlTables); array_init(sqlTables); - ZEPHIR_INIT_VAR(sqlAliases); - array_init(sqlAliases); ZEPHIR_INIT_VAR(sqlColumns); array_init(sqlColumns); + ZEPHIR_INIT_VAR(sqlAliases); + array_init(sqlAliases); ZEPHIR_INIT_VAR(sqlAliasesModels); array_init(sqlAliasesModels); ZEPHIR_INIT_VAR(sqlModelsAliases); @@ -93767,35 +94304,45 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } else { ZEPHIR_CPY_WRT(selectedModels, tables); } + if (!(zephir_array_isset_long(columns, 0))) { + ZEPHIR_INIT_VAR(selectColumns); + zephir_create_array(selectColumns, 1, 0 TSRMLS_CC); + zephir_array_fast_append(selectColumns, columns); + } else { + ZEPHIR_CPY_WRT(selectColumns, columns); + } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); ZEPHIR_OBS_VAR(metaData); zephir_read_property_this(&metaData, this_ptr, SL("_metaData"), PH_NOISY_CC); if (Z_TYPE_P(manager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A models-manager is required to execute the query", "phalcon/mvc/model/query.zep", 1706); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A models-manager is required to execute the query", "phalcon/mvc/model/query.zep", 1782); return; } if (Z_TYPE_P(metaData) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A meta-data is required to execute the query", "phalcon/mvc/model/query.zep", 1710); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A meta-data is required to execute the query", "phalcon/mvc/model/query.zep", 1786); return; } - zephir_is_iterable(selectedModels, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1784); + number = 0; + ZEPHIR_INIT_VAR(automaticJoins); + array_init(automaticJoins); + zephir_is_iterable(selectedModels, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1913); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(selectedModel, _2); ZEPHIR_OBS_NVAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, selectedModel, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1716 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, selectedModel, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1795 TSRMLS_CC); ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1717 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 1722)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1796 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 1799)) { ZEPHIR_INIT_NVAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1724 TSRMLS_CC); + zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1801 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, manager, "getnamespacealias", &_5, 0, _4); zephir_check_call_status(); - zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1724 TSRMLS_CC); + zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1801 TSRMLS_CC); ZEPHIR_INIT_NVAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _3, "\\", _6); } else { @@ -93824,10 +94371,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { object_init_ex(_7, phalcon_mvc_model_exception_ce); _9 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); ZEPHIR_INIT_LNVAR(_10); - ZEPHIR_CONCAT_SVSV(_10, "Alias '", alias, "' is already used, when preparing: ", _9); + ZEPHIR_CONCAT_SVSV(_10, "Alias '", alias, "' is used more than once, when preparing: ", _9); ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 1752 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 1825 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -93836,7 +94383,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { zephir_array_update_zval(&sqlModelsAliases, realModelName, &alias, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, alias, &model, PH_COPY | PH_SEPARATE); if (Z_TYPE_P(completeSource) == IS_ARRAY) { - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1764); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1837); } else { ZEPHIR_INIT_NVAR(completeSource); zephir_create_array(completeSource, 3, 0 TSRMLS_CC); @@ -93846,14 +94393,100 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } zephir_array_update_zval(&models, realModelName, &alias, PH_COPY | PH_SEPARATE); } else { + ZEPHIR_CPY_WRT(alias, source); zephir_array_update_zval(&sqlAliases, realModelName, &source, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModels, realModelName, &realModelName, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlModelsAliases, realModelName, &realModelName, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&models, realModelName, &source, PH_COPY | PH_SEPARATE); } - zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1778); - zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1779); + ZEPHIR_OBS_NVAR(with); + if (zephir_array_isset_string_fetch(&with, selectedModel, SS("with"), 0 TSRMLS_CC)) { + if (!(zephir_array_isset_long(with, 0))) { + ZEPHIR_INIT_NVAR(withs); + zephir_create_array(withs, 1, 0 TSRMLS_CC); + zephir_array_fast_append(withs, with); + } else { + ZEPHIR_CPY_WRT(withs, with); + } + zephir_is_iterable(withs, &_13, &_12, 0, 0, "phalcon/mvc/model/query.zep", 1905); + for ( + ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS + ; zephir_hash_move_forward_ex(_13, &_12) + ) { + ZEPHIR_GET_HVALUE(withItem, _14); + ZEPHIR_SINIT_NVAR(_15); + ZVAL_LONG(&_15, number); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SV(_16, "AA", &_15); + ZEPHIR_CPY_WRT(joinAlias, _16); + ZEPHIR_OBS_NVAR(relationModel); + zephir_array_fetch_string(&relationModel, withItem, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1865 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&relation, manager, "getrelationbyalias", &_17, 0, realModelName, relationModel); + zephir_check_call_status(); + if (Z_TYPE_P(relation) == IS_OBJECT) { + ZEPHIR_INIT_NVAR(_7); + ZVAL_STRING(_7, "alias", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&bestAlias, relation, "getoption", NULL, 0, _7); + zephir_check_temp_parameter(_7); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&relationModel, relation, "getreferencedmodel", NULL, 0); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&eagerType, relation, "gettype", NULL, 0); + zephir_check_call_status(); + } else { + ZEPHIR_CALL_METHOD(&relation, manager, "getrelationsbetween", &_18, 0, realModelName, relationModel); + zephir_check_call_status(); + if (Z_TYPE_P(relation) == IS_OBJECT) { + ZEPHIR_INIT_NVAR(_7); + ZVAL_STRING(_7, "alias", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&bestAlias, relation, "getoption", NULL, 0, _7); + zephir_check_temp_parameter(_7); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&relationModel, relation, "getreferencedmodel", NULL, 0); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&eagerType, relation, "gettype", NULL, 0); + zephir_check_call_status(); + } else { + ZEPHIR_INIT_NVAR(_7); + object_init_ex(_7, phalcon_mvc_model_exception_ce); + _9 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); + ZEPHIR_INIT_LNVAR(_10); + ZEPHIR_CONCAT_SVSVSV(_10, "Can't find a relationship between '", realModelName, "' and '", relationModel, "' when preparing: ", _9); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_11, 9, _10); + zephir_check_call_status(); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 1879 TSRMLS_CC); + ZEPHIR_MM_RESTORE(); + return; + } + } + ZEPHIR_INIT_NVAR(_19); + zephir_create_array(_19, 5, 0 TSRMLS_CC); + add_assoc_long_ex(_19, SS("type"), 353); + zephir_array_update_string(&_19, SL("column"), &joinAlias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_19, SL("eager"), &alias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_19, SL("eagerType"), &eagerType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_19, SL("balias"), &bestAlias, PH_COPY | PH_SEPARATE); + zephir_array_append(&selectColumns, _19, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1889); + ZEPHIR_INIT_NVAR(_20); + zephir_create_array(_20, 3, 0 TSRMLS_CC); + add_assoc_long_ex(_20, SS("type"), 360); + ZEPHIR_INIT_NVAR(_21); + zephir_create_array(_21, 2, 0 TSRMLS_CC); + add_assoc_long_ex(_21, SS("type"), 355); + zephir_array_update_string(&_21, SL("name"), &relationModel, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_20, SL("qualified"), &_21, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_21); + zephir_create_array(_21, 2, 0 TSRMLS_CC); + add_assoc_long_ex(_21, SS("type"), 355); + zephir_array_update_string(&_21, SL("name"), &joinAlias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_20, SL("alias"), &_21, PH_COPY | PH_SEPARATE); + zephir_array_append(&automaticJoins, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1901); + number++; + } + } + zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1907); + zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1908); zephir_array_update_zval(&modelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); } if (!(zephir_is_true(merge))) { @@ -93864,68 +94497,85 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), sqlModelsAliases TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), sqlAliasesModelsInstances TSRMLS_CC); } else { + ZEPHIR_OBS_VAR(tempModels); + zephir_read_property_this(&tempModels, this_ptr, SL("_models"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempModelsInstances); + zephir_read_property_this(&tempModelsInstances, this_ptr, SL("_modelsInstances"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlAliases); + zephir_read_property_this(&tempSqlAliases, this_ptr, SL("_sqlAliases"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlAliasesModels); + zephir_read_property_this(&tempSqlAliasesModels, this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlModelsAliases); + zephir_read_property_this(&tempSqlModelsAliases, this_ptr, SL("_sqlModelsAliases"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlAliasesModelsInstances); + zephir_read_property_this(&tempSqlAliasesModelsInstances, this_ptr, SL("_sqlAliasesModelsInstances"), PH_NOISY_CC); ZEPHIR_INIT_NVAR(_7); _9 = zephir_fetch_nproperty_this(this_ptr, SL("_models"), PH_NOISY_CC); zephir_fast_array_merge(_7, &(_9), &(models) TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_models"), _7 TSRMLS_CC); - ZEPHIR_INIT_VAR(_12); - _13 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); - zephir_fast_array_merge(_12, &(_13), &(modelsInstances) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_modelsInstances"), _12 TSRMLS_CC); - ZEPHIR_INIT_VAR(_14); - _15 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliases"), PH_NOISY_CC); - zephir_fast_array_merge(_14, &(_15), &(sqlAliases) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlAliases"), _14 TSRMLS_CC); - ZEPHIR_INIT_VAR(_16); - _17 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); - zephir_fast_array_merge(_16, &(_17), &(sqlAliasesModels) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlAliasesModels"), _16 TSRMLS_CC); - ZEPHIR_INIT_VAR(_18); - _19 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlModelsAliases"), PH_NOISY_CC); - zephir_fast_array_merge(_18, &(_19), &(sqlModelsAliases) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), _18 TSRMLS_CC); - ZEPHIR_INIT_VAR(_20); - _21 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModelsInstances"), PH_NOISY_CC); - zephir_fast_array_merge(_20, &(_21), &(sqlAliasesModelsInstances) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), _20 TSRMLS_CC); + ZEPHIR_INIT_VAR(_22); + _23 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); + zephir_fast_array_merge(_22, &(_23), &(modelsInstances) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_modelsInstances"), _22 TSRMLS_CC); + ZEPHIR_INIT_VAR(_24); + _25 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliases"), PH_NOISY_CC); + zephir_fast_array_merge(_24, &(_25), &(sqlAliases) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliases"), _24 TSRMLS_CC); + ZEPHIR_INIT_VAR(_26); + _27 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); + zephir_fast_array_merge(_26, &(_27), &(sqlAliasesModels) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModels"), _26 TSRMLS_CC); + ZEPHIR_INIT_VAR(_28); + _29 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlModelsAliases"), PH_NOISY_CC); + zephir_fast_array_merge(_28, &(_29), &(sqlModelsAliases) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), _28 TSRMLS_CC); + ZEPHIR_INIT_VAR(_30); + _31 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModelsInstances"), PH_NOISY_CC); + zephir_fast_array_merge(_30, &(_31), &(sqlAliasesModelsInstances) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), _30 TSRMLS_CC); } ZEPHIR_OBS_VAR(joins); - if (zephir_array_isset_string_fetch(&joins, select, SS("joins"), 0 TSRMLS_CC)) { - if (zephir_fast_count_int(joins TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", NULL, 333, select); + zephir_array_isset_string_fetch(&joins, select, SS("joins"), 0 TSRMLS_CC); + if (zephir_fast_count_int(joins TSRMLS_CC)) { + if (zephir_fast_count_int(automaticJoins TSRMLS_CC)) { + if (zephir_array_isset_long(joins, 0)) { + ZEPHIR_INIT_NVAR(_7); + zephir_fast_array_merge(_7, &(joins), &(automaticJoins) TSRMLS_CC); + zephir_array_update_string(&select, SL("joins"), &_7, PH_COPY | PH_SEPARATE); + } else { + zephir_array_append(&automaticJoins, joins, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1945); + zephir_array_update_string(&select, SL("joins"), &automaticJoins, PH_COPY | PH_SEPARATE); + } + } + ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", &_32, 326, select); + zephir_check_call_status(); + } else { + if (zephir_fast_count_int(automaticJoins TSRMLS_CC)) { + zephir_array_update_string(&select, SL("joins"), &automaticJoins, PH_COPY | PH_SEPARATE); + ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", &_32, 326, select); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(sqlJoins); array_init(sqlJoins); } - } else { - ZEPHIR_INIT_NVAR(sqlJoins); - array_init(sqlJoins); - } - if (!(zephir_array_isset_long(columns, 0))) { - ZEPHIR_INIT_VAR(selectColumns); - zephir_create_array(selectColumns, 1, 0 TSRMLS_CC); - zephir_array_fast_append(selectColumns, columns); - } else { - ZEPHIR_CPY_WRT(selectColumns, columns); } position = 0; ZEPHIR_INIT_VAR(sqlColumnAliases); array_init(sqlColumnAliases); - zephir_is_iterable(selectColumns, &_23, &_22, 0, 0, "phalcon/mvc/model/query.zep", 1857); + zephir_is_iterable(selectColumns, &_34, &_33, 0, 0, "phalcon/mvc/model/query.zep", 1998); for ( - ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS - ; zephir_hash_move_forward_ex(_23, &_22) + ; zephir_hash_get_current_data_ex(_34, (void**) &_35, &_33) == SUCCESS + ; zephir_hash_move_forward_ex(_34, &_33) ) { - ZEPHIR_GET_HVALUE(column, _24); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_25, 334, column); + ZEPHIR_GET_HVALUE(column, _35); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_36, 327, column); zephir_check_call_status(); - zephir_is_iterable(_3, &_27, &_26, 0, 0, "phalcon/mvc/model/query.zep", 1856); + zephir_is_iterable(_3, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 1997); for ( - ; zephir_hash_get_current_data_ex(_27, (void**) &_28, &_26) == SUCCESS - ; zephir_hash_move_forward_ex(_27, &_26) + ; zephir_hash_get_current_data_ex(_38, (void**) &_39, &_37) == SUCCESS + ; zephir_hash_move_forward_ex(_38, &_37) ) { - ZEPHIR_GET_HVALUE(sqlColumn, _28); + ZEPHIR_GET_HVALUE(sqlColumn, _39); ZEPHIR_OBS_NVAR(alias); if (zephir_array_isset_string_fetch(&alias, column, SS("alias"), 0 TSRMLS_CC)) { zephir_array_update_string(&sqlColumn, SL("balias"), &alias, PH_COPY | PH_SEPARATE); @@ -93937,15 +94587,15 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { if (zephir_array_isset_string_fetch(&alias, sqlColumn, SS("balias"), 0 TSRMLS_CC)) { zephir_array_update_zval(&sqlColumns, alias, &sqlColumn, PH_COPY | PH_SEPARATE); } else { - zephir_array_fetch_string(&_4, sqlColumn, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1846 TSRMLS_CC); + zephir_array_fetch_string(&_4, sqlColumn, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1987 TSRMLS_CC); if (ZEPHIR_IS_STRING(_4, "scalar")) { - ZEPHIR_SINIT_NVAR(_29); - ZVAL_LONG(&_29, position); - ZEPHIR_INIT_LNVAR(_30); - ZEPHIR_CONCAT_SV(_30, "_", &_29); - zephir_array_update_zval(&sqlColumns, _30, &sqlColumn, PH_COPY | PH_SEPARATE); + ZEPHIR_SINIT_NVAR(_15); + ZVAL_LONG(&_15, position); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SV(_16, "_", &_15); + zephir_array_update_zval(&sqlColumns, _16, &sqlColumn, PH_COPY | PH_SEPARATE); } else { - zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1849); + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1990); } } } @@ -93967,37 +94617,45 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } ZEPHIR_OBS_VAR(where); if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_31, 323, where); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_40, 316, where); zephir_check_call_status(); zephir_array_update_string(&sqlSelect, SL("where"), &_3, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(groupBy); if (zephir_array_isset_string_fetch(&groupBy, ast, SS("groupBy"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getgroupclause", NULL, 335, groupBy); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getgroupclause", NULL, 328, groupBy); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("group"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("group"), &_41, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(having); if (zephir_array_isset_string_fetch(&having, ast, SS("having"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getexpression", &_31, 323, having); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getexpression", &_40, 316, having); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("having"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("having"), &_41, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(order); if (zephir_array_isset_string_fetch(&order, ast, SS("orderBy"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getorderclause", NULL, 336, order); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getorderclause", NULL, 329, order); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("order"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("order"), &_41, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(limit); if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getlimitclause", NULL, 337, limit); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getlimitclause", NULL, 330, limit); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("limit"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("limit"), &_41, PH_COPY | PH_SEPARATE); } if (zephir_array_isset_string(ast, SS("forUpdate"))) { zephir_array_update_string(&sqlSelect, SL("forUpdate"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE); } + if (zephir_is_true(merge)) { + zephir_update_property_this(this_ptr, SL("_models"), tempModels TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_modelsInstances"), tempModelsInstances TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliases"), tempSqlAliases TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModels"), tempSqlAliasesModels TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), tempSqlModelsAliases TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), tempSqlAliasesModelsInstances TSRMLS_CC); + } RETURN_CCTOR(sqlSelect); } @@ -94017,30 +94675,30 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { ZEPHIR_OBS_VAR(ast); zephir_read_property_this(&ast, this_ptr, SL("_ast"), PH_NOISY_CC); if (!(zephir_array_isset_string(ast, SS("qualifiedName")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 1920); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 2070); return; } if (!(zephir_array_isset_string(ast, SS("values")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 1924); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 2074); return; } ZEPHIR_OBS_VAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, ast, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1927 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, ast, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2077 TSRMLS_CC); if (!(zephir_array_isset_string(qualifiedName, SS("name")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 1931); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 2081); return; } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1935 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 1938)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2085 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2088)) { ZEPHIR_INIT_VAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_1, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1940 TSRMLS_CC); + zephir_array_fetch_long(&_1, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2090 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_0, manager, "getnamespacealias", NULL, 0, _1); zephir_check_call_status(); - zephir_array_fetch_long(&_2, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1940 TSRMLS_CC); + zephir_array_fetch_long(&_2, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2090 TSRMLS_CC); ZEPHIR_INIT_VAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _0, "\\", _2); } else { @@ -94063,8 +94721,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { notQuoting = 0; ZEPHIR_INIT_VAR(exprValues); array_init(exprValues); - zephir_array_fetch_string(&_1, ast, SL("values"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1956 TSRMLS_CC); - zephir_is_iterable(_1, &_5, &_4, 0, 0, "phalcon/mvc/model/query.zep", 1965); + zephir_array_fetch_string(&_1, ast, SL("values"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2106 TSRMLS_CC); + zephir_is_iterable(_1, &_5, &_4, 0, 0, "phalcon/mvc/model/query.zep", 2115); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -94073,12 +94731,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { ZEPHIR_INIT_NVAR(_7); zephir_create_array(_7, 2, 0 TSRMLS_CC); ZEPHIR_OBS_NVAR(_8); - zephir_array_fetch_string(&_8, exprValue, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 1960 TSRMLS_CC); + zephir_array_fetch_string(&_8, exprValue, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2110 TSRMLS_CC); zephir_array_update_string(&_7, SL("type"), &_8, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 323, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 316, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_array_update_string(&_7, SL("value"), &_0, PH_COPY | PH_SEPARATE); - zephir_array_append(&exprValues, _7, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1962); + zephir_array_append(&exprValues, _7, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2112); } ZEPHIR_INIT_VAR(sqlInsert); zephir_create_array(sqlInsert, 2, 0 TSRMLS_CC); @@ -94090,14 +94748,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { if (zephir_array_isset_string_fetch(&fields, ast, SS("fields"), 0 TSRMLS_CC)) { ZEPHIR_INIT_VAR(sqlFields); array_init(sqlFields); - zephir_is_iterable(fields, &_11, &_10, 0, 0, "phalcon/mvc/model/query.zep", 1987); + zephir_is_iterable(fields, &_11, &_10, 0, 0, "phalcon/mvc/model/query.zep", 2137); for ( ; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS ; zephir_hash_move_forward_ex(_11, &_10) ) { ZEPHIR_GET_HVALUE(field, _12); ZEPHIR_OBS_NVAR(name); - zephir_array_fetch_string(&name, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1976 TSRMLS_CC); + zephir_array_fetch_string(&name, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2126 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_0, metaData, "hasattribute", &_13, 0, model, name); zephir_check_call_status(); if (!(zephir_is_true(_0))) { @@ -94108,11 +94766,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { ZEPHIR_CONCAT_SVSVSV(_15, "The model '", modelName, "' doesn't have the attribute '", name, "', when preparing: ", _14); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_16, 9, _15); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 1980 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 2130 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&sqlFields, name, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1984); + zephir_array_append(&sqlFields, name, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2134); } zephir_array_update_string(&sqlInsert, SL("fields"), &sqlFields, PH_COPY | PH_SEPARATE); } @@ -94137,17 +94795,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { zephir_read_property_this(&ast, this_ptr, SL("_ast"), PH_NOISY_CC); ZEPHIR_OBS_VAR(update); if (!(zephir_array_isset_string_fetch(&update, ast, SS("update"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2011); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2161); return; } ZEPHIR_OBS_VAR(tables); if (!(zephir_array_isset_string_fetch(&tables, update, SS("tables"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2015); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2165); return; } ZEPHIR_OBS_VAR(values); if (!(zephir_array_isset_string_fetch(&values, update, SS("values"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2019); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2169); return; } ZEPHIR_INIT_VAR(models); @@ -94171,23 +94829,23 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); - zephir_is_iterable(updateTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2094); + zephir_is_iterable(updateTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2244); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(table, _2); ZEPHIR_OBS_NVAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2042 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2192 TSRMLS_CC); ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2043 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2048)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2193 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2198)) { ZEPHIR_INIT_NVAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2050 TSRMLS_CC); + zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2200 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, manager, "getnamespacealias", &_5, 0, _4); zephir_check_call_status(); - zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2050 TSRMLS_CC); + zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2200 TSRMLS_CC); ZEPHIR_INIT_NVAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _3, "\\", _6); } else { @@ -94214,17 +94872,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { ZEPHIR_OBS_NVAR(alias); if (zephir_array_isset_string_fetch(&alias, table, SS("alias"), 0 TSRMLS_CC)) { zephir_array_update_zval(&sqlAliases, alias, &alias, PH_COPY | PH_SEPARATE); - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2076); - zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2077); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2226); + zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2227); zephir_array_update_zval(&sqlAliasesModelsInstances, alias, &model, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&models, alias, &realModelName, PH_COPY | PH_SEPARATE); } else { zephir_array_update_zval(&sqlAliases, realModelName, &source, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2083); + zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2233); zephir_array_update_zval(&models, realModelName, &source, PH_COPY | PH_SEPARATE); } - zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2087); + zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2237); zephir_array_update_zval(&modelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); } zephir_update_property_this(this_ptr, SL("_models"), models TSRMLS_CC); @@ -94243,27 +94901,27 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { ZEPHIR_CPY_WRT(updateValues, values); } notQuoting = 0; - zephir_is_iterable(updateValues, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 2119); + zephir_is_iterable(updateValues, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 2268); for ( ; zephir_hash_get_current_data_ex(_10, (void**) &_11, &_9) == SUCCESS ; zephir_hash_move_forward_ex(_10, &_9) ) { ZEPHIR_GET_HVALUE(updateValue, _11); - zephir_array_fetch_string(&_4, updateValue, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2110 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 323, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_4, updateValue, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2260 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 316, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - zephir_array_append(&sqlFields, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2110); + zephir_array_append(&sqlFields, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2260); ZEPHIR_OBS_NVAR(exprColumn); - zephir_array_fetch_string(&exprColumn, updateValue, SL("expr"), PH_NOISY, "phalcon/mvc/model/query.zep", 2111 TSRMLS_CC); + zephir_array_fetch_string(&exprColumn, updateValue, SL("expr"), PH_NOISY, "phalcon/mvc/model/query.zep", 2261 TSRMLS_CC); ZEPHIR_INIT_NVAR(_13); zephir_create_array(_13, 2, 0 TSRMLS_CC); ZEPHIR_OBS_NVAR(_14); - zephir_array_fetch_string(&_14, exprColumn, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2113 TSRMLS_CC); + zephir_array_fetch_string(&_14, exprColumn, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2263 TSRMLS_CC); zephir_array_update_string(&_13, SL("type"), &_14, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 316, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_array_update_string(&_13, SL("value"), &_15, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlValues, _13, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2115); + zephir_array_append(&sqlValues, _13, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2265); } ZEPHIR_INIT_VAR(sqlUpdate); zephir_create_array(sqlUpdate, 4, 0 TSRMLS_CC); @@ -94275,13 +94933,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) { ZEPHIR_SINIT_VAR(_16); ZVAL_BOOL(&_16, 1); - ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, where, &_16); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 316, where, &_16); zephir_check_call_status(); zephir_array_update_string(&sqlUpdate, SL("where"), &_15, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(limit); if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 337, limit); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 330, limit); zephir_check_call_status(); zephir_array_update_string(&sqlUpdate, SL("limit"), &_15, PH_COPY | PH_SEPARATE); } @@ -94303,12 +94961,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { zephir_read_property_this(&ast, this_ptr, SL("_ast"), PH_NOISY_CC); ZEPHIR_OBS_VAR(delete); if (!(zephir_array_isset_string_fetch(&delete, ast, SS("delete"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2151); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2300); return; } ZEPHIR_OBS_VAR(tables); if (!(zephir_array_isset_string_fetch(&tables, delete, SS("tables"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2155); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2304); return; } ZEPHIR_INIT_VAR(models); @@ -94332,23 +94990,23 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); - zephir_is_iterable(deleteTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2226); + zephir_is_iterable(deleteTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2374); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(table, _2); ZEPHIR_OBS_NVAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2177 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2328 TSRMLS_CC); ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2178 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2186)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2329 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2334)) { ZEPHIR_INIT_NVAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2188 TSRMLS_CC); + zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2336 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, manager, "getnamespacealias", &_5, 0, _4); zephir_check_call_status(); - zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2188 TSRMLS_CC); + zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2336 TSRMLS_CC); ZEPHIR_INIT_NVAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _3, "\\", _6); } else { @@ -94375,17 +95033,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { ZEPHIR_OBS_NVAR(alias); if (zephir_array_isset_string_fetch(&alias, table, SS("alias"), 0 TSRMLS_CC)) { zephir_array_update_zval(&sqlAliases, alias, &alias, PH_COPY | PH_SEPARATE); - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2208); - zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2209); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2356); + zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2357); zephir_array_update_zval(&sqlAliasesModelsInstances, alias, &model, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&models, alias, &realModelName, PH_COPY | PH_SEPARATE); } else { zephir_array_update_zval(&sqlAliases, realModelName, &source, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2215); + zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2363); zephir_array_update_zval(&models, realModelName, &source, PH_COPY | PH_SEPARATE); } - zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2219); + zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2367); zephir_array_update_zval(&modelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); } zephir_update_property_this(this_ptr, SL("_models"), models TSRMLS_CC); @@ -94400,13 +95058,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) { ZEPHIR_SINIT_VAR(_9); ZVAL_BOOL(&_9, 1); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 323, where, &_9); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 316, where, &_9); zephir_check_call_status(); zephir_array_update_string(&sqlDelete, SL("where"), &_3, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(limit); if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 337, limit); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 330, limit); zephir_check_call_status(); zephir_array_update_string(&sqlDelete, SL("limit"), &_10, PH_COPY | PH_SEPARATE); } @@ -94442,7 +95100,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { _0 = zephir_fetch_static_property_ce(phalcon_mvc_model_query_ce, SL("_irPhqlCache") TSRMLS_CC); if (zephir_array_isset_fetch(&irPhql, _0, uniqueId, 0 TSRMLS_CC)) { if (Z_TYPE_P(irPhql) == IS_ARRAY) { - zephir_array_fetch_string(&_1, ast, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2277 TSRMLS_CC); + zephir_array_fetch_string(&_1, ast, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2425 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); RETURN_CCTOR(irPhql); } @@ -94454,22 +95112,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { zephir_update_property_this(this_ptr, SL("_type"), type TSRMLS_CC); do { if (ZEPHIR_IS_LONG(type, 309)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 328); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 321); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 306)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 338); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 331); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 300)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 339); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 332); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 303)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 340); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 333); zephir_check_call_status(); break; } @@ -94479,7 +95137,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { ZEPHIR_CONCAT_SVSV(_3, "Unknown statement ", type, ", when preparing: ", phql); ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/mvc/model/query.zep", 2310 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/mvc/model/query.zep", 2458 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -94487,7 +95145,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { } } if (Z_TYPE_P(irPhql) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted AST", "phalcon/mvc/model/query.zep", 2316); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted AST", "phalcon/mvc/model/query.zep", 2464); return; } if (Z_TYPE_P(uniqueId) == IS_LONG) { @@ -94531,8 +95189,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_INIT_VAR(connectionTypes); array_init(connectionTypes); ZEPHIR_OBS_VAR(models); - zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2359 TSRMLS_CC); - zephir_is_iterable(models, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2387); + zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2507 TSRMLS_CC); + zephir_is_iterable(models, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2535); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -94551,7 +95209,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_CALL_METHOD(&connection, model, "selectreadconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectReadConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2374); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectReadConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2522); return; } } else { @@ -94562,28 +95220,28 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_check_call_status(); zephir_array_update_zval(&connectionTypes, _6, &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE); if (zephir_fast_count_int(connectionTypes TSRMLS_CC) == 2) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot use models of different database systems in the same query", "phalcon/mvc/model/query.zep", 2383); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot use models of different database systems in the same query", "phalcon/mvc/model/query.zep", 2531); return; } } ZEPHIR_OBS_VAR(columns); - zephir_array_fetch_string(&columns, intermediate, SL("columns"), PH_NOISY, "phalcon/mvc/model/query.zep", 2387 TSRMLS_CC); + zephir_array_fetch_string(&columns, intermediate, SL("columns"), PH_NOISY, "phalcon/mvc/model/query.zep", 2535 TSRMLS_CC); haveObjects = 0; haveScalars = 0; isComplex = 0; numberObjects = 0; ZEPHIR_CPY_WRT(columns1, columns); - zephir_is_iterable(columns, &_8, &_7, 0, 0, "phalcon/mvc/model/query.zep", 2414); + zephir_is_iterable(columns, &_8, &_7, 0, 0, "phalcon/mvc/model/query.zep", 2562); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) ) { ZEPHIR_GET_HVALUE(column, _9); if (Z_TYPE_P(column) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid column definition", "phalcon/mvc/model/query.zep", 2400); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid column definition", "phalcon/mvc/model/query.zep", 2548); return; } - zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2403 TSRMLS_CC); + zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2551 TSRMLS_CC); if (ZEPHIR_IS_STRING(_10, "scalar")) { if (!(zephir_array_isset_string(column, SS("balias")))) { isComplex = 1; @@ -94617,7 +95275,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { array_init(simpleColumnMap); ZEPHIR_OBS_VAR(metaData); zephir_read_property_this(&metaData, this_ptr, SL("_metaData"), PH_NOISY_CC); - zephir_is_iterable(columns, &_12, &_11, 0, 0, "phalcon/mvc/model/query.zep", 2513); + zephir_is_iterable(columns, &_12, &_11, 0, 0, "phalcon/mvc/model/query.zep", 2661); for ( ; zephir_hash_get_current_data_ex(_12, (void**) &_13, &_11) == SUCCESS ; zephir_hash_move_forward_ex(_12, &_11) @@ -94625,11 +95283,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_GET_HMKEY(aliasCopy, _12, _11); ZEPHIR_GET_HVALUE(column, _13); ZEPHIR_OBS_NVAR(sqlColumn); - zephir_array_fetch_string(&sqlColumn, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 2438 TSRMLS_CC); - zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2441 TSRMLS_CC); + zephir_array_fetch_string(&sqlColumn, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 2586 TSRMLS_CC); + zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2589 TSRMLS_CC); if (ZEPHIR_IS_STRING(_10, "object")) { ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, column, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2443 TSRMLS_CC); + zephir_array_fetch_string(&modelName, column, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2591 TSRMLS_CC); ZEPHIR_OBS_NVAR(instance); _3 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&instance, _3, modelName, 0 TSRMLS_CC))) { @@ -94647,7 +95305,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_INIT_NVAR(columnMap); ZVAL_NULL(columnMap); } - zephir_is_iterable(attributes, &_18, &_17, 0, 0, "phalcon/mvc/model/query.zep", 2469); + zephir_is_iterable(attributes, &_18, &_17, 0, 0, "phalcon/mvc/model/query.zep", 2617); for ( ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS ; zephir_hash_move_forward_ex(_18, &_17) @@ -94660,7 +95318,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_INIT_LNVAR(_21); ZEPHIR_CONCAT_SVSV(_21, "_", sqlColumn, "_", attribute); zephir_array_fast_append(_20, _21); - zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2465); + zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2613); } zephir_array_update_multi(&columns1, &instance TSRMLS_CC, SL("zs"), 3, aliasCopy, SL("instance")); zephir_array_update_multi(&columns1, &attributes TSRMLS_CC, SL("zs"), 3, aliasCopy, SL("attributes")); @@ -94674,7 +95332,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_array_update_multi(&columns1, &_4 TSRMLS_CC, SL("zs"), 3, aliasCopy, SL("keepSnapshots")); } } else { - zephir_is_iterable(attributes, &_24, &_23, 0, 0, "phalcon/mvc/model/query.zep", 2487); + zephir_is_iterable(attributes, &_24, &_23, 0, 0, "phalcon/mvc/model/query.zep", 2635); for ( ; zephir_hash_get_current_data_ex(_24, (void**) &_25, &_23) == SUCCESS ; zephir_hash_move_forward_ex(_24, &_23) @@ -94684,7 +95342,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_create_array(_20, 2, 0 TSRMLS_CC); zephir_array_fast_append(_20, attribute); zephir_array_fast_append(_20, sqlColumn); - zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2485); + zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2633); } } } else { @@ -94699,7 +95357,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_array_fast_append(columnAlias, ZEPHIR_GLOBAL(global_null)); zephir_array_fast_append(columnAlias, aliasCopy); } - zephir_array_append(&selectColumns, columnAlias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2498); + zephir_array_append(&selectColumns, columnAlias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2646); } _26 = isComplex == 0; if (_26) { @@ -94720,7 +95378,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { if (Z_TYPE_P(bindParams) == IS_ARRAY) { ZEPHIR_INIT_VAR(processed); array_init(processed); - zephir_is_iterable(bindParams, &_28, &_27, 0, 0, "phalcon/mvc/model/query.zep", 2534); + zephir_is_iterable(bindParams, &_28, &_27, 0, 0, "phalcon/mvc/model/query.zep", 2682); for ( ; zephir_hash_get_current_data_ex(_28, (void**) &_29, &_27) == SUCCESS ; zephir_hash_move_forward_ex(_28, &_27) @@ -94746,7 +95404,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { if (Z_TYPE_P(bindTypes) == IS_ARRAY) { ZEPHIR_INIT_VAR(processedTypes); array_init(processedTypes); - zephir_is_iterable(bindTypes, &_31, &_30, 0, 0, "phalcon/mvc/model/query.zep", 2550); + zephir_is_iterable(bindTypes, &_31, &_30, 0, 0, "phalcon/mvc/model/query.zep", 2698); for ( ; zephir_hash_get_current_data_ex(_31, (void**) &_32, &_30) == SUCCESS ; zephir_hash_move_forward_ex(_31, &_30) @@ -94818,7 +95476,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { array_init(simpleColumnMap); ZEPHIR_CALL_METHOD(&_6, metaData, "getattributes", NULL, 0, model); zephir_check_call_status(); - zephir_is_iterable(_6, &_34, &_33, 0, 0, "phalcon/mvc/model/query.zep", 2633); + zephir_is_iterable(_6, &_34, &_33, 0, 0, "phalcon/mvc/model/query.zep", 2781); for ( ; zephir_hash_get_current_data_ex(_34, (void**) &_35, &_33) == SUCCESS ; zephir_hash_move_forward_ex(_34, &_33) @@ -94828,13 +95486,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_create_array(_20, 2, 0 TSRMLS_CC); zephir_array_fast_append(_20, attribute); ZEPHIR_OBS_NVAR(_36); - zephir_array_fetch(&_36, typesColumnMap, attribute, PH_NOISY, "phalcon/mvc/model/query.zep", 2631 TSRMLS_CC); + zephir_array_fetch(&_36, typesColumnMap, attribute, PH_NOISY, "phalcon/mvc/model/query.zep", 2779 TSRMLS_CC); zephir_array_fast_append(_20, _36); zephir_array_update_zval(&simpleColumnMap, attribute, &_20, PH_COPY | PH_SEPARATE); } } else { array_init(simpleColumnMap); - zephir_is_iterable(columnMap, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 2638); + zephir_is_iterable(columnMap, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 2786); for ( ; zephir_hash_get_current_data_ex(_38, (void**) &_39, &_37) == SUCCESS ; zephir_hash_move_forward_ex(_38, &_37) @@ -94845,7 +95503,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_create_array(_20, 2, 0 TSRMLS_CC); zephir_array_fast_append(_20, attribute); ZEPHIR_OBS_NVAR(_36); - zephir_array_fetch(&_36, typesColumnMap, column, PH_NOISY, "phalcon/mvc/model/query.zep", 2636 TSRMLS_CC); + zephir_array_fetch(&_36, typesColumnMap, column, PH_NOISY, "phalcon/mvc/model/query.zep", 2784 TSRMLS_CC); zephir_array_fast_append(_20, _36); zephir_array_update_zval(&simpleColumnMap, column, &_20, PH_COPY | PH_SEPARATE); } @@ -94856,12 +95514,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { isKeepingSnapshots = zephir_get_boolval(_40); } object_init_ex(return_value, phalcon_mvc_model_resultset_simple_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 341, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 334, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); } object_init_ex(return_value, phalcon_mvc_model_resultset_complex_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 342, columns1, resultData, cache); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 335, columns1, resultData, cache); zephir_check_call_status(); RETURN_MM(); @@ -94882,7 +95540,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_string(&modelName, intermediate, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2675 TSRMLS_CC); + zephir_array_fetch_string(&modelName, intermediate, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2823 TSRMLS_CC); ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); ZEPHIR_OBS_VAR(model); @@ -94897,7 +95555,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2688); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2836); return; } } else { @@ -94922,16 +95580,16 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { } } ZEPHIR_OBS_VAR(values); - zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2711 TSRMLS_CC); + zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2859 TSRMLS_CC); if (zephir_fast_count_int(fields TSRMLS_CC) != zephir_fast_count_int(values TSRMLS_CC)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The column count does not match the values count", "phalcon/mvc/model/query.zep", 2717); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The column count does not match the values count", "phalcon/mvc/model/query.zep", 2865); return; } ZEPHIR_CALL_METHOD(&dialect, connection, "getdialect", NULL, 0); zephir_check_call_status(); ZEPHIR_INIT_VAR(insertValues); array_init(insertValues); - zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 2785); + zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 2933); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -94939,8 +95597,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_GET_HMKEY(number, _3, _2); ZEPHIR_GET_HVALUE(value, _4); ZEPHIR_OBS_NVAR(exprValue); - zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 2728 TSRMLS_CC); - zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2729 TSRMLS_CC); + zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 2876 TSRMLS_CC); + zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2877 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_5, 260) || ZEPHIR_IS_LONG(_5, 258) || ZEPHIR_IS_LONG(_5, 259)) { ZEPHIR_CALL_METHOD(&insertValue, dialect, "getsqlexpression", &_6, 0, exprValue); @@ -94954,7 +95612,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { } if (ZEPHIR_IS_LONG(_5, 273) || ZEPHIR_IS_LONG(_5, 274) || ZEPHIR_IS_LONG(_5, 277)) { if (Z_TYPE_P(bindParams) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 2746); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 2894); return; } ZEPHIR_CALL_METHOD(&_7, dialect, "getsqlexpression", &_8, 0, exprValue); @@ -94973,7 +95631,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_CONCAT_SVS(_11, "Bound parameter '", wildcard, "' cannot be replaced because it isn't in the placeholders list"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_12, 9, _11); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2751 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2899 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -94989,7 +95647,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { } while(0); ZEPHIR_OBS_NVAR(fieldName); - zephir_array_fetch(&fieldName, fields, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2761 TSRMLS_CC); + zephir_array_fetch(&fieldName, fields, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2909 TSRMLS_CC); if (automaticFields == 1) { if (Z_TYPE_P(columnMap) == IS_ARRAY) { ZEPHIR_OBS_NVAR(attributeName); @@ -95000,7 +95658,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_CONCAT_SVS(_11, "Column '", fieldName, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_12, 9, _11); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2769 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2917 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -95021,7 +95679,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_CALL_METHOD(&_15, insertModel, "create", NULL, 0, insertValues); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 343, _15, insertModel); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 336, _15, insertModel); zephir_check_call_status(); RETURN_MM(); @@ -95042,13 +95700,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_OBS_VAR(models); - zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2809 TSRMLS_CC); + zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2957 TSRMLS_CC); if (zephir_array_isset_long(models, 1)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Updating several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 2812); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Updating several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 2960); return; } ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 2815 TSRMLS_CC); + zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 2963 TSRMLS_CC); ZEPHIR_OBS_VAR(model); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&model, _0, modelName, 0 TSRMLS_CC))) { @@ -95060,7 +95718,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2827); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2975); return; } } else { @@ -95070,14 +95728,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CALL_METHOD(&dialect, connection, "getdialect", NULL, 0); zephir_check_call_status(); ZEPHIR_OBS_VAR(fields); - zephir_array_fetch_string(&fields, intermediate, SL("fields"), PH_NOISY, "phalcon/mvc/model/query.zep", 2835 TSRMLS_CC); + zephir_array_fetch_string(&fields, intermediate, SL("fields"), PH_NOISY, "phalcon/mvc/model/query.zep", 2983 TSRMLS_CC); ZEPHIR_OBS_VAR(values); - zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2836 TSRMLS_CC); + zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2984 TSRMLS_CC); ZEPHIR_INIT_VAR(updateValues); array_init(updateValues); ZEPHIR_CPY_WRT(selectBindParams, bindParams); ZEPHIR_CPY_WRT(selectBindTypes, bindTypes); - zephir_is_iterable(fields, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 2903); + zephir_is_iterable(fields, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 3051); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -95085,17 +95743,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_GET_HMKEY(number, _3, _2); ZEPHIR_GET_HVALUE(field, _4); ZEPHIR_OBS_NVAR(value); - zephir_array_fetch(&value, values, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2851 TSRMLS_CC); + zephir_array_fetch(&value, values, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2999 TSRMLS_CC); ZEPHIR_OBS_NVAR(exprValue); - zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 2852 TSRMLS_CC); + zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 3000 TSRMLS_CC); if (zephir_array_isset_string(field, SS("balias"))) { ZEPHIR_OBS_NVAR(fieldName); - zephir_array_fetch_string(&fieldName, field, SL("balias"), PH_NOISY, "phalcon/mvc/model/query.zep", 2855 TSRMLS_CC); + zephir_array_fetch_string(&fieldName, field, SL("balias"), PH_NOISY, "phalcon/mvc/model/query.zep", 3003 TSRMLS_CC); } else { ZEPHIR_OBS_NVAR(fieldName); - zephir_array_fetch_string(&fieldName, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2857 TSRMLS_CC); + zephir_array_fetch_string(&fieldName, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 3005 TSRMLS_CC); } - zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2860 TSRMLS_CC); + zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 3008 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_5, 260) || ZEPHIR_IS_LONG(_5, 258) || ZEPHIR_IS_LONG(_5, 259)) { ZEPHIR_CALL_METHOD(&updateValue, dialect, "getsqlexpression", &_6, 0, exprValue); @@ -95109,7 +95767,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { } if (ZEPHIR_IS_LONG(_5, 273) || ZEPHIR_IS_LONG(_5, 274) || ZEPHIR_IS_LONG(_5, 277)) { if (Z_TYPE_P(bindParams) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 2877); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 3025); return; } ZEPHIR_CALL_METHOD(&_7, dialect, "getsqlexpression", &_8, 0, exprValue); @@ -95131,14 +95789,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CONCAT_SVS(_12, "Bound parameter '", wildcard, "' cannot be replaced because it's not in the placeholders list"); ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_13, 9, _12); zephir_check_call_status(); - zephir_throw_exception_debug(_11, "phalcon/mvc/model/query.zep", 2885 TSRMLS_CC); + zephir_throw_exception_debug(_11, "phalcon/mvc/model/query.zep", 3033 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } break; } if (ZEPHIR_IS_LONG(_5, 277)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/query.zep", 2890); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/query.zep", 3038); return; } ZEPHIR_INIT_NVAR(updateValue); @@ -95152,13 +95810,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { zephir_array_update_zval(&updateValues, fieldName, &updateValue, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, selectBindParams, selectBindTypes); + ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 337, model, intermediate, selectBindParams, selectBindTypes); zephir_check_call_status(); if (!(zephir_fast_count_int(records TSRMLS_CC))) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_11); ZVAL_BOOL(_11, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 336, _11); zephir_check_call_status(); RETURN_MM(); } @@ -95166,7 +95824,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2915); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 3063); return; } } else { @@ -95191,7 +95849,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_11); ZVAL_BOOL(_11, 0); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11, record); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 336, _11, record); zephir_check_call_status(); RETURN_MM(); } @@ -95202,7 +95860,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_11); ZVAL_BOOL(_11, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 336, _11); zephir_check_call_status(); RETURN_MM(); @@ -95221,13 +95879,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { ZEPHIR_OBS_VAR(models); - zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2962 TSRMLS_CC); + zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 3110 TSRMLS_CC); if (zephir_array_isset_long(models, 1)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Delete from several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 2965); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Delete from several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 3113); return; } ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 2968 TSRMLS_CC); + zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 3116 TSRMLS_CC); ZEPHIR_OBS_VAR(model); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&model, _0, modelName, 0 TSRMLS_CC))) { @@ -95235,13 +95893,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { ZEPHIR_CALL_METHOD(&model, _1, "load", NULL, 0, modelName); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, bindParams, bindTypes); + ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 337, model, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (!(zephir_fast_count_int(records TSRMLS_CC))) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_VAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 336, _2); zephir_check_call_status(); RETURN_MM(); } @@ -95249,7 +95907,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2992); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 3140); return; } } else { @@ -95274,7 +95932,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_2); ZVAL_BOOL(_2, 0); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2, record); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 336, _2, record); zephir_check_call_status(); RETURN_MM(); } @@ -95285,7 +95943,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 336, _2); zephir_check_call_status(); RETURN_MM(); @@ -95318,10 +95976,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getRelatedRecords) { zephir_array_fast_append(_0, _1); zephir_array_update_string(&selectIr, SL("columns"), &_0, PH_COPY | PH_SEPARATE); ZEPHIR_OBS_VAR(_4); - zephir_array_fetch_string(&_4, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 3053 TSRMLS_CC); + zephir_array_fetch_string(&_4, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 3201 TSRMLS_CC); zephir_array_update_string(&selectIr, SL("models"), &_4, PH_COPY | PH_SEPARATE); ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, intermediate, SL("tables"), PH_NOISY, "phalcon/mvc/model/query.zep", 3055 TSRMLS_CC); + zephir_array_fetch_string(&_4, intermediate, SL("tables"), PH_NOISY, "phalcon/mvc/model/query.zep", 3203 TSRMLS_CC); zephir_array_update_string(&selectIr, SL("tables"), &_4, PH_COPY | PH_SEPARATE); ZEPHIR_OBS_VAR(whereConditions); if (zephir_array_isset_string_fetch(&whereConditions, intermediate, SS("where"), 0 TSRMLS_CC)) { @@ -95333,18 +95991,18 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getRelatedRecords) { } ZEPHIR_INIT_VAR(query); object_init_ex(query, phalcon_mvc_model_query_ce); - ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345); + ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 338); zephir_check_call_status(); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 346, _5); + ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 339, _5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_2); ZVAL_LONG(_2, 309); - ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 347, _2); + ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 340, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 348, selectIr); + ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 341, selectIr); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 349, bindParams, bindTypes); + ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 342, bindParams, bindTypes); zephir_check_call_status(); RETURN_MM(); @@ -95373,12 +96031,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { zephir_read_property_this(&cacheOptions, this_ptr, SL("_cacheOptions"), PH_NOISY_CC); if (Z_TYPE_P(cacheOptions) != IS_NULL) { if (Z_TYPE_P(cacheOptions) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid caching options", "phalcon/mvc/model/query.zep", 3101); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid caching options", "phalcon/mvc/model/query.zep", 3249); return; } ZEPHIR_OBS_VAR(key); if (!(zephir_array_isset_string_fetch(&key, cacheOptions, SS("key"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A cache key must be provided to identify the cached resultset in the cache backend", "phalcon/mvc/model/query.zep", 3108); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A cache key must be provided to identify the cached resultset in the cache backend", "phalcon/mvc/model/query.zep", 3256); return; } ZEPHIR_OBS_VAR(lifetime); @@ -95395,14 +96053,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { ZEPHIR_CALL_METHOD(&cache, _0, "getshared", NULL, 0, cacheService); zephir_check_call_status(); if (Z_TYPE_P(cache) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache service must be an object", "phalcon/mvc/model/query.zep", 3127); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache service must be an object", "phalcon/mvc/model/query.zep", 3275); return; } ZEPHIR_CALL_METHOD(&result, cache, "get", NULL, 0, key, lifetime); zephir_check_call_status(); if (Z_TYPE_P(result) != IS_NULL) { if (Z_TYPE_P(result) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache didn't return a valid resultset", "phalcon/mvc/model/query.zep", 3134); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache didn't return a valid resultset", "phalcon/mvc/model/query.zep", 3282); return; } ZEPHIR_INIT_VAR(_1); @@ -95450,7 +96108,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { _2 = Z_TYPE_P(mergedParams) != IS_ARRAY; } if (_2) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameters must be an array", "phalcon/mvc/model/query.zep", 3188); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameters must be an array", "phalcon/mvc/model/query.zep", 3336); return; } _3 = Z_TYPE_P(mergedTypes) != IS_NULL; @@ -95458,29 +96116,29 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { _3 = Z_TYPE_P(mergedTypes) != IS_ARRAY; } if (_3) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter types must be an array", "phalcon/mvc/model/query.zep", 3192); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter types must be an array", "phalcon/mvc/model/query.zep", 3340); return; } ZEPHIR_OBS_VAR(type); zephir_read_property_this(&type, this_ptr, SL("_type"), PH_NOISY_CC); do { if (ZEPHIR_IS_LONG(type, 309)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 350, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 343, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 306)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 351, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 344, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 300)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 352, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 345, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 303)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 353, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 346, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } @@ -95490,14 +96148,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { ZEPHIR_CONCAT_SV(_4, "Unknown statement ", type); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 3215 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 3363 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); if (Z_TYPE_P(cacheOptions) != IS_NULL) { if (!ZEPHIR_IS_LONG(type, 309)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only PHQL statements that return resultsets can be cached", "phalcon/mvc/model/query.zep", 3227); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only PHQL statements that return resultsets can be cached", "phalcon/mvc/model/query.zep", 3375); return; } ZEPHIR_CALL_METHOD(NULL, cache, "save", NULL, 0, key, result, lifetime); @@ -95535,7 +96193,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, getSingleResult) { zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 349, bindParams, bindTypes); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 342, bindParams, bindTypes); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(_1, "getfirst", NULL, 0); zephir_check_call_status(); @@ -95707,11 +96365,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, getSql) { _2 = zephir_fetch_nproperty_this(this_ptr, SL("_bindTypes"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_3); ZVAL_BOOL(&_3, 1); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 350, intermediate, _1, _2, &_3); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 343, intermediate, _1, _2, &_3); zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "This type of statement generates multiple SQL statements", "phalcon/mvc/model/query.zep", 3397); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "This type of statement generates multiple SQL statements", "phalcon/mvc/model/query.zep", 3545); return; } @@ -95899,6 +96557,35 @@ static PHP_METHOD(Phalcon_Mvc_Model_Relation, getOptions) { } +static PHP_METHOD(Phalcon_Mvc_Model_Relation, getOption) { + + zval *name_param = NULL, *option, *_0; + zval *name = NULL; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &name_param); + + if (unlikely(Z_TYPE_P(name_param) != IS_STRING && Z_TYPE_P(name_param) != IS_NULL)) { + zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'name' must be a string") TSRMLS_CC); + RETURN_MM_NULL(); + } + + if (likely(Z_TYPE_P(name_param) == IS_STRING)) { + zephir_get_strval(name, name_param); + } else { + ZEPHIR_INIT_VAR(name); + ZVAL_EMPTY_STRING(name); + } + + + _0 = zephir_fetch_nproperty_this(this_ptr, SL("_options"), PH_NOISY_CC); + if (zephir_array_isset_fetch(&option, _0, name, 1 TSRMLS_CC)) { + RETURN_CTOR(option); + } + RETURN_MM_NULL(); + +} + static PHP_METHOD(Phalcon_Mvc_Model_Relation, isForeignKey) { zval *options; @@ -96191,7 +96878,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, next) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_pointer"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, (zephir_get_numberval(_0) + 1)); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_1); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -96231,7 +96918,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, rewind) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 0); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_0); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_0); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -96358,7 +97045,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, offsetGet) { if (ZEPHIR_GT_LONG(_0, index)) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, index); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_1); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_1); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "current", NULL, 0); zephir_check_call_status(); @@ -96428,7 +97115,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, getFirst) { } ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_1); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_1); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "current", NULL, 0); zephir_check_call_status(); @@ -96450,7 +97137,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, getLast) { } ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, (zephir_get_numberval(count) - 1)); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_0); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_0); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "current", NULL, 0); zephir_check_call_status(); @@ -96880,7 +97567,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Row, toArray) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 23, this_ptr); + ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM(); @@ -97068,7 +97755,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction, rollback) { ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_mvc_model_transaction_failed_ce); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackRecord"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 360, rollbackMessage, _5); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 353, rollbackMessage, _5); zephir_check_call_status(); zephir_throw_exception_debug(_0, "phalcon/mvc/model/transaction.zep", 160 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -97087,7 +97774,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction, getConnection) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackOnAbort"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 361); + ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 354); zephir_check_call_status(); if (zephir_is_true(_1)) { ZEPHIR_INIT_VAR(_2); @@ -97657,7 +98344,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Behavior_Timestampable, notify) { ZVAL_NULL(timestamp); ZEPHIR_OBS_VAR(format); if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format); + ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 293, format); zephir_check_call_status(); } else { ZEPHIR_OBS_VAR(generator); @@ -97773,7 +98460,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Apc, read) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_prefix"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); - ZEPHIR_CALL_FUNCTION(&data, "apc_fetch", NULL, 79, _1); + ZEPHIR_CALL_FUNCTION(&data, "apc_fetch", NULL, 81, _1); zephir_check_call_status(); if (Z_TYPE_P(data) == IS_ARRAY) { RETURN_CCTOR(data); @@ -97808,7 +98495,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Apc, write) { ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); _2 = zephir_fetch_nproperty_this(this_ptr, SL("_ttl"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "apc_store", NULL, 80, _1, data, _2); + ZEPHIR_CALL_FUNCTION(NULL, "apc_store", NULL, 82, _1, data, _2); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -98013,9 +98700,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 312, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -98114,7 +98801,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, reset) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 320); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 313); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -98199,9 +98886,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 314, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -98300,7 +98987,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, reset) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 320); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 313); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -98477,9 +99164,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 315, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -98578,7 +99265,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, reset) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_redis_ce, this_ptr, "reset", &_5, 320); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_redis_ce, this_ptr, "reset", &_5, 313); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -98794,7 +99481,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Xcache, read) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_prefix"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); - ZEPHIR_CALL_FUNCTION(&data, "xcache_get", NULL, 81, _1); + ZEPHIR_CALL_FUNCTION(&data, "xcache_get", NULL, 83, _1); zephir_check_call_status(); if (Z_TYPE_P(data) == IS_ARRAY) { RETURN_CCTOR(data); @@ -98829,7 +99516,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Xcache, write) { ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); _2 = zephir_fetch_nproperty_this(this_ptr, SL("_ttl"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, _1, data, _2); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, _1, data, _2); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -99697,14 +100384,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, from) { static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, addFrom) { - zval *model, *alias = NULL, *models = NULL, *currentModel = NULL; + zval *model, *alias = NULL, *with = NULL, *models = NULL, *currentModel = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 1, &model, &alias); + zephir_fetch_params(1, 1, 2, &model, &alias, &with); if (!alias) { alias = ZEPHIR_GLOBAL(global_null); } + if (!with) { + with = ZEPHIR_GLOBAL(global_null); + } ZEPHIR_OBS_VAR(models); @@ -99723,7 +100413,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, addFrom) { if (Z_TYPE_P(alias) == IS_STRING) { zephir_array_update_zval(&models, alias, &model, PH_COPY | PH_SEPARATE); } else { - zephir_array_append(&models, model, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 388); + zephir_array_append(&models, model, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 395); } zephir_update_property_this(this_ptr, SL("_models"), models TSRMLS_CC); RETURN_THIS(); @@ -100194,7 +100884,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, inWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 757); + zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 776); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -100207,7 +100897,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, inWhere) { ZEPHIR_CPY_WRT(key, _0); ZEPHIR_INIT_NVAR(queryKey); ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":"); - zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 748); + zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 767); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); hiddenParam++; } @@ -100266,7 +100956,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, notInWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 800); + zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 819); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -100279,7 +100969,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, notInWhere) { ZEPHIR_CPY_WRT(key, _0); ZEPHIR_INIT_NVAR(queryKey); ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":"); - zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 791); + zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 810); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); hiddenParam++; } @@ -100455,13 +101145,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getGroupBy) { static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { - HashTable *_7, *_10, *_14, *_18, *_21, *_26, *_32; - HashPosition _6, _9, _13, _17, _20, _25, _31; + HashTable *_7, *_10, *_13, *_18, *_23, *_29; + HashPosition _6, _9, _12, _17, _22, _28; zend_class_entry *_3; int ZEPHIR_LAST_CALL_STATUS; - zephir_fcall_cache_entry *_0 = NULL, *_35 = NULL; + zephir_fcall_cache_entry *_0 = NULL, *_32 = NULL; zend_bool noPrimary, _5; - zval *dependencyInjector = NULL, *models, *conditions = NULL, *model = NULL, *metaData = NULL, *modelInstance, *primaryKeys = NULL, *firstPrimaryKey, *columnMap = NULL, *modelAlias = NULL, *attributeField = NULL, *phql = NULL, *column = NULL, *columns, *selectedColumns = NULL, *selectedColumn = NULL, *selectedModel = NULL, *selectedModels, *columnAlias = NULL, *modelColumnAlias = NULL, *joins, *join = NULL, *joinModel = NULL, *joinConditions = NULL, *joinAlias = NULL, *joinType = NULL, *group = NULL, *groupItems = NULL, *groupItem = NULL, *having, *order, *orderItems, *orderItem = NULL, *limit, *number = NULL, *offset = NULL, *forUpdate, *distinct, *withModels, *hiddenParam, *_1 = NULL, *_2 = NULL, *_4 = NULL, **_8, **_11, *_12 = NULL, **_15, *_16 = NULL, **_19, **_22, *_23 = NULL, *_24 = NULL, **_27, *_28 = NULL, _29 = zval_used_for_init, _30, **_33, *_34 = NULL, *_36, *_37; + zval *dependencyInjector = NULL, *models, *conditions = NULL, *model = NULL, *metaData = NULL, *modelInstance, *primaryKeys = NULL, *firstPrimaryKey, *columnMap = NULL, *modelAlias = NULL, *attributeField = NULL, *phql = NULL, *column = NULL, *columns, *selectedColumns = NULL, *selectedColumn = NULL, *selectedModel = NULL, *selectedModels, *columnAlias = NULL, *modelColumnAlias = NULL, *joins, *join = NULL, *joinModel = NULL, *joinConditions = NULL, *joinAlias = NULL, *joinType = NULL, *group = NULL, *groupItems = NULL, *groupItem = NULL, *having, *order, *orderItems, *orderItem = NULL, *limit, *number = NULL, *offset = NULL, *forUpdate, *distinct, *_1 = NULL, *_2 = NULL, *_4 = NULL, **_8, **_11, **_14, *_15 = NULL, *_16 = NULL, **_19, *_20 = NULL, *_21 = NULL, **_24, *_25 = NULL, _26 = zval_used_for_init, _27, **_30, *_31 = NULL, *_33, *_34, *_35, *_36; ZEPHIR_MM_GROW(); @@ -100476,12 +101166,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { zephir_read_property_this(&models, this_ptr, SL("_models"), PH_NOISY_CC); if (Z_TYPE_P(models) == IS_ARRAY) { if (!(zephir_fast_count_int(models TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 981); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 1000); return; } } else { if (!(zephir_is_true(models))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 985); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 1004); return; } } @@ -100490,11 +101180,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (zephir_is_numeric(conditions)) { if (Z_TYPE_P(models) == IS_ARRAY) { if (zephir_fast_count_int(models TSRMLS_CC) > 1) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot build the query. Invalid condition", "phalcon/mvc/model/query/builder.zep", 997); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot build the query. Invalid condition", "phalcon/mvc/model/query/builder.zep", 1017); return; } ZEPHIR_OBS_VAR(model); - zephir_array_fetch_long(&model, models, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 999 TSRMLS_CC); + zephir_array_fetch_long(&model, models, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1019 TSRMLS_CC); } else { ZEPHIR_CPY_WRT(model, models); } @@ -100533,7 +101223,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZEPHIR_CONCAT_SVS(_4, "Column '", firstPrimaryKey, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query/builder.zep", 1027 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query/builder.zep", 1047 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -100547,7 +101237,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { } } if (noPrimary == 1) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Source related to this model does not have a primary key defined", "phalcon/mvc/model/query/builder.zep", 1042); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Source related to this model does not have a primary key defined", "phalcon/mvc/model/query/builder.zep", 1062); return; } } @@ -100574,7 +101264,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(columns) == IS_ARRAY) { ZEPHIR_INIT_VAR(selectedColumns); array_init(selectedColumns); - zephir_is_iterable(columns, &_7, &_6, 0, 0, "phalcon/mvc/model/query/builder.zep", 1074); + zephir_is_iterable(columns, &_7, &_6, 0, 0, "phalcon/mvc/model/query/builder.zep", 1098); for ( ; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS ; zephir_hash_move_forward_ex(_7, &_6) @@ -100582,11 +101272,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZEPHIR_GET_HMKEY(columnAlias, _7, _6); ZEPHIR_GET_HVALUE(column, _8); if (Z_TYPE_P(columnAlias) == IS_LONG) { - zephir_array_append(&selectedColumns, column, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1068); + zephir_array_append(&selectedColumns, column, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1088); } else { - ZEPHIR_INIT_LNVAR(_4); - ZEPHIR_CONCAT_VSV(_4, column, " AS ", columnAlias); - zephir_array_append(&selectedColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1070); + if (zephir_memnstr_str(columnAlias, SL("["), "phalcon/mvc/model/query/builder.zep", 1090)) { + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_VSV(_4, column, " AS ", columnAlias); + zephir_array_append(&selectedColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1091); + } else { + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_VSVS(_4, column, " AS [", columnAlias, "]"); + zephir_array_append(&selectedColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1093); + } } } ZEPHIR_INIT_NVAR(_1); @@ -100599,7 +101295,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(models) == IS_ARRAY) { ZEPHIR_INIT_NVAR(selectedColumns); array_init(selectedColumns); - zephir_is_iterable(models, &_10, &_9, 0, 0, "phalcon/mvc/model/query/builder.zep", 1097); + zephir_is_iterable(models, &_10, &_9, 0, 0, "phalcon/mvc/model/query/builder.zep", 1121); for ( ; zephir_hash_get_current_data_ex(_10, (void**) &_11, &_9) == SUCCESS ; zephir_hash_move_forward_ex(_10, &_9) @@ -100612,136 +101308,115 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { } else { ZEPHIR_CONCAT_SVS(selectedColumn, "[", modelColumnAlias, "].*"); } - zephir_array_append(&selectedColumns, selectedColumn, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1094); + zephir_array_append(&selectedColumns, selectedColumn, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1118); } ZEPHIR_INIT_NVAR(_1); zephir_fast_join_str(_1, SL(", "), selectedColumns TSRMLS_CC); zephir_concat_self(&phql, _1 TSRMLS_CC); } else { - ZEPHIR_INIT_VAR(_12); - ZEPHIR_CONCAT_SVS(_12, "[", models, "].*"); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_SVS(_4, "[", models, "].*"); + zephir_concat_self(&phql, _4 TSRMLS_CC); } } if (Z_TYPE_P(models) == IS_ARRAY) { ZEPHIR_INIT_VAR(selectedModels); array_init(selectedModels); - zephir_is_iterable(models, &_14, &_13, 0, 0, "phalcon/mvc/model/query/builder.zep", 1128); + zephir_is_iterable(models, &_13, &_12, 0, 0, "phalcon/mvc/model/query/builder.zep", 1152); for ( - ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS - ; zephir_hash_move_forward_ex(_14, &_13) + ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS + ; zephir_hash_move_forward_ex(_13, &_12) ) { - ZEPHIR_GET_HMKEY(modelAlias, _14, _13); - ZEPHIR_GET_HVALUE(model, _15); + ZEPHIR_GET_HMKEY(modelAlias, _13, _12); + ZEPHIR_GET_HVALUE(model, _14); if (Z_TYPE_P(modelAlias) == IS_STRING) { ZEPHIR_INIT_NVAR(selectedModel); - if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1112)) { + if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1136)) { ZEPHIR_CONCAT_VSVS(selectedModel, model, " AS [", modelAlias, "]"); } else { ZEPHIR_CONCAT_SVSVS(selectedModel, "[", model, "] AS [", modelAlias, "]"); } } else { - if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1118)) { + if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1142)) { ZEPHIR_CPY_WRT(selectedModel, model); } else { ZEPHIR_INIT_NVAR(selectedModel); ZEPHIR_CONCAT_SVS(selectedModel, "[", model, "]"); } } - zephir_array_append(&selectedModels, selectedModel, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1125); + zephir_array_append(&selectedModels, selectedModel, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1149); } ZEPHIR_INIT_NVAR(_1); zephir_fast_join_str(_1, SL(", "), selectedModels TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " FROM ", _1); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_VAR(_15); + ZEPHIR_CONCAT_SV(_15, " FROM ", _1); + zephir_concat_self(&phql, _15 TSRMLS_CC); } else { - if (zephir_memnstr_str(models, SL("["), "phalcon/mvc/model/query/builder.zep", 1132)) { + if (zephir_memnstr_str(models, SL("["), "phalcon/mvc/model/query/builder.zep", 1156)) { + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SVS(_15, " FROM ", models, ""); + zephir_concat_self(&phql, _15 TSRMLS_CC); + } else { ZEPHIR_INIT_VAR(_16); - ZEPHIR_CONCAT_SVS(_16, " FROM ", models, ""); + ZEPHIR_CONCAT_SVS(_16, " FROM [", models, "]"); zephir_concat_self(&phql, _16 TSRMLS_CC); - } else { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SVS(_12, " FROM [", models, "]"); - zephir_concat_self(&phql, _12 TSRMLS_CC); } } - ZEPHIR_OBS_VAR(withModels); - zephir_read_property_this(&withModels, this_ptr, SL("_with"), PH_NOISY_CC); - if (Z_TYPE_P(withModels) == IS_ARRAY) { - ZEPHIR_INIT_NVAR(selectedColumns); - array_init(selectedColumns); - zephir_is_iterable(withModels, &_18, &_17, 0, 0, "phalcon/mvc/model/query/builder.zep", 1150); - for ( - ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS - ; zephir_hash_move_forward_ex(_18, &_17) - ) { - ZEPHIR_GET_HVALUE(model, _19); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SVS(_12, "[", model, "]"); - zephir_array_append(&selectedColumns, _12, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1147); - } - ZEPHIR_INIT_NVAR(_1); - zephir_fast_join_str(_1, SL(", "), selectedColumns TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " WITH ", _1); - zephir_concat_self(&phql, _12 TSRMLS_CC); - } ZEPHIR_OBS_VAR(joins); zephir_read_property_this(&joins, this_ptr, SL("_joins"), PH_NOISY_CC); if (Z_TYPE_P(joins) == IS_ARRAY) { - zephir_is_iterable(joins, &_21, &_20, 0, 0, "phalcon/mvc/model/query/builder.zep", 1212); + zephir_is_iterable(joins, &_18, &_17, 0, 0, "phalcon/mvc/model/query/builder.zep", 1222); for ( - ; zephir_hash_get_current_data_ex(_21, (void**) &_22, &_20) == SUCCESS - ; zephir_hash_move_forward_ex(_21, &_20) + ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS + ; zephir_hash_move_forward_ex(_18, &_17) ) { - ZEPHIR_GET_HVALUE(join, _22); + ZEPHIR_GET_HVALUE(join, _19); ZEPHIR_OBS_NVAR(joinModel); - zephir_array_fetch_long(&joinModel, join, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1164 TSRMLS_CC); + zephir_array_fetch_long(&joinModel, join, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1174 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinConditions); - zephir_array_fetch_long(&joinConditions, join, 1, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1169 TSRMLS_CC); + zephir_array_fetch_long(&joinConditions, join, 1, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1179 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinAlias); - zephir_array_fetch_long(&joinAlias, join, 2, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1174 TSRMLS_CC); + zephir_array_fetch_long(&joinAlias, join, 2, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1184 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinType); - zephir_array_fetch_long(&joinType, join, 3, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1179 TSRMLS_CC); + zephir_array_fetch_long(&joinType, join, 3, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1189 TSRMLS_CC); if (zephir_is_true(joinType)) { - if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1185)) { + if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1195)) { + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SVSV(_15, " ", joinType, " JOIN ", joinModel); + zephir_concat_self(&phql, _15 TSRMLS_CC); + } else { ZEPHIR_INIT_LNVAR(_16); - ZEPHIR_CONCAT_SVSV(_16, " ", joinType, " JOIN ", joinModel); + ZEPHIR_CONCAT_SVSVS(_16, " ", joinType, " JOIN [", joinModel, "]"); zephir_concat_self(&phql, _16 TSRMLS_CC); - } else { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVSVS(_23, " ", joinType, " JOIN [", joinModel, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); } } else { - if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1191)) { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " JOIN ", joinModel, ""); - zephir_concat_self(&phql, _23 TSRMLS_CC); + if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1201)) { + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " JOIN ", joinModel, ""); + zephir_concat_self(&phql, _20 TSRMLS_CC); } else { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " JOIN [", joinModel, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " JOIN [", joinModel, "]"); + zephir_concat_self(&phql, _20 TSRMLS_CC); } } if (zephir_is_true(joinAlias)) { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " AS [", joinAlias, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " AS [", joinAlias, "]"); + zephir_concat_self(&phql, _20 TSRMLS_CC); } if (zephir_is_true(joinConditions)) { - ZEPHIR_INIT_LNVAR(_24); - ZEPHIR_CONCAT_SV(_24, " ON ", joinConditions); - zephir_concat_self(&phql, _24 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_21); + ZEPHIR_CONCAT_SV(_21, " ON ", joinConditions); + zephir_concat_self(&phql, _21 TSRMLS_CC); } } } if (Z_TYPE_P(conditions) == IS_STRING) { if (!(ZEPHIR_IS_EMPTY(conditions))) { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " WHERE ", conditions); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SV(_15, " WHERE ", conditions); + zephir_concat_self(&phql, _15 TSRMLS_CC); } } ZEPHIR_OBS_VAR(group); @@ -100750,21 +101425,21 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(group) == IS_ARRAY) { ZEPHIR_INIT_VAR(groupItems); array_init(groupItems); - zephir_is_iterable(group, &_26, &_25, 0, 0, "phalcon/mvc/model/query/builder.zep", 1239); + zephir_is_iterable(group, &_23, &_22, 0, 0, "phalcon/mvc/model/query/builder.zep", 1249); for ( - ; zephir_hash_get_current_data_ex(_26, (void**) &_27, &_25) == SUCCESS - ; zephir_hash_move_forward_ex(_26, &_25) + ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS + ; zephir_hash_move_forward_ex(_23, &_22) ) { - ZEPHIR_GET_HVALUE(groupItem, _27); + ZEPHIR_GET_HVALUE(groupItem, _24); if (zephir_is_numeric(groupItem)) { - zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1230); + zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1240); } else { - if (zephir_memnstr_str(groupItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1232)) { - zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1233); + if (zephir_memnstr_str(groupItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1242)) { + zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1243); } else { ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, "[", groupItem, "]"); - zephir_array_append(&groupItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1235); + zephir_array_append(&groupItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1245); } } } @@ -100775,30 +101450,30 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { zephir_concat_self(&phql, _4 TSRMLS_CC); } else { if (zephir_is_numeric(group)) { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " GROUP BY ", group); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SV(_15, " GROUP BY ", group); + zephir_concat_self(&phql, _15 TSRMLS_CC); } else { - if (zephir_memnstr_str(group, SL("."), "phalcon/mvc/model/query/builder.zep", 1244)) { + if (zephir_memnstr_str(group, SL("."), "phalcon/mvc/model/query/builder.zep", 1254)) { ZEPHIR_INIT_LNVAR(_16); ZEPHIR_CONCAT_SV(_16, " GROUP BY ", group); zephir_concat_self(&phql, _16 TSRMLS_CC); } else { - if (zephir_memnstr_str(group, SL(","), "phalcon/mvc/model/query/builder.zep", 1247)) { - ZEPHIR_INIT_VAR(_28); - ZEPHIR_SINIT_VAR(_29); - ZVAL_STRING(&_29, " ", 0); - ZEPHIR_SINIT_VAR(_30); - ZVAL_STRING(&_30, "", 0); - zephir_fast_str_replace(&_28, &_29, &_30, group TSRMLS_CC); - ZEPHIR_CPY_WRT(group, _28); + if (zephir_memnstr_str(group, SL(","), "phalcon/mvc/model/query/builder.zep", 1257)) { + ZEPHIR_INIT_VAR(_25); + ZEPHIR_SINIT_VAR(_26); + ZVAL_STRING(&_26, " ", 0); + ZEPHIR_SINIT_VAR(_27); + ZVAL_STRING(&_27, "", 0); + zephir_fast_str_replace(&_25, &_26, &_27, group TSRMLS_CC); + ZEPHIR_CPY_WRT(group, _25); ZEPHIR_INIT_NVAR(groupItems); zephir_fast_explode_str(groupItems, SL(","), group, LONG_MAX TSRMLS_CC); - ZEPHIR_INIT_NVAR(_28); - zephir_fast_join_str(_28, SL("], ["), groupItems TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " GROUP BY [", _28, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_25); + zephir_fast_join_str(_25, SL("], ["), groupItems TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " GROUP BY [", _25, "]"); + zephir_concat_self(&phql, _20 TSRMLS_CC); } else { ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, " GROUP BY [", group, "]"); @@ -100823,21 +101498,21 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(order) == IS_ARRAY) { ZEPHIR_INIT_VAR(orderItems); array_init(orderItems); - zephir_is_iterable(order, &_32, &_31, 0, 0, "phalcon/mvc/model/query/builder.zep", 1284); + zephir_is_iterable(order, &_29, &_28, 0, 0, "phalcon/mvc/model/query/builder.zep", 1294); for ( - ; zephir_hash_get_current_data_ex(_32, (void**) &_33, &_31) == SUCCESS - ; zephir_hash_move_forward_ex(_32, &_31) + ; zephir_hash_get_current_data_ex(_29, (void**) &_30, &_28) == SUCCESS + ; zephir_hash_move_forward_ex(_29, &_28) ) { - ZEPHIR_GET_HVALUE(orderItem, _33); + ZEPHIR_GET_HVALUE(orderItem, _30); if (zephir_is_numeric(orderItem)) { - zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1275); + zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1285); } else { - if (zephir_memnstr_str(orderItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1277)) { - zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1278); + if (zephir_memnstr_str(orderItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1287)) { + zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1288); } else { ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, "[", orderItem, "]"); - zephir_array_append(&orderItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1280); + zephir_array_append(&orderItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1290); } } } @@ -100847,9 +101522,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZEPHIR_CONCAT_SV(_4, " ORDER BY ", _1); zephir_concat_self(&phql, _4 TSRMLS_CC); } else { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " ORDER BY ", order); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SV(_15, " ORDER BY ", order); + zephir_concat_self(&phql, _15 TSRMLS_CC); } } ZEPHIR_OBS_VAR(limit); @@ -100859,7 +101534,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZVAL_NULL(number); if (Z_TYPE_P(limit) == IS_ARRAY) { ZEPHIR_OBS_NVAR(number); - zephir_array_fetch_string(&number, limit, SL("number"), PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1299 TSRMLS_CC); + zephir_array_fetch_string(&number, limit, SL("number"), PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1309 TSRMLS_CC); ZEPHIR_OBS_VAR(offset); if (zephir_array_isset_string_fetch(&offset, limit, SS("offset"), 0 TSRMLS_CC)) { if (!(zephir_is_numeric(offset))) { @@ -100881,45 +101556,34 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { } } if (zephir_is_numeric(number)) { - ZEPHIR_OBS_VAR(hiddenParam); - zephir_read_property_this(&hiddenParam, this_ptr, SL("_hiddenParamNumber"), PH_NOISY_CC); - ZEPHIR_INIT_LNVAR(_4); - ZEPHIR_CONCAT_SVS(_4, " LIMIT :AP", hiddenParam, ":"); - zephir_concat_self(&phql, _4 TSRMLS_CC); - ZEPHIR_SINIT_NVAR(_29); - ZVAL_LONG(&_29, 10); - ZEPHIR_CALL_FUNCTION(&_34, "intval", &_35, 25, number, &_29); + zephir_concat_self_str(&phql, SL(" LIMIT :APL0:") TSRMLS_CC); + ZEPHIR_SINIT_NVAR(_26); + ZVAL_LONG(&_26, 10); + ZEPHIR_CALL_FUNCTION(&_31, "intval", &_32, 26, number, &_26); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, "AP", hiddenParam); - zephir_update_property_array(this_ptr, SL("_bindParams"), _12, _34 TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_16); - ZEPHIR_CONCAT_SV(_16, "AP", hiddenParam); ZEPHIR_INIT_NVAR(_1); - ZVAL_LONG(_1, 1); - zephir_update_property_array(this_ptr, SL("_bindTypes"), _16, _1 TSRMLS_CC); + ZVAL_STRING(_1, "APL0", 1); + zephir_update_property_array(this_ptr, SL("_bindParams"), _1, _31 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_25); + ZVAL_STRING(_25, "APL0", 1); + ZEPHIR_INIT_VAR(_33); + ZVAL_LONG(_33, 1); + zephir_update_property_array(this_ptr, SL("_bindTypes"), _25, _33 TSRMLS_CC); if (zephir_is_numeric(offset)) { - ZEPHIR_SEPARATE(hiddenParam); - zephir_increment(hiddenParam); - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " OFFSET :AP", hiddenParam, ":"); - zephir_concat_self(&phql, _23 TSRMLS_CC); - ZEPHIR_SINIT_NVAR(_29); - ZVAL_LONG(&_29, 10); - ZEPHIR_CALL_FUNCTION(&_34, "intval", &_35, 25, offset, &_29); + zephir_concat_self_str(&phql, SL(" OFFSET :APL1:") TSRMLS_CC); + ZEPHIR_SINIT_NVAR(_26); + ZVAL_LONG(&_26, 10); + ZEPHIR_CALL_FUNCTION(&_31, "intval", &_32, 26, offset, &_26); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_24); - ZEPHIR_CONCAT_SV(_24, "AP", hiddenParam); - zephir_update_property_array(this_ptr, SL("_bindParams"), _24, _34 TSRMLS_CC); + ZEPHIR_INIT_VAR(_34); + ZVAL_STRING(_34, "APL1", 1); + zephir_update_property_array(this_ptr, SL("_bindParams"), _34, _31 TSRMLS_CC); + ZEPHIR_INIT_VAR(_35); + ZVAL_STRING(_35, "APL1", 1); ZEPHIR_INIT_VAR(_36); - ZEPHIR_CONCAT_SV(_36, "AP", hiddenParam); - ZEPHIR_INIT_NVAR(_28); - ZVAL_LONG(_28, 1); - zephir_update_property_array(this_ptr, SL("_bindTypes"), _36, _28 TSRMLS_CC); + ZVAL_LONG(_36, 1); + zephir_update_property_array(this_ptr, SL("_bindTypes"), _35, _36 TSRMLS_CC); } - ZEPHIR_INIT_ZVAL_NREF(_37); - ZVAL_LONG(_37, (zephir_get_numberval(hiddenParam) + 1)); - zephir_update_property_this(this_ptr, SL("_hiddenParamNumber"), _37 TSRMLS_CC); } } forUpdate = zephir_fetch_nproperty_this(this_ptr, SL("_forUpdate"), PH_NOISY_CC); @@ -100941,21 +101605,21 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getQuery) { ZEPHIR_INIT_VAR(query); object_init_ex(query, phalcon_mvc_model_query_ce); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 354); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 347); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345, _0, _1); + ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 338, _0, _1); zephir_check_call_status(); ZEPHIR_OBS_VAR(bindParams); zephir_read_property_this(&bindParams, this_ptr, SL("_bindParams"), PH_NOISY_CC); if (Z_TYPE_P(bindParams) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 355, bindParams); + ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 348, bindParams); zephir_check_call_status(); } ZEPHIR_OBS_VAR(bindTypes); zephir_read_property_this(&bindTypes, this_ptr, SL("_bindTypes"), PH_NOISY_CC); if (Z_TYPE_P(bindTypes) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 356, bindTypes); + ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 349, bindTypes); zephir_check_call_status(); } RETURN_CCTOR(query); @@ -101210,7 +101874,7 @@ static zval *phql_ret_select_statement(zval *S, zval *W, zval *O, zval *G, zval return ret; } -static zval *phql_ret_select_clause(zval *distinct, zval *columns, zval *tables, zval *with_list, zval *join_list) +static zval *phql_ret_select_clause(zval *distinct, zval *columns, zval *tables, zval *join_list) { zval *ret; @@ -101224,10 +101888,6 @@ static zval *phql_ret_select_clause(zval *distinct, zval *columns, zval *tables, add_assoc_zval(ret, "columns", columns); add_assoc_zval(ret, "tables", tables); - if (with_list) { - add_assoc_zval(ret, "with", with_list); - } - if (join_list) { add_assoc_zval(ret, "joins", join_list); } @@ -101446,7 +102106,7 @@ static zval *phql_ret_column_item(int type, zval *column, phql_parser_token *ide return ret; } -static zval *phql_ret_assoc_name(zval *qualified_name, phql_parser_token *alias) +static zval *phql_ret_assoc_name(zval *qualified_name, phql_parser_token *alias, zval *with) { zval *ret; @@ -101454,11 +102114,16 @@ static zval *phql_ret_assoc_name(zval *qualified_name, phql_parser_token *alias) MAKE_STD_ZVAL(ret); array_init(ret); add_assoc_zval(ret, "qualifiedName", qualified_name); + if (alias) { add_assoc_stringl(ret, "alias", alias->token, alias->token_len, 0); efree(alias); } + if (with) { + add_assoc_zval(ret, "with", with); + } + return ret; } @@ -101536,7 +102201,7 @@ static zval *phql_ret_func_call(phql_parser_token *name, zval *arguments, zval * } -// 459 "parser.c" +// 460 "parser.c" /* Next is all token values, in a form suitable for use by makeheaders. ** This section will be null unless lemon is run with the -m switch. */ @@ -101579,23 +102244,23 @@ static zval *phql_ret_func_call(phql_parser_token *name, zval *arguments, zval * ** defined, then do no error processing. */ #define PPCODETYPE unsigned char -#define PPNOCODE 135 +#define PPNOCODE 134 #define PPACTIONTYPE unsigned short int #define phql_TOKENTYPE phql_parser_token* typedef union { phql_TOKENTYPE pp0; - zval* pp244; - int pp269; + zval* pp162; + int pp267; } PPMINORTYPE; #define PPSTACKDEPTH 100 #define phql_ARG_SDECL phql_parser_status *status; #define phql_ARG_PDECL ,phql_parser_status *status #define phql_ARG_FETCH phql_parser_status *status = pppParser->status #define phql_ARG_STORE pppParser->status = status -#define PPNSTATE 280 -#define PPNRULE 157 +#define PPNSTATE 293 +#define PPNRULE 161 #define PPERRORSYMBOL 79 -#define PPERRSYMDT pp269 +#define PPERRSYMDT pp267 #define PP_NO_ACTION (PPNSTATE+PPNRULE+2) #define PP_ACCEPT_ACTION (PPNSTATE+PPNRULE+1) #define PP_ERROR_ACTION (PPNSTATE+PPNRULE) @@ -101648,254 +102313,266 @@ typedef union { ** pp_default[] Default action for each state. */ static PPACTIONTYPE pp_action[] = { - /* 0 */ 92, 98, 55, 57, 59, 61, 63, 65, 45, 47, + /* 0 */ 120, 126, 55, 57, 59, 61, 63, 65, 45, 47, /* 10 */ 67, 72, 49, 51, 53, 41, 39, 43, 37, 34, - /* 20 */ 94, 74, 69, 92, 98, 55, 57, 59, 61, 63, + /* 20 */ 122, 74, 69, 120, 126, 55, 57, 59, 61, 63, /* 30 */ 65, 45, 47, 67, 72, 49, 51, 53, 41, 39, - /* 40 */ 43, 37, 34, 94, 74, 69, 19, 20, 21, 22, - /* 50 */ 23, 106, 32, 33, 92, 98, 55, 57, 59, 61, - /* 60 */ 63, 65, 45, 47, 67, 72, 49, 51, 53, 41, - /* 70 */ 39, 43, 37, 34, 94, 74, 69, 94, 74, 69, - /* 80 */ 82, 70, 215, 207, 83, 205, 185, 85, 165, 86, - /* 90 */ 163, 193, 217, 126, 196, 160, 234, 92, 98, 55, + /* 40 */ 43, 37, 34, 122, 74, 69, 37, 34, 122, 74, + /* 50 */ 69, 166, 220, 92, 218, 45, 47, 67, 72, 49, + /* 60 */ 51, 53, 41, 39, 43, 37, 34, 122, 74, 69, + /* 70 */ 154, 429, 186, 91, 120, 126, 55, 57, 59, 61, + /* 80 */ 63, 65, 45, 47, 67, 72, 49, 51, 53, 41, + /* 90 */ 39, 43, 37, 34, 122, 74, 69, 120, 126, 55, /* 100 */ 57, 59, 61, 63, 65, 45, 47, 67, 72, 49, - /* 110 */ 51, 53, 41, 39, 43, 37, 34, 94, 74, 69, - /* 120 */ 92, 98, 55, 57, 59, 61, 63, 65, 45, 47, - /* 130 */ 67, 72, 49, 51, 53, 41, 39, 43, 37, 34, - /* 140 */ 94, 74, 69, 92, 98, 55, 57, 59, 61, 63, + /* 110 */ 51, 53, 41, 39, 43, 37, 34, 122, 74, 69, + /* 120 */ 19, 20, 21, 22, 23, 227, 32, 33, 67, 72, + /* 130 */ 49, 51, 53, 41, 39, 43, 37, 34, 122, 74, + /* 140 */ 69, 130, 238, 120, 126, 55, 57, 59, 61, 63, /* 150 */ 65, 45, 47, 67, 72, 49, 51, 53, 41, 39, - /* 160 */ 43, 37, 34, 94, 74, 69, 239, 247, 128, 45, - /* 170 */ 47, 67, 72, 49, 51, 53, 41, 39, 43, 37, - /* 180 */ 34, 94, 74, 69, 266, 273, 269, 118, 102, 92, - /* 190 */ 98, 55, 57, 59, 61, 63, 65, 45, 47, 67, - /* 200 */ 72, 49, 51, 53, 41, 39, 43, 37, 34, 94, - /* 210 */ 74, 69, 438, 1, 2, 3, 4, 5, 6, 198, - /* 220 */ 112, 79, 92, 98, 55, 57, 59, 61, 63, 65, + /* 160 */ 43, 37, 34, 122, 74, 69, 41, 39, 43, 37, + /* 170 */ 34, 122, 74, 69, 140, 8, 120, 126, 55, 57, + /* 180 */ 59, 61, 63, 65, 45, 47, 67, 72, 49, 51, + /* 190 */ 53, 41, 39, 43, 37, 34, 122, 74, 69, 120, + /* 200 */ 126, 55, 57, 59, 61, 63, 65, 45, 47, 67, + /* 210 */ 72, 49, 51, 53, 41, 39, 43, 37, 34, 122, + /* 220 */ 74, 69, 120, 126, 55, 57, 59, 61, 63, 65, /* 230 */ 45, 47, 67, 72, 49, 51, 53, 41, 39, 43, - /* 240 */ 37, 34, 94, 74, 69, 140, 107, 258, 35, 96, - /* 250 */ 6, 141, 143, 274, 124, 126, 248, 160, 131, 257, - /* 260 */ 67, 72, 49, 51, 53, 41, 39, 43, 37, 34, - /* 270 */ 94, 74, 69, 100, 413, 49, 51, 53, 41, 39, - /* 280 */ 43, 37, 34, 94, 74, 69, 268, 269, 146, 147, - /* 290 */ 153, 154, 155, 105, 109, 115, 367, 121, 84, 85, - /* 300 */ 95, 86, 150, 148, 149, 151, 152, 55, 57, 59, - /* 310 */ 61, 63, 65, 45, 47, 67, 72, 49, 51, 53, - /* 320 */ 41, 39, 43, 37, 34, 94, 74, 69, 140, 7, - /* 330 */ 254, 35, 134, 183, 141, 143, 181, 76, 191, 245, - /* 340 */ 189, 131, 41, 39, 43, 37, 34, 94, 74, 69, - /* 350 */ 252, 249, 145, 246, 261, 140, 100, 238, 35, 145, - /* 360 */ 137, 141, 143, 130, 179, 135, 156, 177, 131, 166, - /* 370 */ 130, 146, 147, 153, 154, 155, 105, 109, 115, 280, - /* 380 */ 121, 87, 186, 100, 281, 150, 148, 149, 151, 152, - /* 390 */ 192, 213, 221, 166, 282, 6, 6, 243, 146, 147, - /* 400 */ 153, 154, 155, 105, 109, 115, 138, 121, 134, 134, - /* 410 */ 123, 162, 150, 148, 149, 151, 152, 200, 242, 158, - /* 420 */ 35, 78, 283, 141, 143, 208, 204, 212, 145, 145, - /* 430 */ 201, 175, 284, 132, 173, 76, 211, 219, 227, 130, - /* 440 */ 130, 203, 156, 156, 8, 100, 145, 168, 184, 170, - /* 450 */ 172, 236, 176, 180, 159, 17, 263, 130, 277, 245, - /* 460 */ 146, 147, 153, 154, 155, 105, 109, 115, 232, 121, - /* 470 */ 241, 225, 202, 246, 150, 148, 149, 151, 152, 145, - /* 480 */ 9, 35, 209, 210, 141, 143, 132, 76, 145, 24, - /* 490 */ 130, 131, 103, 229, 233, 243, 6, 26, 138, 130, - /* 500 */ 134, 37, 34, 94, 74, 69, 100, 10, 35, 101, - /* 510 */ 15, 141, 143, 13, 11, 14, 253, 12, 131, 220, - /* 520 */ 145, 146, 147, 153, 154, 155, 105, 109, 115, 145, - /* 530 */ 121, 130, 16, 100, 139, 150, 148, 149, 151, 152, - /* 540 */ 130, 27, 18, 29, 25, 69, 77, 31, 146, 147, - /* 550 */ 153, 154, 155, 105, 109, 115, 75, 121, 81, 232, - /* 560 */ 167, 138, 150, 148, 149, 151, 152, 145, 31, 80, - /* 570 */ 28, 224, 88, 90, 197, 199, 204, 272, 130, 145, - /* 580 */ 89, 188, 412, 97, 38, 231, 104, 76, 145, 108, - /* 590 */ 130, 245, 30, 166, 40, 110, 145, 145, 271, 130, - /* 600 */ 42, 36, 113, 44, 145, 244, 216, 130, 130, 223, - /* 610 */ 114, 145, 119, 125, 145, 130, 157, 133, 46, 116, - /* 620 */ 145, 145, 130, 145, 226, 130, 145, 48, 50, 145, - /* 630 */ 235, 130, 130, 52, 130, 120, 54, 130, 145, 158, - /* 640 */ 130, 159, 136, 164, 145, 169, 313, 145, 145, 130, - /* 650 */ 145, 56, 58, 145, 60, 130, 145, 62, 130, 130, - /* 660 */ 171, 130, 314, 174, 130, 315, 111, 130, 187, 64, - /* 670 */ 66, 145, 145, 316, 145, 188, 117, 145, 68, 91, - /* 680 */ 178, 317, 130, 130, 71, 130, 145, 166, 130, 145, - /* 690 */ 145, 122, 73, 93, 161, 318, 145, 130, 145, 145, - /* 700 */ 130, 130, 182, 319, 145, 320, 321, 130, 99, 130, - /* 710 */ 130, 145, 145, 145, 145, 130, 190, 195, 206, 279, - /* 720 */ 144, 127, 130, 130, 130, 130, 188, 264, 145, 142, - /* 730 */ 129, 194, 228, 230, 188, 214, 218, 237, 166, 130, - /* 740 */ 145, 145, 222, 240, 324, 256, 166, 250, 325, 145, - /* 750 */ 145, 130, 130, 255, 251, 259, 260, 332, 366, 262, - /* 760 */ 130, 130, 265, 267, 270, 275, 276, 338, 278, + /* 240 */ 37, 34, 122, 74, 69, 168, 109, 156, 35, 95, + /* 250 */ 99, 169, 171, 26, 76, 151, 188, 81, 159, 160, + /* 260 */ 82, 111, 209, 113, 114, 17, 146, 285, 192, 208, + /* 270 */ 194, 196, 128, 200, 204, 222, 223, 455, 1, 2, + /* 280 */ 3, 4, 5, 6, 199, 173, 284, 197, 174, 175, + /* 290 */ 181, 182, 183, 133, 137, 143, 76, 149, 158, 24, + /* 300 */ 212, 217, 178, 176, 177, 179, 180, 168, 135, 271, + /* 310 */ 35, 249, 6, 169, 171, 287, 276, 110, 290, 173, + /* 320 */ 159, 49, 51, 53, 41, 39, 43, 37, 34, 122, + /* 330 */ 74, 69, 158, 384, 128, 430, 192, 208, 194, 196, + /* 340 */ 80, 200, 204, 292, 210, 122, 74, 69, 84, 84, + /* 350 */ 174, 175, 181, 182, 183, 133, 137, 143, 125, 149, + /* 360 */ 107, 107, 95, 90, 178, 176, 177, 179, 180, 55, + /* 370 */ 57, 59, 61, 63, 65, 45, 47, 67, 72, 49, + /* 380 */ 51, 53, 41, 39, 43, 37, 34, 122, 74, 69, + /* 390 */ 213, 274, 258, 35, 70, 228, 169, 171, 131, 109, + /* 400 */ 245, 265, 6, 214, 259, 230, 279, 286, 282, 234, + /* 410 */ 173, 83, 203, 6, 129, 201, 84, 128, 173, 152, + /* 420 */ 154, 207, 186, 158, 205, 162, 244, 96, 107, 85, + /* 430 */ 219, 158, 173, 174, 175, 181, 182, 183, 133, 137, + /* 440 */ 143, 94, 149, 173, 7, 158, 102, 178, 176, 177, + /* 450 */ 179, 180, 162, 232, 35, 89, 158, 169, 171, 184, + /* 460 */ 76, 112, 113, 114, 159, 211, 215, 79, 94, 78, + /* 470 */ 173, 226, 221, 217, 94, 6, 277, 240, 128, 160, + /* 480 */ 165, 84, 98, 158, 250, 163, 184, 162, 103, 95, + /* 490 */ 104, 173, 94, 107, 174, 175, 181, 182, 183, 133, + /* 500 */ 137, 143, 92, 149, 158, 173, 108, 155, 178, 176, + /* 510 */ 177, 179, 180, 168, 92, 224, 35, 258, 158, 169, + /* 520 */ 171, 184, 100, 27, 258, 173, 159, 166, 216, 257, + /* 530 */ 191, 115, 189, 254, 105, 173, 259, 124, 158, 69, + /* 540 */ 128, 110, 173, 107, 166, 281, 282, 225, 158, 252, + /* 550 */ 260, 31, 253, 10, 251, 158, 174, 175, 181, 182, + /* 560 */ 183, 133, 137, 143, 233, 149, 107, 106, 42, 173, + /* 570 */ 178, 176, 177, 179, 180, 30, 247, 35, 329, 245, + /* 580 */ 169, 171, 158, 147, 31, 229, 173, 159, 123, 328, + /* 590 */ 261, 332, 256, 270, 101, 327, 162, 173, 326, 158, + /* 600 */ 325, 128, 173, 173, 242, 246, 206, 28, 237, 18, + /* 610 */ 158, 50, 255, 202, 173, 158, 158, 174, 175, 181, + /* 620 */ 182, 183, 133, 137, 143, 121, 149, 158, 239, 173, + /* 630 */ 167, 178, 176, 177, 179, 180, 97, 269, 164, 119, + /* 640 */ 148, 263, 158, 173, 324, 264, 173, 71, 15, 132, + /* 650 */ 150, 267, 323, 161, 145, 256, 158, 173, 73, 158, + /* 660 */ 134, 170, 172, 198, 62, 173, 322, 333, 173, 60, + /* 670 */ 158, 262, 173, 66, 93, 266, 173, 195, 158, 173, + /* 680 */ 173, 158, 173, 187, 139, 158, 136, 173, 268, 158, + /* 690 */ 11, 173, 158, 158, 76, 158, 295, 185, 58, 340, + /* 700 */ 158, 173, 173, 56, 158, 272, 236, 36, 321, 54, + /* 710 */ 38, 383, 293, 157, 158, 158, 173, 127, 40, 273, + /* 720 */ 193, 173, 275, 278, 173, 173, 280, 173, 173, 158, + /* 730 */ 190, 173, 68, 52, 158, 173, 173, 158, 158, 138, + /* 740 */ 158, 158, 48, 283, 158, 13, 25, 88, 158, 158, + /* 750 */ 173, 173, 16, 248, 87, 86, 44, 46, 64, 297, + /* 760 */ 173, 294, 141, 158, 158, 296, 142, 288, 153, 289, + /* 770 */ 346, 173, 291, 158, 173, 173, 173, 12, 29, 75, + /* 780 */ 77, 144, 9, 235, 158, 117, 241, 158, 158, 158, + /* 790 */ 118, 231, 243, 296, 116, 14, }; static PPCODETYPE pp_lookahead[] = { /* 0 */ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, /* 10 */ 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, /* 20 */ 21, 22, 23, 1, 2, 3, 4, 5, 6, 7, /* 30 */ 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, - /* 40 */ 18, 19, 20, 21, 22, 23, 60, 61, 62, 63, - /* 50 */ 64, 45, 53, 54, 1, 2, 3, 4, 5, 6, - /* 60 */ 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, - /* 70 */ 17, 18, 19, 20, 21, 22, 23, 21, 22, 23, - /* 80 */ 97, 11, 12, 30, 101, 32, 103, 104, 30, 106, - /* 90 */ 32, 102, 22, 71, 105, 73, 50, 1, 2, 3, + /* 40 */ 18, 19, 20, 21, 22, 23, 19, 20, 21, 22, + /* 50 */ 23, 25, 30, 25, 32, 9, 10, 11, 12, 13, + /* 60 */ 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, + /* 70 */ 71, 45, 73, 45, 1, 2, 3, 4, 5, 6, + /* 80 */ 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, + /* 90 */ 17, 18, 19, 20, 21, 22, 23, 1, 2, 3, /* 100 */ 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, /* 110 */ 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, - /* 120 */ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, - /* 130 */ 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, - /* 140 */ 21, 22, 23, 1, 2, 3, 4, 5, 6, 7, + /* 120 */ 60, 61, 62, 63, 64, 45, 53, 54, 11, 12, + /* 130 */ 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, + /* 140 */ 23, 45, 56, 1, 2, 3, 4, 5, 6, 7, /* 150 */ 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, - /* 160 */ 18, 19, 20, 21, 22, 23, 44, 45, 72, 9, - /* 170 */ 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, - /* 180 */ 20, 21, 22, 23, 117, 118, 119, 68, 46, 1, - /* 190 */ 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, - /* 200 */ 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, - /* 210 */ 22, 23, 80, 81, 82, 83, 84, 85, 86, 25, - /* 220 */ 32, 27, 1, 2, 3, 4, 5, 6, 7, 8, + /* 160 */ 18, 19, 20, 21, 22, 23, 16, 17, 18, 19, + /* 170 */ 20, 21, 22, 23, 32, 88, 1, 2, 3, 4, + /* 180 */ 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, + /* 190 */ 15, 16, 17, 18, 19, 20, 21, 22, 23, 1, + /* 200 */ 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, + /* 210 */ 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, + /* 220 */ 22, 23, 1, 2, 3, 4, 5, 6, 7, 8, /* 230 */ 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, - /* 240 */ 19, 20, 21, 22, 23, 17, 82, 115, 20, 23, - /* 250 */ 86, 23, 24, 121, 70, 71, 111, 73, 30, 114, - /* 260 */ 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, - /* 270 */ 21, 22, 23, 45, 46, 13, 14, 15, 16, 17, - /* 280 */ 18, 19, 20, 21, 22, 23, 118, 119, 60, 61, - /* 290 */ 62, 63, 64, 65, 66, 67, 0, 69, 103, 104, - /* 300 */ 74, 106, 74, 75, 76, 77, 78, 3, 4, 5, - /* 310 */ 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, - /* 320 */ 16, 17, 18, 19, 20, 21, 22, 23, 17, 87, - /* 330 */ 25, 20, 99, 35, 23, 24, 38, 26, 30, 99, - /* 340 */ 32, 30, 16, 17, 18, 19, 20, 21, 22, 23, - /* 350 */ 110, 46, 119, 113, 58, 17, 45, 107, 20, 119, - /* 360 */ 127, 23, 24, 130, 35, 132, 133, 38, 30, 119, - /* 370 */ 130, 60, 61, 62, 63, 64, 65, 66, 67, 0, - /* 380 */ 69, 107, 25, 45, 0, 74, 75, 76, 77, 78, - /* 390 */ 33, 82, 82, 119, 0, 86, 86, 25, 60, 61, - /* 400 */ 62, 63, 64, 65, 66, 67, 25, 69, 99, 99, - /* 410 */ 128, 129, 74, 75, 76, 77, 78, 17, 46, 31, - /* 420 */ 20, 94, 0, 23, 24, 98, 99, 46, 119, 119, - /* 430 */ 30, 35, 0, 45, 38, 26, 127, 127, 55, 130, - /* 440 */ 130, 17, 133, 133, 88, 45, 119, 34, 35, 36, - /* 450 */ 37, 42, 39, 40, 30, 25, 47, 130, 49, 99, - /* 460 */ 60, 61, 62, 63, 64, 65, 66, 67, 99, 69, - /* 470 */ 110, 56, 31, 113, 74, 75, 76, 77, 78, 119, - /* 480 */ 89, 20, 28, 29, 23, 24, 45, 26, 119, 59, - /* 490 */ 130, 30, 82, 124, 125, 25, 86, 51, 25, 130, - /* 500 */ 99, 19, 20, 21, 22, 23, 45, 90, 20, 99, - /* 510 */ 58, 23, 24, 57, 91, 47, 46, 92, 30, 46, - /* 520 */ 119, 60, 61, 62, 63, 64, 65, 66, 67, 119, - /* 530 */ 69, 130, 126, 45, 133, 74, 75, 76, 77, 78, - /* 540 */ 130, 52, 126, 25, 126, 23, 93, 99, 60, 61, - /* 550 */ 62, 63, 64, 65, 66, 67, 45, 69, 96, 99, - /* 560 */ 30, 25, 74, 75, 76, 77, 78, 119, 99, 95, - /* 570 */ 122, 123, 108, 41, 100, 98, 99, 99, 130, 119, - /* 580 */ 109, 107, 46, 74, 99, 125, 46, 26, 119, 46, - /* 590 */ 130, 99, 123, 119, 99, 45, 119, 119, 120, 130, - /* 600 */ 99, 99, 30, 99, 119, 113, 99, 130, 130, 99, - /* 610 */ 46, 119, 30, 129, 119, 130, 28, 131, 99, 45, - /* 620 */ 119, 119, 130, 119, 99, 130, 119, 99, 99, 119, - /* 630 */ 99, 130, 130, 99, 130, 46, 99, 130, 119, 31, - /* 640 */ 130, 30, 46, 30, 119, 35, 30, 119, 119, 130, - /* 650 */ 119, 99, 99, 119, 99, 130, 119, 99, 130, 130, - /* 660 */ 35, 130, 30, 35, 130, 30, 99, 130, 100, 99, - /* 670 */ 99, 119, 119, 30, 119, 107, 99, 119, 99, 99, - /* 680 */ 35, 30, 130, 130, 99, 130, 119, 119, 130, 119, - /* 690 */ 119, 99, 99, 99, 99, 30, 119, 130, 119, 119, - /* 700 */ 130, 130, 35, 30, 119, 30, 30, 130, 99, 130, - /* 710 */ 130, 119, 119, 119, 119, 130, 30, 30, 30, 100, - /* 720 */ 99, 99, 130, 130, 130, 130, 107, 100, 119, 99, - /* 730 */ 99, 105, 52, 25, 107, 46, 45, 43, 119, 130, - /* 740 */ 119, 119, 46, 45, 0, 30, 119, 44, 0, 119, - /* 750 */ 119, 130, 130, 114, 45, 87, 116, 0, 0, 126, - /* 760 */ 130, 130, 48, 25, 3, 87, 116, 0, 27, + /* 240 */ 19, 20, 21, 22, 23, 17, 31, 72, 20, 119, + /* 250 */ 120, 23, 24, 51, 26, 127, 128, 96, 30, 44, + /* 260 */ 25, 100, 101, 102, 103, 25, 68, 98, 33, 34, + /* 270 */ 35, 36, 44, 38, 39, 28, 29, 80, 81, 82, + /* 280 */ 83, 84, 85, 86, 34, 116, 117, 37, 60, 61, + /* 290 */ 62, 63, 64, 65, 66, 67, 26, 69, 129, 59, + /* 300 */ 97, 98, 74, 75, 76, 77, 78, 17, 82, 112, + /* 310 */ 20, 41, 86, 23, 24, 118, 46, 30, 48, 116, + /* 320 */ 30, 13, 14, 15, 16, 17, 18, 19, 20, 21, + /* 330 */ 22, 23, 129, 0, 44, 45, 33, 34, 35, 36, + /* 340 */ 95, 38, 39, 99, 99, 21, 22, 23, 104, 104, + /* 350 */ 60, 61, 62, 63, 64, 65, 66, 67, 74, 69, + /* 360 */ 116, 116, 119, 120, 74, 75, 76, 77, 78, 3, + /* 370 */ 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, + /* 380 */ 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, + /* 390 */ 17, 58, 98, 20, 11, 12, 23, 24, 82, 31, + /* 400 */ 98, 107, 86, 30, 110, 22, 114, 115, 116, 82, + /* 410 */ 116, 99, 34, 86, 98, 37, 104, 44, 116, 70, + /* 420 */ 71, 34, 73, 129, 37, 98, 124, 30, 116, 32, + /* 430 */ 30, 129, 116, 60, 61, 62, 63, 64, 65, 66, + /* 440 */ 67, 30, 69, 116, 87, 129, 49, 74, 75, 76, + /* 450 */ 77, 78, 98, 126, 20, 44, 129, 23, 24, 132, + /* 460 */ 26, 101, 102, 103, 30, 25, 31, 27, 30, 94, + /* 470 */ 116, 82, 97, 98, 30, 86, 99, 55, 44, 44, + /* 480 */ 126, 104, 44, 129, 42, 131, 132, 98, 44, 119, + /* 490 */ 120, 116, 30, 116, 60, 61, 62, 63, 64, 65, + /* 500 */ 66, 67, 25, 69, 129, 116, 30, 98, 74, 75, + /* 510 */ 76, 77, 78, 17, 25, 126, 20, 98, 129, 23, + /* 520 */ 24, 132, 45, 52, 98, 116, 30, 25, 17, 110, + /* 530 */ 30, 104, 32, 107, 45, 116, 110, 23, 129, 23, + /* 540 */ 44, 30, 116, 116, 25, 115, 116, 45, 129, 43, + /* 550 */ 44, 98, 44, 90, 104, 129, 60, 61, 62, 63, + /* 560 */ 64, 65, 66, 67, 45, 69, 116, 119, 98, 116, + /* 570 */ 74, 75, 76, 77, 78, 122, 50, 20, 30, 98, + /* 580 */ 23, 24, 129, 30, 98, 98, 116, 30, 74, 30, + /* 590 */ 108, 0, 25, 111, 119, 30, 98, 116, 30, 129, + /* 600 */ 30, 44, 116, 116, 123, 124, 34, 121, 122, 125, + /* 610 */ 129, 98, 45, 34, 116, 129, 129, 60, 61, 62, + /* 620 */ 63, 64, 65, 66, 67, 98, 69, 129, 98, 116, + /* 630 */ 132, 74, 75, 76, 77, 78, 49, 30, 45, 98, + /* 640 */ 45, 43, 129, 116, 30, 44, 116, 98, 58, 45, + /* 650 */ 98, 25, 30, 130, 98, 25, 129, 116, 98, 129, + /* 660 */ 44, 98, 98, 34, 98, 116, 30, 0, 116, 98, + /* 670 */ 129, 45, 116, 98, 119, 45, 116, 34, 129, 116, + /* 680 */ 116, 129, 116, 98, 98, 129, 45, 116, 111, 129, + /* 690 */ 91, 116, 129, 129, 26, 129, 0, 28, 98, 0, + /* 700 */ 129, 116, 116, 98, 129, 87, 98, 98, 30, 98, + /* 710 */ 98, 0, 0, 98, 129, 129, 116, 98, 98, 113, + /* 720 */ 34, 116, 125, 47, 116, 116, 25, 116, 116, 129, + /* 730 */ 30, 116, 98, 98, 129, 116, 116, 129, 129, 44, + /* 740 */ 129, 129, 98, 3, 129, 57, 125, 119, 129, 129, + /* 750 */ 116, 116, 125, 98, 49, 30, 98, 98, 98, 0, + /* 760 */ 116, 0, 30, 129, 129, 0, 45, 87, 128, 113, + /* 770 */ 0, 116, 27, 129, 116, 116, 116, 92, 25, 44, + /* 780 */ 93, 44, 89, 45, 129, 106, 52, 129, 129, 129, + /* 790 */ 40, 44, 25, 133, 105, 46, }; -#define PP_SHIFT_USE_DFLT (-15) +#define PP_SHIFT_USE_DFLT (-2) static short pp_shift_ofst[] = { - /* 0 */ 409, 379, 384, 394, 422, 432, 46, 383, 415, 446, - /* 10 */ 452, 456, -15, 468, -15, -14, 430, -14, -15, -15, - /* 20 */ -15, -15, -15, -15, -14, -15, 489, 488, 518, 488, - /* 30 */ -15, -1, -15, -15, 488, 488, 56, 488, 56, 488, - /* 40 */ 482, 488, 482, 488, 482, 488, 249, 488, 249, 488, - /* 50 */ 326, 488, 326, 488, 326, 488, 160, 488, 160, 488, - /* 60 */ 160, 488, 160, 488, 160, 488, 160, 488, 262, 70, - /* 70 */ 488, 522, 488, 262, 511, 311, 454, 400, 194, 530, - /* 80 */ 357, 413, -15, 413, -15, -15, 530, 58, 532, -15, - /* 90 */ 488, 221, 488, 221, 226, -15, 509, -15, 488, 304, - /* 100 */ 461, 142, -15, 540, -15, 6, 561, 543, -15, 550, - /* 110 */ 488, 188, 572, 564, -15, 574, 488, 119, 582, 589, - /* 120 */ -15, 488, 22, 184, -15, -15, 488, 96, 488, 221, - /* 130 */ -15, 388, 588, 228, 221, 596, -15, 536, 338, -15, - /* 140 */ -15, 488, 522, 488, 522, -15, -15, -15, -15, -15, - /* 150 */ -15, -15, -15, -15, -15, -15, -15, -15, 611, -15, - /* 160 */ 488, 221, -15, 613, -15, -15, -15, 608, 610, 616, - /* 170 */ 625, 632, 396, 628, 635, 643, 329, 645, 651, 665, - /* 180 */ 298, 667, 673, 675, 676, -15, 530, -15, 308, 686, - /* 190 */ -15, -15, 687, 687, -15, -15, -15, -15, 400, -15, - /* 200 */ -15, 441, 424, -15, 53, 688, -15, -15, -15, -15, - /* 210 */ -15, 381, -15, 689, -15, 488, 522, 691, 311, 473, - /* 220 */ -15, 696, -15, 56, -15, 488, 221, 680, 488, 708, - /* 230 */ 488, -15, 221, -15, 488, 221, 694, 530, 122, 698, - /* 240 */ 488, 372, 744, 488, -15, 221, -15, 715, 305, 703, - /* 250 */ 709, 488, 470, 748, 715, -15, -15, -15, 46, 296, - /* 260 */ 757, -14, 758, 530, 714, 530, 738, 530, -15, 761, - /* 270 */ 488, -15, 221, -15, 46, 296, 767, 741, 530, -15, + /* 0 */ 270, 712, 761, 696, 765, 759, 526, 422, 86, 202, + /* 10 */ 590, 688, -2, 749, -2, 60, 240, 60, -2, -2, + /* 20 */ -2, -2, -2, -2, 60, -2, 471, 557, 753, 557, + /* 30 */ -2, 73, -2, -2, 557, 557, 324, 557, 324, 557, + /* 40 */ 27, 557, 27, 557, 27, 557, 117, 557, 117, 557, + /* 50 */ 150, 557, 150, 557, 150, 557, 46, 557, 46, 557, + /* 60 */ 46, 557, 46, 557, 46, 557, 46, 557, 308, 383, + /* 70 */ 557, 516, 557, 308, 735, 228, 247, 373, 440, 476, + /* 80 */ 235, -2, 476, -2, 397, 725, 705, 411, -2, 462, + /* 90 */ 28, -2, 462, -2, -2, -2, 587, 438, 462, 477, + /* 100 */ -2, -2, 444, 462, 489, -2, -2, -2, 368, 287, + /* 110 */ -2, 303, -2, -2, 476, 500, 750, -2, 557, 221, + /* 120 */ 557, 221, 514, -2, 284, -2, 557, 366, 434, 96, + /* 130 */ -2, 604, -2, 616, 668, 641, -2, 695, 557, 142, + /* 140 */ 732, 721, -2, 737, 557, 198, 553, 595, -2, 557, + /* 150 */ -1, 349, -2, -2, 557, 175, 557, 221, -2, 215, + /* 160 */ 669, 290, 221, 593, -2, 26, 496, -2, -2, 557, + /* 170 */ 516, 557, 516, -2, -2, -2, -2, -2, -2, -2, + /* 180 */ -2, -2, -2, -2, -2, -2, 557, 221, -2, 700, + /* 190 */ -2, -2, 686, 678, 643, 636, 250, 629, 622, 614, + /* 200 */ 378, 579, 570, 568, 387, 572, 565, 559, 548, -2, + /* 210 */ -2, 373, -2, -2, 435, 511, -2, 22, 400, -2, + /* 220 */ -2, -2, -2, -2, 502, -2, 80, -2, 557, 516, + /* 230 */ 747, 228, 519, -2, 738, -2, 324, -2, 557, 221, + /* 240 */ 734, 557, 767, 557, -2, 221, -2, 557, 221, 442, + /* 250 */ 476, 506, 508, 557, 567, 591, 557, -2, 221, -2, + /* 260 */ 607, 626, 598, 601, 557, 630, 667, 607, -2, -2, + /* 270 */ -2, 526, 333, 699, 60, 711, 476, 676, 476, 701, + /* 280 */ 476, -2, 740, 557, -2, 221, -2, 526, 333, 770, + /* 290 */ 745, 476, -2, }; -#define PP_REDUCE_USE_DFLT (-18) +#define PP_REDUCE_USE_DFLT (-1) static short pp_reduce_ofst[] = { - /* 0 */ 132, -18, -18, -18, -18, -18, 242, 356, 391, 417, - /* 10 */ 423, 425, -18, -18, -18, 406, -18, 416, -18, -18, - /* 20 */ -18, -18, -18, -18, 418, -18, -18, 448, -18, 469, - /* 30 */ -18, -18, -18, -18, 510, 502, -18, 485, -18, 495, - /* 40 */ -18, 501, -18, 504, -18, 519, -18, 528, -18, 529, - /* 50 */ -18, 534, -18, 537, -18, 552, -18, 553, -18, 555, - /* 60 */ -18, 558, -18, 570, -18, 571, -18, 579, -18, -18, - /* 70 */ 585, -18, 593, -18, -18, 309, 453, 327, -18, 474, - /* 80 */ 462, -17, -18, 195, -18, -18, 274, 464, 471, -18, - /* 90 */ 580, -18, 594, -18, -18, -18, -18, -18, 609, -18, - /* 100 */ 410, -18, -18, -18, -18, -18, 164, -18, -18, -18, - /* 110 */ 567, -18, -18, -18, -18, -18, 577, -18, -18, -18, - /* 120 */ -18, 592, 282, 484, -18, -18, 622, -18, 631, -18, - /* 130 */ -18, -18, 486, 233, -18, -18, -18, -18, 401, -18, - /* 140 */ -18, 630, -18, 621, -18, -18, -18, -18, -18, -18, - /* 150 */ -18, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 160 */ 595, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 170 */ -18, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 180 */ -18, -18, -18, -18, -18, -18, 568, -18, -18, -18, - /* 190 */ -18, -18, -11, 626, -18, -18, -18, -18, 477, -18, - /* 200 */ -18, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 210 */ -18, -18, -18, -18, -18, 507, -18, -18, 310, -18, - /* 220 */ -18, -18, -18, -18, -18, 525, -18, -18, 369, -18, - /* 230 */ 460, -18, -18, -18, 531, -18, -18, 250, -18, -18, - /* 240 */ 360, -18, -18, 492, -18, -18, -18, 145, -18, -18, - /* 250 */ -18, 240, -18, -18, 639, -18, -18, -18, 668, 640, - /* 260 */ -18, 633, -18, 627, -18, 67, -18, 168, -18, -18, - /* 270 */ 478, -18, -18, -18, 678, 650, -18, -18, 619, -18, + /* 0 */ 197, -1, -1, -1, -1, -1, 357, 87, 693, 463, + /* 10 */ 599, 685, -1, -1, -1, 627, -1, 484, -1, -1, + /* 20 */ -1, -1, -1, -1, 621, -1, -1, 486, -1, 453, + /* 30 */ -1, -1, -1, -1, 608, 609, -1, 612, -1, 620, + /* 40 */ -1, 470, -1, 658, -1, 659, -1, 644, -1, 513, + /* 50 */ -1, 635, -1, 611, -1, 605, -1, 600, -1, 571, + /* 60 */ -1, 566, -1, 660, -1, 575, -1, 634, -1, -1, + /* 70 */ 549, -1, 560, -1, -1, 389, 687, 375, -1, 245, + /* 80 */ 161, -1, 312, -1, -1, -1, -1, 628, -1, 243, + /* 90 */ -1, -1, 555, -1, -1, -1, -1, 475, 130, -1, + /* 100 */ -1, -1, 448, 370, -1, -1, -1, -1, -1, -1, + /* 110 */ -1, 360, -1, -1, 427, 689, 679, -1, 541, -1, + /* 120 */ 527, -1, -1, -1, -1, -1, 619, -1, 316, -1, + /* 130 */ -1, -1, -1, -1, 226, -1, -1, -1, 586, -1, + /* 140 */ -1, -1, -1, -1, 556, -1, -1, -1, -1, 552, + /* 150 */ 128, 640, -1, -1, 409, -1, 615, -1, -1, -1, + /* 160 */ 523, 354, -1, -1, -1, -1, 498, -1, -1, 563, + /* 170 */ -1, 564, -1, -1, -1, -1, -1, -1, -1, -1, + /* 180 */ -1, -1, -1, -1, -1, -1, 585, -1, -1, -1, + /* 190 */ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + /* 200 */ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + /* 210 */ -1, 203, -1, -1, -1, -1, -1, -1, -1, -1, + /* 220 */ -1, -1, -1, -1, -1, -1, -1, -1, 487, -1, + /* 230 */ -1, 327, -1, -1, -1, -1, -1, -1, 530, -1, + /* 240 */ -1, 481, -1, 302, -1, -1, -1, 655, -1, -1, + /* 250 */ 450, -1, -1, 426, -1, -1, 419, -1, -1, -1, + /* 260 */ 482, -1, -1, -1, 294, -1, -1, 577, -1, -1, + /* 270 */ -1, 618, 606, -1, 597, -1, 377, -1, 292, -1, + /* 280 */ 430, -1, -1, 169, -1, -1, -1, 680, 656, -1, + /* 290 */ -1, 244, -1, }; static PPACTIONTYPE pp_default[] = { - /* 0 */ 437, 437, 437, 437, 437, 437, 345, 354, 359, 347, - /* 10 */ 365, 361, 285, 437, 360, 437, 362, 437, 363, 368, - /* 20 */ 369, 370, 371, 372, 437, 364, 437, 437, 346, 437, - /* 30 */ 348, 350, 351, 352, 437, 437, 373, 437, 375, 437, - /* 40 */ 376, 437, 377, 437, 378, 437, 379, 437, 380, 437, - /* 50 */ 381, 437, 382, 437, 383, 437, 384, 437, 385, 437, - /* 60 */ 386, 437, 387, 437, 388, 437, 389, 437, 390, 437, - /* 70 */ 437, 391, 437, 392, 437, 437, 289, 437, 437, 437, - /* 80 */ 302, 300, 286, 299, 303, 305, 437, 312, 323, 309, - /* 90 */ 437, 322, 437, 400, 437, 418, 437, 419, 437, 420, - /* 100 */ 437, 437, 423, 437, 396, 437, 437, 437, 399, 437, - /* 110 */ 437, 437, 437, 437, 401, 437, 437, 437, 437, 437, - /* 120 */ 402, 437, 437, 437, 403, 404, 437, 437, 437, 406, - /* 130 */ 408, 436, 411, 437, 417, 437, 409, 437, 437, 414, - /* 140 */ 416, 437, 421, 437, 422, 424, 425, 426, 427, 428, - /* 150 */ 429, 430, 431, 432, 433, 434, 415, 410, 437, 435, - /* 160 */ 437, 407, 405, 437, 310, 311, 343, 436, 437, 437, - /* 170 */ 437, 437, 437, 437, 437, 437, 437, 437, 437, 437, - /* 180 */ 437, 437, 437, 437, 437, 304, 437, 297, 342, 437, - /* 190 */ 340, 341, 437, 301, 306, 308, 307, 298, 437, 290, - /* 200 */ 292, 436, 437, 293, 296, 437, 294, 295, 291, 287, - /* 210 */ 288, 437, 394, 437, 397, 437, 393, 437, 437, 437, - /* 220 */ 395, 437, 398, 374, 349, 437, 358, 437, 437, 353, - /* 230 */ 437, 355, 357, 356, 437, 344, 437, 437, 437, 437, - /* 240 */ 437, 437, 437, 437, 326, 328, 327, 437, 437, 437, - /* 250 */ 437, 437, 437, 437, 437, 329, 331, 330, 345, 437, - /* 260 */ 437, 437, 437, 437, 437, 437, 333, 437, 334, 437, - /* 270 */ 437, 336, 337, 335, 345, 437, 437, 437, 437, 339, + /* 0 */ 454, 454, 454, 454, 454, 454, 362, 371, 376, 364, + /* 10 */ 382, 378, 298, 454, 377, 454, 379, 454, 380, 385, + /* 20 */ 386, 387, 388, 389, 454, 381, 454, 454, 363, 454, + /* 30 */ 365, 367, 368, 369, 454, 454, 390, 454, 392, 454, + /* 40 */ 393, 454, 394, 454, 395, 454, 396, 454, 397, 454, + /* 50 */ 398, 454, 399, 454, 400, 454, 401, 454, 402, 454, + /* 60 */ 403, 454, 404, 454, 405, 454, 406, 454, 407, 454, + /* 70 */ 454, 408, 454, 409, 454, 454, 302, 454, 454, 454, + /* 80 */ 313, 299, 454, 310, 350, 454, 348, 454, 351, 454, + /* 90 */ 454, 352, 454, 357, 359, 358, 349, 454, 454, 454, + /* 100 */ 353, 354, 454, 454, 454, 355, 356, 360, 453, 454, + /* 110 */ 452, 312, 314, 316, 454, 320, 331, 317, 454, 330, + /* 120 */ 454, 417, 454, 435, 454, 436, 454, 437, 454, 454, + /* 130 */ 440, 454, 413, 454, 454, 454, 416, 454, 454, 454, + /* 140 */ 454, 454, 418, 454, 454, 454, 454, 454, 419, 454, + /* 150 */ 454, 454, 420, 421, 454, 454, 454, 423, 425, 453, + /* 160 */ 428, 454, 434, 454, 426, 454, 454, 431, 433, 454, + /* 170 */ 438, 454, 439, 441, 442, 443, 444, 445, 446, 447, + /* 180 */ 448, 449, 450, 451, 432, 427, 454, 424, 422, 454, + /* 190 */ 318, 319, 454, 454, 454, 454, 454, 454, 454, 454, + /* 200 */ 454, 454, 454, 454, 454, 454, 454, 454, 454, 315, + /* 210 */ 311, 454, 303, 305, 453, 454, 306, 309, 454, 307, + /* 220 */ 308, 304, 300, 301, 454, 411, 454, 414, 454, 410, + /* 230 */ 454, 454, 454, 412, 454, 415, 391, 366, 454, 375, + /* 240 */ 454, 454, 370, 454, 372, 374, 373, 454, 361, 454, + /* 250 */ 454, 454, 454, 454, 454, 454, 454, 334, 336, 335, + /* 260 */ 454, 454, 454, 454, 454, 454, 454, 454, 337, 339, + /* 270 */ 338, 362, 454, 454, 454, 454, 454, 454, 454, 341, + /* 280 */ 454, 342, 454, 454, 344, 345, 343, 362, 454, 454, + /* 290 */ 454, 454, 347, }; #define PP_SZ_ACTTAB (sizeof(pp_action)/sizeof(pp_action[0])) @@ -101972,11 +102649,11 @@ static const char *ppTokenName[] = { "MINUS", "IS", "IN", "NOT", "BITWISE_NOT", "COMMA", "SELECT", "FROM", "DISTINCT", "ALL", "IDENTIFIER", "DOT", - "AS", "WITH", "INNER", "JOIN", - "CROSS", "LEFT", "OUTER", "RIGHT", - "FULL", "ON", "INSERT", "INTO", - "VALUES", "PARENTHESES_OPEN", "PARENTHESES_CLOSE", "UPDATE", - "SET", "DELETE", "WHERE", "ORDER", + "AS", "INNER", "JOIN", "CROSS", + "LEFT", "OUTER", "RIGHT", "FULL", + "ON", "INSERT", "INTO", "VALUES", + "PARENTHESES_OPEN", "PARENTHESES_CLOSE", "UPDATE", "SET", + "DELETE", "WITH", "WHERE", "ORDER", "BY", "ASC", "DESC", "GROUP", "HAVING", "FOR", "LIMIT", "OFFSET", "INTEGER", "HINTEGER", "NPLACEHOLDER", "SPLACEHOLDER", @@ -101988,16 +102665,16 @@ static const char *ppTokenName[] = { "update_statement", "delete_statement", "select_clause", "where_clause", "group_clause", "having_clause", "order_clause", "select_limit_clause", "for_update_clause", "distinct_all", "column_list", "associated_name_list", - "with_list_or_null", "join_list_or_null", "column_item", "expr", - "associated_name", "join_list", "with_list", "join_item", - "join_clause", "with_item", "join_type", "aliased_or_qualified_name", - "join_associated_name", "join_conditions", "values_list", "field_list", - "value_list", "value_item", "field_item", "update_clause", - "limit_clause", "update_item_list", "update_item", "qualified_name", - "new_value", "delete_clause", "order_list", "order_item", - "group_list", "group_item", "integer_or_placeholder", "argument_list", - "when_clauses", "when_clause", "function_call", "distinct_or_null", - "argument_list_or_null", "argument_item", + "join_list_or_null", "column_item", "expr", "associated_name", + "join_list", "join_item", "join_clause", "join_type", + "aliased_or_qualified_name", "join_associated_name", "join_conditions", "values_list", + "field_list", "value_list", "value_item", "field_item", + "update_clause", "limit_clause", "update_item_list", "update_item", + "qualified_name", "new_value", "delete_clause", "with_item", + "with_list", "order_list", "order_item", "group_list", + "group_item", "integer_or_placeholder", "argument_list", "when_clauses", + "when_clause", "function_call", "distinct_or_null", "argument_list_or_null", + "argument_item", }; #endif /* NDEBUG */ @@ -102011,7 +102688,7 @@ static const char *ppRuleName[] = { /* 3 */ "query_language ::= update_statement", /* 4 */ "query_language ::= delete_statement", /* 5 */ "select_statement ::= select_clause where_clause group_clause having_clause order_clause select_limit_clause for_update_clause", - /* 6 */ "select_clause ::= SELECT distinct_all column_list FROM associated_name_list with_list_or_null join_list_or_null", + /* 6 */ "select_clause ::= SELECT distinct_all column_list FROM associated_name_list join_list_or_null", /* 7 */ "distinct_all ::= DISTINCT", /* 8 */ "distinct_all ::= ALL", /* 9 */ "distinct_all ::=", @@ -102026,142 +102703,146 @@ static const char *ppRuleName[] = { /* 18 */ "associated_name_list ::= associated_name", /* 19 */ "join_list_or_null ::= join_list", /* 20 */ "join_list_or_null ::=", - /* 21 */ "with_list_or_null ::= WITH with_list", - /* 22 */ "with_list_or_null ::=", - /* 23 */ "join_list ::= join_list join_item", - /* 24 */ "join_list ::= join_item", - /* 25 */ "join_item ::= join_clause", - /* 26 */ "with_list ::= with_list with_item", - /* 27 */ "with_list ::= with_item", - /* 28 */ "with_item ::= IDENTIFIER", - /* 29 */ "join_clause ::= join_type aliased_or_qualified_name join_associated_name join_conditions", - /* 30 */ "join_associated_name ::= AS IDENTIFIER", - /* 31 */ "join_associated_name ::= IDENTIFIER", - /* 32 */ "join_associated_name ::=", - /* 33 */ "join_type ::= INNER JOIN", - /* 34 */ "join_type ::= CROSS JOIN", - /* 35 */ "join_type ::= LEFT OUTER JOIN", - /* 36 */ "join_type ::= LEFT JOIN", - /* 37 */ "join_type ::= RIGHT OUTER JOIN", - /* 38 */ "join_type ::= RIGHT JOIN", - /* 39 */ "join_type ::= FULL OUTER JOIN", - /* 40 */ "join_type ::= FULL JOIN", - /* 41 */ "join_type ::= JOIN", - /* 42 */ "join_conditions ::= ON expr", - /* 43 */ "join_conditions ::=", - /* 44 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", - /* 45 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name PARENTHESES_OPEN field_list PARENTHESES_CLOSE VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", - /* 46 */ "values_list ::= values_list COMMA value_item", - /* 47 */ "values_list ::= value_item", - /* 48 */ "value_item ::= expr", - /* 49 */ "field_list ::= field_list COMMA field_item", - /* 50 */ "field_list ::= field_item", - /* 51 */ "field_item ::= IDENTIFIER", - /* 52 */ "update_statement ::= update_clause where_clause limit_clause", - /* 53 */ "update_clause ::= UPDATE associated_name SET update_item_list", - /* 54 */ "update_item_list ::= update_item_list COMMA update_item", - /* 55 */ "update_item_list ::= update_item", - /* 56 */ "update_item ::= qualified_name EQUALS new_value", - /* 57 */ "new_value ::= expr", - /* 58 */ "delete_statement ::= delete_clause where_clause limit_clause", - /* 59 */ "delete_clause ::= DELETE FROM associated_name", - /* 60 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER", - /* 61 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER", - /* 62 */ "associated_name ::= aliased_or_qualified_name", - /* 63 */ "aliased_or_qualified_name ::= qualified_name", - /* 64 */ "where_clause ::= WHERE expr", - /* 65 */ "where_clause ::=", - /* 66 */ "order_clause ::= ORDER BY order_list", - /* 67 */ "order_clause ::=", - /* 68 */ "order_list ::= order_list COMMA order_item", - /* 69 */ "order_list ::= order_item", - /* 70 */ "order_item ::= expr", - /* 71 */ "order_item ::= expr ASC", - /* 72 */ "order_item ::= expr DESC", - /* 73 */ "group_clause ::= GROUP BY group_list", - /* 74 */ "group_clause ::=", - /* 75 */ "group_list ::= group_list COMMA group_item", - /* 76 */ "group_list ::= group_item", - /* 77 */ "group_item ::= expr", - /* 78 */ "having_clause ::= HAVING expr", - /* 79 */ "having_clause ::=", - /* 80 */ "for_update_clause ::= FOR UPDATE", - /* 81 */ "for_update_clause ::=", - /* 82 */ "select_limit_clause ::= LIMIT integer_or_placeholder", - /* 83 */ "select_limit_clause ::= LIMIT integer_or_placeholder COMMA integer_or_placeholder", - /* 84 */ "select_limit_clause ::= LIMIT integer_or_placeholder OFFSET integer_or_placeholder", - /* 85 */ "select_limit_clause ::=", - /* 86 */ "limit_clause ::= LIMIT integer_or_placeholder", - /* 87 */ "limit_clause ::=", - /* 88 */ "integer_or_placeholder ::= INTEGER", - /* 89 */ "integer_or_placeholder ::= HINTEGER", - /* 90 */ "integer_or_placeholder ::= NPLACEHOLDER", - /* 91 */ "integer_or_placeholder ::= SPLACEHOLDER", - /* 92 */ "integer_or_placeholder ::= BPLACEHOLDER", - /* 93 */ "expr ::= MINUS expr", - /* 94 */ "expr ::= expr MINUS expr", - /* 95 */ "expr ::= expr PLUS expr", - /* 96 */ "expr ::= expr TIMES expr", - /* 97 */ "expr ::= expr DIVIDE expr", - /* 98 */ "expr ::= expr MOD expr", - /* 99 */ "expr ::= expr AND expr", - /* 100 */ "expr ::= expr OR expr", - /* 101 */ "expr ::= expr BITWISE_AND expr", - /* 102 */ "expr ::= expr BITWISE_OR expr", - /* 103 */ "expr ::= expr BITWISE_XOR expr", - /* 104 */ "expr ::= expr EQUALS expr", - /* 105 */ "expr ::= expr NOTEQUALS expr", - /* 106 */ "expr ::= expr LESS expr", - /* 107 */ "expr ::= expr GREATER expr", - /* 108 */ "expr ::= expr GREATEREQUAL expr", - /* 109 */ "expr ::= expr LESSEQUAL expr", - /* 110 */ "expr ::= expr LIKE expr", - /* 111 */ "expr ::= expr NOT LIKE expr", - /* 112 */ "expr ::= expr ILIKE expr", - /* 113 */ "expr ::= expr NOT ILIKE expr", - /* 114 */ "expr ::= expr IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", - /* 115 */ "expr ::= expr NOT IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", - /* 116 */ "expr ::= PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 117 */ "expr ::= expr IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 118 */ "expr ::= expr NOT IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 119 */ "expr ::= EXISTS PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 120 */ "expr ::= expr AGAINST expr", - /* 121 */ "expr ::= CAST PARENTHESES_OPEN expr AS IDENTIFIER PARENTHESES_CLOSE", - /* 122 */ "expr ::= CONVERT PARENTHESES_OPEN expr USING IDENTIFIER PARENTHESES_CLOSE", - /* 123 */ "expr ::= CASE expr when_clauses END", - /* 124 */ "when_clauses ::= when_clauses when_clause", - /* 125 */ "when_clauses ::= when_clause", - /* 126 */ "when_clause ::= WHEN expr THEN expr", - /* 127 */ "when_clause ::= ELSE expr", - /* 128 */ "expr ::= function_call", - /* 129 */ "function_call ::= IDENTIFIER PARENTHESES_OPEN distinct_or_null argument_list_or_null PARENTHESES_CLOSE", - /* 130 */ "distinct_or_null ::= DISTINCT", - /* 131 */ "distinct_or_null ::=", - /* 132 */ "argument_list_or_null ::= argument_list", - /* 133 */ "argument_list_or_null ::=", - /* 134 */ "argument_list ::= argument_list COMMA argument_item", - /* 135 */ "argument_list ::= argument_item", - /* 136 */ "argument_item ::= TIMES", - /* 137 */ "argument_item ::= expr", - /* 138 */ "expr ::= expr IS NULL", - /* 139 */ "expr ::= expr IS NOT NULL", - /* 140 */ "expr ::= expr BETWEEN expr", - /* 141 */ "expr ::= NOT expr", - /* 142 */ "expr ::= BITWISE_NOT expr", - /* 143 */ "expr ::= PARENTHESES_OPEN expr PARENTHESES_CLOSE", - /* 144 */ "expr ::= qualified_name", - /* 145 */ "expr ::= INTEGER", - /* 146 */ "expr ::= HINTEGER", - /* 147 */ "expr ::= STRING", - /* 148 */ "expr ::= DOUBLE", - /* 149 */ "expr ::= NULL", - /* 150 */ "expr ::= TRUE", - /* 151 */ "expr ::= FALSE", - /* 152 */ "expr ::= NPLACEHOLDER", - /* 153 */ "expr ::= SPLACEHOLDER", - /* 154 */ "expr ::= BPLACEHOLDER", - /* 155 */ "qualified_name ::= IDENTIFIER DOT IDENTIFIER", - /* 156 */ "qualified_name ::= IDENTIFIER", + /* 21 */ "join_list ::= join_list join_item", + /* 22 */ "join_list ::= join_item", + /* 23 */ "join_item ::= join_clause", + /* 24 */ "join_clause ::= join_type aliased_or_qualified_name join_associated_name join_conditions", + /* 25 */ "join_associated_name ::= AS IDENTIFIER", + /* 26 */ "join_associated_name ::= IDENTIFIER", + /* 27 */ "join_associated_name ::=", + /* 28 */ "join_type ::= INNER JOIN", + /* 29 */ "join_type ::= CROSS JOIN", + /* 30 */ "join_type ::= LEFT OUTER JOIN", + /* 31 */ "join_type ::= LEFT JOIN", + /* 32 */ "join_type ::= RIGHT OUTER JOIN", + /* 33 */ "join_type ::= RIGHT JOIN", + /* 34 */ "join_type ::= FULL OUTER JOIN", + /* 35 */ "join_type ::= FULL JOIN", + /* 36 */ "join_type ::= JOIN", + /* 37 */ "join_conditions ::= ON expr", + /* 38 */ "join_conditions ::=", + /* 39 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", + /* 40 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name PARENTHESES_OPEN field_list PARENTHESES_CLOSE VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", + /* 41 */ "values_list ::= values_list COMMA value_item", + /* 42 */ "values_list ::= value_item", + /* 43 */ "value_item ::= expr", + /* 44 */ "field_list ::= field_list COMMA field_item", + /* 45 */ "field_list ::= field_item", + /* 46 */ "field_item ::= IDENTIFIER", + /* 47 */ "update_statement ::= update_clause where_clause limit_clause", + /* 48 */ "update_clause ::= UPDATE associated_name SET update_item_list", + /* 49 */ "update_item_list ::= update_item_list COMMA update_item", + /* 50 */ "update_item_list ::= update_item", + /* 51 */ "update_item ::= qualified_name EQUALS new_value", + /* 52 */ "new_value ::= expr", + /* 53 */ "delete_statement ::= delete_clause where_clause limit_clause", + /* 54 */ "delete_clause ::= DELETE FROM associated_name", + /* 55 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER", + /* 56 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER", + /* 57 */ "associated_name ::= aliased_or_qualified_name", + /* 58 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER WITH with_item", + /* 59 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER WITH PARENTHESES_OPEN with_list PARENTHESES_CLOSE", + /* 60 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER WITH PARENTHESES_OPEN with_list PARENTHESES_CLOSE", + /* 61 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER WITH with_item", + /* 62 */ "associated_name ::= aliased_or_qualified_name WITH PARENTHESES_OPEN with_list PARENTHESES_CLOSE", + /* 63 */ "associated_name ::= aliased_or_qualified_name WITH with_item", + /* 64 */ "with_list ::= with_list COMMA with_item", + /* 65 */ "with_list ::= with_item", + /* 66 */ "with_item ::= IDENTIFIER", + /* 67 */ "aliased_or_qualified_name ::= qualified_name", + /* 68 */ "where_clause ::= WHERE expr", + /* 69 */ "where_clause ::=", + /* 70 */ "order_clause ::= ORDER BY order_list", + /* 71 */ "order_clause ::=", + /* 72 */ "order_list ::= order_list COMMA order_item", + /* 73 */ "order_list ::= order_item", + /* 74 */ "order_item ::= expr", + /* 75 */ "order_item ::= expr ASC", + /* 76 */ "order_item ::= expr DESC", + /* 77 */ "group_clause ::= GROUP BY group_list", + /* 78 */ "group_clause ::=", + /* 79 */ "group_list ::= group_list COMMA group_item", + /* 80 */ "group_list ::= group_item", + /* 81 */ "group_item ::= expr", + /* 82 */ "having_clause ::= HAVING expr", + /* 83 */ "having_clause ::=", + /* 84 */ "for_update_clause ::= FOR UPDATE", + /* 85 */ "for_update_clause ::=", + /* 86 */ "select_limit_clause ::= LIMIT integer_or_placeholder", + /* 87 */ "select_limit_clause ::= LIMIT integer_or_placeholder COMMA integer_or_placeholder", + /* 88 */ "select_limit_clause ::= LIMIT integer_or_placeholder OFFSET integer_or_placeholder", + /* 89 */ "select_limit_clause ::=", + /* 90 */ "limit_clause ::= LIMIT integer_or_placeholder", + /* 91 */ "limit_clause ::=", + /* 92 */ "integer_or_placeholder ::= INTEGER", + /* 93 */ "integer_or_placeholder ::= HINTEGER", + /* 94 */ "integer_or_placeholder ::= NPLACEHOLDER", + /* 95 */ "integer_or_placeholder ::= SPLACEHOLDER", + /* 96 */ "integer_or_placeholder ::= BPLACEHOLDER", + /* 97 */ "expr ::= MINUS expr", + /* 98 */ "expr ::= expr MINUS expr", + /* 99 */ "expr ::= expr PLUS expr", + /* 100 */ "expr ::= expr TIMES expr", + /* 101 */ "expr ::= expr DIVIDE expr", + /* 102 */ "expr ::= expr MOD expr", + /* 103 */ "expr ::= expr AND expr", + /* 104 */ "expr ::= expr OR expr", + /* 105 */ "expr ::= expr BITWISE_AND expr", + /* 106 */ "expr ::= expr BITWISE_OR expr", + /* 107 */ "expr ::= expr BITWISE_XOR expr", + /* 108 */ "expr ::= expr EQUALS expr", + /* 109 */ "expr ::= expr NOTEQUALS expr", + /* 110 */ "expr ::= expr LESS expr", + /* 111 */ "expr ::= expr GREATER expr", + /* 112 */ "expr ::= expr GREATEREQUAL expr", + /* 113 */ "expr ::= expr LESSEQUAL expr", + /* 114 */ "expr ::= expr LIKE expr", + /* 115 */ "expr ::= expr NOT LIKE expr", + /* 116 */ "expr ::= expr ILIKE expr", + /* 117 */ "expr ::= expr NOT ILIKE expr", + /* 118 */ "expr ::= expr IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", + /* 119 */ "expr ::= expr NOT IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", + /* 120 */ "expr ::= PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 121 */ "expr ::= expr IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 122 */ "expr ::= expr NOT IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 123 */ "expr ::= EXISTS PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 124 */ "expr ::= expr AGAINST expr", + /* 125 */ "expr ::= CAST PARENTHESES_OPEN expr AS IDENTIFIER PARENTHESES_CLOSE", + /* 126 */ "expr ::= CONVERT PARENTHESES_OPEN expr USING IDENTIFIER PARENTHESES_CLOSE", + /* 127 */ "expr ::= CASE expr when_clauses END", + /* 128 */ "when_clauses ::= when_clauses when_clause", + /* 129 */ "when_clauses ::= when_clause", + /* 130 */ "when_clause ::= WHEN expr THEN expr", + /* 131 */ "when_clause ::= ELSE expr", + /* 132 */ "expr ::= function_call", + /* 133 */ "function_call ::= IDENTIFIER PARENTHESES_OPEN distinct_or_null argument_list_or_null PARENTHESES_CLOSE", + /* 134 */ "distinct_or_null ::= DISTINCT", + /* 135 */ "distinct_or_null ::=", + /* 136 */ "argument_list_or_null ::= argument_list", + /* 137 */ "argument_list_or_null ::=", + /* 138 */ "argument_list ::= argument_list COMMA argument_item", + /* 139 */ "argument_list ::= argument_item", + /* 140 */ "argument_item ::= TIMES", + /* 141 */ "argument_item ::= expr", + /* 142 */ "expr ::= expr IS NULL", + /* 143 */ "expr ::= expr IS NOT NULL", + /* 144 */ "expr ::= expr BETWEEN expr", + /* 145 */ "expr ::= NOT expr", + /* 146 */ "expr ::= BITWISE_NOT expr", + /* 147 */ "expr ::= PARENTHESES_OPEN expr PARENTHESES_CLOSE", + /* 148 */ "expr ::= qualified_name", + /* 149 */ "expr ::= INTEGER", + /* 150 */ "expr ::= HINTEGER", + /* 151 */ "expr ::= STRING", + /* 152 */ "expr ::= DOUBLE", + /* 153 */ "expr ::= NULL", + /* 154 */ "expr ::= TRUE", + /* 155 */ "expr ::= FALSE", + /* 156 */ "expr ::= NPLACEHOLDER", + /* 157 */ "expr ::= SPLACEHOLDER", + /* 158 */ "expr ::= BPLACEHOLDER", + /* 159 */ "qualified_name ::= IDENTIFIER DOT IDENTIFIER", + /* 160 */ "qualified_name ::= IDENTIFIER", }; #endif /* NDEBUG */ @@ -102281,7 +102962,7 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 76: case 77: case 78: -// 557 "parser.lemon" +// 558 "parser.lemon" { if ((pppminor->pp0)) { if ((pppminor->pp0)->free_flag) { @@ -102290,7 +102971,7 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ efree((pppminor->pp0)); } } -// 1253 "parser.c" +// 1270 "parser.c" break; case 81: case 82: @@ -102300,6 +102981,7 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 86: case 94: case 95: + case 97: case 98: case 99: case 100: @@ -102307,27 +102989,26 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 102: case 103: case 104: - case 105: - case 106: - case 107: + case 108: + case 109: case 111: case 112: case 114: case 115: - case 117: + case 116: case 118: case 119: + case 120: case 121: case 122: case 123: case 124: - case 125: - case 127: - case 130: - case 133: -// 570 "parser.lemon" -{ zval_ptr_dtor(&(pppminor->pp244)); } -// 1290 "parser.c" + case 126: + case 129: + case 132: +// 571 "parser.lemon" +{ zval_ptr_dtor(&(pppminor->pp162)); } +// 1307 "parser.c" break; case 87: case 88: @@ -102336,14 +103017,14 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 91: case 92: case 93: - case 108: - case 109: - case 116: + case 105: + case 106: + case 113: + case 130: case 131: - case 132: -// 882 "parser.lemon" -{ zephir_safe_zval_ptr_dtor((pppminor->pp244)); } -// 1306 "parser.c" +// 899 "parser.lemon" +{ zephir_safe_zval_ptr_dtor((pppminor->pp162)); } +// 1323 "parser.c" break; default: break; /* If no destructor action specified: do nothing */ } @@ -102486,78 +103167,82 @@ static struct { { 81, 1 }, { 81, 1 }, { 82, 7 }, - { 86, 7 }, + { 86, 6 }, { 93, 1 }, { 93, 1 }, { 93, 0 }, { 94, 3 }, { 94, 1 }, - { 98, 1 }, - { 98, 3 }, - { 98, 3 }, - { 98, 2 }, - { 98, 1 }, + { 97, 1 }, + { 97, 3 }, + { 97, 3 }, + { 97, 2 }, + { 97, 1 }, { 95, 3 }, { 95, 1 }, - { 97, 1 }, - { 97, 0 }, - { 96, 2 }, + { 96, 1 }, { 96, 0 }, - { 101, 2 }, + { 100, 2 }, + { 100, 1 }, { 101, 1 }, - { 103, 1 }, - { 102, 2 }, - { 102, 1 }, + { 102, 4 }, + { 105, 2 }, { 105, 1 }, - { 104, 4 }, - { 108, 2 }, - { 108, 1 }, - { 108, 0 }, - { 106, 2 }, - { 106, 2 }, - { 106, 3 }, - { 106, 2 }, - { 106, 3 }, - { 106, 2 }, - { 106, 3 }, + { 105, 0 }, + { 103, 2 }, + { 103, 2 }, + { 103, 3 }, + { 103, 2 }, + { 103, 3 }, + { 103, 2 }, + { 103, 3 }, + { 103, 2 }, + { 103, 1 }, { 106, 2 }, - { 106, 1 }, - { 109, 2 }, - { 109, 0 }, + { 106, 0 }, { 83, 7 }, { 83, 10 }, - { 110, 3 }, + { 107, 3 }, + { 107, 1 }, { 110, 1 }, - { 113, 1 }, - { 111, 3 }, + { 108, 3 }, + { 108, 1 }, { 111, 1 }, - { 114, 1 }, { 84, 3 }, - { 115, 4 }, - { 117, 3 }, + { 112, 4 }, + { 114, 3 }, + { 114, 1 }, + { 115, 3 }, { 117, 1 }, + { 85, 3 }, { 118, 3 }, + { 99, 3 }, + { 99, 2 }, + { 99, 1 }, + { 99, 5 }, + { 99, 7 }, + { 99, 6 }, + { 99, 4 }, + { 99, 5 }, + { 99, 3 }, + { 120, 3 }, { 120, 1 }, - { 85, 3 }, - { 121, 3 }, - { 100, 3 }, - { 100, 2 }, - { 100, 1 }, - { 107, 1 }, + { 119, 1 }, + { 104, 1 }, { 87, 2 }, { 87, 0 }, { 90, 3 }, { 90, 0 }, - { 122, 3 }, + { 121, 3 }, + { 121, 1 }, { 122, 1 }, - { 123, 1 }, - { 123, 2 }, - { 123, 2 }, + { 122, 2 }, + { 122, 2 }, { 88, 3 }, { 88, 0 }, - { 124, 3 }, + { 123, 3 }, + { 123, 1 }, { 124, 1 }, - { 125, 1 }, { 89, 2 }, { 89, 0 }, { 92, 2 }, @@ -102566,77 +103251,77 @@ static struct { { 91, 4 }, { 91, 4 }, { 91, 0 }, - { 116, 2 }, - { 116, 0 }, - { 126, 1 }, - { 126, 1 }, - { 126, 1 }, - { 126, 1 }, - { 126, 1 }, - { 99, 2 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 4 }, - { 99, 3 }, - { 99, 4 }, - { 99, 5 }, - { 99, 6 }, - { 99, 3 }, - { 99, 5 }, - { 99, 6 }, - { 99, 4 }, - { 99, 3 }, - { 99, 6 }, - { 99, 6 }, - { 99, 4 }, + { 113, 2 }, + { 113, 0 }, + { 125, 1 }, + { 125, 1 }, + { 125, 1 }, + { 125, 1 }, + { 125, 1 }, + { 98, 2 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 4 }, + { 98, 3 }, + { 98, 4 }, + { 98, 5 }, + { 98, 6 }, + { 98, 3 }, + { 98, 5 }, + { 98, 6 }, + { 98, 4 }, + { 98, 3 }, + { 98, 6 }, + { 98, 6 }, + { 98, 4 }, + { 127, 2 }, + { 127, 1 }, + { 128, 4 }, { 128, 2 }, - { 128, 1 }, - { 129, 4 }, - { 129, 2 }, - { 99, 1 }, - { 130, 5 }, + { 98, 1 }, + { 129, 5 }, + { 130, 1 }, + { 130, 0 }, { 131, 1 }, { 131, 0 }, + { 126, 3 }, + { 126, 1 }, { 132, 1 }, - { 132, 0 }, - { 127, 3 }, - { 127, 1 }, - { 133, 1 }, - { 133, 1 }, - { 99, 3 }, - { 99, 4 }, - { 99, 3 }, - { 99, 2 }, - { 99, 2 }, - { 99, 3 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 119, 3 }, - { 119, 1 }, + { 132, 1 }, + { 98, 3 }, + { 98, 4 }, + { 98, 3 }, + { 98, 2 }, + { 98, 2 }, + { 98, 3 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 116, 3 }, + { 116, 1 }, }; static void pp_accept(ppParser*); /* Forward Declaration */ @@ -102670,11 +103355,11 @@ static void pp_reduce( ** break; */ case 0: -// 566 "parser.lemon" +// 567 "parser.lemon" { - status->ret = ppmsp[0].minor.pp244; + status->ret = ppmsp[0].minor.pp162; } -// 1680 "parser.c" +// 1701 "parser.c" break; case 1: case 2: @@ -102682,880 +103367,927 @@ static void pp_reduce( case 4: case 18: case 19: - case 24: - case 25: - case 27: - case 48: - case 55: - case 57: - case 63: - case 69: - case 76: - case 77: - case 128: + case 22: + case 23: + case 43: + case 50: + case 52: + case 65: + case 67: + case 73: + case 80: + case 81: case 132: - case 137: - case 144: -// 572 "parser.lemon" + case 136: + case 141: + case 148: +// 573 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; } -// 1706 "parser.c" +// 1727 "parser.c" break; case 5: -// 590 "parser.lemon" +// 591 "parser.lemon" { - ppgotominor.pp244 = phql_ret_select_statement(ppmsp[-6].minor.pp244, ppmsp[-5].minor.pp244, ppmsp[-2].minor.pp244, ppmsp[-4].minor.pp244, ppmsp[-3].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_select_statement(ppmsp[-6].minor.pp162, ppmsp[-5].minor.pp162, ppmsp[-2].minor.pp162, ppmsp[-4].minor.pp162, ppmsp[-3].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1713 "parser.c" +// 1734 "parser.c" break; case 6: -// 596 "parser.lemon" +// 597 "parser.lemon" { - ppgotominor.pp244 = phql_ret_select_clause(ppmsp[-5].minor.pp244, ppmsp[-4].minor.pp244, ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); - pp_destructor(26,&ppmsp[-6].minor); - pp_destructor(27,&ppmsp[-3].minor); + ppgotominor.pp162 = phql_ret_select_clause(ppmsp[-4].minor.pp162, ppmsp[-3].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); + pp_destructor(26,&ppmsp[-5].minor); + pp_destructor(27,&ppmsp[-2].minor); } -// 1722 "parser.c" +// 1743 "parser.c" break; case 7: -// 602 "parser.lemon" +// 603 "parser.lemon" { - ppgotominor.pp244 = phql_ret_distinct_all(1); + ppgotominor.pp162 = phql_ret_distinct_all(1); pp_destructor(28,&ppmsp[0].minor); } -// 1730 "parser.c" +// 1751 "parser.c" break; case 8: -// 606 "parser.lemon" +// 607 "parser.lemon" { - ppgotominor.pp244 = phql_ret_distinct_all(0); + ppgotominor.pp162 = phql_ret_distinct_all(0); pp_destructor(29,&ppmsp[0].minor); } -// 1738 "parser.c" +// 1759 "parser.c" break; case 9: case 20: - case 22: - case 32: - case 43: - case 65: - case 67: - case 74: - case 79: - case 81: + case 27: + case 38: + case 69: + case 71: + case 78: + case 83: case 85: - case 87: - case 131: - case 133: -// 610 "parser.lemon" + case 89: + case 91: + case 135: + case 137: +// 611 "parser.lemon" { - ppgotominor.pp244 = NULL; + ppgotominor.pp162 = NULL; } -// 1758 "parser.c" +// 1778 "parser.c" break; case 10: case 17: - case 46: + case 41: + case 44: case 49: - case 54: - case 68: - case 75: - case 134: -// 616 "parser.lemon" + case 64: + case 72: + case 79: + case 138: +// 617 "parser.lemon" { - ppgotominor.pp244 = phql_ret_zval_list(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_zval_list(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(25,&ppmsp[-1].minor); } -// 1773 "parser.c" +// 1794 "parser.c" break; case 11: - case 47: - case 50: - case 125: - case 135: -// 620 "parser.lemon" + case 42: + case 45: + case 129: + case 139: +// 621 "parser.lemon" { - ppgotominor.pp244 = phql_ret_zval_list(ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_zval_list(ppmsp[0].minor.pp162, NULL); } -// 1784 "parser.c" +// 1805 "parser.c" break; case 12: - case 136: -// 626 "parser.lemon" + case 140: +// 627 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_STARALL, NULL, NULL, NULL); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_STARALL, NULL, NULL, NULL); pp_destructor(17,&ppmsp[0].minor); } -// 1793 "parser.c" +// 1814 "parser.c" break; case 13: -// 630 "parser.lemon" +// 631 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_DOMAINALL, NULL, ppmsp[-2].minor.pp0, NULL); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_DOMAINALL, NULL, ppmsp[-2].minor.pp0, NULL); pp_destructor(31,&ppmsp[-1].minor); pp_destructor(17,&ppmsp[0].minor); } -// 1802 "parser.c" +// 1823 "parser.c" break; case 14: -// 634 "parser.lemon" +// 635 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-2].minor.pp244, NULL, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-2].minor.pp162, NULL, ppmsp[0].minor.pp0); pp_destructor(32,&ppmsp[-1].minor); } -// 1810 "parser.c" +// 1831 "parser.c" break; case 15: -// 638 "parser.lemon" +// 639 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-1].minor.pp244, NULL, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-1].minor.pp162, NULL, ppmsp[0].minor.pp0); } -// 1817 "parser.c" +// 1838 "parser.c" break; case 16: -// 642 "parser.lemon" +// 643 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[0].minor.pp244, NULL, NULL); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[0].minor.pp162, NULL, NULL); } -// 1824 "parser.c" +// 1845 "parser.c" break; case 21: -// 664 "parser.lemon" + case 128: +// 667 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; - pp_destructor(33,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_zval_list(ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1832 "parser.c" +// 1853 "parser.c" + break; + case 24: +// 684 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_join_item(ppmsp[-3].minor.pp162, ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); +} +// 1860 "parser.c" + break; + case 25: +// 690 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); + pp_destructor(32,&ppmsp[-1].minor); +} +// 1868 "parser.c" break; - case 23: case 26: - case 124: -// 674 "parser.lemon" + case 46: + case 66: + case 160: +// 694 "parser.lemon" { - ppgotominor.pp244 = phql_ret_zval_list(ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); } -// 1841 "parser.c" +// 1878 "parser.c" break; case 28: - case 31: - case 51: - case 156: -// 700 "parser.lemon" +// 704 "parser.lemon" { - ppgotominor.pp244 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_INNERJOIN); + pp_destructor(33,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1851 "parser.c" +// 1887 "parser.c" break; case 29: -// 707 "parser.lemon" +// 708 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_item(ppmsp[-3].minor.pp244, ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_CROSSJOIN); + pp_destructor(35,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1858 "parser.c" +// 1896 "parser.c" break; case 30: -// 713 "parser.lemon" +// 712 "parser.lemon" { - ppgotominor.pp244 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); - pp_destructor(32,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_LEFTJOIN); + pp_destructor(36,&ppmsp[-2].minor); + pp_destructor(37,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1866 "parser.c" +// 1906 "parser.c" break; - case 33: -// 727 "parser.lemon" + case 31: +// 716 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_INNERJOIN); - pp_destructor(34,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_LEFTJOIN); + pp_destructor(36,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1875 "parser.c" +// 1915 "parser.c" break; - case 34: -// 731 "parser.lemon" + case 32: +// 720 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_CROSSJOIN); - pp_destructor(36,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_RIGHTJOIN); + pp_destructor(38,&ppmsp[-2].minor); + pp_destructor(37,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1884 "parser.c" +// 1925 "parser.c" break; - case 35: -// 735 "parser.lemon" + case 33: +// 724 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_LEFTJOIN); - pp_destructor(37,&ppmsp[-2].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_RIGHTJOIN); pp_destructor(38,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1894 "parser.c" +// 1934 "parser.c" break; - case 36: -// 739 "parser.lemon" + case 34: +// 728 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_LEFTJOIN); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_FULLJOIN); + pp_destructor(39,&ppmsp[-2].minor); pp_destructor(37,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1903 "parser.c" +// 1944 "parser.c" break; - case 37: -// 743 "parser.lemon" + case 35: +// 732 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_RIGHTJOIN); - pp_destructor(39,&ppmsp[-2].minor); - pp_destructor(38,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_FULLJOIN); + pp_destructor(39,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1913 "parser.c" +// 1953 "parser.c" break; - case 38: -// 747 "parser.lemon" + case 36: +// 736 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_RIGHTJOIN); - pp_destructor(39,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_INNERJOIN); + pp_destructor(34,&ppmsp[0].minor); } -// 1922 "parser.c" +// 1961 "parser.c" break; - case 39: -// 751 "parser.lemon" + case 37: +// 742 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_FULLJOIN); - pp_destructor(40,&ppmsp[-2].minor); - pp_destructor(38,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = ppmsp[0].minor.pp162; + pp_destructor(40,&ppmsp[-1].minor); } -// 1932 "parser.c" +// 1969 "parser.c" + break; + case 39: +// 753 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_insert_statement(ppmsp[-4].minor.pp162, NULL, ppmsp[-1].minor.pp162); + pp_destructor(41,&ppmsp[-6].minor); + pp_destructor(42,&ppmsp[-5].minor); + pp_destructor(43,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); +} +// 1981 "parser.c" break; case 40: -// 755 "parser.lemon" +// 757 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_FULLJOIN); - pp_destructor(40,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_insert_statement(ppmsp[-7].minor.pp162, ppmsp[-5].minor.pp162, ppmsp[-1].minor.pp162); + pp_destructor(41,&ppmsp[-9].minor); + pp_destructor(42,&ppmsp[-8].minor); + pp_destructor(44,&ppmsp[-6].minor); + pp_destructor(45,&ppmsp[-4].minor); + pp_destructor(43,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 1941 "parser.c" +// 1995 "parser.c" break; - case 41: -// 759 "parser.lemon" + case 47: +// 795 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_INNERJOIN); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_update_statement(ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1949 "parser.c" +// 2002 "parser.c" break; - case 42: -// 765 "parser.lemon" + case 48: +// 801 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; - pp_destructor(41,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_update_clause(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); + pp_destructor(46,&ppmsp[-3].minor); + pp_destructor(47,&ppmsp[-1].minor); } -// 1957 "parser.c" +// 2011 "parser.c" break; - case 44: -// 776 "parser.lemon" + case 51: +// 817 "parser.lemon" { - ppgotominor.pp244 = phql_ret_insert_statement(ppmsp[-4].minor.pp244, NULL, ppmsp[-1].minor.pp244); - pp_destructor(42,&ppmsp[-6].minor); - pp_destructor(43,&ppmsp[-5].minor); - pp_destructor(44,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_update_item(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); + pp_destructor(3,&ppmsp[-1].minor); } -// 1969 "parser.c" +// 2019 "parser.c" break; - case 45: -// 780 "parser.lemon" + case 53: +// 829 "parser.lemon" { - ppgotominor.pp244 = phql_ret_insert_statement(ppmsp[-7].minor.pp244, ppmsp[-5].minor.pp244, ppmsp[-1].minor.pp244); - pp_destructor(42,&ppmsp[-9].minor); - pp_destructor(43,&ppmsp[-8].minor); - pp_destructor(45,&ppmsp[-6].minor); - pp_destructor(46,&ppmsp[-4].minor); - pp_destructor(44,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_delete_statement(ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1983 "parser.c" +// 2026 "parser.c" break; - case 52: -// 818 "parser.lemon" + case 54: +// 835 "parser.lemon" { - ppgotominor.pp244 = phql_ret_update_statement(ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_delete_clause(ppmsp[0].minor.pp162); + pp_destructor(48,&ppmsp[-2].minor); + pp_destructor(27,&ppmsp[-1].minor); } -// 1990 "parser.c" +// 2035 "parser.c" break; - case 53: -// 824 "parser.lemon" + case 55: +// 841 "parser.lemon" { - ppgotominor.pp244 = phql_ret_update_clause(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); - pp_destructor(47,&ppmsp[-3].minor); - pp_destructor(48,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp0, NULL); + pp_destructor(32,&ppmsp[-1].minor); } -// 1999 "parser.c" +// 2043 "parser.c" break; case 56: -// 840 "parser.lemon" +// 845 "parser.lemon" { - ppgotominor.pp244 = phql_ret_update_item(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); - pp_destructor(3,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-1].minor.pp162, ppmsp[0].minor.pp0, NULL); +} +// 2050 "parser.c" + break; + case 57: +// 849 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[0].minor.pp162, NULL, NULL); } -// 2007 "parser.c" +// 2057 "parser.c" break; case 58: -// 852 "parser.lemon" +// 853 "parser.lemon" { - ppgotominor.pp244 = phql_ret_delete_statement(ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-4].minor.pp162, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp162); + pp_destructor(32,&ppmsp[-3].minor); + pp_destructor(49,&ppmsp[-1].minor); } -// 2014 "parser.c" +// 2066 "parser.c" break; case 59: -// 858 "parser.lemon" +// 857 "parser.lemon" { - ppgotominor.pp244 = phql_ret_delete_clause(ppmsp[0].minor.pp244); - pp_destructor(49,&ppmsp[-2].minor); - pp_destructor(27,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-6].minor.pp162, ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp162); + pp_destructor(32,&ppmsp[-5].minor); + pp_destructor(49,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2023 "parser.c" +// 2077 "parser.c" break; case 60: -// 864 "parser.lemon" +// 861 "parser.lemon" { - ppgotominor.pp244 = phql_ret_assoc_name(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp0); - pp_destructor(32,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-5].minor.pp162, ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp162); + pp_destructor(49,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2031 "parser.c" +// 2087 "parser.c" break; case 61: -// 868 "parser.lemon" +// 865 "parser.lemon" { - ppgotominor.pp244 = phql_ret_assoc_name(ppmsp[-1].minor.pp244, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-3].minor.pp162, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp162); + pp_destructor(49,&ppmsp[-1].minor); } -// 2038 "parser.c" +// 2095 "parser.c" break; case 62: -// 872 "parser.lemon" +// 869 "parser.lemon" { - ppgotominor.pp244 = phql_ret_assoc_name(ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-4].minor.pp162, NULL, ppmsp[-1].minor.pp162); + pp_destructor(49,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2045 "parser.c" +// 2105 "parser.c" break; - case 64: -// 884 "parser.lemon" + case 63: +// 873 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-2].minor.pp162, NULL, ppmsp[0].minor.pp162); + pp_destructor(49,&ppmsp[-1].minor); +} +// 2113 "parser.c" + break; + case 68: +// 901 "parser.lemon" +{ + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(50,&ppmsp[-1].minor); } -// 2053 "parser.c" +// 2121 "parser.c" break; - case 66: -// 894 "parser.lemon" + case 70: +// 911 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(51,&ppmsp[-2].minor); pp_destructor(52,&ppmsp[-1].minor); } -// 2062 "parser.c" +// 2130 "parser.c" break; - case 70: -// 914 "parser.lemon" + case 74: +// 931 "parser.lemon" { - ppgotominor.pp244 = phql_ret_order_item(ppmsp[0].minor.pp244, 0); + ppgotominor.pp162 = phql_ret_order_item(ppmsp[0].minor.pp162, 0); } -// 2069 "parser.c" +// 2137 "parser.c" break; - case 71: -// 918 "parser.lemon" + case 75: +// 935 "parser.lemon" { - ppgotominor.pp244 = phql_ret_order_item(ppmsp[-1].minor.pp244, PHQL_T_ASC); + ppgotominor.pp162 = phql_ret_order_item(ppmsp[-1].minor.pp162, PHQL_T_ASC); pp_destructor(53,&ppmsp[0].minor); } -// 2077 "parser.c" +// 2145 "parser.c" break; - case 72: -// 922 "parser.lemon" + case 76: +// 939 "parser.lemon" { - ppgotominor.pp244 = phql_ret_order_item(ppmsp[-1].minor.pp244, PHQL_T_DESC); + ppgotominor.pp162 = phql_ret_order_item(ppmsp[-1].minor.pp162, PHQL_T_DESC); pp_destructor(54,&ppmsp[0].minor); } -// 2085 "parser.c" +// 2153 "parser.c" break; - case 73: -// 928 "parser.lemon" + case 77: +// 945 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(55,&ppmsp[-2].minor); pp_destructor(52,&ppmsp[-1].minor); } -// 2094 "parser.c" +// 2162 "parser.c" break; - case 78: -// 954 "parser.lemon" + case 82: +// 971 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(56,&ppmsp[-1].minor); } -// 2102 "parser.c" +// 2170 "parser.c" break; - case 80: -// 964 "parser.lemon" + case 84: +// 981 "parser.lemon" { - ppgotominor.pp244 = phql_ret_for_update_clause(); + ppgotominor.pp162 = phql_ret_for_update_clause(); pp_destructor(57,&ppmsp[-1].minor); - pp_destructor(47,&ppmsp[0].minor); + pp_destructor(46,&ppmsp[0].minor); } -// 2111 "parser.c" +// 2179 "parser.c" break; - case 82: case 86: -// 974 "parser.lemon" + case 90: +// 991 "parser.lemon" { - ppgotominor.pp244 = phql_ret_limit_clause(ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_limit_clause(ppmsp[0].minor.pp162, NULL); pp_destructor(58,&ppmsp[-1].minor); } -// 2120 "parser.c" +// 2188 "parser.c" break; - case 83: -// 978 "parser.lemon" + case 87: +// 995 "parser.lemon" { - ppgotominor.pp244 = phql_ret_limit_clause(ppmsp[0].minor.pp244, ppmsp[-2].minor.pp244); + ppgotominor.pp162 = phql_ret_limit_clause(ppmsp[0].minor.pp162, ppmsp[-2].minor.pp162); pp_destructor(58,&ppmsp[-3].minor); pp_destructor(25,&ppmsp[-1].minor); } -// 2129 "parser.c" +// 2197 "parser.c" break; - case 84: -// 982 "parser.lemon" + case 88: +// 999 "parser.lemon" { - ppgotominor.pp244 = phql_ret_limit_clause(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_limit_clause(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(58,&ppmsp[-3].minor); pp_destructor(59,&ppmsp[-1].minor); } -// 2138 "parser.c" +// 2206 "parser.c" break; - case 88: - case 145: -// 1000 "parser.lemon" + case 92: + case 149: +// 1017 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_INTEGER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_INTEGER, ppmsp[0].minor.pp0); } -// 2146 "parser.c" +// 2214 "parser.c" break; - case 89: - case 146: -// 1004 "parser.lemon" + case 93: + case 150: +// 1021 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_HINTEGER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_HINTEGER, ppmsp[0].minor.pp0); } -// 2154 "parser.c" +// 2222 "parser.c" break; - case 90: - case 152: -// 1008 "parser.lemon" + case 94: + case 156: +// 1025 "parser.lemon" { - ppgotominor.pp244 = phql_ret_placeholder_zval(PHQL_T_NPLACEHOLDER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_placeholder_zval(PHQL_T_NPLACEHOLDER, ppmsp[0].minor.pp0); } -// 2162 "parser.c" +// 2230 "parser.c" break; - case 91: - case 153: -// 1012 "parser.lemon" + case 95: + case 157: +// 1029 "parser.lemon" { - ppgotominor.pp244 = phql_ret_placeholder_zval(PHQL_T_SPLACEHOLDER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_placeholder_zval(PHQL_T_SPLACEHOLDER, ppmsp[0].minor.pp0); } -// 2170 "parser.c" +// 2238 "parser.c" break; - case 92: - case 154: -// 1016 "parser.lemon" + case 96: + case 158: +// 1033 "parser.lemon" { - ppgotominor.pp244 = phql_ret_placeholder_zval(PHQL_T_BPLACEHOLDER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_placeholder_zval(PHQL_T_BPLACEHOLDER, ppmsp[0].minor.pp0); } -// 2178 "parser.c" +// 2246 "parser.c" break; - case 93: -// 1022 "parser.lemon" + case 97: +// 1039 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_MINUS, NULL, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_MINUS, NULL, ppmsp[0].minor.pp162); pp_destructor(20,&ppmsp[-1].minor); } -// 2186 "parser.c" +// 2254 "parser.c" break; - case 94: -// 1026 "parser.lemon" + case 98: +// 1043 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_SUB, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_SUB, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(20,&ppmsp[-1].minor); } -// 2194 "parser.c" +// 2262 "parser.c" break; - case 95: -// 1030 "parser.lemon" + case 99: +// 1047 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ADD, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ADD, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(19,&ppmsp[-1].minor); } -// 2202 "parser.c" +// 2270 "parser.c" break; - case 96: -// 1034 "parser.lemon" + case 100: +// 1051 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_MUL, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_MUL, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(17,&ppmsp[-1].minor); } -// 2210 "parser.c" +// 2278 "parser.c" break; - case 97: -// 1038 "parser.lemon" + case 101: +// 1055 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_DIV, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_DIV, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(16,&ppmsp[-1].minor); } -// 2218 "parser.c" +// 2286 "parser.c" break; - case 98: -// 1042 "parser.lemon" + case 102: +// 1059 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_MOD, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_MOD, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(18,&ppmsp[-1].minor); } -// 2226 "parser.c" +// 2294 "parser.c" break; - case 99: -// 1046 "parser.lemon" + case 103: +// 1063 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_AND, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_AND, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(9,&ppmsp[-1].minor); } -// 2234 "parser.c" +// 2302 "parser.c" break; - case 100: -// 1050 "parser.lemon" + case 104: +// 1067 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_OR, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_OR, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(10,&ppmsp[-1].minor); } -// 2242 "parser.c" +// 2310 "parser.c" break; - case 101: -// 1054 "parser.lemon" + case 105: +// 1071 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_AND, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_AND, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(13,&ppmsp[-1].minor); } -// 2250 "parser.c" +// 2318 "parser.c" break; - case 102: -// 1058 "parser.lemon" + case 106: +// 1075 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_OR, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_OR, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(14,&ppmsp[-1].minor); } -// 2258 "parser.c" +// 2326 "parser.c" break; - case 103: -// 1062 "parser.lemon" + case 107: +// 1079 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_XOR, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_XOR, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(15,&ppmsp[-1].minor); } -// 2266 "parser.c" +// 2334 "parser.c" break; - case 104: -// 1066 "parser.lemon" + case 108: +// 1083 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_EQUALS, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_EQUALS, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(3,&ppmsp[-1].minor); } -// 2274 "parser.c" +// 2342 "parser.c" break; - case 105: -// 1070 "parser.lemon" + case 109: +// 1087 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NOTEQUALS, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NOTEQUALS, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(4,&ppmsp[-1].minor); } -// 2282 "parser.c" +// 2350 "parser.c" break; - case 106: -// 1074 "parser.lemon" + case 110: +// 1091 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_LESS, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_LESS, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(5,&ppmsp[-1].minor); } -// 2290 "parser.c" +// 2358 "parser.c" break; - case 107: -// 1078 "parser.lemon" + case 111: +// 1095 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_GREATER, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_GREATER, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(6,&ppmsp[-1].minor); } -// 2298 "parser.c" +// 2366 "parser.c" break; - case 108: -// 1082 "parser.lemon" + case 112: +// 1099 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_GREATEREQUAL, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_GREATEREQUAL, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(7,&ppmsp[-1].minor); } -// 2306 "parser.c" +// 2374 "parser.c" break; - case 109: -// 1086 "parser.lemon" + case 113: +// 1103 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_LESSEQUAL, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_LESSEQUAL, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(8,&ppmsp[-1].minor); } -// 2314 "parser.c" +// 2382 "parser.c" break; - case 110: -// 1090 "parser.lemon" + case 114: +// 1107 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_LIKE, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_LIKE, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(11,&ppmsp[-1].minor); } -// 2322 "parser.c" +// 2390 "parser.c" break; - case 111: -// 1094 "parser.lemon" + case 115: +// 1111 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NLIKE, ppmsp[-3].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NLIKE, ppmsp[-3].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(23,&ppmsp[-2].minor); pp_destructor(11,&ppmsp[-1].minor); } -// 2331 "parser.c" +// 2399 "parser.c" break; - case 112: -// 1098 "parser.lemon" + case 116: +// 1115 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ILIKE, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ILIKE, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(12,&ppmsp[-1].minor); } -// 2339 "parser.c" +// 2407 "parser.c" break; - case 113: -// 1102 "parser.lemon" + case 117: +// 1119 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NILIKE, ppmsp[-3].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NILIKE, ppmsp[-3].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(23,&ppmsp[-2].minor); pp_destructor(12,&ppmsp[-1].minor); } -// 2348 "parser.c" +// 2416 "parser.c" break; - case 114: - case 117: -// 1106 "parser.lemon" + case 118: + case 121: +// 1123 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_IN, ppmsp[-4].minor.pp244, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_IN, ppmsp[-4].minor.pp162, ppmsp[-1].minor.pp162); pp_destructor(22,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2359 "parser.c" +// 2427 "parser.c" break; - case 115: - case 118: -// 1110 "parser.lemon" + case 119: + case 122: +// 1127 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NOTIN, ppmsp[-5].minor.pp244, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NOTIN, ppmsp[-5].minor.pp162, ppmsp[-1].minor.pp162); pp_destructor(23,&ppmsp[-4].minor); pp_destructor(22,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2371 "parser.c" +// 2439 "parser.c" break; - case 116: -// 1114 "parser.lemon" + case 120: +// 1131 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_SUBQUERY, ppmsp[-1].minor.pp244, NULL); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_SUBQUERY, ppmsp[-1].minor.pp162, NULL); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2380 "parser.c" +// 2448 "parser.c" break; - case 119: -// 1126 "parser.lemon" + case 123: +// 1143 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_EXISTS, NULL, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_EXISTS, NULL, ppmsp[-1].minor.pp162); pp_destructor(65,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2390 "parser.c" +// 2458 "parser.c" break; - case 120: -// 1130 "parser.lemon" + case 124: +// 1147 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_AGAINST, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_AGAINST, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(1,&ppmsp[-1].minor); } -// 2398 "parser.c" +// 2466 "parser.c" break; - case 121: -// 1134 "parser.lemon" + case 125: +// 1151 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_CAST, ppmsp[-3].minor.pp244, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_CAST, ppmsp[-3].minor.pp162, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); pp_destructor(66,&ppmsp[-5].minor); - pp_destructor(45,&ppmsp[-4].minor); + pp_destructor(44,&ppmsp[-4].minor); pp_destructor(32,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2409 "parser.c" +// 2477 "parser.c" break; - case 122: -// 1138 "parser.lemon" + case 126: +// 1155 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_CONVERT, ppmsp[-3].minor.pp244, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_CONVERT, ppmsp[-3].minor.pp162, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); pp_destructor(67,&ppmsp[-5].minor); - pp_destructor(45,&ppmsp[-4].minor); + pp_destructor(44,&ppmsp[-4].minor); pp_destructor(68,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2420 "parser.c" +// 2488 "parser.c" break; - case 123: -// 1142 "parser.lemon" + case 127: +// 1159 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_CASE, ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_CASE, ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162); pp_destructor(69,&ppmsp[-3].minor); pp_destructor(70,&ppmsp[0].minor); } -// 2429 "parser.c" +// 2497 "parser.c" break; - case 126: -// 1154 "parser.lemon" + case 130: +// 1171 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_WHEN, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_WHEN, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(71,&ppmsp[-3].minor); pp_destructor(72,&ppmsp[-1].minor); } -// 2438 "parser.c" +// 2506 "parser.c" break; - case 127: -// 1158 "parser.lemon" + case 131: +// 1175 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ELSE, ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ELSE, ppmsp[0].minor.pp162, NULL); pp_destructor(73,&ppmsp[-1].minor); } -// 2446 "parser.c" +// 2514 "parser.c" break; - case 129: -// 1168 "parser.lemon" + case 133: +// 1185 "parser.lemon" { - ppgotominor.pp244 = phql_ret_func_call(ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp244, ppmsp[-2].minor.pp244); - pp_destructor(45,&ppmsp[-3].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_func_call(ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp162, ppmsp[-2].minor.pp162); + pp_destructor(44,&ppmsp[-3].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2455 "parser.c" +// 2523 "parser.c" break; - case 130: -// 1174 "parser.lemon" + case 134: +// 1191 "parser.lemon" { - ppgotominor.pp244 = phql_ret_distinct(); + ppgotominor.pp162 = phql_ret_distinct(); pp_destructor(28,&ppmsp[0].minor); } -// 2463 "parser.c" +// 2531 "parser.c" break; - case 138: -// 1212 "parser.lemon" + case 142: +// 1229 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ISNULL, ppmsp[-2].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ISNULL, ppmsp[-2].minor.pp162, NULL); pp_destructor(21,&ppmsp[-1].minor); pp_destructor(74,&ppmsp[0].minor); } -// 2472 "parser.c" +// 2540 "parser.c" break; - case 139: -// 1216 "parser.lemon" + case 143: +// 1233 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ISNOTNULL, ppmsp[-3].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ISNOTNULL, ppmsp[-3].minor.pp162, NULL); pp_destructor(21,&ppmsp[-2].minor); pp_destructor(23,&ppmsp[-1].minor); pp_destructor(74,&ppmsp[0].minor); } -// 2482 "parser.c" +// 2550 "parser.c" break; - case 140: -// 1220 "parser.lemon" + case 144: +// 1237 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BETWEEN, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BETWEEN, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(2,&ppmsp[-1].minor); } -// 2490 "parser.c" +// 2558 "parser.c" break; - case 141: -// 1224 "parser.lemon" + case 145: +// 1241 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NOT, NULL, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NOT, NULL, ppmsp[0].minor.pp162); pp_destructor(23,&ppmsp[-1].minor); } -// 2498 "parser.c" +// 2566 "parser.c" break; - case 142: -// 1228 "parser.lemon" + case 146: +// 1245 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_NOT, NULL, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_NOT, NULL, ppmsp[0].minor.pp162); pp_destructor(24,&ppmsp[-1].minor); } -// 2506 "parser.c" +// 2574 "parser.c" break; - case 143: -// 1232 "parser.lemon" + case 147: +// 1249 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ENCLOSED, ppmsp[-1].minor.pp244, NULL); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ENCLOSED, ppmsp[-1].minor.pp162, NULL); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2515 "parser.c" +// 2583 "parser.c" break; - case 147: -// 1248 "parser.lemon" + case 151: +// 1265 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_STRING, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_STRING, ppmsp[0].minor.pp0); } -// 2522 "parser.c" +// 2590 "parser.c" break; - case 148: -// 1252 "parser.lemon" + case 152: +// 1269 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_DOUBLE, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_DOUBLE, ppmsp[0].minor.pp0); } -// 2529 "parser.c" +// 2597 "parser.c" break; - case 149: -// 1256 "parser.lemon" + case 153: +// 1273 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_NULL, NULL); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_NULL, NULL); pp_destructor(74,&ppmsp[0].minor); } -// 2537 "parser.c" +// 2605 "parser.c" break; - case 150: -// 1260 "parser.lemon" + case 154: +// 1277 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_TRUE, NULL); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_TRUE, NULL); pp_destructor(77,&ppmsp[0].minor); } -// 2545 "parser.c" +// 2613 "parser.c" break; - case 151: -// 1264 "parser.lemon" + case 155: +// 1281 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_FALSE, NULL); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_FALSE, NULL); pp_destructor(78,&ppmsp[0].minor); } -// 2553 "parser.c" +// 2621 "parser.c" break; - case 155: -// 1285 "parser.lemon" + case 159: +// 1302 "parser.lemon" { - ppgotominor.pp244 = phql_ret_qualified_name(NULL, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_qualified_name(NULL, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp0); pp_destructor(31,&ppmsp[-1].minor); } -// 2561 "parser.c" +// 2629 "parser.c" break; }; ppgoto = ppRuleInfo[ppruleno].lhs; @@ -103591,7 +104323,7 @@ static void pp_syntax_error( ){ phql_ARG_FETCH; #define PPTOKEN (ppminor.pp0) -// 490 "parser.lemon" +// 491 "parser.lemon" if (status->scanner_state->start_length) { { @@ -103658,7 +104390,7 @@ static void pp_syntax_error( status->status = PHQL_PARSING_FAILED; -// 2670 "parser.c" +// 2738 "parser.c" phql_ARG_STORE; /* Suppress warning about unused %extra_argument variable */ } @@ -104418,7 +105150,7 @@ static int phql_internal_parse_phql(zval **result, char *phql, unsigned int phql } -/* Generated by re2c 0.13.6 on Mon Jul 6 13:03:04 2015 */ +/* Generated by re2c 0.13.6 on Wed Aug 5 14:30:06 2015 */ // 1 "scanner.re" @@ -110837,7 +111569,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, __construct) { zephir_update_property_this(this_ptr, SL("_columnTypes"), columnTypes TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 357, result, cache); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 350, result, cache); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -110845,12 +111577,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, __construct) { static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { - zephir_fcall_cache_entry *_12 = NULL, *_14 = NULL; - zend_class_entry *_11; - HashTable *_2, *_5; - HashPosition _1, _4; + zephir_fcall_cache_entry *_13 = NULL, *_15 = NULL; + zend_class_entry *_12; + HashTable *_3, *_6; + HashPosition _2, _5; int dirtyState, ZEPHIR_LAST_CALL_STATUS; - zval *row, *hydrateMode, *alias = NULL, *activeRow = NULL, *type = NULL, *columnTypes, *column = NULL, *columnValue = NULL, *value = NULL, *attribute = NULL, *source = NULL, *attributes = NULL, *columnMap = NULL, *rowModel = NULL, *keepSnapshots = NULL, *sqlAlias = NULL, *modelName = NULL, *_0, **_3, **_6, *_7 = NULL, *_8 = NULL, *_9, *_10 = NULL, *_13, _15 = zval_used_for_init, _16 = zval_used_for_init; + zval *row, *hydrateMode, *eager, *alias = NULL, *activeRow = NULL, *type = NULL, *column = NULL, *columnValue = NULL, *value = NULL, *attribute = NULL, *source = NULL, *attributes = NULL, *columnMap = NULL, *rowModel = NULL, *keepSnapshots = NULL, *sqlAlias = NULL, *modelName = NULL, *_0, *_1, **_4, **_7, *_8 = NULL, *_9 = NULL, *_10, *_11 = NULL, *_14, _16 = zval_used_for_init, _17 = zval_used_for_init; ZEPHIR_MM_GROW(); @@ -110892,41 +111624,40 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { break; } while(0); - ZEPHIR_OBS_VAR(columnTypes); - zephir_read_property_this(&columnTypes, this_ptr, SL("_columnTypes"), PH_NOISY_CC); dirtyState = 0; - zephir_is_iterable(columnTypes, &_2, &_1, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 245); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_columnTypes"), PH_NOISY_CC); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 246); for ( - ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS - ; zephir_hash_move_forward_ex(_2, &_1) + ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS + ; zephir_hash_move_forward_ex(_3, &_2) ) { - ZEPHIR_GET_HMKEY(alias, _2, _1); - ZEPHIR_GET_HVALUE(column, _3); + ZEPHIR_GET_HMKEY(alias, _3, _2); + ZEPHIR_GET_HVALUE(column, _4); if (Z_TYPE_P(column) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Column type is corrupt", "phalcon/mvc/model/resultset/complex.zep", 135); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Column type is corrupt", "phalcon/mvc/model/resultset/complex.zep", 133); return; } ZEPHIR_OBS_NVAR(type); - zephir_array_fetch_string(&type, column, SL("type"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 138 TSRMLS_CC); + zephir_array_fetch_string(&type, column, SL("type"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 136 TSRMLS_CC); if (ZEPHIR_IS_STRING(type, "object")) { ZEPHIR_OBS_NVAR(source); - zephir_array_fetch_string(&source, column, SL("column"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 144 TSRMLS_CC); + zephir_array_fetch_string(&source, column, SL("column"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 142 TSRMLS_CC); ZEPHIR_OBS_NVAR(attributes); - zephir_array_fetch_string(&attributes, column, SL("attributes"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 145 TSRMLS_CC); + zephir_array_fetch_string(&attributes, column, SL("attributes"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 143 TSRMLS_CC); ZEPHIR_OBS_NVAR(columnMap); - zephir_array_fetch_string(&columnMap, column, SL("columnMap"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 146 TSRMLS_CC); + zephir_array_fetch_string(&columnMap, column, SL("columnMap"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 144 TSRMLS_CC); ZEPHIR_INIT_NVAR(rowModel); array_init(rowModel); - zephir_is_iterable(attributes, &_5, &_4, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 164); + zephir_is_iterable(attributes, &_6, &_5, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 162); for ( - ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS - ; zephir_hash_move_forward_ex(_5, &_4) + ; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS + ; zephir_hash_move_forward_ex(_6, &_5) ) { - ZEPHIR_GET_HVALUE(attribute, _6); + ZEPHIR_GET_HVALUE(attribute, _7); ZEPHIR_OBS_NVAR(columnValue); - ZEPHIR_INIT_LNVAR(_7); - ZEPHIR_CONCAT_SVSV(_7, "_", source, "_", attribute); - zephir_array_fetch(&columnValue, row, _7, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 157 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_8); + ZEPHIR_CONCAT_SVSV(_8, "_", source, "_", attribute); + zephir_array_fetch(&columnValue, row, _8, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 155 TSRMLS_CC); zephir_array_update_zval(&rowModel, attribute, &columnValue, PH_COPY | PH_SEPARATE); } do { @@ -110937,43 +111668,43 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { ZVAL_BOOL(keepSnapshots, 0); } if (ZEPHIR_GLOBAL(orm).late_state_binding) { - ZEPHIR_OBS_NVAR(_8); - zephir_array_fetch_string(&_8, column, SL("instance"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 175 TSRMLS_CC); - if (zephir_instance_of_ev(_8, phalcon_mvc_model_ce TSRMLS_CC)) { - zephir_array_fetch_string(&_9, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 176 TSRMLS_CC); + ZEPHIR_OBS_NVAR(_9); + zephir_array_fetch_string(&_9, column, SL("instance"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 173 TSRMLS_CC); + if (zephir_instance_of_ev(_9, phalcon_mvc_model_ce TSRMLS_CC)) { + zephir_array_fetch_string(&_10, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 174 TSRMLS_CC); ZEPHIR_INIT_NVAR(modelName); - zephir_get_class(modelName, _9, 0 TSRMLS_CC); + zephir_get_class(modelName, _10, 0 TSRMLS_CC); } else { ZEPHIR_INIT_NVAR(modelName); ZVAL_STRING(modelName, "Phalcon\\Mvc\\Model", 1); } - zephir_array_fetch_string(&_9, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 182 TSRMLS_CC); - ZEPHIR_INIT_NVAR(_10); - ZVAL_LONG(_10, dirtyState); - _11 = zephir_fetch_class(modelName TSRMLS_CC); - ZEPHIR_CALL_CE_STATIC(&value, _11, "cloneresultmap", NULL, 0, _9, rowModel, columnMap, _10, keepSnapshots); + zephir_array_fetch_string(&_10, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 180 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_11); + ZVAL_LONG(_11, dirtyState); + _12 = zephir_fetch_class(modelName TSRMLS_CC); + ZEPHIR_CALL_CE_STATIC(&value, _12, "cloneresultmap", NULL, 0, _10, rowModel, columnMap, _11, keepSnapshots); zephir_check_call_status(); } else { - zephir_array_fetch_string(&_13, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 190 TSRMLS_CC); - ZEPHIR_INIT_NVAR(_10); - ZVAL_LONG(_10, dirtyState); - ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmap", &_12, 0, _13, rowModel, columnMap, _10, keepSnapshots); + zephir_array_fetch_string(&_14, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 188 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_11); + ZVAL_LONG(_11, dirtyState); + ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmap", &_13, 0, _14, rowModel, columnMap, _11, keepSnapshots); zephir_check_call_status(); } break; } - ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_14, 0, rowModel, columnMap, hydrateMode); + ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_15, 0, rowModel, columnMap, hydrateMode); zephir_check_call_status(); break; } while(0); ZEPHIR_OBS_NVAR(attribute); - zephir_array_fetch_string(&attribute, column, SL("balias"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 204 TSRMLS_CC); + zephir_array_fetch_string(&attribute, column, SL("balias"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 202 TSRMLS_CC); } else { ZEPHIR_OBS_NVAR(sqlAlias); if (zephir_array_isset_string_fetch(&sqlAlias, column, SS("sqlAlias"), 0 TSRMLS_CC)) { ZEPHIR_OBS_NVAR(value); - zephir_array_fetch(&value, row, sqlAlias, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 212 TSRMLS_CC); + zephir_array_fetch(&value, row, sqlAlias, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 210 TSRMLS_CC); } else { ZEPHIR_OBS_NVAR(value); zephir_array_isset_fetch(&value, row, alias, 0 TSRMLS_CC); @@ -110981,23 +111712,25 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { if (zephir_array_isset_string(column, SS("balias"))) { ZEPHIR_CPY_WRT(attribute, alias); } else { - ZEPHIR_SINIT_NVAR(_15); - ZVAL_STRING(&_15, "_", 0); ZEPHIR_SINIT_NVAR(_16); - ZVAL_STRING(&_16, "", 0); + ZVAL_STRING(&_16, "_", 0); + ZEPHIR_SINIT_NVAR(_17); + ZVAL_STRING(&_17, "", 0); ZEPHIR_INIT_NVAR(attribute); - zephir_fast_str_replace(&attribute, &_15, &_16, alias TSRMLS_CC); + zephir_fast_str_replace(&attribute, &_16, &_17, alias TSRMLS_CC); } } - do { - if (ZEPHIR_IS_LONG(hydrateMode, 1)) { - zephir_array_update_zval(&activeRow, attribute, &value, PH_COPY | PH_SEPARATE); + if (!(zephir_array_isset_string_fetch(&eager, column, SS("eager"), 1 TSRMLS_CC))) { + do { + if (ZEPHIR_IS_LONG(hydrateMode, 1)) { + zephir_array_update_zval(&activeRow, attribute, &value, PH_COPY | PH_SEPARATE); + break; + } + zephir_update_property_zval_zval(activeRow, attribute, value TSRMLS_CC); break; - } - zephir_update_property_zval_zval(activeRow, attribute, value TSRMLS_CC); - break; - } while(0); + } while(0); + } } zephir_update_property_this(this_ptr, SL("_activeRow"), activeRow TSRMLS_CC); RETURN_CCTOR(activeRow); @@ -111021,7 +111754,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, toArray) { _0->funcs->get_current_data(_0, &ZEPHIR_TMP_ITERATOR_PTR TSRMLS_CC); ZEPHIR_CPY_WRT(current, (*ZEPHIR_TMP_ITERATOR_PTR)); } - zephir_array_append(&records, current, PH_SEPARATE, "phalcon/mvc/model/resultset/complex.zep", 258); + zephir_array_append(&records, current, PH_SEPARATE, "phalcon/mvc/model/resultset/complex.zep", 259); } _0->funcs->dtor(_0 TSRMLS_CC); RETURN_CCTOR(records); @@ -111050,7 +111783,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, serialize) { zephir_array_update_string(&_0, SL("rows"), &records, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_0, SL("columnTypes"), &columnTypes, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_0, SL("hydrateMode"), &hydrateMode, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 71, _0); + ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_CCTOR(serialized); @@ -111079,23 +111812,23 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, unserialize) { zephir_update_property_this(this_ptr, SL("_disableHydration"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(resultset) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/complex.zep", 303); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/complex.zep", 304); return; } - zephir_array_fetch_string(&_0, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 306 TSRMLS_CC); + zephir_array_fetch_string(&_0, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 307 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_rows"), _0 TSRMLS_CC); - zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 307 TSRMLS_CC); + zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 308 TSRMLS_CC); ZEPHIR_INIT_ZVAL_NREF(_2); ZVAL_LONG(_2, zephir_fast_count_int(_1 TSRMLS_CC)); zephir_update_property_this(this_ptr, SL("_count"), _2 TSRMLS_CC); - zephir_array_fetch_string(&_3, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 308 TSRMLS_CC); + zephir_array_fetch_string(&_3, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 309 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_cache"), _3 TSRMLS_CC); - zephir_array_fetch_string(&_4, resultset, SL("columnTypes"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 309 TSRMLS_CC); + zephir_array_fetch_string(&_4, resultset, SL("columnTypes"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 310 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_columnTypes"), _4 TSRMLS_CC); - zephir_array_fetch_string(&_5, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 310 TSRMLS_CC); + zephir_array_fetch_string(&_5, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 311 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_hydrateMode"), _5 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -111154,7 +111887,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, __construct) { zephir_update_property_this(this_ptr, SL("_model"), model TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_columnMap"), columnMap TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_keepSnapshots"), keepSnapshots TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 357, result, cache); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 350, result, cache); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -111209,12 +111942,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, current) { _6 = zephir_fetch_nproperty_this(this_ptr, SL("_keepSnapshots"), PH_NOISY_CC); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, 0); - ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 358, _2, row, columnMap, _3, _6); + ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 351, _2, row, columnMap, _3, _6); zephir_check_call_status(); } break; } - ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 359, row, columnMap, hydrateMode); + ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 352, row, columnMap, hydrateMode); zephir_check_call_status(); break; } while(0); @@ -111346,7 +112079,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, serialize) { ZEPHIR_OBS_NVAR(_1); zephir_read_property_this(&_1, this_ptr, SL("_hydrateMode"), PH_NOISY_CC); zephir_array_update_string(&_0, SL("hydrateMode"), &_1, PH_COPY | PH_SEPARATE); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -111374,7 +112107,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, unserialize) { } - ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(resultset) != IS_ARRAY) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/simple.zep", 252); @@ -111681,7 +112414,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, get) { ZEPHIR_INIT_VAR(_3); ZVAL_STRING(_3, "rollbackPendent", 1); zephir_array_fast_append(_2, _3); - ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 362, _2); + ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 355, _2); zephir_check_call_status(); } zephir_update_property_this(this_ptr, SL("_initialized"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); @@ -111740,9 +112473,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, getOrCreateTransaction) ZEPHIR_INIT_VAR(transaction); object_init_ex(transaction, phalcon_mvc_model_transaction_ce); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_service"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 363, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5); + ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 356, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 364, this_ptr); + ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 357, this_ptr); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_transactions"), transaction TSRMLS_CC); RETURN_ON_FAILURE(zephir_property_incr(this_ptr, SL("_number") TSRMLS_CC)); @@ -112030,7 +112763,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Email, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 274); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_0); @@ -112045,7 +112778,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Email, validate) { ZEPHIR_INIT_VAR(_5); zephir_create_array(_5, 1, 0 TSRMLS_CC); zephir_array_update_string(&_5, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, _5); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, _5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Email", ZEPHIR_TEMP_PARAM_COPY); @@ -112173,7 +112906,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Exclusionin, validate) { ZEPHIR_INIT_NVAR(_0); zephir_fast_join_str(_0, SL(", "), domain TSRMLS_CC); zephir_array_update_string(&_4, SL(":domain"), &_0, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Exclusion", ZEPHIR_TEMP_PARAM_COPY); @@ -112303,7 +113036,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Inclusionin, validate) { zephir_check_temp_parameter(_0); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 365, value, domain, strict); + ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 358, value, domain, strict); zephir_check_call_status(); if (!(zephir_is_true(_5))) { ZEPHIR_INIT_NVAR(_0); @@ -112321,7 +113054,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Inclusionin, validate) { ZEPHIR_INIT_NVAR(_0); zephir_fast_join_str(_0, SL(", "), domain TSRMLS_CC); zephir_array_update_string(&_6, SL(":domain"), &_0, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 53, message, _6); + ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 54, message, _6); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Inclusion", ZEPHIR_TEMP_PARAM_COPY); @@ -112449,7 +113182,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Ip, validate) { zephir_array_update_string(&options, SL("flags"), &_6, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, 275); - ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 191, value, &_5, options); + ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 192, value, &_5, options); zephir_check_call_status(); if (!(zephir_is_true(_7))) { ZEPHIR_INIT_NVAR(_0); @@ -112463,7 +113196,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Ip, validate) { ZEPHIR_INIT_NVAR(_4); zephir_create_array(_4, 1, 0 TSRMLS_CC); zephir_array_update_string(&_4, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "IP", ZEPHIR_TEMP_PARAM_COPY); @@ -112570,7 +113303,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Numericality, validate) { ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 1, 0 TSRMLS_CC); zephir_array_update_string(&_3, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, _3); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Numericality", ZEPHIR_TEMP_PARAM_COPY); @@ -112673,7 +113406,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_PresenceOf, validate) { ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 1, 0 TSRMLS_CC); zephir_array_update_string(&_3, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, _3); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "PresenceOf", ZEPHIR_TEMP_PARAM_COPY); @@ -112805,7 +113538,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Regex, validate) { ZEPHIR_INIT_VAR(_6); zephir_create_array(_6, 1, 0 TSRMLS_CC); zephir_array_update_string(&_6, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 53, message, _6); + ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 54, message, _6); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_5); ZVAL_STRING(_5, "Regex", ZEPHIR_TEMP_PARAM_COPY); @@ -112919,7 +113652,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) { RETURN_MM_BOOL(1); } if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value); + ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 359, value); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(length); @@ -112945,7 +113678,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) { zephir_create_array(_4, 2, 0 TSRMLS_CC); zephir_array_update_string(&_4, SL(":field"), &field, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL(":max"), &maximum, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "TooLong", ZEPHIR_TEMP_PARAM_COPY); @@ -112975,7 +113708,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) { zephir_create_array(_4, 2, 0 TSRMLS_CC); zephir_array_update_string(&_4, SL(":field"), &field, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL(":min"), &minimum, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "TooShort", ZEPHIR_TEMP_PARAM_COPY); @@ -113256,7 +113989,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) { ZVAL_STRING(message, "Value of field: ':field' is already present in another record", 1); } } - ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_18); ZVAL_STRING(_18, "Unique", ZEPHIR_TEMP_PARAM_COPY); @@ -113352,7 +114085,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Url, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 273); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_0); @@ -113367,7 +114100,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Url, validate) { ZEPHIR_INIT_VAR(_5); zephir_create_array(_5, 1, 0 TSRMLS_CC); zephir_array_update_string(&_5, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, _5); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, _5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Url", ZEPHIR_TEMP_PARAM_COPY); @@ -113687,7 +114420,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Annotations, handle) { } zephir_update_property_this(this_ptr, SL("_processed"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 367, realUri); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 360, realUri); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -113902,7 +114635,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Annotations, processActionAnnotation) { zephir_check_temp_parameter(_3); zephir_check_call_status(); if (Z_TYPE_P(converts) == IS_ARRAY) { - zephir_is_iterable(converts, &_5, &_4, 0, 0, "phalcon/mvc/router/annotations.zep", 360); + zephir_is_iterable(converts, &_5, &_4, 0, 0, "phalcon/mvc/router/annotations.zep", 354); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -113919,7 +114652,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Annotations, processActionAnnotation) { zephir_check_temp_parameter(_3); zephir_check_call_status(); if (Z_TYPE_P(converts) == IS_ARRAY) { - zephir_is_iterable(converts, &_9, &_8, 0, 0, "phalcon/mvc/router/annotations.zep", 370); + zephir_is_iterable(converts, &_9, &_8, 0, 0, "phalcon/mvc/router/annotations.zep", 364); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) @@ -114519,7 +115252,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Group, _addRoute) { zephir_read_property_this(&defaultPaths, this_ptr, SL("_paths"), PH_NOISY_CC); if (Z_TYPE_P(defaultPaths) == IS_ARRAY) { if (Z_TYPE_P(paths) == IS_STRING) { - ZEPHIR_CALL_CE_STATIC(&processedPaths, phalcon_mvc_router_route_ce, "getroutepaths", &_0, 75, paths); + ZEPHIR_CALL_CE_STATIC(&processedPaths, phalcon_mvc_router_route_ce, "getroutepaths", &_0, 77, paths); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(processedPaths, paths); @@ -114538,10 +115271,10 @@ static PHP_METHOD(Phalcon_Mvc_Router_Group, _addRoute) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_prefix"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_2); ZEPHIR_CONCAT_VV(_2, _1, pattern); - ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 74, _2, mergedPaths, httpMethods); + ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 76, _2, mergedPaths, httpMethods); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_routes"), route TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 368, this_ptr); + ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 361, this_ptr); zephir_check_call_status(); RETURN_CCTOR(route); @@ -116050,7 +116783,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, _loadTemplateEngines) { if (Z_TYPE_P(registeredEngines) != IS_ARRAY) { ZEPHIR_INIT_VAR(_0); object_init_ex(_0, phalcon_mvc_view_engine_php_ce); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 370, this_ptr, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 363, this_ptr, dependencyInjector); zephir_check_call_status(); zephir_array_update_string(&engines, SL(".phtml"), &_0, PH_COPY | PH_SEPARATE); } else { @@ -116289,7 +117022,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, render) { ZEPHIR_INIT_VAR(_1); zephir_create_symbol_table(TSRMLS_C); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_OBS_VAR(viewParams); zephir_read_property_this(&viewParams, this_ptr, SL("_viewParams"), PH_NOISY_CC); @@ -116303,7 +117036,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, render) { } else { ZEPHIR_CPY_WRT(mergedParams, viewParams); } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 389, path, mergedParams); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 382, path, mergedParams); zephir_check_call_status(); if (Z_TYPE_P(cache) == IS_OBJECT) { ZEPHIR_CALL_METHOD(&_0, cache, "isstarted", NULL, 0); @@ -116323,7 +117056,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, render) { zephir_check_call_status(); } } - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); RETURN_MM_MEMBER(this_ptr, "_content"); @@ -116354,7 +117087,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, partial) { } - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); if (Z_TYPE_P(params) == IS_ARRAY) { ZEPHIR_OBS_VAR(viewParams); @@ -116371,12 +117104,12 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, partial) { } else { ZEPHIR_CPY_WRT(mergedParams, params); } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 389, partialPath, mergedParams); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 382, partialPath, mergedParams); zephir_check_call_status(); if (Z_TYPE_P(params) == IS_ARRAY) { zephir_update_property_this(this_ptr, SL("_viewParams"), viewParams TSRMLS_CC); } - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_content"), PH_NOISY_CC); zend_print_zval(_1, 0); @@ -116755,7 +117488,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Php, render) { if (mustClean == 1) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371); + ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 364); zephir_check_call_status(); } if (Z_TYPE_P(params) == IS_ARRAY) { @@ -116777,7 +117510,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Php, render) { } if (mustClean == 1) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 117); + ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 119); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _4, "setcontent", NULL, 0, _5); zephir_check_call_status(); @@ -116850,18 +117583,18 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, getCompiler) { ZEPHIR_INIT_NVAR(compiler); object_init_ex(compiler, phalcon_mvc_view_engine_volt_compiler_ce); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 372, _0); + ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 365, _0); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _1); if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) { - ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 373, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 366, dependencyInjector); zephir_check_call_status(); } ZEPHIR_OBS_VAR(options); zephir_read_property_this(&options, this_ptr, SL("_options"), PH_NOISY_CC); if (Z_TYPE_P(options) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 374, options); + ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 367, options); zephir_check_call_status(); } zephir_update_property_this(this_ptr, SL("_compiler"), compiler TSRMLS_CC); @@ -116901,7 +117634,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) { if (mustClean) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371); + ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 364); zephir_check_call_status(); } ZEPHIR_CALL_METHOD(&compiler, this_ptr, "getcompiler", NULL, 0); @@ -116929,7 +117662,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) { } if (mustClean) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 117); + ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 119); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _4, "setcontent", NULL, 0, _5); zephir_check_call_status(); @@ -116960,7 +117693,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, length) { ZVAL_LONG(length, zephir_fast_count_int(item TSRMLS_CC)); } else { if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, item); + ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 359, item); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(length); @@ -116986,7 +117719,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, isIncluded) { } if (Z_TYPE_P(haystack) == IS_STRING) { if ((zephir_function_exists_ex(SS("mb_strpos") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 375, haystack, needle); + ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 368, haystack, needle); zephir_check_call_status(); RETURN_MM_BOOL(!ZEPHIR_IS_FALSE_IDENTICAL(_0)); } @@ -117039,7 +117772,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) { _0 = ZEPHIR_IS_STRING(to, "utf8"); } if (_0) { - ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 376, text); + ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 369, text); zephir_check_call_status(); RETURN_MM(); } @@ -117048,17 +117781,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) { _1 = ZEPHIR_IS_STRING(from, "utf8"); } if (_1) { - ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 377, text); + ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 370, text); zephir_check_call_status(); RETURN_MM(); } if ((zephir_function_exists_ex(SS("mb_convert_encoding") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, text, from, to); + ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 181, text, from, to); zephir_check_call_status(); RETURN_MM(); } if ((zephir_function_exists_ex(SS("iconv") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 378, from, to, text); + ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 371, from, to, text); zephir_check_call_status(); RETURN_MM(); } @@ -117129,7 +117862,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) { if (Z_TYPE_P(value) == IS_ARRAY) { ZEPHIR_SINIT_VAR(_5); ZVAL_LONG(&_5, start); - ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 379, value, &_5, length); + ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 372, value, &_5, length); zephir_check_call_status(); RETURN_MM(); } @@ -117137,13 +117870,13 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) { if (Z_TYPE_P(length) != IS_NULL) { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, start); - ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5, length); + ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 373, value, &_5, length); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, start); - ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5); + ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 373, value, &_5); zephir_check_call_status(); RETURN_MM(); } @@ -117173,7 +117906,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, sort) { Z_SET_ISREF_P(value); - ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 381, value); + ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 374, value); Z_UNSET_ISREF_P(value); zephir_check_call_status(); RETURN_CTOR(value); @@ -117217,7 +117950,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, callMacro) { ZEPHIR_MM_RESTORE(); return; } - ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 382, macro, arguments); + ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 375, macro, arguments); zephir_check_call_status(); RETURN_MM(); @@ -117479,7 +118212,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, addExtension) { if (Z_TYPE_P(extension) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The extension is not valid", "phalcon/mvc/view/engine/volt/compiler.zep", 198); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "The extension is not valid", "phalcon/mvc/view/engine/volt/compiler.zep", 198); return; } if ((zephir_method_exists_ex(extension, SS("initialize") TSRMLS_CC) == SUCCESS)) { @@ -117619,7 +118352,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, getUniquePrefix) { } } if (Z_TYPE_P(prefix) != IS_STRING) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The unique compilation prefix is invalid", "phalcon/mvc/view/engine/volt/compiler.zep", 292); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "The unique compilation prefix is invalid", "phalcon/mvc/view/engine/volt/compiler.zep", 292); return; } RETURN_CCTOR(prefix); @@ -117680,7 +118413,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) { } } } else { - ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 383, left); + ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 376, left); zephir_check_call_status(); ZEPHIR_OBS_VAR(leftType); zephir_array_fetch_string(&leftType, left, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 339 TSRMLS_CC); @@ -117702,7 +118435,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) { zephir_array_fetch_string(&_7, right, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 352 TSRMLS_CC); zephir_concat_self(&exprCode, _7 TSRMLS_CC); } else { - ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 383, right); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 376, right); zephir_check_call_status(); zephir_concat_self(&exprCode, _1 TSRMLS_CC); } @@ -117712,10 +118445,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) { static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { - zend_bool _7; + zend_bool _6; zephir_fcall_cache_entry *_0 = NULL; int ZEPHIR_LAST_CALL_STATUS; - zval *expr_param = NULL, *code = NULL, *funcArguments = NULL, *arguments = NULL, *nameExpr, *nameType, *name, *extensions, *functions, *definition, *extendedBlocks, *block, *currentBlock, *exprLevel, *escapedCode = NULL, *method = NULL, *arrayHelpers = NULL, *className, *_2 = NULL, *_3, *_4, *_5 = NULL, *_6, *_8 = NULL; + zval *expr_param = NULL, *code = NULL, *funcArguments = NULL, *arguments = NULL, *nameExpr, *nameType, *name, *extensions, *functions, *definition, *extendedBlocks, *block, *currentBlock, *exprLevel, *escapedCode = NULL, *method = NULL, *arrayHelpers = NULL, *className, *_2 = NULL, *_3, *_4, *_5, *_7 = NULL; zval *expr = NULL, *_1 = NULL; ZEPHIR_MM_GROW(); @@ -117731,7 +118464,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { ZVAL_NULL(funcArguments); ZEPHIR_OBS_NVAR(funcArguments); if (zephir_array_isset_string_fetch(&funcArguments, expr, SS("arguments"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 383, funcArguments); + ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 376, funcArguments); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(arguments); @@ -117754,7 +118487,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { zephir_array_fast_append(_1, funcArguments); ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "compileFunction", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _2, _1); + ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 377, _2, _1); zephir_check_temp_parameter(_2); zephir_check_call_status(); if (Z_TYPE_P(code) == IS_STRING) { @@ -117782,7 +118515,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { } } ZEPHIR_INIT_NVAR(_2); - object_init_ex(_2, phalcon_mvc_view_exception_ce); + object_init_ex(_2, phalcon_mvc_view_engine_volt_exception_ce); zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 427 TSRMLS_CC); zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 427 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); @@ -117794,16 +118527,11 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { return; } } - _6 = zephir_fetch_nproperty_this(this_ptr, SL("_macros"), PH_NOISY_CC); - if (zephir_array_isset(_6, name)) { - ZEPHIR_CONCAT_SVSVS(return_value, "$this->callMacro('", name, "', array(", arguments, "))"); - RETURN_MM(); - } - _7 = ZEPHIR_IS_STRING(name, "get_content"); - if (!(_7)) { - _7 = ZEPHIR_IS_STRING(name, "content"); + _6 = ZEPHIR_IS_STRING(name, "get_content"); + if (!(_6)) { + _6 = ZEPHIR_IS_STRING(name, "content"); } - if (_7) { + if (_6) { RETURN_MM_STRING("$this->getContent()", 1); } if (ZEPHIR_IS_STRING(name, "partial")) { @@ -117821,7 +118549,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { ZEPHIR_OBS_VAR(exprLevel); zephir_read_property_this(&exprLevel, this_ptr, SL("_exprLevel"), PH_NOISY_CC); if (Z_TYPE_P(block) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 385, block); + ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 378, block); zephir_check_call_status(); if (ZEPHIR_IS_LONG(exprLevel, 1)) { ZEPHIR_CPY_WRT(escapedCode, code); @@ -117848,7 +118576,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { } ZEPHIR_INIT_NVAR(_2); zephir_camelize(_2, name); - ZEPHIR_CALL_FUNCTION(&method, "lcfirst", NULL, 65, _2); + ZEPHIR_CALL_FUNCTION(&method, "lcfirst", NULL, 67, _2); zephir_check_call_status(); ZEPHIR_INIT_VAR(className); ZVAL_STRING(className, "Phalcon\\Tag", 1); @@ -117914,21 +118642,12 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { ZEPHIR_CONCAT_SVS(return_value, "constant(", arguments, ")"); RETURN_MM(); } - ZEPHIR_INIT_NVAR(_2); - object_init_ex(_2, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC); - zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_5); - ZEPHIR_CONCAT_SVSVSV(_5, "Undefined function '", name, "' in ", _3, " on line ", _4); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _5); - zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC); - ZEPHIR_MM_RESTORE(); - return; + ZEPHIR_CONCAT_SVSVS(return_value, "$this->callMacro('", name, "', array(", arguments, "))"); + RETURN_MM(); } - ZEPHIR_CALL_METHOD(&_8, this_ptr, "expression", &_0, 383, nameExpr); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "expression", &_0, 376, nameExpr); zephir_check_call_status(); - ZEPHIR_CONCAT_VSVS(return_value, _8, "(", arguments, ")"); + ZEPHIR_CONCAT_VSVS(return_value, _7, "(", arguments, ")"); RETURN_MM(); } @@ -117950,10 +118669,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) { ZEPHIR_OBS_VAR(type); - zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 586 TSRMLS_CC); + zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 579 TSRMLS_CC); if (ZEPHIR_IS_LONG(type, 265)) { ZEPHIR_OBS_VAR(name); - zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 593 TSRMLS_CC); + zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 586 TSRMLS_CC); if (ZEPHIR_IS_STRING(name, "empty")) { ZEPHIR_CONCAT_SVS(return_value, "empty(", left, ")"); RETURN_MM(); @@ -117981,33 +118700,33 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) { } if (ZEPHIR_IS_LONG(type, 350)) { ZEPHIR_OBS_VAR(testName); - zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 644 TSRMLS_CC); + zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 637 TSRMLS_CC); ZEPHIR_OBS_NVAR(name); if (zephir_array_isset_string_fetch(&name, testName, SS("value"), 0 TSRMLS_CC)) { if (ZEPHIR_IS_STRING(name, "divisibleby")) { - zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 648 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1); + zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 641 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, _1); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "(((", left, ") % (", _0, ")) == 0)"); RETURN_MM(); } if (ZEPHIR_IS_STRING(name, "sameas")) { - zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 655 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1); + zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 648 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, _1); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "(", left, ") === (", _0, ")"); RETURN_MM(); } if (ZEPHIR_IS_STRING(name, "type")) { - zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 662 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1); + zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 655 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, _1); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "gettype(", left, ") === (", _0, ")"); RETURN_MM(); } } } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, test); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, test); zephir_check_call_status(); ZEPHIR_CONCAT_VSV(return_value, left, " == ", _0); RETURN_MM(); @@ -118033,28 +118752,28 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { ZEPHIR_INIT_VAR(code); ZVAL_NULL(code); ZEPHIR_OBS_VAR(type); - zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 681 TSRMLS_CC); + zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 674 TSRMLS_CC); if (ZEPHIR_IS_LONG(type, 265)) { ZEPHIR_OBS_VAR(name); - zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 687 TSRMLS_CC); + zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 680 TSRMLS_CC); } else { if (!ZEPHIR_IS_LONG(type, 350)) { ZEPHIR_INIT_VAR(_0); - object_init_ex(_0, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC); - zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC); + object_init_ex(_0, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 688 TSRMLS_CC); + zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 688 TSRMLS_CC); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SVSV(_3, "Unknown filter type in ", _1, " on line ", _2); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 688 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_VAR(functionName); - zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 698 TSRMLS_CC); + zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 691 TSRMLS_CC); ZEPHIR_OBS_NVAR(name); - zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 699 TSRMLS_CC); + zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 692 TSRMLS_CC); } ZEPHIR_INIT_VAR(funcArguments); ZVAL_NULL(funcArguments); @@ -118064,9 +118783,9 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { if (zephir_array_isset_string_fetch(&funcArguments, filter, SS("arguments"), 0 TSRMLS_CC)) { if (!ZEPHIR_IS_STRING(name, "default")) { ZEPHIR_OBS_VAR(file); - zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC); + zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 707 TSRMLS_CC); ZEPHIR_OBS_VAR(line); - zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC); + zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 707 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); zephir_create_array(_4, 3, 0 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); @@ -118079,11 +118798,11 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { zephir_array_update_string(&_4, SL("file"), &file, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("line"), &line, PH_COPY | PH_SEPARATE); Z_SET_ISREF_P(funcArguments); - ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 386, funcArguments, _4); + ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 379, funcArguments, _4); Z_UNSET_ISREF_P(funcArguments); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 383, funcArguments); + ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 376, funcArguments); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(arguments, left); @@ -118098,7 +118817,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { zephir_array_fast_append(_4, funcArguments); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "compileFilter", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _0, _4); + ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 377, _0, _4); zephir_check_temp_parameter(_0); zephir_check_call_status(); if (Z_TYPE_P(code) == IS_STRING) { @@ -118126,14 +118845,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { } } ZEPHIR_INIT_NVAR(_0); - object_init_ex(_0, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC); - zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC); + object_init_ex(_0, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 770 TSRMLS_CC); + zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 770 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVSVSV(_3, "Invalid definition for user filter '", name, "' in ", _1, " on line ", _2); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 770 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -118255,14 +118974,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { RETURN_MM(); } ZEPHIR_INIT_NVAR(_0); - object_init_ex(_0, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC); - zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC); + object_init_ex(_0, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 959 TSRMLS_CC); + zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 959 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVSVSV(_3, "Unknown filter \"", name, "\" in ", _1, " on line ", _2); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 959 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -118296,7 +119015,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { zephir_array_fast_append(_0, expr); ZEPHIR_INIT_NVAR(_1); ZVAL_STRING(_1, "resolveExpression", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 384, _1, _0); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 377, _1, _0); zephir_check_temp_parameter(_1); zephir_check_call_status(); if (Z_TYPE_P(exprCode) == IS_STRING) { @@ -118307,22 +119026,22 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { if (!(zephir_array_isset_string_fetch(&type, expr, SS("type"), 0 TSRMLS_CC))) { ZEPHIR_INIT_NVAR(items); array_init(items); - zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1007); + zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1000); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) ) { ZEPHIR_GET_HVALUE(singleExpr, _5); - zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1000 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 383, _6); + zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 993 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 376, _6); zephir_check_call_status(); ZEPHIR_OBS_NVAR(name); if (zephir_array_isset_string_fetch(&name, singleExpr, SS("name"), 0 TSRMLS_CC)) { ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSV(_8, "'", name, "' => ", singleExprCode); - zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1002); + zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 995); } else { - zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1004); + zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 997); } } ZEPHIR_INIT_NVAR(exprCode); @@ -118336,24 +119055,24 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } ZEPHIR_OBS_NVAR(left); if (zephir_array_isset_string_fetch(&left, expr, SS("left"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 383, left); + ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 376, left); zephir_check_call_status(); } if (ZEPHIR_IS_LONG(type, 311)) { - zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1030 TSRMLS_CC); + zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1023 TSRMLS_CC); ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvetest", &_10, 0, _6, leftCode); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 124)) { - zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1038 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 387, _11, leftCode); + zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1031 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 380, _11, leftCode); zephir_check_call_status(); break; } ZEPHIR_OBS_NVAR(right); if (zephir_array_isset_string_fetch(&right, expr, SS("right"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 383, right); + ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 376, right); zephir_check_call_status(); } ZEPHIR_INIT_NVAR(exprCode); @@ -118425,17 +119144,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } if (ZEPHIR_IS_LONG(type, 258)) { ZEPHIR_OBS_NVAR(exprCode); - zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1105 TSRMLS_CC); + zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1098 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(type, 259)) { ZEPHIR_OBS_NVAR(exprCode); - zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1109 TSRMLS_CC); + zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1102 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(type, 260)) { ZEPHIR_INIT_NVAR(_1); - zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1113 TSRMLS_CC); + zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1106 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_13); ZVAL_STRING(&_13, "'", 0); ZEPHIR_SINIT_NVAR(_14); @@ -118461,7 +119180,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { break; } if (ZEPHIR_IS_LONG(type, 265)) { - zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1129 TSRMLS_CC); + zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1122 TSRMLS_CC); ZEPHIR_INIT_NVAR(exprCode); ZEPHIR_CONCAT_SV(exprCode, "$", _11); break; @@ -118529,7 +119248,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { if (ZEPHIR_IS_LONG(type, 365)) { ZEPHIR_OBS_NVAR(start); if (zephir_array_isset_string_fetch(&start, expr, SS("start"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 383, start); + ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 376, start); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(startCode); @@ -118537,7 +119256,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } ZEPHIR_OBS_NVAR(end); if (zephir_array_isset_string_fetch(&end, expr, SS("end"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 383, end); + ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 376, end); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(endCode); @@ -118628,8 +119347,8 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { break; } if (ZEPHIR_IS_LONG(type, 366)) { - zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1268 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 383, _6); + zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1261 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 376, _6); zephir_check_call_status(); ZEPHIR_INIT_NVAR(exprCode); ZEPHIR_CONCAT_SVSVSVS(exprCode, "(", _16, " ? ", leftCode, " : ", rightCode, ")"); @@ -118647,18 +119366,18 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } if (ZEPHIR_IS_LONG(type, 364)) { ZEPHIR_OBS_NVAR(exprCode); - zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1280 TSRMLS_CC); + zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1273 TSRMLS_CC); break; } ZEPHIR_INIT_NVAR(_1); - object_init_ex(_1, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC); - zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC); + object_init_ex(_1, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1277 TSRMLS_CC); + zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1277 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSVSV(_8, "Unknown expression ", type, " in ", _11, " on line ", _17); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_18, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1277 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -118689,7 +119408,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends } isStatementList = 1; if (!(zephir_array_isset_string(statements, SS("type")))) { - zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1324); + zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1317); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -118702,7 +119421,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends } } if (isStatementList == 1) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 388, statements); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 381, statements); zephir_check_call_status(); RETURN_MM(); } @@ -118734,7 +119453,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { if (!(zephir_array_isset_string(statement, SS("expr")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1352); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1345); return; } ZEPHIR_INIT_VAR(compilation); @@ -118749,15 +119468,15 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { ZEPHIR_INIT_VAR(prefixLevel); ZEPHIR_CONCAT_VV(prefixLevel, prefix, level); ZEPHIR_OBS_VAR(expr); - zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1370 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr); + zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1363 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 376, expr); zephir_check_call_status(); ZEPHIR_OBS_VAR(blockStatements); - zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1376 TSRMLS_CC); + zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1369 TSRMLS_CC); ZEPHIR_INIT_NVAR(forElse); ZVAL_BOOL(forElse, 0); if (Z_TYPE_P(blockStatements) == IS_ARRAY) { - zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1402); + zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1395); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -118780,7 +119499,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { } } } - ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 381, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_OBS_VAR(loopContext); zephir_read_property_this(&loopContext, this_ptr, SL("_loopPointers"), PH_NOISY_CC); @@ -118815,7 +119534,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { ZEPHIR_CPY_WRT(iterator, exprCode); } ZEPHIR_OBS_VAR(variable); - zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1431 TSRMLS_CC); + zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1424 TSRMLS_CC); ZEPHIR_OBS_VAR(key); if (zephir_array_isset_string_fetch(&key, statement, SS("key"), 0 TSRMLS_CC)) { ZEPHIR_INIT_LNVAR(_5); @@ -118828,7 +119547,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { } ZEPHIR_OBS_VAR(ifExpr); if (zephir_array_isset_string_fetch(&ifExpr, statement, SS("if_expr"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 383, ifExpr); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 376, ifExpr); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVS(_5, "if (", _12, ") { ?>"); @@ -118923,19 +119642,19 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileIf) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1522); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1515); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); - zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1528 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 388, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1521 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 381, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_INIT_VAR(compilation); ZEPHIR_CONCAT_SVSV(compilation, "", _1); ZEPHIR_OBS_VAR(blockStatements); if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("false_statements"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 381, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SV(_5, "", _4); @@ -118961,10 +119680,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileElseIf) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1557); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1550); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, ""); RETURN_MM(); @@ -118993,12 +119712,12 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1577); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1570); return; } - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 376, expr); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 383, expr); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 376, expr); zephir_check_call_status(); ZEPHIR_INIT_VAR(compilation); ZEPHIR_CONCAT_SVS(compilation, "di->get('viewCache'); "); @@ -119007,14 +119726,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) { ZEPHIR_INIT_VAR(_2); ZEPHIR_CONCAT_SVS(_2, "$_cacheKey[", exprCode, "]"); zephir_concat_self(&compilation, _2 TSRMLS_CC); - zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1587 TSRMLS_CC); + zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1580 TSRMLS_CC); if (ZEPHIR_IS_LONG(_3, 265)) { - zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1588 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1581 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", $", _4, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); } else { - zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1590 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1583 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", ", _4, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); @@ -119027,20 +119746,20 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) { ZEPHIR_INIT_LNVAR(_2); ZEPHIR_CONCAT_SVS(_2, "if ($_cacheKey[", exprCode, "] === null) { ?>"); zephir_concat_self(&compilation, _2 TSRMLS_CC); - zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1600 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 388, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1593 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 381, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_concat_self(&compilation, _6 TSRMLS_CC); ZEPHIR_OBS_NVAR(lifetime); if (zephir_array_isset_string_fetch(&lifetime, statement, SS("lifetime"), 0 TSRMLS_CC)) { - zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1606 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1599 TSRMLS_CC); if (ZEPHIR_IS_LONG(_4, 265)) { - zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1607 TSRMLS_CC); + zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1600 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, $", _7, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); } else { - zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1609 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1602 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, ", _4, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); @@ -119075,24 +119794,24 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileSet) { ZEPHIR_OBS_VAR(assignments); if (!(zephir_array_isset_string_fetch(&assignments, statement, SS("assignments"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1630); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1623); return; } ZEPHIR_INIT_VAR(compilation); ZVAL_STRING(compilation, ""); RETURN_MM(); @@ -119170,10 +119889,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileReturn) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1711); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1704); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, ""); RETURN_MM(); @@ -119197,14 +119916,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileAutoEscape) { ZEPHIR_OBS_VAR(autoescape); if (!(zephir_array_isset_string_fetch(&autoescape, statement, SS("enable"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1731); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1724); return; } ZEPHIR_OBS_VAR(oldAutoescape); zephir_read_property_this(&oldAutoescape, this_ptr, SL("_autoescape"), PH_NOISY_CC); zephir_update_property_this(this_ptr, SL("_autoescape"), autoescape TSRMLS_CC); - zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1740 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 388, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1733 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 381, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_autoescape"), oldAutoescape TSRMLS_CC); RETURN_CCTOR(compilation); @@ -119226,17 +119945,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileEcho) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1761); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1754); return; } - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); - zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1769 TSRMLS_CC); + zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1762 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 350)) { - zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1771 TSRMLS_CC); - zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1773 TSRMLS_CC); + zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1764 TSRMLS_CC); + zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1766 TSRMLS_CC); if (ZEPHIR_IS_LONG(_1, 265)) { - zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1778 TSRMLS_CC); + zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1771 TSRMLS_CC); if (ZEPHIR_IS_STRING(_2, "super")) { RETURN_CCTOR(exprCode); } @@ -119268,14 +119987,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) { ZEPHIR_OBS_VAR(pathExpr); if (!(zephir_array_isset_string_fetch(&pathExpr, statement, SS("path"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1806); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1799); return; } - zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1813 TSRMLS_CC); + zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1806 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 260)) { if (!(zephir_array_isset_string(statement, SS("params")))) { ZEPHIR_OBS_VAR(path); - zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1823 TSRMLS_CC); + zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1816 TSRMLS_CC); ZEPHIR_OBS_VAR(view); zephir_read_property_this(&view, this_ptr, SL("_view"), PH_NOISY_CC); if (Z_TYPE_P(view) == IS_OBJECT) { @@ -119303,14 +120022,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) { RETURN_CCTOR(compilation); } } - ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 383, pathExpr); + ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 376, pathExpr); zephir_check_call_status(); ZEPHIR_OBS_VAR(params); if (!(zephir_array_isset_string_fetch(¶ms, statement, SS("params"), 0 TSRMLS_CC))) { ZEPHIR_CONCAT_SVS(return_value, "partial(", path, "); ?>"); RETURN_MM(); } - ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 383, params); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 376, params); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "partial(", path, ", ", _1, "); ?>"); RETURN_MM(); @@ -119337,18 +120056,18 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { ZEPHIR_OBS_VAR(name); if (!(zephir_array_isset_string_fetch(&name, statement, SS("name"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1878); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1871); return; } _0 = zephir_fetch_nproperty_this(this_ptr, SL("_macros"), PH_NOISY_CC); if (zephir_array_isset(_0, name)) { ZEPHIR_INIT_VAR(_1); - object_init_ex(_1, phalcon_mvc_view_exception_ce); + object_init_ex(_1, phalcon_mvc_view_engine_volt_exception_ce); ZEPHIR_INIT_VAR(_2); ZEPHIR_CONCAT_SVS(_2, "Macro '", name, "' is already defined"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1885 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1878 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -119366,7 +120085,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { ZEPHIR_INIT_LNVAR(_2); ZEPHIR_CONCAT_VS(_2, macroName, " = function($__p = null) { "); zephir_concat_self(&code, _2 TSRMLS_CC); - zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1923); + zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1916); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -119374,7 +120093,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { ZEPHIR_GET_HMKEY(position, _4, _3); ZEPHIR_GET_HVALUE(parameter, _5); ZEPHIR_OBS_NVAR(variableName); - zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1907 TSRMLS_CC); + zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1900 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_6); ZEPHIR_CONCAT_SVS(_6, "if (isset($__p[", position, "])) { "); zephir_concat_self(&code, _6 TSRMLS_CC); @@ -119391,7 +120110,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { zephir_concat_self_str(&code, SL(" } else { ") TSRMLS_CC); ZEPHIR_OBS_NVAR(defaultValue); if (zephir_array_isset_string_fetch(&defaultValue, parameter, SS("default"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 383, defaultValue); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 376, defaultValue); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SVSVS(_12, "$", variableName, " = ", _10, ";"); @@ -119407,7 +120126,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { } ZEPHIR_OBS_VAR(blockStatements); if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("block_statements"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 381, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_2); ZEPHIR_CONCAT_VS(_2, _10, " + +#include +#include +#include + + + +ZEPHIR_INIT_CLASS(Phalcon_Mvc_View_Engine_Volt_Exception) { + + ZEPHIR_REGISTER_CLASS_EX(Phalcon\\Mvc\\View\\Engine\\Volt, Exception, phalcon, mvc_view_engine_volt_exception, phalcon_mvc_view_exception_ce, NULL, 0); + + return SUCCESS; + +} + + + /* Driver template for the LEMON parser generator. ** The author disclaims copyright to this source code. */ @@ -130015,7 +130756,7 @@ static PHP_METHOD(Phalcon_Paginator_Adapter_NativeArray, getPaginate) { number = zephir_fast_count_int(items TSRMLS_CC); ZEPHIR_SINIT_VAR(_2); ZVAL_LONG(&_2, show); - ZEPHIR_CALL_FUNCTION(&_3, "floatval", NULL, 311, &_2); + ZEPHIR_CALL_FUNCTION(&_3, "floatval", NULL, 304, &_2); zephir_check_call_status(); roundedTotal = zephir_safe_div_long_zval(number, _3 TSRMLS_CC); totalPages = (int) (roundedTotal); @@ -130026,7 +130767,7 @@ static PHP_METHOD(Phalcon_Paginator_Adapter_NativeArray, getPaginate) { ZVAL_LONG(&_2, (show * ((pageNumber - 1)))); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, show); - ZEPHIR_CALL_FUNCTION(&_5, "array_slice", NULL, 379, items, &_2, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "array_slice", NULL, 372, items, &_2, &_4); zephir_check_call_status(); ZEPHIR_CPY_WRT(items, _5); if (pageNumber < totalPages) { @@ -130336,7 +131077,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, connect) { ZEPHIR_INIT_VAR(_3); ZVAL_NULL(_3); Z_SET_ISREF_P(_2); - ZEPHIR_CALL_FUNCTION(&connection, "fsockopen", NULL, 390, _0, _1, _2, _3); + ZEPHIR_CALL_FUNCTION(&connection, "fsockopen", NULL, 383, _0, _1, _2, _3); Z_UNSET_ISREF_P(_2); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_RESOURCE) { @@ -130345,7 +131086,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, connect) { } ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, -1); - ZEPHIR_CALL_FUNCTION(NULL, "stream_set_timeout", NULL, 391, connection, &_4, ZEPHIR_GLOBAL(global_null)); + ZEPHIR_CALL_FUNCTION(NULL, "stream_set_timeout", NULL, 384, connection, &_4, ZEPHIR_GLOBAL(global_null)); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_connection"), connection TSRMLS_CC); RETURN_CCTOR(connection); @@ -130382,7 +131123,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, put) { ZEPHIR_INIT_NVAR(ttr); ZVAL_LONG(ttr, 86400); } - ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 71, data); + ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 73, data); zephir_check_call_status(); ZEPHIR_INIT_VAR(length); ZVAL_LONG(length, zephir_fast_strlen_ev(serialized)); @@ -130392,7 +131133,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, put) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", &_1, 0, serialized); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&status, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 128 TSRMLS_CC); _2 = !ZEPHIR_IS_STRING(status, "INSERTED"); @@ -130428,7 +131169,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, reserve) { } ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, command); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&_0, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 153 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_0, "RESERVED")) { @@ -130439,9 +131180,9 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, reserve) { zephir_array_fetch_long(&_3, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 163 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_2, this_ptr, "read", NULL, 0, _3); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "unserialize", NULL, 72, _2); + ZEPHIR_CALL_FUNCTION(&_4, "unserialize", NULL, 74, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 393, this_ptr, _1, _4); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 386, this_ptr, _1, _4); zephir_check_call_status(); RETURN_MM(); @@ -130473,7 +131214,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, choose) { ZEPHIR_CONCAT_SV(_0, "use ", tube); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 176 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "USING")) { @@ -130510,7 +131251,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, watch) { ZEPHIR_CONCAT_SV(_0, "watch ", tube); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 193 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "WATCHING")) { @@ -130533,7 +131274,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, stats) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_temp_parameter(_0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 394); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 387); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 210 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "OK")) { @@ -130570,7 +131311,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, statsTube) { ZEPHIR_CONCAT_SV(_0, "stats-tube ", tube); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 394); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 387); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 227 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "OK")) { @@ -130581,6 +131322,29 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, statsTube) { } +static PHP_METHOD(Phalcon_Queue_Beanstalk, listTubes) { + + int ZEPHIR_LAST_CALL_STATUS; + zval *response = NULL, *_0, *_1, *_2; + + ZEPHIR_MM_GROW(); + + ZEPHIR_INIT_VAR(_0); + ZVAL_STRING(_0, "list-tubes", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); + zephir_check_temp_parameter(_0); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 387); + zephir_check_call_status(); + zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 244 TSRMLS_CC); + if (!ZEPHIR_IS_STRING(_1, "OK")) { + RETURN_MM_BOOL(0); + } + zephir_array_fetch_long(&_2, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 248 TSRMLS_CC); + RETURN_CTOR(_2); + +} + static PHP_METHOD(Phalcon_Queue_Beanstalk, peekReady) { int ZEPHIR_LAST_CALL_STATUS; @@ -130593,20 +131357,20 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, peekReady) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_temp_parameter(_0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); - zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 244 TSRMLS_CC); + zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 261 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "FOUND")) { RETURN_MM_BOOL(0); } object_init_ex(return_value, phalcon_queue_beanstalk_job_ce); - zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 248 TSRMLS_CC); - zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 248 TSRMLS_CC); + zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); + zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, this_ptr, "read", NULL, 0, _4); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 72, _3); + ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 74, _3); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 393, this_ptr, _2, _5); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 386, this_ptr, _2, _5); zephir_check_call_status(); RETURN_MM(); @@ -130624,20 +131388,20 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, peekBuried) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_temp_parameter(_0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); - zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 261 TSRMLS_CC); + zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 278 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "FOUND")) { RETURN_MM_BOOL(0); } object_init_ex(return_value, phalcon_queue_beanstalk_job_ce); - zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); - zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); + zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 282 TSRMLS_CC); + zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 282 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, this_ptr, "read", NULL, 0, _4); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 72, _3); + ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 74, _3); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 393, this_ptr, _2, _5); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 386, this_ptr, _2, _5); zephir_check_call_status(); RETURN_MM(); @@ -130668,13 +131432,13 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, readYaml) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); ZEPHIR_OBS_VAR(status); - zephir_array_fetch_long(&status, response, 0, PH_NOISY, "phalcon/queue/beanstalk.zep", 290 TSRMLS_CC); + zephir_array_fetch_long(&status, response, 0, PH_NOISY, "phalcon/queue/beanstalk.zep", 307 TSRMLS_CC); if (zephir_fast_count_int(response TSRMLS_CC) > 1) { ZEPHIR_OBS_VAR(numberOfBytes); - zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 293 TSRMLS_CC); + zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 310 TSRMLS_CC); ZEPHIR_CALL_METHOD(&response, this_ptr, "read", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_FUNCTION(&data, "yaml_parse", NULL, 0, response); @@ -130723,13 +131487,13 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, read) { } ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, (length + 2)); - ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 395, connection, &_0); + ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 388, connection, &_0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 396, connection); + ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 389, connection); zephir_check_call_status(); - zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 337 TSRMLS_CC); + zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 354 TSRMLS_CC); if (zephir_is_true(_2)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 338); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 355); return; } ZEPHIR_SINIT_NVAR(_0); @@ -130741,7 +131505,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, read) { ZVAL_LONG(&_0, 16384); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "\r\n", 0); - ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 397, connection, &_0, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 390, connection, &_0, &_3); zephir_check_call_status(); RETURN_MM(); @@ -130773,7 +131537,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, write) { ZEPHIR_CPY_WRT(packet, _0); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, zephir_fast_strlen_ev(packet)); - ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 398, connection, packet, &_1); + ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 391, connection, packet, &_1); zephir_check_call_status(); RETURN_MM(); @@ -131065,6 +131829,315 @@ ZEPHIR_INIT_CLASS(Phalcon_Security_Exception) { +#ifdef HAVE_CONFIG_H +#endif + +#include + +#include +#include +#include + + + +ZEPHIR_INIT_CLASS(Phalcon_Security_Random) { + + ZEPHIR_REGISTER_CLASS(Phalcon\\Security, Random, phalcon, security_random, phalcon_security_random_method_entry, 0); + + return SUCCESS; + +} + +static PHP_METHOD(Phalcon_Security_Random, bytes) { + + zval *len_param = NULL, *handle = NULL, *ret = NULL, *_0 = NULL, _1, _2 = zval_used_for_init, _3; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &len_param); + + if (!len_param) { + len = 16; + } else { + len = zephir_get_intval(len_param); + } + + + if (len <= 0) { + len = 16; + } + if ((zephir_function_exists_ex(SS("\\sodium\\randombytes_buf") TSRMLS_CC) == SUCCESS)) { + ZEPHIR_INIT_VAR(_0); + ZVAL_LONG(_0, len); + ZEPHIR_RETURN_CALL_FUNCTION("\\sodium\\randombytes_buf", NULL, 0, _0); + zephir_check_call_status(); + RETURN_MM(); + } + if ((zephir_function_exists_ex(SS("openssl_random_pseudo_bytes") TSRMLS_CC) == SUCCESS)) { + ZEPHIR_INIT_NVAR(_0); + ZVAL_LONG(_0, len); + ZEPHIR_RETURN_CALL_FUNCTION("openssl_random_pseudo_bytes", NULL, 400, _0); + zephir_check_call_status(); + RETURN_MM(); + } + ZEPHIR_SINIT_VAR(_1); + ZVAL_STRING(&_1, "/dev/urandom", 0); + if ((zephir_file_exists(&_1 TSRMLS_CC) == SUCCESS)) { + ZEPHIR_SINIT_VAR(_2); + ZVAL_STRING(&_2, "/dev/urandom", 0); + ZEPHIR_SINIT_VAR(_3); + ZVAL_STRING(&_3, "rb", 0); + ZEPHIR_CALL_FUNCTION(&handle, "fopen", NULL, 285, &_2, &_3); + zephir_check_call_status(); + if (!ZEPHIR_IS_FALSE_IDENTICAL(handle)) { + ZEPHIR_SINIT_NVAR(_2); + ZVAL_LONG(&_2, 0); + ZEPHIR_CALL_FUNCTION(NULL, "stream_set_read_buffer", NULL, 403, handle, &_2); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_2); + ZVAL_LONG(&_2, len); + ZEPHIR_CALL_FUNCTION(&ret, "fread", NULL, 388, handle, &_2); + zephir_check_call_status(); + zephir_fclose(handle TSRMLS_CC); + if (zephir_fast_strlen_ev(ret) != len) { + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_security_exception_ce, "Unexpected partial read from random device", "phalcon/security/random.zep", 117); + return; + } + RETURN_CCTOR(ret); + } + } + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_security_exception_ce, "No random device", "phalcon/security/random.zep", 124); + return; + +} + +static PHP_METHOD(Phalcon_Security_Random, hex) { + + zval *len_param = NULL, *_0 = NULL, *_1, _2, *_3 = NULL; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &len_param); + + if (!len_param) { + len = 0; + } else { + len = zephir_get_intval(len_param); + } + + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, len); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "bytes", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_SINIT_VAR(_2); + ZVAL_STRING(&_2, "H*", 0); + ZEPHIR_CALL_FUNCTION(&_3, "unpack", NULL, 404, &_2, _0); + zephir_check_call_status(); + Z_SET_ISREF_P(_3); + ZEPHIR_RETURN_CALL_FUNCTION("array_shift", NULL, 121, _3); + Z_UNSET_ISREF_P(_3); + zephir_check_call_status(); + RETURN_MM(); + +} + +static PHP_METHOD(Phalcon_Security_Random, base64) { + + zval *len_param = NULL, *_0 = NULL, *_1; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &len_param); + + if (!len_param) { + len = 0; + } else { + len = zephir_get_intval(len_param); + } + + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, len); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "bytes", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", NULL, 114, _0); + zephir_check_call_status(); + RETURN_MM(); + +} + +static PHP_METHOD(Phalcon_Security_Random, base64Safe) { + + zend_bool padding; + zval *len_param = NULL, *padding_param = NULL, *s = NULL, *_0 = NULL, *_1 = NULL, *_2, _3; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 2, &len_param, &padding_param); + + if (!len_param) { + len = 0; + } else { + len = zephir_get_intval(len_param); + } + if (!padding_param) { + padding = 0; + } else { + padding = zephir_get_boolval(padding_param); + } + + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, len); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "base64", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_INIT_NVAR(_1); + ZVAL_STRING(_1, "#[^a-z0-9_=-]+#i", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_INIT_VAR(_2); + ZVAL_STRING(_2, "", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_FUNCTION(&s, "preg_replace", NULL, 29, _1, _2, _0); + zephir_check_temp_parameter(_1); + zephir_check_temp_parameter(_2); + zephir_check_call_status(); + if (!(padding)) { + ZEPHIR_SINIT_VAR(_3); + ZVAL_STRING(&_3, "=", 0); + zephir_fast_trim(return_value, s, &_3, ZEPHIR_TRIM_BOTH TSRMLS_CC); + RETURN_MM(); + } + RETURN_CCTOR(s); + +} + +static PHP_METHOD(Phalcon_Security_Random, uuid) { + + int ZEPHIR_LAST_CALL_STATUS; + zval *ary = NULL, *_0 = NULL, *_1 = NULL, _2 = zval_used_for_init, *_3 = NULL, *_4, *_5, *_6, *_7; + + ZEPHIR_MM_GROW(); + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, 16); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "bytes", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_SINIT_VAR(_2); + ZVAL_STRING(&_2, "N1a/n1b/n1c/n1d/n1e/N1f", 0); + ZEPHIR_CALL_FUNCTION(&_3, "unpack", NULL, 404, &_2, _0); + zephir_check_call_status(); + ZEPHIR_CALL_FUNCTION(&ary, "array_values", NULL, 215, _3); + zephir_check_call_status(); + zephir_array_fetch_long(&_4, ary, 2, PH_NOISY | PH_READONLY, "phalcon/security/random.zep", 222 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_1); + ZVAL_LONG(_1, ((((int) (zephir_get_numberval(_4)) & 0x0fff)) | 0x4000)); + zephir_array_update_long(&ary, 2, &_1, PH_COPY | PH_SEPARATE, "phalcon/security/random.zep", 222); + zephir_array_fetch_long(&_5, ary, 3, PH_NOISY | PH_READONLY, "phalcon/security/random.zep", 223 TSRMLS_CC); + ZEPHIR_INIT_VAR(_6); + ZVAL_LONG(_6, ((((int) (zephir_get_numberval(_5)) & 0x3fff)) | 0x8000)); + zephir_array_update_long(&ary, 3, &_6, PH_COPY | PH_SEPARATE, "phalcon/security/random.zep", 223); + ZEPHIR_INIT_VAR(_7); + ZVAL_STRING(_7, "%08x-%04x-%04x-%04x-%04x%08x", ZEPHIR_TEMP_PARAM_COPY); + Z_SET_ISREF_P(ary); + ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 379, ary, _7); + zephir_check_temp_parameter(_7); + Z_UNSET_ISREF_P(ary); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_2); + ZVAL_STRING(&_2, "sprintf", 0); + ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, &_2, ary); + zephir_check_call_status(); + RETURN_MM(); + +} + +static PHP_METHOD(Phalcon_Security_Random, number) { + + zephir_fcall_cache_entry *_4 = NULL, *_9 = NULL, *_14 = NULL, *_18 = NULL; + zval *len_param = NULL, *hex = NULL, *bin = NULL, *mask = NULL, *rnd = NULL, *ret = NULL, *first = NULL, _0 = zval_used_for_init, *_1, _2, *_3, *_8 = NULL, _10 = zval_used_for_init, _11 = zval_used_for_init, _12 = zval_used_for_init, *_13 = NULL, _15 = zval_used_for_init, _16 = zval_used_for_init, *_17 = NULL; + int len, ZEPHIR_LAST_CALL_STATUS, _5, _6, _7; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &len_param); + + len = zephir_get_intval(len_param); + + + if (len > 0) { + ZEPHIR_SINIT_VAR(_0); + ZVAL_LONG(&_0, len); + ZEPHIR_CALL_FUNCTION(&hex, "dechex", NULL, 405, &_0); + zephir_check_call_status(); + if (((zephir_fast_strlen_ev(hex) & 1)) == 1) { + ZEPHIR_INIT_VAR(_1); + ZEPHIR_CONCAT_SV(_1, "0", hex); + ZEPHIR_CPY_WRT(hex, _1); + } + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "H*", 0); + ZEPHIR_CALL_FUNCTION(&bin, "pack", NULL, 406, &_0, hex); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_LONG(&_0, 0); + ZEPHIR_SINIT_VAR(_2); + ZVAL_LONG(&_2, 1); + ZEPHIR_INIT_VAR(_3); + zephir_substr(_3, bin, 0 , 1 , 0); + ZEPHIR_CALL_FUNCTION(&mask, "ord", &_4, 132, _3); + zephir_check_call_status(); + _5 = ((int) (zephir_get_numberval(mask)) | (((int) (zephir_get_numberval(mask)) >> 1))); + ZEPHIR_INIT_NVAR(mask); + ZVAL_LONG(mask, _5); + _6 = ((int) (zephir_get_numberval(mask)) | (((int) (zephir_get_numberval(mask)) >> 2))); + ZEPHIR_INIT_NVAR(mask); + ZVAL_LONG(mask, _6); + _7 = ((int) (zephir_get_numberval(mask)) | (((int) (zephir_get_numberval(mask)) >> 4))); + ZEPHIR_INIT_NVAR(mask); + ZVAL_LONG(mask, _7); + do { + ZEPHIR_INIT_NVAR(_8); + ZVAL_LONG(_8, zephir_fast_strlen_ev(bin)); + ZEPHIR_CALL_METHOD(&rnd, this_ptr, "bytes", &_9, 0, _8); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_10); + ZVAL_LONG(&_10, 0); + ZEPHIR_SINIT_NVAR(_11); + ZVAL_LONG(&_11, 1); + ZEPHIR_INIT_NVAR(_8); + zephir_substr(_8, rnd, 0 , 1 , 0); + ZEPHIR_CALL_FUNCTION(&first, "ord", &_4, 132, _8); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_12); + zephir_bitwise_and_function(&_12, first, mask TSRMLS_CC); + ZEPHIR_CALL_FUNCTION(&_13, "chr", &_14, 130, &_12); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_15); + ZVAL_LONG(&_15, 0); + ZEPHIR_SINIT_NVAR(_16); + ZVAL_LONG(&_16, 1); + ZEPHIR_CALL_FUNCTION(&_17, "substr_replace", &_18, 407, rnd, _13, &_15, &_16); + zephir_check_call_status(); + ZEPHIR_CPY_WRT(rnd, _17); + } while (ZEPHIR_LT(bin, rnd)); + ZEPHIR_SINIT_NVAR(_10); + ZVAL_STRING(&_10, "H*", 0); + ZEPHIR_CALL_FUNCTION(&ret, "unpack", NULL, 404, &_10, rnd); + zephir_check_call_status(); + Z_SET_ISREF_P(ret); + ZEPHIR_CALL_FUNCTION(&_13, "array_shift", NULL, 121, ret); + Z_UNSET_ISREF_P(ret); + zephir_check_call_status(); + ZEPHIR_RETURN_CALL_FUNCTION("hexdec", NULL, 408, _13); + zephir_check_call_status(); + RETURN_MM(); + } + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_security_exception_ce, "Require a positive integer > 0", "phalcon/security/random.zep", 269); + return; + +} + + + + #ifdef HAVE_CONFIG_H #endif @@ -131125,7 +132198,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, start) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 54); + ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 55); zephir_check_call_status(); if (!(zephir_is_true(_0))) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_started"), PH_NOISY_CC); @@ -131136,7 +132209,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, start) { _2 = !ZEPHIR_IS_LONG_IDENTICAL(_3, 2); } if (_2) { - ZEPHIR_CALL_FUNCTION(NULL, "session_start", NULL, 55); + ZEPHIR_CALL_FUNCTION(NULL, "session_start", NULL, 56); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_started"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); RETURN_MM_BOOL(1); @@ -131183,7 +132256,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, setName) { zephir_get_strval(name, name_param); - ZEPHIR_CALL_FUNCTION(NULL, "session_name", NULL, 56, name); + ZEPHIR_CALL_FUNCTION(NULL, "session_name", NULL, 57, name); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -131195,16 +132268,38 @@ static PHP_METHOD(Phalcon_Session_Adapter, getName) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("session_name", NULL, 56); + ZEPHIR_RETURN_CALL_FUNCTION("session_name", NULL, 57); zephir_check_call_status(); RETURN_MM(); } +static PHP_METHOD(Phalcon_Session_Adapter, regenerateId) { + + int ZEPHIR_LAST_CALL_STATUS; + zval *deleteOldSession_param = NULL; + zend_bool deleteOldSession; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &deleteOldSession_param); + + if (!deleteOldSession_param) { + deleteOldSession = 1; + } else { + deleteOldSession = zephir_get_boolval(deleteOldSession_param); + } + + + ZEPHIR_CALL_FUNCTION(NULL, "session_regenerate_id", NULL, 58, (deleteOldSession ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_check_call_status(); + RETURN_THIS(); + +} + static PHP_METHOD(Phalcon_Session_Adapter, get) { zend_bool remove; - zval *index_param = NULL, *defaultValue = NULL, *remove_param = NULL, *value, *key, *_0, *_SESSION; + zval *index_param = NULL, *defaultValue = NULL, *remove_param = NULL, *value, *key = NULL, *uniqueId, *_SESSION; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -131222,9 +132317,13 @@ static PHP_METHOD(Phalcon_Session_Adapter, get) { } - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(key); - ZEPHIR_CONCAT_VV(key, _0, index); + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(key); + ZEPHIR_CONCAT_VSV(key, uniqueId, "#", index); + } else { + ZEPHIR_CPY_WRT(key, index); + } ZEPHIR_OBS_VAR(value); if (zephir_array_isset_fetch(&value, _SESSION, key, 0 TSRMLS_CC)) { if (remove) { @@ -131239,8 +132338,8 @@ static PHP_METHOD(Phalcon_Session_Adapter, get) { static PHP_METHOD(Phalcon_Session_Adapter, set) { - int _2; - zval *index_param = NULL, *value, *_SESSION, *_0, *_1; + int _1; + zval *index_param = NULL, *value, *uniqueId, *_SESSION, *_0; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -131250,12 +132349,20 @@ static PHP_METHOD(Phalcon_Session_Adapter, set) { zephir_get_strval(index, index_param); - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_1); - ZEPHIR_CONCAT_VV(_1, _0, index); - _2 = zephir_maybe_separate_zval(&_SESSION); - zephir_array_update_zval(&_SESSION, _1, &value, PH_COPY | PH_SEPARATE); - if (_2) { + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + ZEPHIR_CONCAT_VSV(_0, uniqueId, "#", index); + _1 = zephir_maybe_separate_zval(&_SESSION); + zephir_array_update_zval(&_SESSION, _0, &value, PH_COPY | PH_SEPARATE); + if (_1) { + ZEND_SET_SYMBOL(&EG(symbol_table), "_SESSION", _SESSION); + } + RETURN_MM_NULL(); + } + _1 = zephir_maybe_separate_zval(&_SESSION); + zephir_array_update_zval(&_SESSION, index, &value, PH_COPY | PH_SEPARATE); + if (_1) { ZEND_SET_SYMBOL(&EG(symbol_table), "_SESSION", _SESSION); } ZEPHIR_MM_RESTORE(); @@ -131264,7 +132371,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, set) { static PHP_METHOD(Phalcon_Session_Adapter, has) { - zval *index_param = NULL, *_SESSION, *_0, *_1; + zval *index_param = NULL, *uniqueId, *_SESSION, *_0; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -131274,16 +132381,19 @@ static PHP_METHOD(Phalcon_Session_Adapter, has) { zephir_get_strval(index, index_param); - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_1); - ZEPHIR_CONCAT_VV(_1, _0, index); - RETURN_MM_BOOL(zephir_array_isset(_SESSION, _1)); + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + ZEPHIR_CONCAT_VSV(_0, uniqueId, "#", index); + RETURN_MM_BOOL(zephir_array_isset(_SESSION, _0)); + } + RETURN_MM_BOOL(zephir_array_isset(_SESSION, index)); } static PHP_METHOD(Phalcon_Session_Adapter, remove) { - zval *index_param = NULL, *_0, *_1, *_SESSION; + zval *index_param = NULL, *uniqueId, *_0, *_SESSION; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -131293,10 +132403,14 @@ static PHP_METHOD(Phalcon_Session_Adapter, remove) { zephir_get_strval(index, index_param); - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_1); - ZEPHIR_CONCAT_VV(_1, _0, index); - zephir_array_unset(&_SESSION, _1, PH_SEPARATE); + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + ZEPHIR_CONCAT_VSV(_0, uniqueId, "#", index); + zephir_array_unset(&_SESSION, _0, PH_SEPARATE); + RETURN_MM_NULL(); + } + zephir_array_unset(&_SESSION, index, PH_SEPARATE); ZEPHIR_MM_RESTORE(); } @@ -131307,7 +132421,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, getId) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("session_id", NULL, 57); + ZEPHIR_RETURN_CALL_FUNCTION("session_id", NULL, 59); zephir_check_call_status(); RETURN_MM(); @@ -131325,7 +132439,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, setId) { zephir_get_strval(id, id_param); - ZEPHIR_CALL_FUNCTION(NULL, "session_id", NULL, 57, id); + ZEPHIR_CALL_FUNCTION(NULL, "session_id", NULL, 59, id); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -131341,11 +132455,47 @@ static PHP_METHOD(Phalcon_Session_Adapter, isStarted) { static PHP_METHOD(Phalcon_Session_Adapter, destroy) { int ZEPHIR_LAST_CALL_STATUS; + HashTable *_2; + HashPosition _1; + zval *removeData_param = NULL, *uniqueId, *key = NULL, *_SESSION = NULL, *_0 = NULL, **_3, *_4 = NULL; + zend_bool removeData; ZEPHIR_MM_GROW(); + zephir_get_global(&_SESSION, SS("_SESSION") TSRMLS_CC); + zephir_fetch_params(1, 0, 1, &removeData_param); + if (!removeData_param) { + removeData = 0; + } else { + removeData = zephir_get_boolval(removeData_param); + } + + + if (removeData) { + ZEPHIR_OBS_VAR(uniqueId); + zephir_read_property_this(&uniqueId, this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + zephir_is_iterable(_SESSION, &_2, &_1, 1, 0, "phalcon/session/adapter.zep", 265); + for ( + ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS + ; zephir_hash_move_forward_ex(_2, &_1) + ) { + ZEPHIR_GET_HMKEY(key, _2, _1); + ZEPHIR_GET_HVALUE(_0, _3); + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_VS(_4, uniqueId, "#"); + if (zephir_start_with(key, _4, NULL)) { + zephir_array_unset(&_SESSION, key, PH_SEPARATE); + } + } + } else { + ZEPHIR_INIT_NVAR(_SESSION); + array_init(_SESSION); + } + } zephir_update_property_this(this_ptr, SL("_started"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); - ZEPHIR_RETURN_CALL_FUNCTION("session_destroy", NULL, 58); + ZEPHIR_RETURN_CALL_FUNCTION("session_destroy", NULL, 60); zephir_check_call_status(); RETURN_MM(); @@ -131359,7 +132509,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, status) { ZEPHIR_MM_GROW(); if (!(zephir_is_php_version(50300))) { - ZEPHIR_CALL_FUNCTION(&status, "session_status", NULL, 59); + ZEPHIR_CALL_FUNCTION(&status, "session_status", NULL, 61); zephir_check_call_status(); do { if (ZEPHIR_IS_LONG(status, 0)) { @@ -131487,6 +132637,8 @@ ZEPHIR_DOC_METHOD(Phalcon_Session_AdapterInterface, isStarted); ZEPHIR_DOC_METHOD(Phalcon_Session_AdapterInterface, destroy); +ZEPHIR_DOC_METHOD(Phalcon_Session_AdapterInterface, regenerateId); + @@ -131613,7 +132765,7 @@ static PHP_METHOD(Phalcon_Session_Bag, initialize) { static PHP_METHOD(Phalcon_Session_Bag, destroy) { int ZEPHIR_LAST_CALL_STATUS; - zval *_0, *_1, *_2; + zval *_0, *_1, *_2, *_3; ZEPHIR_MM_GROW(); @@ -131622,9 +132774,12 @@ static PHP_METHOD(Phalcon_Session_Bag, destroy) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "initialize", NULL, 0); zephir_check_call_status(); } - _1 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _1, "remove", NULL, 0, _2); + ZEPHIR_INIT_VAR(_1); + array_init(_1); + zephir_update_property_this(this_ptr, SL("_data"), _1 TSRMLS_CC); + _2 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); + _3 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(NULL, _2, "remove", NULL, 0, _3); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -131825,7 +132980,7 @@ static PHP_METHOD(Phalcon_Session_Bag, __isset) { static PHP_METHOD(Phalcon_Session_Bag, remove) { int ZEPHIR_LAST_CALL_STATUS; - zval *property_param = NULL, *_0, *_1, *_2, *_3, *_4; + zval *property_param = NULL, *data, *_0, *_1; zval *property = NULL; ZEPHIR_MM_GROW(); @@ -131844,15 +132999,15 @@ static PHP_METHOD(Phalcon_Session_Bag, remove) { } - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - if (zephir_array_isset(_0, property)) { - _1 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - zephir_array_unset(&_1, property, PH_SEPARATE); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); - _3 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _2, "set", NULL, 0, _3, _4); + ZEPHIR_OBS_VAR(data); + zephir_read_property_this(&data, this_ptr, SL("_data"), PH_NOISY_CC); + if (zephir_array_isset(data, property)) { + zephir_array_unset(&data, property, PH_SEPARATE); + _0 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(NULL, _0, "set", NULL, 0, _1, data); zephir_check_call_status(); + zephir_update_property_this(this_ptr, SL("_data"), data TSRMLS_CC); RETURN_MM_BOOL(1); } RETURN_MM_BOOL(0); @@ -131918,7 +133073,7 @@ static PHP_METHOD(Phalcon_Session_Bag, getIterator) { } object_init_ex(return_value, zephir_get_internal_ce(SS("arrayiterator") TSRMLS_CC)); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 412, _1); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 411, _1); zephir_check_call_status(); RETURN_MM(); @@ -132206,7 +133361,7 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); ZEPHIR_INIT_VAR(_4); zephir_create_array(_4, 4, 0 TSRMLS_CC); @@ -132214,7 +133369,7 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) { zephir_array_update_string(&_4, SL("client"), &client, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("prefix"), &prefix, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("statsKey"), &statsKey, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, _4); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 312, _1, _4); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_libmemcached"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); @@ -132253,9 +133408,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) { ZEPHIR_INIT_NVAR(_6); ZVAL_STRING(_6, "gc", 1); zephir_array_fast_append(_11, _6); - ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _5, _7, _8, _9, _10, _11); + ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 409, _5, _7, _8, _9, _10, _11); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 411, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 410, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -132431,9 +133586,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 314, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -132472,9 +133627,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) { ZEPHIR_INIT_NVAR(_5); ZVAL_STRING(_5, "gc", 1); zephir_array_fast_append(_10, _5); - ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10); + ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 409, _4, _6, _7, _8, _9, _10); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 411, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 410, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -132648,9 +133803,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 315, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -132689,9 +133844,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct) { ZEPHIR_INIT_NVAR(_5); ZVAL_STRING(_5, "gc", 1); zephir_array_fast_append(_10, _5); - ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10); + ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 409, _4, _6, _7, _8, _9, _10); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_redis_ce, this_ptr, "__construct", &_11, 411, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_redis_ce, this_ptr, "__construct", &_11, 410, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -132932,7 +134087,7 @@ static PHP_METHOD(Phalcon_Tag_Select, selectField) { ZEPHIR_GET_CONSTANT(_6, "PHP_EOL"); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, "", _6); - ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 416, options, using, value, _7); + ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 415, options, using, value, _7); zephir_check_call_status(); zephir_concat_self(&code, _8 TSRMLS_CC); } else { @@ -132941,7 +134096,7 @@ static PHP_METHOD(Phalcon_Tag_Select, selectField) { ZEPHIR_GET_CONSTANT(_6, "PHP_EOL"); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, "", _6); - ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 417, options, value, _7); + ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 416, options, value, _7); zephir_check_call_status(); zephir_concat_self(&code, _8 TSRMLS_CC); } else { @@ -133079,12 +134234,12 @@ static PHP_METHOD(Phalcon_Tag_Select, _optionsFromArray) { ) { ZEPHIR_GET_HMKEY(optionValue, _1, _0); ZEPHIR_GET_HVALUE(optionText, _2); - ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 181, optionValue); + ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 182, optionValue); zephir_check_call_status(); if (Z_TYPE_P(optionText) == IS_ARRAY) { ZEPHIR_INIT_NVAR(_4); ZEPHIR_GET_CONSTANT(_4, "PHP_EOL"); - ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 417, optionText, value, closeOption); + ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 416, optionText, value, closeOption); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_7); ZEPHIR_GET_CONSTANT(_7, "PHP_EOL"); @@ -133478,7 +134633,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct) { - ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_csv_ce, this_ptr, "__construct", &_0, 426, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_csv_ce, this_ptr, "__construct", &_0, 425, options); zephir_check_call_status(); if (!(zephir_array_isset_string(options, SS("content")))) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter 'content' is required", "phalcon/translate/adapter/csv.zep", 43); @@ -133491,7 +134646,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct) { ZVAL_STRING(_3, ";", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_4); ZVAL_STRING(_4, "\"", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_load", NULL, 427, _1, _2, _3, _4); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_load", NULL, 426, _1, _2, _3, _4); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -133513,7 +134668,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Csv, _load) { ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "rb", 0); - ZEPHIR_CALL_FUNCTION(&fileHandler, "fopen", NULL, 292, file, &_0); + ZEPHIR_CALL_FUNCTION(&fileHandler, "fopen", NULL, 285, file, &_0); zephir_check_call_status(); if (Z_TYPE_P(fileHandler) != IS_RESOURCE) { ZEPHIR_INIT_VAR(_1); @@ -133527,7 +134682,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Csv, _load) { return; } while (1) { - ZEPHIR_CALL_FUNCTION(&data, "fgetcsv", &_3, 428, fileHandler, length, delimiter, enclosure); + ZEPHIR_CALL_FUNCTION(&data, "fgetcsv", &_3, 427, fileHandler, length, delimiter, enclosure); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(data)) { break; @@ -133685,7 +134840,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, __construct) { - ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_gettext_ce, this_ptr, "__construct", &_0, 426, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_gettext_ce, this_ptr, "__construct", &_0, 425, options); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, this_ptr, "prepareoptions", NULL, 0, options); zephir_check_call_status(); @@ -133718,22 +134873,22 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, query) { } - ZEPHIR_CALL_FUNCTION(&_0, "func_num_args", NULL, 421); + ZEPHIR_CALL_FUNCTION(&_0, "func_num_args", NULL, 420); zephir_check_call_status(); if (ZEPHIR_GT_LONG(_0, 2)) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 2); - ZEPHIR_CALL_FUNCTION(&domain, "func_get_arg", NULL, 420, &_1); + ZEPHIR_CALL_FUNCTION(&domain, "func_get_arg", NULL, 419, &_1); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(domain); ZVAL_NULL(domain); } if (!(zephir_is_true(domain))) { - ZEPHIR_CALL_FUNCTION(&translation, "gettext", NULL, 429, index); + ZEPHIR_CALL_FUNCTION(&translation, "gettext", NULL, 428, index); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&translation, "dgettext", NULL, 430, domain, index); + ZEPHIR_CALL_FUNCTION(&translation, "dgettext", NULL, 429, domain, index); zephir_check_call_status(); } ZEPHIR_RETURN_CALL_METHOD(this_ptr, "replaceplaceholders", NULL, 0, translation, placeholders); @@ -133831,12 +134986,12 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, nquery) { if (!(domain && Z_STRLEN_P(domain))) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, count); - ZEPHIR_CALL_FUNCTION(&translation, "ngettext", NULL, 431, msgid1, msgid2, &_0); + ZEPHIR_CALL_FUNCTION(&translation, "ngettext", NULL, 430, msgid1, msgid2, &_0); zephir_check_call_status(); } else { ZEPHIR_SINIT_NVAR(_0); ZVAL_LONG(&_0, count); - ZEPHIR_CALL_FUNCTION(&translation, "dngettext", NULL, 432, domain, msgid1, msgid2, &_0); + ZEPHIR_CALL_FUNCTION(&translation, "dngettext", NULL, 431, domain, msgid1, msgid2, &_0); zephir_check_call_status(); } ZEPHIR_RETURN_CALL_METHOD(this_ptr, "replaceplaceholders", NULL, 0, translation, placeholders); @@ -133867,7 +135022,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setDomain) { } - ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 433, domain); + ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 432, domain); zephir_check_call_status(); RETURN_MM(); @@ -133882,7 +135037,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, resetDomain) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getdefaultdomain", NULL, 0); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 433, _0); + ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 432, _0); zephir_check_call_status(); RETURN_MM(); @@ -133944,14 +135099,14 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setDirectory) { ) { ZEPHIR_GET_HMKEY(key, _1, _0); ZEPHIR_GET_HVALUE(value, _2); - ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 434, key, value); + ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 433, key, value); zephir_check_call_status(); } } } else { ZEPHIR_CALL_METHOD(&_4, this_ptr, "getdefaultdomain", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 434, _4, directory); + ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 433, _4, directory); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -133994,7 +135149,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setLocale) { ZEPHIR_INIT_VAR(_0); - ZEPHIR_CALL_FUNCTION(&_1, "func_get_args", NULL, 166); + ZEPHIR_CALL_FUNCTION(&_1, "func_get_args", NULL, 167); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_2); ZVAL_STRING(&_2, "setlocale", 0); @@ -134007,12 +135162,12 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setLocale) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_locale"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_4); ZEPHIR_CONCAT_SV(_4, "LC_ALL=", _3); - ZEPHIR_CALL_FUNCTION(NULL, "putenv", NULL, 435, _4); + ZEPHIR_CALL_FUNCTION(NULL, "putenv", NULL, 434, _4); zephir_check_call_status(); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_locale"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_6); ZVAL_LONG(&_6, 0); - ZEPHIR_CALL_FUNCTION(NULL, "setlocale", NULL, 415, &_6, _5); + ZEPHIR_CALL_FUNCTION(NULL, "setlocale", NULL, 414, &_6, _5); zephir_check_call_status(); RETURN_MM_MEMBER(this_ptr, "_locale"); @@ -134125,7 +135280,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_NativeArray, __construct) { - ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_nativearray_ce, this_ptr, "__construct", &_0, 426, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_nativearray_ce, this_ptr, "__construct", &_0, 425, options); zephir_check_call_status(); ZEPHIR_OBS_VAR(data); if (!(zephir_array_isset_string_fetch(&data, options, SS("content"), 0 TSRMLS_CC))) { @@ -134331,7 +135486,7 @@ static PHP_METHOD(Phalcon_Translate_Interpolator_IndexedArray, replacePlaceholde } if (_0) { Z_SET_ISREF_P(placeholders); - ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 386, placeholders, translation); + ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 379, placeholders, translation); Z_UNSET_ISREF_P(placeholders); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_1); @@ -134552,7 +135707,7 @@ static PHP_METHOD(Phalcon_Validation_Message, __set_state) { zephir_array_fetch_string(&_0, message, SL("_message"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC); zephir_array_fetch_string(&_1, message, SL("_field"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC); zephir_array_fetch_string(&_2, message, SL("_type"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 436, _0, _1, _2); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 435, _0, _1, _2); zephir_check_call_status(); RETURN_MM(); @@ -135166,7 +136321,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) { if (_2) { RETURN_MM_BOOL(1); } - ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 437, value); + ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 436, value); zephir_check_call_status(); if (!(zephir_is_true(_3))) { ZEPHIR_INIT_NVAR(_1); @@ -135195,11 +136350,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Alnum", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -135269,7 +136424,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) { if (_2) { RETURN_MM_BOOL(1); } - ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 438, value); + ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 437, value); zephir_check_call_status(); if (!(zephir_is_true(_3))) { ZEPHIR_INIT_NVAR(_1); @@ -135298,11 +136453,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Alpha", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -135415,11 +136570,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Between, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Between", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -135483,7 +136638,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&valueWith, validation, "getvalue", NULL, 0, fieldWith); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 439, value, valueWith); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 438, value, valueWith); zephir_check_call_status(); if (!(zephir_is_true(_1))) { ZEPHIR_INIT_NVAR(_0); @@ -135522,11 +136677,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZVAL_STRING(_3, "Confirmation", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _2, field, _3); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 435, _2, field, _3); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -135565,12 +136720,12 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, compare) { } ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "utf-8", 0); - ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 194, a, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 195, a, &_3); zephir_check_call_status(); zephir_get_strval(a, _4); ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "utf-8", 0); - ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 194, b, &_3); + ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 195, b, &_3); zephir_check_call_status(); zephir_get_strval(b, _6); } @@ -135637,7 +136792,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) { if (_2) { RETURN_MM_BOOL(1); } - ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 440, value); + ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 439, value); zephir_check_call_status(); if (!(zephir_is_true(_3))) { ZEPHIR_INIT_NVAR(_1); @@ -135666,11 +136821,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Digit", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -135742,7 +136897,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Email, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 274); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_1); @@ -135771,11 +136926,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Email, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "Email", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _5, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -135884,11 +137039,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_ExclusionIn, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_3, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_3, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_4); ZVAL_STRING(_4, "ExclusionIn", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _3, field, _4); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _3, field, _4); zephir_check_temp_parameter(_4); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -136000,11 +137155,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_11); ZVAL_STRING(_11, "FileIniSize", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 436, _9, field, _11); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 435, _9, field, _11); zephir_check_temp_parameter(_11); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -136044,7 +137199,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { _20 = _18; if (!(_20)) { zephir_array_fetch_string(&_21, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 79 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 232, _21); + ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 233, _21); zephir_check_call_status(); _20 = !zephir_is_true(_9); } @@ -136066,11 +137221,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_23); ZVAL_STRING(_23, "FileEmpty", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _22, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -136103,11 +137258,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_23); ZVAL_STRING(_23, "FileValid", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _9, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _9, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -136153,7 +137308,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { zephir_array_fetch_long(&unit, matches, 2, PH_NOISY, "phalcon/validation/validator/file.zep", 115 TSRMLS_CC); } zephir_array_fetch_long(&_28, matches, 1, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _28); + ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 304, _28); zephir_check_call_status(); ZEPHIR_INIT_VAR(_30); zephir_array_fetch(&_31, byteUnits, unit, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC); @@ -136163,9 +137318,9 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { ZEPHIR_INIT_VAR(bytes); mul_function(bytes, _22, _30 TSRMLS_CC); zephir_array_fetch_string(&_33, value, SL("size"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 120 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _33); + ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 304, _33); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 311, bytes); + ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 304, bytes); zephir_check_call_status(); if (ZEPHIR_GT(_22, _34)) { ZEPHIR_INIT_NVAR(_30); @@ -136186,11 +137341,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_30); object_init_ex(_30, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_36); ZVAL_STRING(_36, "FileSize", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 436, _35, field, _36); + ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 435, _35, field, _36); zephir_check_temp_parameter(_36); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _30); @@ -136216,12 +137371,12 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { if ((zephir_function_exists_ex(SS("finfo_open") TSRMLS_CC) == SUCCESS)) { ZEPHIR_SINIT_NVAR(_32); ZVAL_LONG(&_32, 16); - ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 229, &_32); + ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 230, &_32); zephir_check_call_status(); zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 143 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, tmp, _28); + ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 231, tmp, _28); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, tmp); + ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 232, tmp); zephir_check_call_status(); } else { ZEPHIR_OBS_NVAR(mime); @@ -136248,11 +137403,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_23); ZVAL_STRING(_23, "FileType", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _22, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -136276,7 +137431,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } if (_37) { zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 164 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 249, _28); + ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 241, _28); zephir_check_call_status(); ZEPHIR_OBS_VAR(width); zephir_array_fetch_long(&width, tmp, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 165 TSRMLS_CC); @@ -136333,11 +137488,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_23); ZVAL_STRING(_23, "FileMinResolution", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _35, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _35, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -136389,11 +137544,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_23); object_init_ex(_23, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_41, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_41, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_26); ZVAL_STRING(_26, "FileMaxResolution", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 436, _41, field, _26); + ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 435, _41, field, _26); zephir_check_temp_parameter(_26); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _23); @@ -136507,11 +137662,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Identical, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_4); ZVAL_STRING(_4, "Identical", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _4); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _2, field, _4); zephir_check_temp_parameter(_4); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -136608,7 +137763,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) { zephir_check_temp_parameter(_1); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 365, value, domain, strict); + ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 358, value, domain, strict); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_1); @@ -136640,11 +137795,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "InclusionIn", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _5, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -136746,11 +137901,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Numericality, validate) { } ZEPHIR_INIT_NVAR(_5); object_init_ex(_5, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "Numericality", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 436, _6, field, _7); + ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 435, _6, field, _7); zephir_check_temp_parameter(_7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _5); @@ -136839,11 +137994,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_PresenceOf, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZVAL_STRING(_3, "PresenceOf", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _3); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _2, field, _3); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -136955,11 +138110,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Regex, validate) { } ZEPHIR_INIT_NVAR(_4); object_init_ex(_4, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "Regex", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 436, _6, field, _7); + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 435, _6, field, _7); zephir_check_temp_parameter(_7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _4); @@ -137058,7 +138213,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) { zephir_check_call_status(); } if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value); + ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 359, value); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(length); @@ -137089,11 +138244,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "TooLong", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 436, _4, field, _6); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 435, _4, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -137126,11 +138281,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) { } ZEPHIR_INIT_NVAR(_6); object_init_ex(_6, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_8); ZVAL_STRING(_8, "TooShort", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 436, _4, field, _8); + ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 435, _4, field, _8); zephir_check_temp_parameter(_8); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _6); @@ -137267,11 +138422,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "Uniqueness", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _6, field, _7); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 435, _6, field, _7); zephir_check_temp_parameter(_7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -137343,7 +138498,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Url, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 273); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_1); @@ -137372,11 +138527,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Url, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "Url", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _5, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -137453,6 +138608,7 @@ zend_class_entry *phalcon_di_serviceinterface_ce; zend_class_entry *phalcon_escaperinterface_ce; zend_class_entry *phalcon_events_managerinterface_ce; zend_class_entry *phalcon_filterinterface_ce; +zend_class_entry *phalcon_http_cookieinterface_ce; zend_class_entry *phalcon_http_request_fileinterface_ce; zend_class_entry *phalcon_http_requestinterface_ce; zend_class_entry *phalcon_http_response_cookiesinterface_ce; @@ -137516,6 +138672,7 @@ zend_class_entry *phalcon_cache_frontend_data_ce; zend_class_entry *phalcon_di_factorydefault_ce; zend_class_entry *phalcon_mvc_model_transaction_exception_ce; zend_class_entry *phalcon_mvc_router_ce; +zend_class_entry *phalcon_mvc_view_exception_ce; zend_class_entry *phalcon_0__closure_ce; zend_class_entry *phalcon_acl_adapter_memory_ce; zend_class_entry *phalcon_acl_ce; @@ -137714,7 +138871,7 @@ zend_class_entry *phalcon_mvc_view_ce; zend_class_entry *phalcon_mvc_view_engine_php_ce; zend_class_entry *phalcon_mvc_view_engine_volt_ce; zend_class_entry *phalcon_mvc_view_engine_volt_compiler_ce; -zend_class_entry *phalcon_mvc_view_exception_ce; +zend_class_entry *phalcon_mvc_view_engine_volt_exception_ce; zend_class_entry *phalcon_mvc_view_simple_ce; zend_class_entry *phalcon_paginator_adapter_model_ce; zend_class_entry *phalcon_paginator_adapter_nativearray_ce; @@ -137725,6 +138882,7 @@ zend_class_entry *phalcon_queue_beanstalk_job_ce; zend_class_entry *phalcon_registry_ce; zend_class_entry *phalcon_security_ce; zend_class_entry *phalcon_security_exception_ce; +zend_class_entry *phalcon_security_random_ce; zend_class_entry *phalcon_session_adapter_files_ce; zend_class_entry *phalcon_session_adapter_libmemcached_ce; zend_class_entry *phalcon_session_adapter_memcache_ce; @@ -137781,6 +138939,7 @@ PHP_INI_BEGIN() STD_PHP_INI_BOOLEAN("phalcon.orm.exception_on_failed_save", "0", PHP_INI_ALL, OnUpdateBool, orm.exception_on_failed_save, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.enable_literals", "1", PHP_INI_ALL, OnUpdateBool, orm.enable_literals, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.late_state_binding", "0", PHP_INI_ALL, OnUpdateBool, orm.late_state_binding, zend_phalcon_globals, phalcon_globals) + STD_PHP_INI_BOOLEAN("phalcon.orm.enable_implicit_joins", "1", PHP_INI_ALL, OnUpdateBool, orm.enable_implicit_joins, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.cast_on_hydrate", "0", PHP_INI_ALL, OnUpdateBool, orm.cast_on_hydrate, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.ignore_unknown_columns", "0", PHP_INI_ALL, OnUpdateBool, orm.ignore_unknown_columns, zend_phalcon_globals, phalcon_globals) PHP_INI_END() @@ -137846,6 +139005,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_EscaperInterface); ZEPHIR_INIT(Phalcon_Events_ManagerInterface); ZEPHIR_INIT(Phalcon_FilterInterface); + ZEPHIR_INIT(Phalcon_Http_CookieInterface); ZEPHIR_INIT(Phalcon_Http_RequestInterface); ZEPHIR_INIT(Phalcon_Http_Request_FileInterface); ZEPHIR_INIT(Phalcon_Http_ResponseInterface); @@ -137909,6 +139069,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_Di_FactoryDefault); ZEPHIR_INIT(Phalcon_Mvc_Model_Transaction_Exception); ZEPHIR_INIT(Phalcon_Mvc_Router); + ZEPHIR_INIT(Phalcon_Mvc_View_Exception); ZEPHIR_INIT(Phalcon_Acl); ZEPHIR_INIT(Phalcon_Acl_Adapter_Memory); ZEPHIR_INIT(Phalcon_Acl_Exception); @@ -138106,7 +139267,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Php); ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Volt); ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Volt_Compiler); - ZEPHIR_INIT(Phalcon_Mvc_View_Exception); + ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Volt_Exception); ZEPHIR_INIT(Phalcon_Mvc_View_Simple); ZEPHIR_INIT(Phalcon_Paginator_Adapter_Model); ZEPHIR_INIT(Phalcon_Paginator_Adapter_NativeArray); @@ -138117,6 +139278,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_Registry); ZEPHIR_INIT(Phalcon_Security); ZEPHIR_INIT(Phalcon_Security_Exception); + ZEPHIR_INIT(Phalcon_Security_Random); ZEPHIR_INIT(Phalcon_Session); ZEPHIR_INIT(Phalcon_Session_Adapter_Files); ZEPHIR_INIT(Phalcon_Session_Adapter_Libmemcached); @@ -138210,6 +139372,7 @@ static void php_zephir_init_globals(zend_phalcon_globals *phalcon_globals TSRMLS + } static PHP_RINIT_FUNCTION(phalcon) diff --git a/build/64bits/phalcon.zep.h b/build/64bits/phalcon.zep.h index 877bafc5931..c72569af8a9 100644 --- a/build/64bits/phalcon.zep.h +++ b/build/64bits/phalcon.zep.h @@ -2627,6 +2627,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, setOptions); static PHP_METHOD(Phalcon_Session_Adapter, getOptions); static PHP_METHOD(Phalcon_Session_Adapter, setName); static PHP_METHOD(Phalcon_Session_Adapter, getName); +static PHP_METHOD(Phalcon_Session_Adapter, regenerateId); static PHP_METHOD(Phalcon_Session_Adapter, get); static PHP_METHOD(Phalcon_Session_Adapter, set); static PHP_METHOD(Phalcon_Session_Adapter, has); @@ -2653,6 +2654,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setname, 0, 0, 1) ZEND_ARG_INFO(0, name) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_regenerateid, 0, 0, 0) + ZEND_ARG_INFO(0, deleteOldSession) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_get, 0, 0, 1) ZEND_ARG_INFO(0, index) ZEND_ARG_INFO(0, defaultValue) @@ -2676,6 +2681,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setid, 0, 0, 1) ZEND_ARG_INFO(0, id) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_destroy, 0, 0, 0) + ZEND_ARG_INFO(0, removeData) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___get, 0, 0, 1) ZEND_ARG_INFO(0, index) ZEND_END_ARG_INFO() @@ -2700,6 +2709,7 @@ ZEPHIR_INIT_FUNCS(phalcon_session_adapter_method_entry) { PHP_ME(Phalcon_Session_Adapter, getOptions, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, setName, arginfo_phalcon_session_adapter_setname, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, getName, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Session_Adapter, regenerateId, arginfo_phalcon_session_adapter_regenerateid, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, get, arginfo_phalcon_session_adapter_get, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, set, arginfo_phalcon_session_adapter_set, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, has, arginfo_phalcon_session_adapter_has, ZEND_ACC_PUBLIC) @@ -2707,7 +2717,7 @@ ZEPHIR_INIT_FUNCS(phalcon_session_adapter_method_entry) { PHP_ME(Phalcon_Session_Adapter, getId, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, setId, arginfo_phalcon_session_adapter_setid, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, isStarted, NULL, ZEND_ACC_PUBLIC) - PHP_ME(Phalcon_Session_Adapter, destroy, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Session_Adapter, destroy, arginfo_phalcon_session_adapter_destroy, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, status, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, __get, arginfo_phalcon_session_adapter___get, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, __set, arginfo_phalcon_session_adapter___set, ZEND_ACC_PUBLIC) @@ -2742,6 +2752,14 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_remove, 0, 0, 1) ZEND_ARG_INFO(0, index) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_destroy, 0, 0, 0) + ZEND_ARG_INFO(0, removeData) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_regenerateid, 0, 0, 0) + ZEND_ARG_INFO(0, deleteOldSession) +ZEND_END_ARG_INFO() + ZEPHIR_INIT_FUNCS(phalcon_session_adapterinterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, start, NULL) PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, setOptions, arginfo_phalcon_session_adapterinterface_setoptions) @@ -2752,7 +2770,8 @@ ZEPHIR_INIT_FUNCS(phalcon_session_adapterinterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, remove, arginfo_phalcon_session_adapterinterface_remove) PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getId, NULL) PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, isStarted, NULL) - PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, destroy, NULL) + PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, destroy, arginfo_phalcon_session_adapterinterface_destroy) + PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, regenerateId, arginfo_phalcon_session_adapterinterface_regenerateid) PHP_FE_END }; @@ -4594,6 +4613,11 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_di_serviceinterface_resolve, 0, 0, 0) ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 1) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_di_serviceinterface_setparameter, 0, 0, 2) + ZEND_ARG_INFO(0, position) + ZEND_ARG_ARRAY_INFO(0, parameter, 0) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_di_serviceinterface___set_state, 0, 0, 1) ZEND_ARG_ARRAY_INFO(0, attributes, 0) ZEND_END_ARG_INFO() @@ -4606,6 +4630,7 @@ ZEPHIR_INIT_FUNCS(phalcon_di_serviceinterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, setDefinition, arginfo_phalcon_di_serviceinterface_setdefinition) PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, getDefinition, NULL) PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, resolve, arginfo_phalcon_di_serviceinterface_resolve) + PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, setParameter, arginfo_phalcon_di_serviceinterface_setparameter) ZEND_FENTRY(__set_state, NULL, arginfo_phalcon_di_serviceinterface___set_state, ZEND_ACC_STATIC|ZEND_ACC_ABSTRACT|ZEND_ACC_PUBLIC) PHP_FE_END }; @@ -4712,6 +4737,64 @@ ZEPHIR_INIT_FUNCS(phalcon_filterinterface_method_entry) { PHP_FE_END }; +zend_class_entry *phalcon_http_cookieinterface_ce; + +ZEPHIR_INIT_CLASS(Phalcon_Http_CookieInterface); + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setvalue, 0, 0, 1) + ZEND_ARG_INFO(0, value) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_getvalue, 0, 0, 0) + ZEND_ARG_INFO(0, filters) + ZEND_ARG_INFO(0, defaultValue) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_useencryption, 0, 0, 1) + ZEND_ARG_INFO(0, useEncryption) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setexpiration, 0, 0, 1) + ZEND_ARG_INFO(0, expire) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setpath, 0, 0, 1) + ZEND_ARG_INFO(0, path) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setdomain, 0, 0, 1) + ZEND_ARG_INFO(0, domain) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setsecure, 0, 0, 1) + ZEND_ARG_INFO(0, secure) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_sethttponly, 0, 0, 1) + ZEND_ARG_INFO(0, httpOnly) +ZEND_END_ARG_INFO() + +ZEPHIR_INIT_FUNCS(phalcon_http_cookieinterface_method_entry) { + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setValue, arginfo_phalcon_http_cookieinterface_setvalue) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getValue, arginfo_phalcon_http_cookieinterface_getvalue) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, send, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, delete, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, useEncryption, arginfo_phalcon_http_cookieinterface_useencryption) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, isUsingEncryption, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setExpiration, arginfo_phalcon_http_cookieinterface_setexpiration) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getExpiration, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setPath, arginfo_phalcon_http_cookieinterface_setpath) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getName, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getPath, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setDomain, arginfo_phalcon_http_cookieinterface_setdomain) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getDomain, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setSecure, arginfo_phalcon_http_cookieinterface_setsecure) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getSecure, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setHttpOnly, arginfo_phalcon_http_cookieinterface_sethttponly) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getHttpOnly, NULL) + PHP_FE_END +}; + zend_class_entry *phalcon_http_request_fileinterface_ce; ZEPHIR_INIT_CLASS(Phalcon_Http_Request_FileInterface); @@ -5247,12 +5330,6 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_criteriainterface_notinwhere, 0 ZEND_ARG_ARRAY_INFO(0, values, 0) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_criteriainterface_frominput, 0, 0, 3) - ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 0) - ZEND_ARG_INFO(0, modelName) - ZEND_ARG_ARRAY_INFO(0, data, 0) -ZEND_END_ARG_INFO() - ZEPHIR_INIT_FUNCS(phalcon_mvc_model_criteriainterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, setModelName, arginfo_phalcon_mvc_model_criteriainterface_setmodelname) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getModelName, NULL) @@ -5275,7 +5352,6 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_criteriainterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getLimit, NULL) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getOrder, NULL) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getParams, NULL) - ZEND_FENTRY(fromInput, NULL, arginfo_phalcon_mvc_model_criteriainterface_frominput, ZEND_ACC_STATIC|ZEND_ACC_ABSTRACT|ZEND_ACC_PUBLIC) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, execute, NULL) PHP_FE_END }; @@ -6369,6 +6445,11 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_urlinterface_method_entry) { PHP_FE_END }; +zend_class_entry *phalcon_mvc_view_exception_ce; + +ZEPHIR_INIT_CLASS(Phalcon_Mvc_View_Exception); + + zend_class_entry *phalcon_mvc_viewinterface_ce; ZEPHIR_INIT_CLASS(Phalcon_Mvc_ViewInterface); @@ -8134,6 +8215,7 @@ static PHP_METHOD(Phalcon_Cache_Multiple, start); static PHP_METHOD(Phalcon_Cache_Multiple, save); static PHP_METHOD(Phalcon_Cache_Multiple, delete); static PHP_METHOD(Phalcon_Cache_Multiple, exists); +static PHP_METHOD(Phalcon_Cache_Multiple, flush); ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_multiple___construct, 0, 0, 0) ZEND_ARG_INFO(0, backends) @@ -8177,6 +8259,7 @@ ZEPHIR_INIT_FUNCS(phalcon_cache_multiple_method_entry) { PHP_ME(Phalcon_Cache_Multiple, save, arginfo_phalcon_cache_multiple_save, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Cache_Multiple, delete, arginfo_phalcon_cache_multiple_delete, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Cache_Multiple, exists, arginfo_phalcon_cache_multiple_exists, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Cache_Multiple, flush, NULL, ZEND_ACC_PUBLIC) PHP_FE_END }; @@ -9682,11 +9765,11 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setsqlstatement, 0, 0, 1 ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setsqlvariables, 0, 0, 1) - ZEND_ARG_INFO(0, sqlVariables) + ZEND_ARG_ARRAY_INFO(0, sqlVariables, 0) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setsqlbindtypes, 0, 0, 1) - ZEND_ARG_INFO(0, sqlBindTypes) + ZEND_ARG_ARRAY_INFO(0, sqlBindTypes, 0) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setinitialtime, 0, 0, 1) @@ -13544,7 +13627,7 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model___call, 0, 0, 2) ZEND_ARG_INFO(0, arguments) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model___callstatic, 0, 0, 1) +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model___callstatic, 0, 0, 2) ZEND_ARG_INFO(0, method) ZEND_ARG_INFO(0, arguments) ZEND_END_ARG_INFO() @@ -13879,6 +13962,7 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_criteria_frominput, 0, 0, 3) ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 0) ZEND_ARG_INFO(0, modelName) ZEND_ARG_ARRAY_INFO(0, data, 0) + ZEND_ARG_INFO(0, operator) ZEND_END_ARG_INFO() ZEPHIR_INIT_FUNCS(phalcon_mvc_model_criteria_method_entry) { @@ -14723,6 +14807,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, getSql); ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query___construct, 0, 0, 0) ZEND_ARG_INFO(0, phql) ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 1) + ZEND_ARG_INFO(0, options) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query_setdi, 0, 0, 1) @@ -14985,6 +15070,7 @@ ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query_builder_addfrom, 0, 0, 1) ZEND_ARG_INFO(0, model) ZEND_ARG_INFO(0, alias) + ZEND_ARG_INFO(0, with) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query_builder_join, 0, 0, 1) @@ -15164,6 +15250,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Relation, getReferencedModel); static PHP_METHOD(Phalcon_Mvc_Model_Relation, getFields); static PHP_METHOD(Phalcon_Mvc_Model_Relation, getReferencedFields); static PHP_METHOD(Phalcon_Mvc_Model_Relation, getOptions); +static PHP_METHOD(Phalcon_Mvc_Model_Relation, getOption); static PHP_METHOD(Phalcon_Mvc_Model_Relation, isForeignKey); static PHP_METHOD(Phalcon_Mvc_Model_Relation, getForeignKey); static PHP_METHOD(Phalcon_Mvc_Model_Relation, getParams); @@ -15187,6 +15274,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_relation_setintermediaterelatio ZEND_ARG_INFO(0, intermediateReferencedFields) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_relation_getoption, 0, 0, 1) + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO() + ZEPHIR_INIT_FUNCS(phalcon_mvc_model_relation_method_entry) { PHP_ME(Phalcon_Mvc_Model_Relation, __construct, arginfo_phalcon_mvc_model_relation___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR) PHP_ME(Phalcon_Mvc_Model_Relation, setIntermediateRelation, arginfo_phalcon_mvc_model_relation_setintermediaterelation, ZEND_ACC_PUBLIC) @@ -15195,6 +15286,7 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_relation_method_entry) { PHP_ME(Phalcon_Mvc_Model_Relation, getFields, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getReferencedFields, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getOptions, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Mvc_Model_Relation, getOption, arginfo_phalcon_mvc_model_relation_getoption, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, isForeignKey, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getForeignKey, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getParams, NULL, ZEND_ACC_PUBLIC) @@ -16640,9 +16732,9 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_view_engine_volt_compiler_method_entry) { PHP_FE_END }; -zend_class_entry *phalcon_mvc_view_exception_ce; +zend_class_entry *phalcon_mvc_view_engine_volt_exception_ce; -ZEPHIR_INIT_CLASS(Phalcon_Mvc_View_Exception); +ZEPHIR_INIT_CLASS(Phalcon_Mvc_View_Engine_Volt_Exception); zend_class_entry *phalcon_mvc_view_simple_ce; @@ -16847,6 +16939,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, choose); static PHP_METHOD(Phalcon_Queue_Beanstalk, watch); static PHP_METHOD(Phalcon_Queue_Beanstalk, stats); static PHP_METHOD(Phalcon_Queue_Beanstalk, statsTube); +static PHP_METHOD(Phalcon_Queue_Beanstalk, listTubes); static PHP_METHOD(Phalcon_Queue_Beanstalk, peekReady); static PHP_METHOD(Phalcon_Queue_Beanstalk, peekBuried); static PHP_METHOD(Phalcon_Queue_Beanstalk, readStatus); @@ -16897,6 +16990,7 @@ ZEPHIR_INIT_FUNCS(phalcon_queue_beanstalk_method_entry) { PHP_ME(Phalcon_Queue_Beanstalk, watch, arginfo_phalcon_queue_beanstalk_watch, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, stats, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, statsTube, arginfo_phalcon_queue_beanstalk_statstube, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Queue_Beanstalk, listTubes, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, peekReady, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, peekBuried, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, readStatus, NULL, ZEND_ACC_FINAL|ZEND_ACC_PUBLIC) @@ -17130,6 +17224,48 @@ zend_class_entry *phalcon_security_exception_ce; ZEPHIR_INIT_CLASS(Phalcon_Security_Exception); +zend_class_entry *phalcon_security_random_ce; + +ZEPHIR_INIT_CLASS(Phalcon_Security_Random); + +static PHP_METHOD(Phalcon_Security_Random, bytes); +static PHP_METHOD(Phalcon_Security_Random, hex); +static PHP_METHOD(Phalcon_Security_Random, base64); +static PHP_METHOD(Phalcon_Security_Random, base64Safe); +static PHP_METHOD(Phalcon_Security_Random, uuid); +static PHP_METHOD(Phalcon_Security_Random, number); + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_bytes, 0, 0, 0) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_hex, 0, 0, 0) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_base64, 0, 0, 0) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_base64safe, 0, 0, 0) + ZEND_ARG_INFO(0, len) + ZEND_ARG_INFO(0, padding) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_number, 0, 0, 1) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEPHIR_INIT_FUNCS(phalcon_security_random_method_entry) { + PHP_ME(Phalcon_Security_Random, bytes, arginfo_phalcon_security_random_bytes, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, hex, arginfo_phalcon_security_random_hex, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, base64, arginfo_phalcon_security_random_base64, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, base64Safe, arginfo_phalcon_security_random_base64safe, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, uuid, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, number, arginfo_phalcon_security_random_number, ZEND_ACC_PUBLIC) + PHP_FE_END +}; + zend_class_entry *phalcon_session_ce; ZEPHIR_INIT_CLASS(Phalcon_Session); diff --git a/build/64bits/php_phalcon.h b/build/64bits/php_phalcon.h index aed59e8482d..34511ce576f 100644 --- a/build/64bits/php_phalcon.h +++ b/build/64bits/php_phalcon.h @@ -196,7 +196,7 @@ typedef zend_function zephir_fcall_cache_entry; #define PHP_PHALCON_NAME "phalcon" -#define PHP_PHALCON_VERSION "2.0.6" +#define PHP_PHALCON_VERSION "2.0.7" #define PHP_PHALCON_EXTNAME "phalcon" #define PHP_PHALCON_AUTHOR "Phalcon Team and contributors" #define PHP_PHALCON_ZEPVERSION "0.7.1b" @@ -219,6 +219,7 @@ typedef struct _zephir_struct_orm { zend_bool exception_on_failed_save; zend_bool enable_literals; zend_bool late_state_binding; + zend_bool enable_implicit_joins; zend_bool cast_on_hydrate; zend_bool ignore_unknown_columns; } zephir_struct_orm; diff --git a/build/safe/phalcon.zep.c b/build/safe/phalcon.zep.c index f03e012a1f9..e17ef2cdf8d 100644 --- a/build/safe/phalcon.zep.c +++ b/build/safe/phalcon.zep.c @@ -248,23 +248,23 @@ PHP includes the Zend Engine, freely available at #define PHQL_IDENTIFIER 30 #define PHQL_DOT 31 #define PHQL_AS 32 -#define PHQL_WITH 33 -#define PHQL_INNER 34 -#define PHQL_JOIN 35 -#define PHQL_CROSS 36 -#define PHQL_LEFT 37 -#define PHQL_OUTER 38 -#define PHQL_RIGHT 39 -#define PHQL_FULL 40 -#define PHQL_ON 41 -#define PHQL_INSERT 42 -#define PHQL_INTO 43 -#define PHQL_VALUES 44 -#define PHQL_PARENTHESES_OPEN 45 -#define PHQL_PARENTHESES_CLOSE 46 -#define PHQL_UPDATE 47 -#define PHQL_SET 48 -#define PHQL_DELETE 49 +#define PHQL_INNER 33 +#define PHQL_JOIN 34 +#define PHQL_CROSS 35 +#define PHQL_LEFT 36 +#define PHQL_OUTER 37 +#define PHQL_RIGHT 38 +#define PHQL_FULL 39 +#define PHQL_ON 40 +#define PHQL_INSERT 41 +#define PHQL_INTO 42 +#define PHQL_VALUES 43 +#define PHQL_PARENTHESES_OPEN 44 +#define PHQL_PARENTHESES_CLOSE 45 +#define PHQL_UPDATE 46 +#define PHQL_SET 47 +#define PHQL_DELETE 48 +#define PHQL_WITH 49 #define PHQL_WHERE 50 #define PHQL_ORDER 51 #define PHQL_BY 52 @@ -3765,10 +3765,19 @@ static void zephir_concat_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) #include #include +double zephir_sin(zval *op1 TSRMLS_DC); +double zephir_asin(zval *op1 TSRMLS_DC); +double zephir_tan(zval *op1 TSRMLS_DC); +double zephir_cos(zval *op1 TSRMLS_DC); +double zephir_acos(zval *op1 TSRMLS_DC); +double zephir_sqrt(zval *op1 TSRMLS_DC); + double zephir_floor(zval *op1 TSRMLS_DC); double zephir_ceil(zval *op1 TSRMLS_DC); + static void zephir_round(zval *return_value, zval *op1, zval *op2, zval *op3 TSRMLS_DC); static void zephir_pow(zval *return_value, zval *op1, zval *op2 TSRMLS_DC); + long zephir_mt_rand(long min, long max TSRMLS_DC); #endif @@ -16302,6 +16311,96 @@ double zephir_floor(zval *op1 TSRMLS_DC) return floor(zephir_get_numberval(op1)); } +double zephir_sin(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return sin(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return sin(zephir_get_numberval(op1)); +} + +double zephir_asin(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return asin(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return asin(zephir_get_numberval(op1)); +} + +double zephir_cos(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return cos(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return cos(zephir_get_numberval(op1)); +} + +double zephir_acos(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return acos(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return acos(zephir_get_numberval(op1)); +} + +double zephir_sqrt(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return sqrt(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return sqrt(zephir_get_numberval(op1)); +} + +double zephir_tan(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return tan(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return tan(zephir_get_numberval(op1)); +} + double zephir_ceil(zval *op1 TSRMLS_DC) { @@ -16397,6 +16496,8 @@ static void zephir_pow_function_ex(zval *return_value, zval *zbase, zval *zexp T } #endif + + long zephir_mt_rand(long min, long max TSRMLS_DC) { long number; @@ -17626,7 +17727,7 @@ static PHP_METHOD(phalcon_0__closure, __invoke) { zephir_array_fetch_long(&_0, matches, 1, PH_NOISY | PH_READONLY, "phalcon/text.zep", 272 TSRMLS_CC); ZEPHIR_INIT_VAR(words); zephir_fast_explode_str(words, SL("|"), _0, LONG_MAX TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 442, words); + ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 441, words); zephir_check_call_status(); zephir_array_fetch(&_1, words, _2, PH_NOISY | PH_READONLY, "phalcon/text.zep", 273 TSRMLS_CC); RETURN_CTOR(_1); @@ -17729,7 +17830,7 @@ static PHP_METHOD(Phalcon_Config, offsetExists) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); RETURN_MM_BOOL(zephir_isset_property_zval(this_ptr, index TSRMLS_CC)); @@ -17750,7 +17851,7 @@ static PHP_METHOD(Phalcon_Config, get) { } - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); if (zephir_isset_property_zval(this_ptr, index TSRMLS_CC)) { @@ -17774,7 +17875,7 @@ static PHP_METHOD(Phalcon_Config, offsetGet) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); ZEPHIR_OBS_VAR(_1); @@ -17794,13 +17895,13 @@ static PHP_METHOD(Phalcon_Config, offsetSet) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); if (Z_TYPE_P(value) == IS_ARRAY) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_config_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 21, value); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 22, value); zephir_check_call_status(); zephir_update_property_zval_zval(this_ptr, index, _1 TSRMLS_CC); } else { @@ -17821,7 +17922,7 @@ static PHP_METHOD(Phalcon_Config, offsetUnset) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); zephir_update_property_zval_zval(this_ptr, index, ZEPHIR_GLOBAL(global_null) TSRMLS_CC); @@ -17839,7 +17940,7 @@ static PHP_METHOD(Phalcon_Config, merge) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_merge", NULL, 22, config); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_merge", NULL, 23, config); zephir_check_call_status(); RETURN_MM(); @@ -17856,7 +17957,7 @@ static PHP_METHOD(Phalcon_Config, toArray) { ZEPHIR_INIT_VAR(arrayConfig); array_init(arrayConfig); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, this_ptr); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/config.zep", 180); for ( @@ -17888,7 +17989,7 @@ static PHP_METHOD(Phalcon_Config, count) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, this_ptr); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM_LONG(zephir_fast_count_int(_0 TSRMLS_CC)); @@ -17908,7 +18009,7 @@ static PHP_METHOD(Phalcon_Config, __set_state) { object_init_ex(return_value, phalcon_config_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 21, data); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 22, data); zephir_check_call_status(); RETURN_MM(); @@ -17916,12 +18017,12 @@ static PHP_METHOD(Phalcon_Config, __set_state) { static PHP_METHOD(Phalcon_Config, _merge) { - zephir_fcall_cache_entry *_8 = NULL, *_9 = NULL; + zephir_fcall_cache_entry *_6 = NULL, *_7 = NULL; zend_bool _4, _5; HashTable *_2; HashPosition _1; int ZEPHIR_LAST_CALL_STATUS; - zval *config, *instance = NULL, *key = NULL, *value = NULL, *number = NULL, *_0 = NULL, **_3, *_6 = NULL, *_7 = NULL; + zval *config, *instance = NULL, *key = NULL, *value = NULL, *number = NULL, *localObject = NULL, *_0 = NULL, **_3; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 1, 1, &config, &instance); @@ -17938,39 +18039,40 @@ static PHP_METHOD(Phalcon_Config, _merge) { } ZEPHIR_CALL_METHOD(&number, instance, "count", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, config); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, config); zephir_check_call_status(); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/config.zep", 239); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/config.zep", 245); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) ) { ZEPHIR_GET_HMKEY(key, _2, _1); ZEPHIR_GET_HVALUE(value, _3); - _4 = zephir_isset_property_zval(instance, key TSRMLS_CC); - if (_4) { - _4 = Z_TYPE_P(value) == IS_OBJECT; - } - _5 = _4; - if (_5) { - ZEPHIR_OBS_NVAR(_6); - zephir_read_property_zval(&_6, instance, key, PH_NOISY_CC); - _5 = Z_TYPE_P(_6) == IS_OBJECT; + ZEPHIR_OBS_NVAR(localObject); + if (zephir_fetch_property_zval(&localObject, instance, key, PH_SILENT_CC)) { + _4 = Z_TYPE_P(localObject) == IS_OBJECT; + if (_4) { + _4 = Z_TYPE_P(value) == IS_OBJECT; + } + if (_4) { + _5 = zephir_instance_of_ev(localObject, phalcon_config_ce TSRMLS_CC); + if (_5) { + _5 = zephir_instance_of_ev(value, phalcon_config_ce TSRMLS_CC); + } + if (_5) { + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_merge", &_6, 23, value, localObject); + zephir_check_call_status(); + continue; + } + } } - if (_5) { - ZEPHIR_OBS_NVAR(_7); - zephir_read_property_zval(&_7, instance, key, PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_merge", &_8, 22, value, _7); + if (Z_TYPE_P(key) == IS_LONG) { + ZEPHIR_CALL_FUNCTION(&key, "strval", &_7, 21, number); zephir_check_call_status(); - } else { - if (Z_TYPE_P(key) == IS_LONG) { - ZEPHIR_CALL_FUNCTION(&key, "strval", &_9, 20, number); - zephir_check_call_status(); - ZEPHIR_SEPARATE(number); - zephir_increment(number); - } - zephir_update_property_zval_zval(instance, key, value TSRMLS_CC); + ZEPHIR_SEPARATE(number); + zephir_increment(number); } + zephir_update_property_zval_zval(instance, key, value TSRMLS_CC); } RETVAL_ZVAL(instance, 1, 0); RETURN_MM(); @@ -18196,15 +18298,15 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 1) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (paddingSize - 1)); - ZEPHIR_CALL_FUNCTION(&_4, "str_repeat", &_5, 129, _2, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "str_repeat", &_5, 131, _2, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(padding); ZEPHIR_CONCAT_VV(padding, _4, _6); @@ -18213,11 +18315,11 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 2) { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 129, _2, &_1); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 131, _2, &_1); zephir_check_call_status(); break; } @@ -18238,16 +18340,16 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { _7 = 1; } i = _8; - ZEPHIR_CALL_FUNCTION(&_2, "rand", &_10, 107); + ZEPHIR_CALL_FUNCTION(&_2, "rand", &_10, 109); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 128, _2); + ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 130, _2); zephir_check_call_status(); zephir_concat_self(&padding, _4 TSRMLS_CC); } } ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 130, &_1); zephir_check_call_status(); zephir_concat_self(&padding, _6 TSRMLS_CC); break; @@ -18255,15 +18357,15 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 4) { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 0x80); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (paddingSize - 1)); - ZEPHIR_CALL_FUNCTION(&_6, "str_repeat", &_5, 129, _4, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "str_repeat", &_5, 131, _4, &_1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(padding); ZEPHIR_CONCAT_VV(padding, _2, _6); @@ -18272,11 +18374,11 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 5) { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 129, _2, &_1); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 131, _2, &_1); zephir_check_call_status(); break; } @@ -18285,7 +18387,7 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) { ZVAL_STRING(&_1, " ", 0); ZEPHIR_SINIT_VAR(_11); ZVAL_LONG(&_11, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 129, &_1, &_11); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 131, &_1, &_11); zephir_check_call_status(); break; } @@ -18373,18 +18475,18 @@ static PHP_METHOD(Phalcon_Crypt, _cryptUnpadText) { ZVAL_LONG(&_4, 1); ZEPHIR_INIT_VAR(last); zephir_substr(last, text, zephir_get_intval(&_3), 1 , 0); - ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 130, last); + ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 132, last); zephir_check_call_status(); ord = zephir_get_intval(_5); if (ord <= blockSize) { paddingSize = ord; ZEPHIR_SINIT_VAR(_7); ZVAL_LONG(&_7, 0); - ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 128, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 130, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, (paddingSize - 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, _8, &_7); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, _8, &_7); zephir_check_call_status(); ZEPHIR_INIT_VAR(padding); ZEPHIR_CONCAT_VV(padding, _10, last); @@ -18405,18 +18507,18 @@ static PHP_METHOD(Phalcon_Crypt, _cryptUnpadText) { ZVAL_LONG(&_4, 1); ZEPHIR_INIT_NVAR(last); zephir_substr(last, text, zephir_get_intval(&_3), 1 , 0); - ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 130, last); + ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 132, last); zephir_check_call_status(); ord = zephir_get_intval(_5); if (ord <= blockSize) { paddingSize = ord; ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, paddingSize); - ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 128, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 130, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_11, 129, _8, &_7); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_11, 131, _8, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, (length - paddingSize)); @@ -18435,7 +18537,7 @@ static PHP_METHOD(Phalcon_Crypt, _cryptUnpadText) { ZVAL_LONG(&_4, 1); ZEPHIR_INIT_NVAR(last); zephir_substr(last, text, zephir_get_intval(&_3), 1 , 0); - ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 130, last); + ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 132, last); zephir_check_call_status(); paddingSize = zephir_get_intval(_5); break; @@ -18591,7 +18693,7 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) { zephir_read_property_this(&cipher, this_ptr, SL("_cipher"), PH_NOISY_CC); ZEPHIR_OBS_VAR(mode); zephir_read_property_this(&mode, this_ptr, SL("_mode"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 131, cipher, mode); + ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 133, cipher, mode); zephir_check_call_status(); if (ZEPHIR_LT_LONG(ivSize, zephir_fast_strlen_ev(encryptKey))) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 320); @@ -18599,14 +18701,14 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) { } ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 2); - ZEPHIR_CALL_FUNCTION(&iv, "mcrypt_create_iv", NULL, 132, ivSize, &_0); + ZEPHIR_CALL_FUNCTION(&iv, "mcrypt_create_iv", NULL, 134, ivSize, &_0); zephir_check_call_status(); if (Z_TYPE_P(iv) != IS_STRING) { - ZEPHIR_CALL_FUNCTION(&_1, "strval", NULL, 20, iv); + ZEPHIR_CALL_FUNCTION(&_1, "strval", NULL, 21, iv); zephir_check_call_status(); ZEPHIR_CPY_WRT(iv, _1); } - ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 133, cipher, mode); + ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 135, cipher, mode); zephir_check_call_status(); if (Z_TYPE_P(blockSize) != IS_LONG) { _2 = zephir_get_intval(blockSize); @@ -18629,7 +18731,7 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) { } else { ZEPHIR_CPY_WRT(padded, text); } - ZEPHIR_CALL_FUNCTION(&_1, "mcrypt_encrypt", NULL, 134, cipher, encryptKey, padded, mode, iv); + ZEPHIR_CALL_FUNCTION(&_1, "mcrypt_encrypt", NULL, 136, cipher, encryptKey, padded, mode, iv); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, iv, _1); RETURN_MM(); @@ -18680,7 +18782,7 @@ static PHP_METHOD(Phalcon_Crypt, decrypt) { zephir_read_property_this(&cipher, this_ptr, SL("_cipher"), PH_NOISY_CC); ZEPHIR_OBS_VAR(mode); zephir_read_property_this(&mode, this_ptr, SL("_mode"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 131, cipher, mode); + ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 133, cipher, mode); zephir_check_call_status(); ZEPHIR_INIT_VAR(keySize); ZVAL_LONG(keySize, zephir_fast_strlen_ev(decryptKey)); @@ -18700,9 +18802,9 @@ static PHP_METHOD(Phalcon_Crypt, decrypt) { ZVAL_LONG(&_1, 0); ZEPHIR_INIT_VAR(_2); zephir_substr(_2, text, 0 , zephir_get_intval(ivSize), 0); - ZEPHIR_CALL_FUNCTION(&decrypted, "mcrypt_decrypt", NULL, 135, cipher, decryptKey, _0, mode, _2); + ZEPHIR_CALL_FUNCTION(&decrypted, "mcrypt_decrypt", NULL, 137, cipher, decryptKey, _0, mode, _2); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 133, cipher, mode); + ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 135, cipher, mode); zephir_check_call_status(); ZEPHIR_OBS_VAR(paddingType); zephir_read_property_this(&paddingType, this_ptr, SL("_padding"), PH_NOISY_CC); @@ -18759,19 +18861,19 @@ static PHP_METHOD(Phalcon_Crypt, encryptBase64) { if (safe == 1) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "encrypt", &_1, 0, text, key); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_2, "base64_encode", &_3, 112, _0); + ZEPHIR_CALL_FUNCTION(&_2, "base64_encode", &_3, 114, _0); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "+/", 0); ZEPHIR_SINIT_VAR(_5); ZVAL_STRING(&_5, "-_", 0); - ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 53, _2, &_4, &_5); + ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 54, _2, &_4, &_5); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_CALL_METHOD(&_0, this_ptr, "encrypt", &_1, 0, text, key); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", &_3, 112, _0); + ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", &_3, 114, _0); zephir_check_call_status(); RETURN_MM(); @@ -18819,15 +18921,15 @@ static PHP_METHOD(Phalcon_Crypt, decryptBase64) { ZVAL_STRING(&_0, "-_", 0); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "+/", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, text, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, text, &_0, &_1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_3, "base64_decode", &_4, 113, _2); + ZEPHIR_CALL_FUNCTION(&_3, "base64_decode", &_4, 115, _2); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "decrypt", &_5, 0, _3, key); zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_CALL_FUNCTION(&_2, "base64_decode", &_4, 113, text); + ZEPHIR_CALL_FUNCTION(&_2, "base64_decode", &_4, 115, text); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "decrypt", &_5, 0, _2, key); zephir_check_call_status(); @@ -18841,7 +18943,7 @@ static PHP_METHOD(Phalcon_Crypt, getAvailableCiphers) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_algorithms", NULL, 136); + ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_algorithms", NULL, 138); zephir_check_call_status(); RETURN_MM(); @@ -18853,7 +18955,7 @@ static PHP_METHOD(Phalcon_Crypt, getAvailableModes) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_modes", NULL, 137); + ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_modes", NULL, 139); zephir_check_call_status(); RETURN_MM(); @@ -19139,7 +19241,7 @@ static PHP_METHOD(Phalcon_Debug, listenExceptions) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "onUncaughtException", 1); zephir_array_fast_append(_0, _1); - ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _0); + ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 149, _0); zephir_check_call_status(); RETURN_THIS(); @@ -19159,7 +19261,7 @@ static PHP_METHOD(Phalcon_Debug, listenLowSeverity) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "onUncaughtLowSeverity", 1); zephir_array_fast_append(_0, _1); - ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 149, _0); + ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 150, _0); zephir_check_call_status(); ZEPHIR_INIT_VAR(_2); zephir_create_array(_2, 2, 0 TSRMLS_CC); @@ -19167,7 +19269,7 @@ static PHP_METHOD(Phalcon_Debug, listenLowSeverity) { ZEPHIR_INIT_NVAR(_1); ZVAL_STRING(_1, "onUncaughtException", 1); zephir_array_fast_append(_2, _1); - ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _2); + ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 149, _2); zephir_check_call_status(); RETURN_THIS(); @@ -19202,7 +19304,7 @@ static PHP_METHOD(Phalcon_Debug, debugVar) { ZEPHIR_INIT_VAR(_0); zephir_create_array(_0, 3, 0 TSRMLS_CC); zephir_array_fast_append(_0, varz); - ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 150); + ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 151); zephir_check_call_status(); zephir_array_fast_append(_0, _1); ZEPHIR_INIT_VAR(_2); @@ -19242,7 +19344,7 @@ static PHP_METHOD(Phalcon_Debug, _escapeString) { ZVAL_LONG(&_3, 2); ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "utf-8", 0); - ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 151, _0, &_3, &_4); + ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 152, _0, &_3, &_4); zephir_check_call_status(); RETURN_MM(); } @@ -19293,7 +19395,7 @@ static PHP_METHOD(Phalcon_Debug, _getArrayDump) { ) { ZEPHIR_GET_HMKEY(k, _2, _1); ZEPHIR_GET_HVALUE(v, _3); - ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 152, v); + ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 153, v); zephir_check_call_status(); if (zephir_is_true(_4)) { ZEPHIR_INIT_NVAR(varDump); @@ -19310,7 +19412,7 @@ static PHP_METHOD(Phalcon_Debug, _getArrayDump) { if (Z_TYPE_P(v) == IS_ARRAY) { ZEPHIR_INIT_NVAR(_8); ZVAL_LONG(_8, (zephir_get_numberval(n) + 1)); - ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 153, v, _8); + ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 154, v, _8); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVSVS(_10, "[", k, "] => Array(", _6, ")"); @@ -19351,7 +19453,7 @@ static PHP_METHOD(Phalcon_Debug, _getVarDump) { - ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 152, variable); + ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 153, variable); zephir_check_call_status(); if (zephir_is_true(_0)) { if (Z_TYPE_P(variable) == IS_BOOL) { @@ -19385,7 +19487,7 @@ static PHP_METHOD(Phalcon_Debug, _getVarDump) { } } if (Z_TYPE_P(variable) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 153, variable); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 154, variable); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "Array(", _1, ")"); RETURN_MM(); @@ -19406,7 +19508,7 @@ static PHP_METHOD(Phalcon_Debug, getMajorVersion) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 154); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 155); zephir_check_call_status(); ZEPHIR_INIT_VAR(parts); zephir_fast_explode_str(parts, SL(" "), _0, LONG_MAX TSRMLS_CC); @@ -19425,7 +19527,7 @@ static PHP_METHOD(Phalcon_Debug, getVersion) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmajorversion", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 154); + ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 155); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "
Phalcon Framework ", _1, "
"); RETURN_MM(); @@ -19517,9 +19619,9 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) { } else { ZEPHIR_INIT_VAR(classReflection); object_init_ex(classReflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, classReflection, "__construct", NULL, 62, className); + ZEPHIR_CALL_METHOD(NULL, classReflection, "__construct", NULL, 64, className); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 155); + ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 156); zephir_check_call_status(); if (zephir_is_true(_8)) { ZEPHIR_INIT_VAR(_9); @@ -19552,9 +19654,9 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) { if ((zephir_function_exists(functionName TSRMLS_CC) == SUCCESS)) { ZEPHIR_INIT_VAR(functionReflection); object_init_ex(functionReflection, zephir_get_internal_ce(SS("reflectionfunction") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 156, functionName); + ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 157, functionName); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 157); + ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 158); zephir_check_call_status(); if (zephir_is_true(_8)) { ZEPHIR_SINIT_NVAR(_4); @@ -19615,7 +19717,7 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) { ZEPHIR_OBS_VAR(showFiles); zephir_read_property_this(&showFiles, this_ptr, SL("_showFiles"), PH_NOISY_CC); if (zephir_is_true(showFiles)) { - ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 158, filez); + ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 159, filez); zephir_check_call_status(); ZEPHIR_INIT_VAR(numberLines); ZVAL_LONG(numberLines, zephir_fast_count_int(lines TSRMLS_CC)); @@ -19698,7 +19800,7 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) { ZVAL_LONG(&_23, 2); ZEPHIR_SINIT_NVAR(_25); ZVAL_STRING(&_25, "UTF-8", 0); - ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_26, 151, _21, &_23, &_25); + ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_26, 152, _21, &_23, &_25); zephir_check_call_status(); zephir_concat_self(&html, _8 TSRMLS_CC); } @@ -19722,7 +19824,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) { - ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 159); + ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 160); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_1); zephir_bitwise_and_function(&_1, _0, severity TSRMLS_CC); @@ -19731,7 +19833,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) { object_init_ex(_2, zephir_get_internal_ce(SS("errorexception") TSRMLS_CC)); ZEPHIR_INIT_VAR(_3); ZVAL_LONG(_3, 0); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 160, message, _3, severity, file, line); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 161, message, _3, severity, file, line); zephir_check_call_status(); zephir_throw_exception_debug(_2, "phalcon/debug.zep", 566 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -19756,10 +19858,10 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) { - ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 161); + ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 162); zephir_check_call_status(); if (ZEPHIR_GT_LONG(obLevel, 0)) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); } _0 = zephir_fetch_static_property_ce(phalcon_debug_ce, SL("_isActive") TSRMLS_CC); @@ -19823,7 +19925,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) { ) { ZEPHIR_GET_HMKEY(n, _11, _10); ZEPHIR_GET_HVALUE(traceItem, _12); - ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 162, n, traceItem); + ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 163, n, traceItem); zephir_check_call_status(); zephir_concat_self(&html, _13 TSRMLS_CC); } @@ -19842,7 +19944,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) { ZEPHIR_CONCAT_SVSVS(_18, "
"); zephir_concat_self(&html, _18 TSRMLS_CC); } else { - ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 163, value, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 164, value, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_18); ZEPHIR_CONCAT_SVSVS(_18, ""); @@ -19868,7 +19970,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) { zephir_concat_self_str(&html, SL("
Memory
Usage", _13, "
", keyRequest, "", value, "
", keyRequest, "", _13, "
") TSRMLS_CC); zephir_concat_self_str(&html, SL("
") TSRMLS_CC); zephir_concat_self_str(&html, SL("") TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 164); + ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 165); zephir_check_call_status(); zephir_is_iterable(_13, &_25, &_24, 0, 0, "phalcon/debug.zep", 694); for ( @@ -19883,7 +19985,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) { } zephir_concat_self_str(&html, SL("
#Path
") TSRMLS_CC); zephir_concat_self_str(&html, SL("
") TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 165, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 166, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_27); ZEPHIR_CONCAT_SVS(_27, ""); @@ -20018,7 +20120,7 @@ static PHP_METHOD(Phalcon_Di, set) { ZEPHIR_INIT_VAR(service); object_init_ex(service, phalcon_di_service_ce); - ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 61, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 63, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_services"), name, service TSRMLS_CC); RETURN_CCTOR(service); @@ -20051,7 +20153,7 @@ static PHP_METHOD(Phalcon_Di, setShared) { object_init_ex(service, phalcon_di_service_ce); ZEPHIR_SINIT_VAR(_0); ZVAL_BOOL(&_0, 1); - ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 61, name, definition, &_0); + ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 63, name, definition, &_0); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_services"), name, service TSRMLS_CC); RETURN_CCTOR(service); @@ -20119,7 +20221,7 @@ static PHP_METHOD(Phalcon_Di, attempt) { if (!(zephir_array_isset(_0, name))) { ZEPHIR_INIT_VAR(service); object_init_ex(service, phalcon_di_service_ce); - ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 61, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 63, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_services"), name, service TSRMLS_CC); RETURN_CCTOR(service); @@ -20287,7 +20389,7 @@ static PHP_METHOD(Phalcon_Di, get) { ZEPHIR_CONCAT_SVS(_3, "Service '", name, "' wasn't found in the dependency injection container"); ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/di.zep", 229 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/di.zep", 230 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -20296,9 +20398,9 @@ static PHP_METHOD(Phalcon_Di, get) { if (zephir_is_php_version(50600)) { ZEPHIR_INIT_VAR(reflection); object_init_ex(reflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 62, name); + ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 64, name); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&instance, reflection, "newinstanceargs", NULL, 63, parameters); + ZEPHIR_CALL_METHOD(&instance, reflection, "newinstanceargs", NULL, 65, parameters); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(instance); @@ -20309,9 +20411,9 @@ static PHP_METHOD(Phalcon_Di, get) { if (zephir_is_php_version(50600)) { ZEPHIR_INIT_NVAR(reflection); object_init_ex(reflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 62, name); + ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 64, name); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 64); + ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 66); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(instance); @@ -20323,9 +20425,9 @@ static PHP_METHOD(Phalcon_Di, get) { if (zephir_is_php_version(50600)) { ZEPHIR_INIT_NVAR(reflection); object_init_ex(reflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 62, name); + ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 64, name); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 64); + ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 66); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(instance); @@ -20577,7 +20679,7 @@ static PHP_METHOD(Phalcon_Di, __call) { ZVAL_LONG(&_0, 3); ZEPHIR_INIT_VAR(_1); zephir_substr(_1, method, 3 , 0, ZEPHIR_SUBSTR_NO_LENGTH); - ZEPHIR_CALL_FUNCTION(&possibleService, "lcfirst", &_2, 65, _1); + ZEPHIR_CALL_FUNCTION(&possibleService, "lcfirst", &_2, 67, _1); zephir_check_call_status(); if (zephir_array_isset(services, possibleService)) { if (zephir_fast_count_int(arguments TSRMLS_CC)) { @@ -20597,7 +20699,7 @@ static PHP_METHOD(Phalcon_Di, __call) { ZVAL_LONG(&_0, 3); ZEPHIR_INIT_NVAR(_1); zephir_substr(_1, method, 3 , 0, ZEPHIR_SUBSTR_NO_LENGTH); - ZEPHIR_CALL_FUNCTION(&_4, "lcfirst", &_2, 65, _1); + ZEPHIR_CALL_FUNCTION(&_4, "lcfirst", &_2, 67, _1); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, this_ptr, "set", NULL, 0, _4, definition); zephir_check_call_status(); @@ -20610,7 +20712,7 @@ static PHP_METHOD(Phalcon_Di, __call) { ZEPHIR_CONCAT_SVS(_5, "Call to undefined method or service '", method, "'"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _5); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/di.zep", 427 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/di.zep", 428 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -21646,13 +21748,13 @@ static PHP_METHOD(Phalcon_Escaper, detectEncoding) { ; zephir_hash_move_forward_ex(_3, &_2) ) { ZEPHIR_GET_HVALUE(charset, _4); - ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 178, str, charset, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 179, str, charset, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); if (zephir_is_true(_5)) { RETURN_CCTOR(charset); } } - ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 178, str); + ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 179, str); zephir_check_call_status(); RETURN_MM(); @@ -21674,11 +21776,11 @@ static PHP_METHOD(Phalcon_Escaper, normalizeEncoding) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_escaper_exception_ce, "Extension 'mbstring' is required", "phalcon/escaper.zep", 128); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 179, str); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 180, str); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "UTF-32", 0); - ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, str, &_1, _0); + ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 181, str, &_1, _0); zephir_check_call_status(); RETURN_MM(); @@ -21698,7 +21800,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeHtml) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_htmlQuoteType"), PH_NOISY_CC); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC); - ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, text, _0, _1); + ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 182, text, _0, _1); zephir_check_call_status(); RETURN_MM(); @@ -21719,7 +21821,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeHtmlAttr) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 3); - ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, attribute, &_1, _0); + ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 182, attribute, &_1, _0); zephir_check_call_status(); RETURN_MM(); @@ -21737,7 +21839,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeCss) { zephir_get_strval(css, css_param); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, css); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 183, css); zephir_check_call_status(); zephir_escape_css(return_value, _0); RETURN_MM(); @@ -21756,7 +21858,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeJs) { zephir_get_strval(js, js_param); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, js); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 183, js); zephir_check_call_status(); zephir_escape_js(return_value, _0); RETURN_MM(); @@ -21775,7 +21877,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeUrl) { zephir_get_strval(url, url_param); - ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 183, url); + ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 184, url); zephir_check_call_status(); RETURN_MM(); @@ -22054,16 +22156,16 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { if (ZEPHIR_IS_STRING(filter, "email")) { ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "FILTER_SANITIZE_EMAIL", 0); - ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 191, &_3); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, _4); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, _4); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "int")) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 519); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, &_3); zephir_check_call_status(); RETURN_MM(); } @@ -22073,14 +22175,14 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { if (ZEPHIR_IS_STRING(filter, "absint")) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, zephir_get_intval(value)); - ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 192, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 193, &_3); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "string")) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 513); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, &_3); zephir_check_call_status(); RETURN_MM(); } @@ -22090,7 +22192,7 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { add_assoc_long_ex(_2, SS("flags"), 4096); ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 520); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3, _2); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, &_3, _2); zephir_check_call_status(); RETURN_MM(); } @@ -22102,7 +22204,7 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { ZVAL_STRING(_6, "/[^A-Za-z0-9]/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_FUNCTION("preg_replace", NULL, 28, _6, _7, value); + ZEPHIR_RETURN_CALL_FUNCTION("preg_replace", NULL, 29, _6, _7, value); zephir_check_temp_parameter(_6); zephir_check_temp_parameter(_7); zephir_check_call_status(); @@ -22113,13 +22215,13 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "striptags")) { - ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 193, value); + ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 194, value); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "lower")) { if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, value); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 195, value); zephir_check_call_status(); RETURN_MM(); } @@ -22128,7 +22230,7 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) { } if (ZEPHIR_IS_STRING(filter, "upper")) { if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, value); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 196, value); zephir_check_call_status(); RETURN_MM(); } @@ -22909,7 +23011,7 @@ static PHP_METHOD(Phalcon_Loader, register) { ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "autoLoad", 1); zephir_array_fast_append(_1, _2); - ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 293, _1); + ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 286, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_registered"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } @@ -22933,7 +23035,7 @@ static PHP_METHOD(Phalcon_Loader, unregister) { ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "autoLoad", 1); zephir_array_fast_append(_1, _2); - ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 294, _1); + ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 287, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_registered"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } @@ -23041,7 +23143,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) { zephir_check_temp_parameter(_9); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath); + ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 288, filePath); zephir_check_call_status(); if (zephir_is_true(_11)) { if (Z_TYPE_P(eventsManager) == IS_OBJECT) { @@ -23112,7 +23214,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) { zephir_check_temp_parameter(_9); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath); + ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 288, filePath); zephir_check_call_status(); if (zephir_is_true(_11)) { if (Z_TYPE_P(eventsManager) == IS_OBJECT) { @@ -23170,7 +23272,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) { zephir_check_temp_parameter(_9); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath); + ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 288, filePath); zephir_check_call_status(); if (zephir_is_true(_11)) { if (Z_TYPE_P(eventsManager) == IS_OBJECT) { @@ -23423,7 +23525,7 @@ static PHP_METHOD(Phalcon_Registry, next) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 399, _0); + ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 392, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -23439,7 +23541,7 @@ static PHP_METHOD(Phalcon_Registry, key) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 400, _0); + ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 393, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); RETURN_MM(); @@ -23455,7 +23557,7 @@ static PHP_METHOD(Phalcon_Registry, rewind) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 401, _0); + ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 394, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -23471,7 +23573,7 @@ static PHP_METHOD(Phalcon_Registry, valid) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 400, _0); + ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 393, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); RETURN_MM_BOOL(Z_TYPE_P(_1) != IS_NULL); @@ -23487,7 +23589,7 @@ static PHP_METHOD(Phalcon_Registry, current) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 402, _0); + ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 395, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); RETURN_MM(); @@ -23516,7 +23618,7 @@ static PHP_METHOD(Phalcon_Registry, __set) { } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 403, key, value); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 396, key, value); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -23544,7 +23646,7 @@ static PHP_METHOD(Phalcon_Registry, __get) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 404, key); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 397, key); zephir_check_call_status(); RETURN_MM(); @@ -23572,7 +23674,7 @@ static PHP_METHOD(Phalcon_Registry, __isset) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 405, key); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 398, key); zephir_check_call_status(); RETURN_MM(); @@ -23600,7 +23702,7 @@ static PHP_METHOD(Phalcon_Registry, __unset) { } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 406, key); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 399, key); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -23756,9 +23858,9 @@ static PHP_METHOD(Phalcon_Security, getSaltBytes) { ZEPHIR_INIT_NVAR(safeBytes); ZEPHIR_INIT_NVAR(_1); ZVAL_LONG(_1, numberBytes); - ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 407, _1); + ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 400, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "base64_encode", &_5, 112, _2); + ZEPHIR_CALL_FUNCTION(&_4, "base64_encode", &_5, 114, _2); zephir_check_call_status(); zephir_filter_alphanum(safeBytes, _4); if (!(zephir_is_true(safeBytes))) { @@ -23848,7 +23950,7 @@ static PHP_METHOD(Phalcon_Security, hash) { } ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SVSV(_3, "$", variant, "$", saltBytes); - ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3); + ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 401, password, _3); zephir_check_call_status(); RETURN_MM(); } @@ -23871,11 +23973,11 @@ static PHP_METHOD(Phalcon_Security, hash) { ZVAL_STRING(&_5, "%02s", 0); ZEPHIR_SINIT_VAR(_6); ZVAL_LONG(&_6, workFactor); - ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 187, &_5, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 188, &_5, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVSVSV(_3, "$2", variant, "$", _7, "$", saltBytes); - ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3); + ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 401, password, _3); zephir_check_call_status(); RETURN_MM(); } while(0); @@ -23915,7 +24017,7 @@ static PHP_METHOD(Phalcon_Security, checkHash) { RETURN_MM_BOOL(0); } } - ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 408, password, passwordHash); + ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 401, password, passwordHash); zephir_check_call_status(); zephir_get_strval(_2, _1); ZEPHIR_CPY_WRT(cryptedHash, _2); @@ -23979,9 +24081,9 @@ static PHP_METHOD(Phalcon_Security, getTokenKey) { ZEPHIR_INIT_VAR(safeBytes); ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, numberBytes); - ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 407, _1); + ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 400, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_3, "base64_encode", NULL, 112, _2); + ZEPHIR_CALL_FUNCTION(&_3, "base64_encode", NULL, 114, _2); zephir_check_call_status(); zephir_filter_alphanum(safeBytes, _3); ZEPHIR_INIT_NVAR(_1); @@ -24021,9 +24123,9 @@ static PHP_METHOD(Phalcon_Security, getToken) { } ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, numberBytes); - ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 407, _0); + ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 400, _0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "base64_encode", NULL, 112, token); + ZEPHIR_CALL_FUNCTION(&_1, "base64_encode", NULL, 114, token); zephir_check_call_status(); ZEPHIR_CPY_WRT(token, _1); ZEPHIR_INIT_NVAR(_0); @@ -24194,7 +24296,7 @@ static PHP_METHOD(Phalcon_Security, computeHmac) { } - ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 409, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 402, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); if (!(zephir_is_true(hmac))) { ZEPHIR_INIT_VAR(_0); @@ -24985,7 +25087,7 @@ static PHP_METHOD(Phalcon_Tag, colorField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "color", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25005,7 +25107,7 @@ static PHP_METHOD(Phalcon_Tag, textField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "text", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25025,7 +25127,7 @@ static PHP_METHOD(Phalcon_Tag, numericField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "number", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25045,7 +25147,7 @@ static PHP_METHOD(Phalcon_Tag, rangeField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "range", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25065,7 +25167,7 @@ static PHP_METHOD(Phalcon_Tag, emailField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "email", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25085,7 +25187,7 @@ static PHP_METHOD(Phalcon_Tag, dateField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "date", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25105,7 +25207,7 @@ static PHP_METHOD(Phalcon_Tag, dateTimeField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "datetime", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25125,7 +25227,7 @@ static PHP_METHOD(Phalcon_Tag, dateTimeLocalField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "datetime-local", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25145,7 +25247,7 @@ static PHP_METHOD(Phalcon_Tag, monthField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "month", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25165,7 +25267,7 @@ static PHP_METHOD(Phalcon_Tag, timeField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "time", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25185,7 +25287,7 @@ static PHP_METHOD(Phalcon_Tag, weekField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "week", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25205,7 +25307,7 @@ static PHP_METHOD(Phalcon_Tag, passwordField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "password", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25225,7 +25327,7 @@ static PHP_METHOD(Phalcon_Tag, hiddenField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "hidden", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25245,7 +25347,7 @@ static PHP_METHOD(Phalcon_Tag, fileField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "file", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25265,7 +25367,7 @@ static PHP_METHOD(Phalcon_Tag, searchField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "search", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25285,7 +25387,7 @@ static PHP_METHOD(Phalcon_Tag, telField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "tel", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25305,7 +25407,7 @@ static PHP_METHOD(Phalcon_Tag, urlField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "url", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25325,7 +25427,7 @@ static PHP_METHOD(Phalcon_Tag, checkField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "checkbox", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 413, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25345,7 +25447,7 @@ static PHP_METHOD(Phalcon_Tag, radioField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "radio", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 413, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25367,7 +25469,7 @@ static PHP_METHOD(Phalcon_Tag, imageInput) { ZVAL_STRING(_1, "image", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters, _2); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25389,7 +25491,7 @@ static PHP_METHOD(Phalcon_Tag, submitButton) { ZVAL_STRING(_1, "submit", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters, _2); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -25410,7 +25512,7 @@ static PHP_METHOD(Phalcon_Tag, selectStatic) { } - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 207, parameters, data); zephir_check_call_status(); RETURN_MM(); @@ -25430,7 +25532,7 @@ static PHP_METHOD(Phalcon_Tag, select) { } - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 207, parameters, data); zephir_check_call_status(); RETURN_MM(); @@ -25934,20 +26036,20 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) { ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "iconv", 0); - ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", &_2, 126, &_0); + ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", &_2, 128, &_0); zephir_check_call_status(); if (zephir_is_true(_1)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "en_US.UTF-8", 0); - ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 415, &_0, &_3); + ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 414, &_0, &_3); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "UTF-8", 0); ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "ASCII//TRANSLIT", 0); - ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 378, &_0, &_3, text); + ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 371, &_0, &_3, text); zephir_check_call_status(); zephir_get_strval(text, _5); } @@ -25985,7 +26087,7 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) { ZVAL_STRING(_11, "/[^a-zA-Z0-9\\/_|+ -]/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_12); ZVAL_STRING(_12, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&friendly, "preg_replace", &_13, 28, _11, _12, text); + ZEPHIR_CALL_FUNCTION(&friendly, "preg_replace", &_13, 29, _11, _12, text); zephir_check_temp_parameter(_11); zephir_check_temp_parameter(_12); zephir_check_call_status(); @@ -25996,7 +26098,7 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) { } ZEPHIR_INIT_NVAR(_11); ZVAL_STRING(_11, "/[\\/_|+ -]+/", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_5, "preg_replace", &_13, 28, _11, separator, friendly); + ZEPHIR_CALL_FUNCTION(&_5, "preg_replace", &_13, 29, _11, separator, friendly); zephir_check_temp_parameter(_11); zephir_check_call_status(); ZEPHIR_CPY_WRT(friendly, _5); @@ -26005,12 +26107,12 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) { ZEPHIR_CPY_WRT(friendly, _11); ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "iconv", 0); - ZEPHIR_CALL_FUNCTION(&_5, "extension_loaded", &_2, 126, &_3); + ZEPHIR_CALL_FUNCTION(&_5, "extension_loaded", &_2, 128, &_3); zephir_check_call_status(); if (zephir_is_true(_5)) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 0); - ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 415, &_3, locale); + ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 414, &_3, locale); zephir_check_call_status(); } RETURN_CCTOR(friendly); @@ -26378,13 +26480,13 @@ static PHP_METHOD(Phalcon_Text, random) { ZVAL_STRING(&_0, "a", 0); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "z", 0); - ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "A", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "Z", 0); - ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_INIT_VAR(pool); zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC); @@ -26395,13 +26497,13 @@ static PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "a", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "f", 0); - ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(pool); zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC); @@ -26412,7 +26514,7 @@ static PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); break; } @@ -26421,7 +26523,7 @@ static PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 1); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); break; } @@ -26429,21 +26531,21 @@ static PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "a", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "z", 0); - ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "A", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "Z", 0); - ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 419, _2, _4, _5); + ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 418, _2, _4, _5); zephir_check_call_status(); break; } while(0); @@ -26547,7 +26649,7 @@ static PHP_METHOD(Phalcon_Text, lower) { if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, str, encoding); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 195, str, encoding); zephir_check_call_status(); RETURN_MM(); } @@ -26595,7 +26697,7 @@ static PHP_METHOD(Phalcon_Text, upper) { if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, str, encoding); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 196, str, encoding); zephir_check_call_status(); RETURN_MM(); } @@ -26620,7 +26722,7 @@ static PHP_METHOD(Phalcon_Text, reduceSlashes) { ZVAL_STRING(_0, "#(?funcs->dtor(_0 TSRMLS_CC); @@ -36378,7 +36504,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_File, __construct) { return; } } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_file_ce, this_ptr, "__construct", &_5, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_file_ce, this_ptr, "__construct", &_5, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -36570,7 +36696,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_File, delete) { ZEPHIR_INIT_VAR(cacheFile); ZEPHIR_CONCAT_VVV(cacheFile, cacheDir, _1, _2); if ((zephir_file_exists(cacheFile TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("unlink", NULL, 104, cacheFile); + ZEPHIR_RETURN_CALL_FUNCTION("unlink", NULL, 106, cacheFile); zephir_check_call_status(); RETURN_MM(); } @@ -36603,7 +36729,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_File, queryKeys) { } ZEPHIR_INIT_VAR(_2); object_init_ex(_2, spl_ce_DirectoryIterator); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 105, cacheDir); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 107, cacheDir); zephir_check_call_status(); _1 = zephir_get_iterator(_2 TSRMLS_CC); _1->funcs->rewind(_1 TSRMLS_CC); @@ -36859,7 +36985,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_File, flush) { } ZEPHIR_INIT_VAR(_2); object_init_ex(_2, spl_ce_DirectoryIterator); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 105, cacheDir); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 107, cacheDir); zephir_check_call_status(); _1 = zephir_get_iterator(_2 TSRMLS_CC); _1->funcs->rewind(_1 TSRMLS_CC); @@ -36881,7 +37007,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_File, flush) { _4 = zephir_start_with(key, prefix, NULL); } if (_4) { - ZEPHIR_CALL_FUNCTION(&_5, "unlink", &_6, 104, cacheFile); + ZEPHIR_CALL_FUNCTION(&_5, "unlink", &_6, 106, cacheFile); zephir_check_call_status(); if (!(zephir_is_true(_5))) { RETURN_MM_BOOL(0); @@ -36989,7 +37115,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Libmemcached, __construct) { ZVAL_STRING(_1, "_PHCM", 1); zephir_array_update_string(&options, SL("statsKey"), &_1, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_libmemcached_ce, this_ptr, "__construct", &_2, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_libmemcached_ce, this_ptr, "__construct", &_2, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -37553,7 +37679,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Memcache, __construct) { ZVAL_STRING(_0, "_PHCM", 1); zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_memcache_ce, this_ptr, "__construct", &_1, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_memcache_ce, this_ptr, "__construct", &_1, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -38374,7 +38500,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Memory, serialize) { ZEPHIR_OBS_VAR(_1); zephir_read_property_this(&_1, this_ptr, SL("_frontend"), PH_NOISY_CC); zephir_array_update_string(&_0, SL("frontend"), &_1, PH_COPY | PH_SEPARATE); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -38390,7 +38516,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Memory, unserialize) { - ZEPHIR_CALL_FUNCTION(&unserialized, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&unserialized, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(unserialized) != IS_ARRAY) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(zend_exception_get_default(TSRMLS_C), "Unserialized data must be an array", "phalcon/cache/backend/memory.zep", 295); @@ -38455,7 +38581,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, __construct) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "The parameter 'collection' is required", "phalcon/cache/backend/mongo.zep", 79); return; } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_mongo_ce, this_ptr, "__construct", &_0, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_mongo_ce, this_ptr, "__construct", &_0, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -38555,7 +38681,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, get) { zephir_time(_2); zephir_array_update_string(&_1, SL("$gt"), &_2, PH_COPY | PH_SEPARATE); zephir_array_update_string(&conditions, SL("time"), &_1, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&document, _3, "findone", NULL, 0, conditions); zephir_check_call_status(); @@ -38644,7 +38770,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, save) { } else { ZEPHIR_CPY_WRT(ttl, lifetime); } - ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_0); zephir_time(_0); @@ -38703,7 +38829,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, delete) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 1, 0 TSRMLS_CC); @@ -38713,7 +38839,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, delete) { zephir_array_update_string(&_1, SL("key"), &_3, PH_COPY | PH_SEPARATE); ZEPHIR_CALL_METHOD(NULL, _0, "remove", NULL, 0, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "rand", NULL, 107); + ZEPHIR_CALL_FUNCTION(&_4, "rand", NULL, 109); zephir_check_call_status(); if (zephir_safe_mod_long_long(zephir_get_intval(_4), 100 TSRMLS_CC) == 0) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "gc", NULL, 0); @@ -38759,7 +38885,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, queryKeys) { zephir_time(_0); zephir_array_update_string(&_2, SL("$gt"), &_0, PH_COPY | PH_SEPARATE); zephir_array_update_string(&conditions, SL("time"), &_2, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 1, 0 TSRMLS_CC); @@ -38817,7 +38943,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, exists) { ZEPHIR_CONCAT_VV(lastKey, _0, keyName); } if (zephir_is_true(lastKey)) { - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 2, 0 TSRMLS_CC); @@ -38844,7 +38970,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, gc) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 1, 0 TSRMLS_CC); @@ -38879,7 +39005,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, increment) { ZEPHIR_INIT_VAR(prefixedKey); ZEPHIR_CONCAT_VV(prefixedKey, _0, keyName); zephir_update_property_this(this_ptr, SL("_lastKey"), prefixedKey TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_2); zephir_create_array(_2, 1, 0 TSRMLS_CC); @@ -38930,7 +39056,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, decrement) { ZEPHIR_INIT_VAR(prefixedKey); ZEPHIR_CONCAT_VV(prefixedKey, _0, keyName); zephir_update_property_this(this_ptr, SL("_lastKey"), prefixedKey TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_2); zephir_create_array(_2, 1, 0 TSRMLS_CC); @@ -38969,11 +39095,11 @@ static PHP_METHOD(Phalcon_Cache_Backend_Mongo, flush) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _0, "remove", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "rand", NULL, 107); + ZEPHIR_CALL_FUNCTION(&_1, "rand", NULL, 109); zephir_check_call_status(); if (zephir_safe_mod_long_long(zephir_get_intval(_1), 100 TSRMLS_CC) == 0) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "gc", NULL, 0); @@ -39057,7 +39183,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Redis, __construct) { ZVAL_STRING(_0, "_PHCR", 1); zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_redis_ce, this_ptr, "__construct", &_3, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_redis_ce, this_ptr, "__construct", &_3, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -39075,8 +39201,10 @@ static PHP_METHOD(Phalcon_Cache_Backend_Redis, _connect) { zephir_read_property_this(&options, this_ptr, SL("_options"), PH_NOISY_CC); ZEPHIR_INIT_VAR(redis); object_init_ex(redis, zephir_get_internal_ce(SS("redis") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, redis, "__construct", NULL, 0); - zephir_check_call_status(); + if (zephir_has_constructor(redis TSRMLS_CC)) { + ZEPHIR_CALL_METHOD(NULL, redis, "__construct", NULL, 0); + zephir_check_call_status(); + } ZEPHIR_OBS_VAR(host); _0 = !(zephir_array_isset_string_fetch(&host, options, SS("host"), 0 TSRMLS_CC)); if (!(_0)) { @@ -39615,7 +39743,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, __construct) { ZVAL_STRING(_0, "_PHCX", 1); zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_xcache_ce, this_ptr, "__construct", &_1, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_xcache_ce, this_ptr, "__construct", &_1, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -39640,7 +39768,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, get) { ZEPHIR_INIT_VAR(prefixedKey); ZEPHIR_CONCAT_SVV(prefixedKey, "_PHCX", _0, keyName); zephir_update_property_this(this_ptr, SL("_lastKey"), prefixedKey TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&cachedContent, "xcache_get", NULL, 81, prefixedKey); + ZEPHIR_CALL_FUNCTION(&cachedContent, "xcache_get", NULL, 83, prefixedKey); zephir_check_call_status(); if (!(zephir_is_true(cachedContent))) { RETURN_MM_NULL(); @@ -39718,10 +39846,10 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, save) { ZEPHIR_CPY_WRT(tt1, lifetime); } if (zephir_is_numeric(cachedContent)) { - ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 82, lastKey, cachedContent, tt1); + ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 84, lastKey, cachedContent, tt1); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 82, lastKey, preparedContent, tt1); + ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 84, lastKey, preparedContent, tt1); zephir_check_call_status(); } ZEPHIR_CALL_METHOD(&isBuffering, frontend, "isbuffering", NULL, 0); @@ -39743,14 +39871,14 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, save) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Unexpected inconsistency in options", "phalcon/cache/backend/xcache.zep", 169); return; } - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) != IS_ARRAY) { ZEPHIR_INIT_NVAR(keys); array_init(keys); } zephir_array_update_zval(&keys, lastKey, &tt1, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", &_1, 82, specialKey, keys); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", &_1, 84, specialKey, keys); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -39776,14 +39904,14 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, delete) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Unexpected inconsistency in options", "phalcon/cache/backend/xcache.zep", 199); return; } - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) != IS_ARRAY) { ZEPHIR_INIT_NVAR(keys); array_init(keys); } zephir_array_unset(&keys, prefixedKey, PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, specialKey, keys); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, specialKey, keys); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -39820,7 +39948,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, queryKeys) { } ZEPHIR_INIT_VAR(retval); array_init(retval); - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) == IS_ARRAY) { ZEPHIR_INIT_VAR(_1); @@ -39869,7 +39997,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, exists) { ZEPHIR_CONCAT_SVV(lastKey, "_PHCX", _0, keyName); } if (zephir_is_true(lastKey)) { - ZEPHIR_RETURN_CALL_FUNCTION("xcache_isset", NULL, 108, lastKey); + ZEPHIR_RETURN_CALL_FUNCTION("xcache_isset", NULL, 110, lastKey); zephir_check_call_status(); RETURN_MM(); } @@ -39908,14 +40036,14 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, increment) { if ((zephir_function_exists_ex(SS("xcache_inc") TSRMLS_CC) == SUCCESS)) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, value); - ZEPHIR_CALL_FUNCTION(&newVal, "xcache_inc", NULL, 109, lastKey, &_1); + ZEPHIR_CALL_FUNCTION(&newVal, "xcache_inc", NULL, 111, lastKey, &_1); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 81, lastKey); + ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 83, lastKey); zephir_check_call_status(); ZEPHIR_INIT_NVAR(newVal); ZVAL_LONG(newVal, (zephir_get_numberval(origVal) - value)); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, lastKey, newVal); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, lastKey, newVal); zephir_check_call_status(); } RETURN_CCTOR(newVal); @@ -39953,14 +40081,14 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, decrement) { if ((zephir_function_exists_ex(SS("xcache_dec") TSRMLS_CC) == SUCCESS)) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, value); - ZEPHIR_CALL_FUNCTION(&newVal, "xcache_dec", NULL, 110, lastKey, &_1); + ZEPHIR_CALL_FUNCTION(&newVal, "xcache_dec", NULL, 112, lastKey, &_1); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 81, lastKey); + ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 83, lastKey); zephir_check_call_status(); ZEPHIR_INIT_NVAR(newVal); ZVAL_LONG(newVal, (zephir_get_numberval(origVal) - value)); - ZEPHIR_CALL_FUNCTION(&success, "xcache_set", NULL, 82, lastKey, newVal); + ZEPHIR_CALL_FUNCTION(&success, "xcache_set", NULL, 84, lastKey, newVal); zephir_check_call_status(); } RETURN_CCTOR(newVal); @@ -39985,7 +40113,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, flush) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Unexpected inconsistency in options", "phalcon/cache/backend/xcache.zep", 350); return; } - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) == IS_ARRAY) { ZEPHIR_INIT_VAR(_1); @@ -39997,10 +40125,10 @@ static PHP_METHOD(Phalcon_Cache_Backend_Xcache, flush) { ZEPHIR_GET_HMKEY(key, _3, _2); ZEPHIR_GET_HVALUE(_1, _4); zephir_array_unset(&keys, key, PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_unset", &_5, 111, key); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_unset", &_5, 113, key); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, specialKey, keys); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, specialKey, keys); zephir_check_call_status(); } RETURN_MM_BOOL(1); @@ -40098,7 +40226,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Base64, beforeStore) { - ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", NULL, 112, data); + ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", NULL, 114, data); zephir_check_call_status(); RETURN_MM(); @@ -40114,7 +40242,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Base64, afterRetrieve) { - ZEPHIR_RETURN_CALL_FUNCTION("base64_decode", NULL, 113, data); + ZEPHIR_RETURN_CALL_FUNCTION("base64_decode", NULL, 115, data); zephir_check_call_status(); RETURN_MM(); @@ -40211,7 +40339,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Data, beforeStore) { - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, data); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, data); zephir_check_call_status(); RETURN_MM(); @@ -40227,7 +40355,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Data, afterRetrieve) { - ZEPHIR_RETURN_CALL_FUNCTION("unserialize", NULL, 72, data); + ZEPHIR_RETURN_CALL_FUNCTION("unserialize", NULL, 74, data); zephir_check_call_status(); RETURN_MM(); @@ -40322,7 +40450,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Igbinary, beforeStore) { - ZEPHIR_RETURN_CALL_FUNCTION("igbinary_serialize", NULL, 114, data); + ZEPHIR_RETURN_CALL_FUNCTION("igbinary_serialize", NULL, 116, data); zephir_check_call_status(); RETURN_MM(); @@ -40338,7 +40466,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Igbinary, afterRetrieve) { - ZEPHIR_RETURN_CALL_FUNCTION("igbinary_unserialize", NULL, 115, data); + ZEPHIR_RETURN_CALL_FUNCTION("igbinary_unserialize", NULL, 117, data); zephir_check_call_status(); RETURN_MM(); @@ -40603,7 +40731,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Output, start) { ZEPHIR_MM_GROW(); zephir_update_property_this(this_ptr, SL("_buffering"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -40618,7 +40746,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Output, getContent) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_buffering"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_contents", NULL, 117); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_contents", NULL, 119); zephir_check_call_status(); RETURN_MM(); } @@ -40635,7 +40763,7 @@ static PHP_METHOD(Phalcon_Cache_Frontend_Output, stop) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_buffering"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); } zephir_update_property_this(this_ptr, SL("_buffering"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); @@ -41025,7 +41153,7 @@ static PHP_METHOD(Phalcon_Cli_Console, setArgument) { } if (_0) { Z_SET_ISREF_P(arguments); - ZEPHIR_CALL_FUNCTION(NULL, "array_shift", &_1, 119, arguments); + ZEPHIR_CALL_FUNCTION(NULL, "array_shift", &_1, 121, arguments); Z_UNSET_ISREF_P(arguments); zephir_check_call_status(); } @@ -41040,7 +41168,7 @@ static PHP_METHOD(Phalcon_Cli_Console, setArgument) { ZVAL_STRING(&_5, "--", 0); ZEPHIR_SINIT_NVAR(_6); ZVAL_LONG(&_6, 2); - ZEPHIR_CALL_FUNCTION(&_7, "strncmp", &_8, 120, arg, &_5, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "strncmp", &_8, 122, arg, &_5, &_6); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_7, 0)) { ZEPHIR_SINIT_NVAR(_5); @@ -41077,7 +41205,7 @@ static PHP_METHOD(Phalcon_Cli_Console, setArgument) { ZVAL_STRING(&_12, "-", 0); ZEPHIR_SINIT_NVAR(_13); ZVAL_LONG(&_13, 1); - ZEPHIR_CALL_FUNCTION(&_15, "strncmp", &_8, 120, arg, &_12, &_13); + ZEPHIR_CALL_FUNCTION(&_15, "strncmp", &_8, 122, arg, &_12, &_13); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_15, 0)) { ZEPHIR_SINIT_NVAR(_12); @@ -41095,21 +41223,21 @@ static PHP_METHOD(Phalcon_Cli_Console, setArgument) { } if (str) { ZEPHIR_INIT_NVAR(_9); - ZEPHIR_CALL_CE_STATIC(&_7, phalcon_cli_router_route_ce, "getdelimiter", &_16, 121); + ZEPHIR_CALL_CE_STATIC(&_7, phalcon_cli_router_route_ce, "getdelimiter", &_16, 123); zephir_check_call_status(); zephir_fast_join(_9, _7, args TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_arguments"), _9 TSRMLS_CC); } else { if (zephir_fast_count_int(args TSRMLS_CC)) { Z_SET_ISREF_P(args); - ZEPHIR_CALL_FUNCTION(&_15, "array_shift", &_1, 119, args); + ZEPHIR_CALL_FUNCTION(&_15, "array_shift", &_1, 121, args); Z_UNSET_ISREF_P(args); zephir_check_call_status(); zephir_array_update_string(&handleArgs, SL("task"), &_15, PH_COPY | PH_SEPARATE); } if (zephir_fast_count_int(args TSRMLS_CC)) { Z_SET_ISREF_P(args); - ZEPHIR_CALL_FUNCTION(&_7, "array_shift", &_1, 119, args); + ZEPHIR_CALL_FUNCTION(&_7, "array_shift", &_1, 121, args); Z_UNSET_ISREF_P(args); zephir_check_call_status(); zephir_array_update_string(&handleArgs, SL("action"), &_7, PH_COPY | PH_SEPARATE); @@ -41167,7 +41295,7 @@ static PHP_METHOD(Phalcon_Cli_Dispatcher, __construct) { ZEPHIR_INIT_VAR(_0); array_init(_0); zephir_update_property_this(this_ptr, SL("_options"), _0 TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_cli_dispatcher_ce, this_ptr, "__construct", &_1, 122); + ZEPHIR_CALL_PARENT(NULL, phalcon_cli_dispatcher_ce, this_ptr, "__construct", &_1, 124); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -41402,7 +41530,7 @@ static PHP_METHOD(Phalcon_Cli_Router, __construct) { add_assoc_long_ex(_1, SS("task"), 1); ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "#^(?::delimiter)?([a-zA-Z0-9\\_\\-]+)[:delimiter]{0,1}$#", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 123, _2, _1); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 125, _2, _1); zephir_check_temp_parameter(_2); zephir_check_call_status(); zephir_array_append(&routes, _0, PH_SEPARATE, "phalcon/cli/router.zep", 90); @@ -41415,7 +41543,7 @@ static PHP_METHOD(Phalcon_Cli_Router, __construct) { add_assoc_long_ex(_4, SS("params"), 3); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "#^(?::delimiter)?([a-zA-Z0-9\\_\\-]+):delimiter([a-zA-Z0-9\\.\\_]+)(:delimiter.*)*$#", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 123, _5, _4); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 125, _5, _4); zephir_check_temp_parameter(_5); zephir_check_call_status(); zephir_array_append(&routes, _2, PH_SEPARATE, "phalcon/cli/router.zep", 96); @@ -41702,7 +41830,7 @@ static PHP_METHOD(Phalcon_Cli_Router, handle) { ZEPHIR_INIT_VAR(strParams); zephir_substr(strParams, _15, 1 , 0, ZEPHIR_SUBSTR_NO_LENGTH); if (zephir_is_true(strParams)) { - ZEPHIR_CALL_CE_STATIC(&_17, phalcon_cli_router_route_ce, "getdelimiter", &_18, 121); + ZEPHIR_CALL_CE_STATIC(&_17, phalcon_cli_router_route_ce, "getdelimiter", &_18, 123); zephir_check_call_status(); ZEPHIR_INIT_NVAR(params); zephir_fast_explode(params, _17, strParams, LONG_MAX TSRMLS_CC); @@ -41758,7 +41886,7 @@ static PHP_METHOD(Phalcon_Cli_Router, add) { ZEPHIR_INIT_VAR(route); object_init_ex(route, phalcon_cli_router_route_ce); - ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 123, pattern, paths); + ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 125, pattern, paths); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_routes"), route TSRMLS_CC); RETURN_CCTOR(route); @@ -42788,7 +42916,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Ini, __construct) { } - ZEPHIR_CALL_FUNCTION(&iniConfig, "parse_ini_file", NULL, 124, filePath, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&iniConfig, "parse_ini_file", NULL, 126, filePath, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(iniConfig)) { ZEPHIR_INIT_VAR(_0); @@ -42838,7 +42966,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Ini, __construct) { zephir_array_update_zval(&config, section, &directives, PH_COPY | PH_SEPARATE); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_ini_ce, this_ptr, "__construct", &_12, 21, config); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_ini_ce, this_ptr, "__construct", &_12, 22, config); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -42885,7 +43013,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Ini, _parseIniString) { zephir_substr(_3, path, zephir_get_intval(&_2), 0, ZEPHIR_SUBSTR_NO_LENGTH); zephir_get_strval(path, _3); zephir_create_array(return_value, 1, 0 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "_parseinistring", NULL, 125, path, value); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "_parseinistring", NULL, 127, path, value); zephir_check_call_status(); zephir_array_update_zval(&return_value, key, &_4, PH_COPY); RETURN_MM(); @@ -42941,7 +43069,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Json, __construct) { ZEPHIR_INIT_VAR(_2); zephir_file_get_contents(_2, filePath TSRMLS_CC); zephir_json_decode(_1, &(_1), _2, zephir_get_intval(ZEPHIR_GLOBAL(global_true)) TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_json_ce, this_ptr, "__construct", &_0, 21, _1); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_json_ce, this_ptr, "__construct", &_0, 22, _1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -42996,7 +43124,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Php, __construct) { if (zephir_require_zval_ret(&_1, filePath TSRMLS_CC) == FAILURE) { RETURN_MM_NULL(); } - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_php_ce, this_ptr, "__construct", &_0, 21, _1); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_php_ce, this_ptr, "__construct", &_0, 22, _1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -43057,7 +43185,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Yaml, __construct) { ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "yaml", 0); - ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", NULL, 126, &_0); + ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", NULL, 128, &_0); zephir_check_call_status(); if (!(zephir_is_true(_1))) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_config_exception_ce, "Yaml extension not loaded", "phalcon/config/adapter/yaml.zep", 62); @@ -43069,11 +43197,11 @@ static PHP_METHOD(Phalcon_Config_Adapter_Yaml, __construct) { ZEPHIR_INIT_VAR(_3); ZVAL_LONG(_3, ndocs); Z_SET_ISREF_P(_3); - ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 127, filePath, _2, _3, callbacks); + ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 129, filePath, _2, _3, callbacks); Z_UNSET_ISREF_P(_3); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 127, filePath); + ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 129, filePath); zephir_check_call_status(); } if (ZEPHIR_IS_FALSE_IDENTICAL(yamlConfig)) { @@ -43089,7 +43217,7 @@ static PHP_METHOD(Phalcon_Config_Adapter_Yaml, __construct) { ZEPHIR_MM_RESTORE(); return; } - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_yaml_ce, this_ptr, "__construct", &_6, 21, yamlConfig); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_yaml_ce, this_ptr, "__construct", &_6, 22, yamlConfig); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -45708,7 +45836,7 @@ static PHP_METHOD(Phalcon_Db_Column, __set_state) { zephir_array_update_string(&definition, SL("bindType"), &bindType, PH_COPY | PH_SEPARATE); } object_init_ex(return_value, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 140, columnName, definition); zephir_check_call_status(); RETURN_MM(); @@ -46036,7 +46164,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getColumnList) { ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(column, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlcolumn", &_4, 29, column, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlcolumn", &_4, 30, column, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_append(&columns, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 158); } @@ -46164,17 +46292,17 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpression) { } do { if (ZEPHIR_IS_STRING(type, "scalar")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionscalar", NULL, 30, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionscalar", NULL, 31, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "object")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionobject", NULL, 31, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionobject", NULL, 32, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "qualified")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionqualified", NULL, 32, expression, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionqualified", NULL, 33, expression, escapeChar); zephir_check_call_status(); RETURN_MM(); } @@ -46223,34 +46351,34 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpression) { RETURN_CTOR(_0); } if (ZEPHIR_IS_STRING(type, "binary-op")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionbinaryoperations", NULL, 33, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionbinaryoperations", NULL, 34, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "unary-op")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionunaryoperations", NULL, 34, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionunaryoperations", NULL, 35, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "parentheses")) { zephir_array_fetch_string(&_0, expression, SL("left"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 305 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_6, this_ptr, "getsqlexpression", NULL, 35, _0, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_6, this_ptr, "getsqlexpression", NULL, 36, _0, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "(", _6, ")"); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "functionCall")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionfunctioncall", NULL, 36, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionfunctioncall", NULL, 37, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "list")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionlist", NULL, 37, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionlist", NULL, 38, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "all")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionall", NULL, 38, expression, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionall", NULL, 39, expression, escapeChar); zephir_check_call_status(); RETURN_MM(); } @@ -46262,17 +46390,17 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpression) { RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "cast")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncastvalue", NULL, 39, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncastvalue", NULL, 40, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "convert")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionconvertvalue", NULL, 40, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionconvertvalue", NULL, 41, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "case")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncase", NULL, 41, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncase", NULL, 42, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } @@ -46318,7 +46446,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlTable) { zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", NULL, 42, table, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", NULL, 43, table, escapeChar); zephir_check_call_status(); RETURN_MM(); @@ -46364,12 +46492,12 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { zephir_array_isset_string_fetch(&bindCounts, definition, SS("bindCounts"), 0 TSRMLS_CC); ZEPHIR_OBS_VAR(escapeChar); zephir_read_property_this(&escapeChar, this_ptr, SL("_escapeChar"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 43, columns, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 44, columns, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SV(_1, " ", _0); zephir_concat_self(&sql, _1 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "getsqlexpressionfrom", NULL, 44, tables, escapeChar); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "getsqlexpressionfrom", NULL, 45, tables, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SV(_3, " ", _2); @@ -46381,7 +46509,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { } if (_4) { zephir_array_fetch_string(&_6, definition, SL("joins"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 429 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionjoins", NULL, 45, _6, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionjoins", NULL, 46, _6, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -46393,7 +46521,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { _8 = zephir_is_true(where); } if (_8) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionwhere", NULL, 46, where, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionwhere", NULL, 47, where, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -46405,7 +46533,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { _9 = zephir_is_true(groupBy); } if (_9) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressiongroupby", NULL, 47, groupBy, escapeChar); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressiongroupby", NULL, 48, groupBy, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -46417,7 +46545,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { _10 = zephir_is_true(having); } if (_10) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionhaving", NULL, 48, having, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionhaving", NULL, 49, having, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -46429,7 +46557,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { _11 = zephir_is_true(orderBy); } if (_11) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionorderby", NULL, 49, orderBy, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionorderby", NULL, 50, orderBy, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -46445,7 +46573,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, select) { zephir_create_array(_13, 2, 0 TSRMLS_CC); zephir_array_update_string(&_13, SL("sql"), &sql, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_13, SL("value"), &limit, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&sql, this_ptr, "getsqlexpressionlimit", NULL, 50, _13, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&sql, this_ptr, "getsqlexpressionlimit", NULL, 51, _13, escapeChar, bindCounts); zephir_check_call_status(); } _14 = zephir_array_isset_string_fetch(&forUpdate, definition, SS("forUpdate"), 1 TSRMLS_CC); @@ -46581,7 +46709,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionScalar) { if (zephir_array_isset_string(expression, SS("column"))) { zephir_array_fetch_string(&_0, expression, SL("column"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 525 TSRMLS_CC); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlcolumn", NULL, 29, _0); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlcolumn", NULL, 30, _0); zephir_check_call_status(); RETURN_MM(); } @@ -46708,7 +46836,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionBinaryOperations) { ZEPHIR_CALL_METHOD(&left, this_ptr, "getsqlexpression", &_1, 0, _0, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_2, expression, SL("right"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 583 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 35, _2, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 36, _2, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_3, expression, SL("op"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 585 TSRMLS_CC); ZEPHIR_CONCAT_VSVSV(return_value, left, " ", _3, " ", right); @@ -46751,7 +46879,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionUnaryOperations) { ZEPHIR_OBS_VAR(right); if (zephir_array_isset_string_fetch(&right, expression, SS("right"), 0 TSRMLS_CC)) { zephir_array_fetch_string(&_2, expression, SL("op"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 606 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getsqlexpression", &_1, 35, right, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getsqlexpression", &_1, 36, right, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_VSV(return_value, _2, " ", _0); RETURN_MM(); @@ -46955,7 +47083,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionCastValue) { ZEPHIR_CALL_METHOD(&left, this_ptr, "getsqlexpression", &_1, 0, _0, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_2, expression, SL("right"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 693 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 35, _2, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 36, _2, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "CAST(", left, " AS ", right, ")"); RETURN_MM(); @@ -46990,7 +47118,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionConvertValue) { ZEPHIR_CALL_METHOD(&left, this_ptr, "getsqlexpression", &_1, 0, _0, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_2, expression, SL("right"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 706 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 35, _2, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 36, _2, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "CONVERT(", left, " USING ", right, ")"); RETURN_MM(); @@ -47038,17 +47166,17 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionCase) { zephir_array_fetch_string(&_7, whenClause, SL("type"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 721 TSRMLS_CC); if (ZEPHIR_IS_STRING(_7, "when")) { zephir_array_fetch_string(&_9, whenClause, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 723 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 35, _9, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 36, _9, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_11, whenClause, SL("then"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 725 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_10, this_ptr, "getsqlexpression", &_2, 35, _11, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "getsqlexpression", &_2, 36, _11, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SVSV(_12, " WHEN ", _8, " THEN ", _10); zephir_concat_self(&sql, _12 TSRMLS_CC); } else { zephir_array_fetch_string(&_9, whenClause, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 727 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 35, _9, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 36, _9, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SV(_12, " ELSE ", _8); @@ -47089,7 +47217,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionFrom) { ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(table, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqltable", &_4, 51, table, escapeChar); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqltable", &_4, 52, table, escapeChar); zephir_check_call_status(); zephir_array_append(&tables, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 746); } @@ -47156,7 +47284,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionJoins) { ; zephir_hash_move_forward_ex(_6, &_5) ) { ZEPHIR_GET_HVALUE(condition, _7); - ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_4, 35, condition, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_4, 36, condition, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_append(&joinCondition, _8, PH_SEPARATE, "phalcon/db/dialect.zep", 779); } @@ -47177,7 +47305,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionJoins) { zephir_concat_self_str(&joinType, SL(" ") TSRMLS_CC); } zephir_array_fetch_string(&_11, join, SL("source"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 792 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&joinTable, this_ptr, "getsqltable", &_12, 51, _11, escapeChar); + ZEPHIR_CALL_METHOD(&joinTable, this_ptr, "getsqltable", &_12, 52, _11, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_13); ZEPHIR_CONCAT_SVSVSV(_13, " ", joinType, "JOIN ", joinTable, " ON ", joinCondition); @@ -47415,7 +47543,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionLimit) { _3 = Z_TYPE_P(offset) == IS_ARRAY; } if (_3) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getsqlexpression", &_2, 35, offset, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getsqlexpression", &_2, 36, offset, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CPY_WRT(offset, _4); } @@ -47467,7 +47595,7 @@ static PHP_METHOD(Phalcon_Db_Dialect, prepareColumnAlias) { if (!ZEPHIR_IS_STRING(alias, "")) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", NULL, 42, alias, escapeChar); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", NULL, 43, alias, escapeChar); zephir_check_call_status(); ZEPHIR_CONCAT_VSV(return_value, qualified, " AS ", _0); RETURN_MM(); @@ -47517,18 +47645,18 @@ static PHP_METHOD(Phalcon_Db_Dialect, prepareTable) { } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", &_1, 42, table, escapeChar); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", &_1, 43, table, escapeChar); zephir_check_call_status(); zephir_get_strval(table, _0); if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 42, schema, escapeChar); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 43, schema, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_VSV(_3, _2, ".", table); zephir_get_strval(table, _3); } if (!ZEPHIR_IS_STRING(alias, "")) { - ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 42, alias, escapeChar); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 43, alias, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_VSV(_3, table, " AS ", _2); @@ -47576,11 +47704,11 @@ static PHP_METHOD(Phalcon_Db_Dialect, prepareQualified) { if (!ZEPHIR_IS_STRING(domain, "")) { ZEPHIR_INIT_VAR(_0); ZEPHIR_CONCAT_VSV(_0, domain, ".", column); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 42, _0, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 43, _0, escapeChar); zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 42, column, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 43, column, escapeChar); zephir_check_call_status(); RETURN_MM(); @@ -47890,19 +48018,19 @@ static PHP_METHOD(Phalcon_Db_Profiler, startProfile) { ZEPHIR_CALL_METHOD(NULL, activeProfile, "__construct", NULL, 0); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 144, sqlStatement); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 145, sqlStatement); zephir_check_call_status(); if (Z_TYPE_P(sqlVariables) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 145, sqlVariables); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 146, sqlVariables); zephir_check_call_status(); } if (Z_TYPE_P(sqlBindTypes) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 146, sqlBindTypes); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 147, sqlBindTypes); zephir_check_call_status(); } ZEPHIR_INIT_VAR(_0); zephir_microtime(_0, ZEPHIR_GLOBAL(global_true) TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 147, _0); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 148, _0); zephir_check_call_status(); if ((zephir_method_exists_ex(this_ptr, SS("beforestartprofile") TSRMLS_CC) == SUCCESS)) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "beforestartprofile", NULL, 0, activeProfile); @@ -48397,7 +48525,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo, __construct) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "connect", NULL, 0, descriptor); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_ce, this_ptr, "__construct", &_0, 24, descriptor); + ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_ce, this_ptr, "__construct", &_0, 25, descriptor); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -48571,7 +48699,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo, executePrepared) { if (ZEPHIR_IS_LONG(type, 1)) { ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 10); - ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_5, 25, value, &_4); + ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_5, 26, value, &_4); zephir_check_call_status(); break; } @@ -48723,7 +48851,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo, query) { zephir_check_call_status(); } object_init_ex(return_value, phalcon_db_result_pdo_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 26, this_ptr, statement, sqlStatement, bindParams, bindTypes); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 27, this_ptr, statement, sqlStatement, bindParams, bindTypes); zephir_check_call_status(); RETURN_MM(); } @@ -48904,7 +49032,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo, convertBoundParams) { ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, setOrder); Z_SET_ISREF_P(matches); - ZEPHIR_CALL_FUNCTION(&_1, "preg_match_all", NULL, 27, bindPattern, sql, matches, _0); + ZEPHIR_CALL_FUNCTION(&_1, "preg_match_all", NULL, 28, bindPattern, sql, matches, _0); Z_UNSET_ISREF_P(matches); zephir_check_call_status(); if (zephir_is_true(_1)) { @@ -48933,7 +49061,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo, convertBoundParams) { } ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "?", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&boundSql, "preg_replace", NULL, 28, bindPattern, _0, sql); + ZEPHIR_CALL_FUNCTION(&boundSql, "preg_replace", NULL, 29, bindPattern, _0, sql); zephir_check_temp_parameter(_0); zephir_check_call_status(); } else { @@ -49521,7 +49649,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Mysql, describeColumns) { zephir_array_fetch_long(&columnName, field, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/mysql.zep", 324 TSRMLS_CC); ZEPHIR_INIT_NVAR(_7); object_init_ex(_7, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_15, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_15, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter/pdo/mysql.zep", 325); ZEPHIR_CPY_WRT(oldColumn, columnName); @@ -49579,7 +49707,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Oracle, connect) { ZEPHIR_OBS_NVAR(descriptor); zephir_read_property_this(&descriptor, this_ptr, SL("_descriptor"), PH_NOISY_CC); } - ZEPHIR_CALL_PARENT(&status, phalcon_db_adapter_pdo_oracle_ce, this_ptr, "connect", &_0, 139, descriptor); + ZEPHIR_CALL_PARENT(&status, phalcon_db_adapter_pdo_oracle_ce, this_ptr, "connect", &_0, 141, descriptor); zephir_check_call_status(); ZEPHIR_OBS_VAR(startup); if (zephir_array_isset_string_fetch(&startup, descriptor, SS("startup"), 0 TSRMLS_CC)) { @@ -49753,7 +49881,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Oracle, describeColumns) { zephir_array_fetch_long(&columnName, field, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/oracle.zep", 194 TSRMLS_CC); ZEPHIR_INIT_NVAR(_8); object_init_ex(_8, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _8, "__construct", &_11, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _8, "__construct", &_11, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _8, PH_SEPARATE, "phalcon/db/adapter/pdo/oracle.zep", 199); ZEPHIR_CPY_WRT(oldColumn, columnName); @@ -49888,7 +50016,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, connect) { zephir_array_update_string(&descriptor, SL("password"), &ZEPHIR_GLOBAL(global_null), PH_COPY | PH_SEPARATE); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_postgresql_ce, this_ptr, "connect", &_3, 139, descriptor); + ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_postgresql_ce, this_ptr, "connect", &_3, 141, descriptor); zephir_check_call_status(); if (!(ZEPHIR_IS_EMPTY(schema))) { ZEPHIR_INIT_VAR(sql); @@ -50108,7 +50236,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, describeColumns) { ZVAL_STRING(_8, "/^'|'?::[[:alnum:][:space:]]+$/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_9); ZVAL_STRING(_9, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_15, "preg_replace", &_16, 28, _8, _9, _14); + ZEPHIR_CALL_FUNCTION(&_15, "preg_replace", &_16, 29, _8, _9, _14); zephir_check_temp_parameter(_8); zephir_check_temp_parameter(_9); zephir_check_call_status(); @@ -50116,7 +50244,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, describeColumns) { zephir_array_fetch_string(&_17, definition, SL("default"), PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/postgresql.zep", 305 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_18); ZVAL_STRING(&_18, "null", 0); - ZEPHIR_CALL_FUNCTION(&_19, "strcasecmp", &_20, 140, _17, &_18); + ZEPHIR_CALL_FUNCTION(&_19, "strcasecmp", &_20, 19, _17, &_18); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_19, 0)) { zephir_array_update_string(&definition, SL("default"), &ZEPHIR_GLOBAL(global_null), PH_COPY | PH_SEPARATE); @@ -50125,7 +50253,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, describeColumns) { zephir_array_fetch_long(&columnName, field, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/postgresql.zep", 313 TSRMLS_CC); ZEPHIR_INIT_NVAR(_7); object_init_ex(_7, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter/pdo/postgresql.zep", 314); ZEPHIR_CPY_WRT(oldColumn, columnName); @@ -50418,7 +50546,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, connect) { return; } zephir_array_update_string(&descriptor, SL("dsn"), &dbname, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_sqlite_ce, this_ptr, "connect", &_0, 139, descriptor); + ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_sqlite_ce, this_ptr, "connect", &_0, 141, descriptor); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -50616,7 +50744,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, describeColumns) { zephir_array_fetch_long(&_13, field, 4, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/sqlite.zep", 279 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "null", 0); - ZEPHIR_CALL_FUNCTION(&_15, "strcasecmp", &_16, 140, _13, &_14); + ZEPHIR_CALL_FUNCTION(&_15, "strcasecmp", &_16, 19, _13, &_14); zephir_check_call_status(); _9 = !ZEPHIR_IS_LONG(_15, 0); if (_9) { @@ -50629,7 +50757,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, describeColumns) { ZVAL_STRING(_7, "/^'|'$/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_8); ZVAL_STRING(_8, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_19, "preg_replace", &_20, 28, _7, _8, _18); + ZEPHIR_CALL_FUNCTION(&_19, "preg_replace", &_20, 29, _7, _8, _18); zephir_check_temp_parameter(_7); zephir_check_temp_parameter(_8); zephir_check_call_status(); @@ -50638,7 +50766,7 @@ static PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, describeColumns) { zephir_array_fetch_long(&columnName, field, 1, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/sqlite.zep", 286 TSRMLS_CC); ZEPHIR_INIT_NVAR(_7); object_init_ex(_7, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter/pdo/sqlite.zep", 287); ZEPHIR_CPY_WRT(oldColumn, columnName); @@ -51093,7 +51221,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) { ZEPHIR_GET_HVALUE(value, _7); ZEPHIR_SINIT_NVAR(_8); ZVAL_STRING(&_8, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_9, 141, value, &_8); + ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_9, 142, value, &_8); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "\"", _0, "\", "); @@ -51111,7 +51239,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) { } else { ZEPHIR_SINIT_NVAR(_10); ZVAL_STRING(&_10, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_9, 141, typeValues, &_10); + ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_9, 142, typeValues, &_10); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, "(\"", _2, "\")"); @@ -51170,7 +51298,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 142, defaultValue, &_3); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\""); @@ -51247,7 +51375,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 142, defaultValue, &_3); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\""); @@ -51363,7 +51491,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 43, _4); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 44, _4); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSVS(_1, "`", _2, "` (", _3, ")"); @@ -51460,7 +51588,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addPrimaryKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 44, _2); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD PRIMARY KEY (", _1, ")"); RETURN_MM(); @@ -51546,7 +51674,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 43, _3); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 44, _3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_5, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); @@ -51556,7 +51684,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_8, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 43, _8); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 44, _8); zephir_check_call_status(); ZEPHIR_INIT_VAR(sql); ZEPHIR_CONCAT_SVSVSVSVSVS(sql, "ALTER TABLE ", _0, " ADD FOREIGN KEY `", _1, "`(", _2, ") REFERENCES ", _4, "(", _7, ")"); @@ -51707,7 +51835,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_NVAR(_6); ZVAL_STRING(&_6, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 142, defaultValue, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\""); @@ -51745,7 +51873,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) { ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_13, 43, _4); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_13, 44, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(indexSql); ZEPHIR_CONCAT_SVS(indexSql, "PRIMARY KEY (", _3, ")"); @@ -51754,13 +51882,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { if (!(ZEPHIR_IS_EMPTY(indexType))) { ZEPHIR_CALL_METHOD(&_14, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_13, 43, _14); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_13, 44, _14); zephir_check_call_status(); ZEPHIR_CONCAT_VSVSVS(indexSql, indexType, " KEY `", indexName, "` (", _7, ")"); } else { ZEPHIR_CALL_METHOD(&_15, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_14, this_ptr, "getcolumnlist", &_13, 43, _15); + ZEPHIR_CALL_METHOD(&_14, this_ptr, "getcolumnlist", &_13, 44, _15); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(indexSql, "KEY `", indexName, "` (", _14, ")"); } @@ -51780,13 +51908,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_13, 43, _7); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_13, 44, _7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_14, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_13, 43, _19); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_13, 44, _19); zephir_check_call_status(); ZEPHIR_INIT_NVAR(referenceSql); ZEPHIR_CONCAT_SVSVSSVSVS(referenceSql, "CONSTRAINT `", _3, "` FOREIGN KEY (", _4, ")", " REFERENCES `", _14, "`(", _15, ")"); @@ -53016,14 +53144,14 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, viewExists) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, viewName); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_VIEWS WHERE VIEW_NAME='", _0, "' AND OWNER='", _2, "'"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, viewName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_VIEWS WHERE VIEW_NAME='", _0, "'"); RETURN_MM(); @@ -53049,7 +53177,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, listViews) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT VIEW_NAME FROM ALL_VIEWS WHERE OWNER='", _0, "' ORDER BY VIEW_NAME"); RETURN_MM(); @@ -53088,14 +53216,14 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, tableExists) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, tableName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, tableName); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_TABLES WHERE TABLE_NAME='", _0, "' AND OWNER = '", _2, "'"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, tableName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, tableName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_TABLES WHERE TABLE_NAME='", _0, "'"); RETURN_MM(); @@ -53132,14 +53260,14 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeColumns) { if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schema); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT TC.COLUMN_NAME, TC.DATA_TYPE, TC.DATA_LENGTH, TC.DATA_PRECISION, TC.DATA_SCALE, TC.NULLABLE, C.CONSTRAINT_TYPE, TC.DATA_DEFAULT, CC.POSITION FROM ALL_TAB_COLUMNS TC LEFT JOIN (ALL_CONS_COLUMNS CC JOIN ALL_CONSTRAINTS C ON (CC.CONSTRAINT_NAME = C.CONSTRAINT_NAME AND CC.TABLE_NAME = C.TABLE_NAME AND CC.OWNER = C.OWNER AND C.CONSTRAINT_TYPE = 'P')) ON TC.TABLE_NAME = CC.TABLE_NAME AND TC.COLUMN_NAME = CC.COLUMN_NAME WHERE TC.TABLE_NAME = '", _0, "' AND TC.OWNER = '", _2, "' ORDER BY TC.COLUMN_ID"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT TC.COLUMN_NAME, TC.DATA_TYPE, TC.DATA_LENGTH, TC.DATA_PRECISION, TC.DATA_SCALE, TC.NULLABLE, C.CONSTRAINT_TYPE, TC.DATA_DEFAULT, CC.POSITION FROM ALL_TAB_COLUMNS TC LEFT JOIN (ALL_CONS_COLUMNS CC JOIN ALL_CONSTRAINTS C ON (CC.CONSTRAINT_NAME = C.CONSTRAINT_NAME AND CC.TABLE_NAME = C.TABLE_NAME AND CC.OWNER = C.OWNER AND C.CONSTRAINT_TYPE = 'P')) ON TC.TABLE_NAME = CC.TABLE_NAME AND TC.COLUMN_NAME = CC.COLUMN_NAME WHERE TC.TABLE_NAME = '", _0, "' ORDER BY TC.COLUMN_ID"); RETURN_MM(); @@ -53165,7 +53293,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, listTables) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT TABLE_NAME, OWNER FROM ALL_TABLES WHERE OWNER='", _0, "' ORDER BY OWNER, TABLE_NAME"); RETURN_MM(); @@ -53204,14 +53332,14 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeIndexes) { if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schema); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT I.TABLE_NAME, 0 AS C0, I.INDEX_NAME, IC.COLUMN_POSITION, IC.COLUMN_NAME FROM ALL_INDEXES I JOIN ALL_IND_COLUMNS IC ON I.INDEX_NAME = IC.INDEX_NAME WHERE I.TABLE_NAME = '", _0, "' AND IC.INDEX_OWNER = '", _2, "'"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT I.TABLE_NAME, 0 AS C0, I.INDEX_NAME, IC.COLUMN_POSITION, IC.COLUMN_NAME FROM ALL_INDEXES I JOIN ALL_IND_COLUMNS IC ON I.INDEX_NAME = IC.INDEX_NAME WHERE I.TABLE_NAME = '", _0, "'"); RETURN_MM(); @@ -53250,15 +53378,15 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeReferences) { ZEPHIR_INIT_VAR(sql); ZVAL_STRING(sql, "SELECT AC.TABLE_NAME, CC.COLUMN_NAME, AC.CONSTRAINT_NAME, AC.R_OWNER, RCC.TABLE_NAME R_TABLE_NAME, RCC.COLUMN_NAME R_COLUMN_NAME FROM ALL_CONSTRAINTS AC JOIN ALL_CONS_COLUMNS CC ON AC.CONSTRAINT_NAME = CC.CONSTRAINT_NAME JOIN ALL_CONS_COLUMNS RCC ON AC.R_OWNER = RCC.OWNER AND AC.R_CONSTRAINT_NAME = RCC.CONSTRAINT_NAME WHERE AC.CONSTRAINT_TYPE='R' ", 1); if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, schema); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SVSVS(_3, "AND AC.OWNER='", _0, "' AND AC.TABLE_NAME = '", _2, "'"); zephir_concat_self(&sql, _3 TSRMLS_CC); } else { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVS(_3, "AND AC.TABLE_NAME = '", _0, "'"); @@ -53354,11 +53482,11 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, prepareTable) { } - ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 142, table); + ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 143, table); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_3, phalcon_text_ce, "upper", &_2, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_3, phalcon_text_ce, "upper", &_2, 143, schema); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_PARENT(phalcon_db_dialect_oracle_ce, this_ptr, "preparetable", &_0, 143, _1, _3, alias, escapeChar); + ZEPHIR_RETURN_CALL_PARENT(phalcon_db_dialect_oracle_ce, this_ptr, "preparetable", &_0, 144, _1, _3, alias, escapeChar); zephir_check_call_status(); RETURN_MM(); @@ -53527,7 +53655,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, getColumnDefinition) { ZEPHIR_GET_HVALUE(value, _4); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_6, 141, value, &_5); + ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_6, 142, value, &_5); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "\"", _0, "\", "); @@ -53545,7 +53673,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, getColumnDefinition) { } else { ZEPHIR_SINIT_NVAR(_7); ZVAL_STRING(&_7, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_10, "addcslashes", &_6, 141, typeValues, &_7); + ZEPHIR_CALL_FUNCTION(&_10, "addcslashes", &_6, 142, typeValues, &_7); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, "(\"", _10, "\")"); @@ -53607,7 +53735,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 142, defaultValue, &_4); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\""); @@ -53739,7 +53867,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) { zephir_check_call_status(); ZEPHIR_SINIT_VAR(_11); ZVAL_STRING(&_11, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_12, "addcslashes", NULL, 141, defaultValue, &_11); + ZEPHIR_CALL_FUNCTION(&_12, "addcslashes", NULL, 142, defaultValue, &_11); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_VSVSVS(_9, sqlAlterTable, " ALTER COLUMN \"", _8, "\" SET DEFAULT \"", _12, "\""); @@ -53859,7 +53987,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addIndex) { zephir_concat_self(&sql, _1 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 43, _5); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 44, _5); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZEPHIR_CONCAT_SVS(_6, " (", _4, ")"); @@ -53953,7 +54081,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 44, _2); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _1, ")"); RETURN_MM(); @@ -54039,13 +54167,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 43, _3); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 44, _3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_4, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_6, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", NULL, 43, _6); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", NULL, 44, _6); zephir_check_call_status(); ZEPHIR_INIT_VAR(sql); ZEPHIR_CONCAT_SVSVSVSSVSVS(sql, "ALTER TABLE ", _0, " ADD CONSTRAINT \"", _1, "\" FOREIGN KEY (", _2, ")", " REFERENCES \"", _4, "\" (", _5, ")"); @@ -54120,12 +54248,12 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropForeignKey) { static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { - zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_16 = NULL; - HashTable *_1, *_14, *_23; - HashPosition _0, _13, _22; + zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL; + HashTable *_1, *_13, *_21; + HashPosition _0, _12, _20; int ZEPHIR_LAST_CALL_STATUS; zval *definition = NULL; - zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, *_10 = NULL, *_11 = NULL, *_12 = NULL, **_15, *_17 = NULL, *_18 = NULL, *_19 = NULL, *_20 = NULL, *_21 = NULL, **_24, *_25 = NULL; + zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, *_10 = NULL, *_11 = NULL, **_14, *_15 = NULL, *_16 = NULL, *_17 = NULL, *_18 = NULL, *_19 = NULL, **_22, *_23, *_24 = NULL; zval *tableName = NULL, *schemaName = NULL; ZEPHIR_MM_GROW(); @@ -54198,7 +54326,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_NVAR(_6); ZVAL_STRING(&_6, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 142, defaultValue, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\""); @@ -54223,22 +54351,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 381); } if (!(ZEPHIR_IS_EMPTY(primaryColumns))) { - ZEPHIR_INIT_VAR(_12); - zephir_fast_join_str(_12, SL(","), primaryColumns TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 44, primaryColumns); + zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); - ZEPHIR_CONCAT_SVS(_9, "PRIMARY KEY (", _12, ")"); + ZEPHIR_CONCAT_SVS(_9, "PRIMARY KEY (", _3, ")"); zephir_array_append(&createLines, _9, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 384); } ZEPHIR_INIT_VAR(indexSqlAfterCreate); ZVAL_STRING(indexSqlAfterCreate, "", 1); ZEPHIR_OBS_VAR(indexes); if (zephir_array_isset_string_fetch(&indexes, definition, SS("indexes"), 0 TSRMLS_CC)) { - zephir_is_iterable(indexes, &_14, &_13, 0, 0, "phalcon/db/dialect/postgresql.zep", 418); + zephir_is_iterable(indexes, &_13, &_12, 0, 0, "phalcon/db/dialect/postgresql.zep", 418); for ( - ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS - ; zephir_hash_move_forward_ex(_14, &_13) + ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS + ; zephir_hash_move_forward_ex(_13, &_12) ) { - ZEPHIR_GET_HVALUE(index, _15); + ZEPHIR_GET_HVALUE(index, _14); ZEPHIR_CALL_METHOD(&indexName, index, "getname", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0); @@ -54248,7 +54376,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) { ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_16, 43, _4); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 44, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(indexSql); ZEPHIR_CONCAT_SVS(indexSql, "CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _3, ")"); @@ -54256,25 +54384,25 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { if (!(ZEPHIR_IS_EMPTY(indexType))) { ZEPHIR_CALL_METHOD(&_10, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_16, 43, _10); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 44, _10); zephir_check_call_status(); ZEPHIR_INIT_NVAR(indexSql); ZEPHIR_CONCAT_SVSVSVS(indexSql, "CONSTRAINT \"", indexName, "\" ", indexType, " (", _7, ")"); } else { ZEPHIR_CALL_METHOD(&_11, index, "getname", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_17, this_ptr, "preparetable", NULL, 143, tableName, schemaName); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "preparetable", NULL, 144, tableName, schemaName); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_18); - ZEPHIR_CONCAT_SVSV(_18, "CREATE INDEX \"", _11, "\" ON ", _17); - zephir_concat_self(&indexSqlAfterCreate, _18 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_20, index, "getcolumns", NULL, 0); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SVSV(_16, "CREATE INDEX \"", _11, "\" ON ", _15); + zephir_concat_self(&indexSqlAfterCreate, _16 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_18, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_19, this_ptr, "getcolumnlist", &_16, 43, _20); + ZEPHIR_CALL_METHOD(&_17, this_ptr, "getcolumnlist", NULL, 44, _18); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_21); - ZEPHIR_CONCAT_SVS(_21, " (", _19, ");"); - zephir_concat_self(&indexSqlAfterCreate, _21 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_19); + ZEPHIR_CONCAT_SVS(_19, " (", _17, ");"); + zephir_concat_self(&indexSqlAfterCreate, _19 TSRMLS_CC); } } if (!(ZEPHIR_IS_EMPTY(indexSql))) { @@ -54284,64 +54412,64 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { } ZEPHIR_OBS_VAR(references); if (zephir_array_isset_string_fetch(&references, definition, SS("references"), 0 TSRMLS_CC)) { - zephir_is_iterable(references, &_23, &_22, 0, 0, "phalcon/db/dialect/postgresql.zep", 443); + zephir_is_iterable(references, &_21, &_20, 0, 0, "phalcon/db/dialect/postgresql.zep", 443); for ( - ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS - ; zephir_hash_move_forward_ex(_23, &_22) + ; zephir_hash_get_current_data_ex(_21, (void**) &_22, &_20) == SUCCESS + ; zephir_hash_move_forward_ex(_21, &_20) ) { - ZEPHIR_GET_HVALUE(reference, _24); + ZEPHIR_GET_HVALUE(reference, _22); ZEPHIR_CALL_METHOD(&_3, reference, "getname", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_16, 43, _7); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 44, _7); zephir_check_call_status(); ZEPHIR_INIT_NVAR(referenceSql); ZEPHIR_CONCAT_SVSVS(referenceSql, "CONSTRAINT \"", _3, "\" FOREIGN KEY (", _4, ") REFERENCES "); ZEPHIR_CALL_METHOD(&_11, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_10, this_ptr, "preparetable", NULL, 143, _11, schemaName); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "preparetable", NULL, 144, _11, schemaName); zephir_check_call_status(); zephir_concat_self(&referenceSql, _10 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0); + ZEPHIR_CALL_METHOD(&_17, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_17, this_ptr, "getcolumnlist", &_16, 43, _19); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", NULL, 44, _17); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); - ZEPHIR_CONCAT_SVS(_9, " (", _17, ")"); + ZEPHIR_CONCAT_SVS(_9, " (", _15, ")"); zephir_concat_self(&referenceSql, _9 TSRMLS_CC); ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0); zephir_check_call_status(); if (!(ZEPHIR_IS_EMPTY(onDelete))) { - ZEPHIR_INIT_LNVAR(_18); - ZEPHIR_CONCAT_SV(_18, " ON DELETE ", onDelete); - zephir_concat_self(&referenceSql, _18 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SV(_16, " ON DELETE ", onDelete); + zephir_concat_self(&referenceSql, _16 TSRMLS_CC); } ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0); zephir_check_call_status(); if (!(ZEPHIR_IS_EMPTY(onUpdate))) { - ZEPHIR_INIT_LNVAR(_21); - ZEPHIR_CONCAT_SV(_21, " ON UPDATE ", onUpdate); - zephir_concat_self(&referenceSql, _21 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_19); + ZEPHIR_CONCAT_SV(_19, " ON UPDATE ", onUpdate); + zephir_concat_self(&referenceSql, _19 TSRMLS_CC); } zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 441); } } - ZEPHIR_INIT_NVAR(_12); - zephir_fast_join_str(_12, SL(",\n\t"), createLines TSRMLS_CC); + ZEPHIR_INIT_VAR(_23); + zephir_fast_join_str(_23, SL(",\n\t"), createLines TSRMLS_CC); ZEPHIR_INIT_LNVAR(_9); - ZEPHIR_CONCAT_VS(_9, _12, "\n)"); + ZEPHIR_CONCAT_VS(_9, _23, "\n)"); zephir_concat_self(&sql, _9 TSRMLS_CC); if (zephir_array_isset_string(definition, SS("options"))) { ZEPHIR_CALL_METHOD(&_3, this_ptr, "_gettableoptions", NULL, 0, definition); zephir_check_call_status(); - ZEPHIR_INIT_VAR(_25); - ZEPHIR_CONCAT_SV(_25, " ", _3); - zephir_concat_self(&sql, _25 TSRMLS_CC); + ZEPHIR_INIT_VAR(_24); + ZEPHIR_CONCAT_SV(_24, " ", _3); + zephir_concat_self(&sql, _24 TSRMLS_CC); } - ZEPHIR_INIT_LNVAR(_25); - ZEPHIR_CONCAT_SV(_25, ";", indexSqlAfterCreate); - zephir_concat_self(&sql, _25 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_24); + ZEPHIR_CONCAT_SV(_24, ";", indexSqlAfterCreate); + zephir_concat_self(&sql, _24 TSRMLS_CC); RETURN_CCTOR(sql); } @@ -54892,7 +55020,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, getColumnDefinition) { ZEPHIR_GET_HVALUE(value, _5); ZEPHIR_SINIT_NVAR(_6); ZVAL_STRING(&_6, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_7, 141, value, &_6); + ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_7, 142, value, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "\"", _0, "\", "); @@ -54910,7 +55038,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, getColumnDefinition) { } else { ZEPHIR_SINIT_NVAR(_8); ZVAL_STRING(&_8, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_7, 141, typeValues, &_8); + ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_7, 142, typeValues, &_8); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVS(_10, "(\"", _2, "\")"); @@ -54972,7 +55100,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 142, defaultValue, &_4); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\""); @@ -55136,7 +55264,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addIndex) { } ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 43, _2); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 44, _2); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_VS(_1, _0, ")"); @@ -55841,13 +55969,17 @@ ZEPHIR_INIT_CLASS(Phalcon_Db_Profiler_Item) { static PHP_METHOD(Phalcon_Db_Profiler_Item, setSqlStatement) { - zval *sqlStatement; + zval *sqlStatement_param = NULL; + zval *sqlStatement = NULL; - zephir_fetch_params(0, 1, 0, &sqlStatement); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &sqlStatement_param); + zephir_get_strval(sqlStatement, sqlStatement_param); zephir_update_property_this(this_ptr, SL("_sqlStatement"), sqlStatement TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -55860,13 +55992,17 @@ static PHP_METHOD(Phalcon_Db_Profiler_Item, getSqlStatement) { static PHP_METHOD(Phalcon_Db_Profiler_Item, setSqlVariables) { - zval *sqlVariables; + zval *sqlVariables_param = NULL; + zval *sqlVariables = NULL; - zephir_fetch_params(0, 1, 0, &sqlVariables); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &sqlVariables_param); + zephir_get_arrval(sqlVariables, sqlVariables_param); zephir_update_property_this(this_ptr, SL("_sqlVariables"), sqlVariables TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -55879,13 +56015,17 @@ static PHP_METHOD(Phalcon_Db_Profiler_Item, getSqlVariables) { static PHP_METHOD(Phalcon_Db_Profiler_Item, setSqlBindTypes) { - zval *sqlBindTypes; + zval *sqlBindTypes_param = NULL; + zval *sqlBindTypes = NULL; - zephir_fetch_params(0, 1, 0, &sqlBindTypes); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &sqlBindTypes_param); + zephir_get_arrval(sqlBindTypes, sqlBindTypes_param); zephir_update_property_this(this_ptr, SL("_sqlBindTypes"), sqlBindTypes TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -55898,13 +56038,17 @@ static PHP_METHOD(Phalcon_Db_Profiler_Item, getSqlBindTypes) { static PHP_METHOD(Phalcon_Db_Profiler_Item, setInitialTime) { - zval *initialTime; + zval *initialTime_param = NULL, *_0; + double initialTime; - zephir_fetch_params(0, 1, 0, &initialTime); + zephir_fetch_params(0, 1, 0, &initialTime_param); + initialTime = zephir_get_doubleval(initialTime_param); - zephir_update_property_this(this_ptr, SL("_initialTime"), initialTime TSRMLS_CC); + ZEPHIR_INIT_ZVAL_NREF(_0); + ZVAL_DOUBLE(_0, initialTime); + zephir_update_property_this(this_ptr, SL("_initialTime"), _0 TSRMLS_CC); } @@ -55917,13 +56061,17 @@ static PHP_METHOD(Phalcon_Db_Profiler_Item, getInitialTime) { static PHP_METHOD(Phalcon_Db_Profiler_Item, setFinalTime) { - zval *finalTime; + zval *finalTime_param = NULL, *_0; + double finalTime; - zephir_fetch_params(0, 1, 0, &finalTime); + zephir_fetch_params(0, 1, 0, &finalTime_param); + finalTime = zephir_get_doubleval(finalTime_param); - zephir_update_property_this(this_ptr, SL("_finalTime"), finalTime TSRMLS_CC); + ZEPHIR_INIT_ZVAL_NREF(_0); + ZVAL_DOUBLE(_0, finalTime); + zephir_update_property_this(this_ptr, SL("_finalTime"), _0 TSRMLS_CC); } @@ -56425,7 +56573,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, all) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "variables", 1); zephir_array_fast_append(_0, _1); - ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 166); + ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 167); zephir_check_call_status(); ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, _0, _2); zephir_check_call_status(); @@ -56576,7 +56724,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { add_assoc_long_ex(_1, SS(":count"), zephir_fast_count_int(variable TSRMLS_CC)); ZEPHIR_SINIT_VAR(_5); ZVAL_STRING(&_5, "Array (:count) (\n", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); zephir_concat_self(&output, _2 TSRMLS_CC); zephir_is_iterable(variable, &_8, &_7, 0, 0, "phalcon/debug/dump.zep", 154); @@ -56588,7 +56736,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZEPHIR_GET_HVALUE(value, _9); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -56601,7 +56749,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_12, SL(":key"), &key, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "[:key] => ", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _10, _13); @@ -56625,7 +56773,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 167, value, _3, &_5); + ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 168, value, _3, &_5); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); @@ -56635,7 +56783,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab - 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_CONCAT_VVS(return_value, output, _10, ")"); RETURN_MM(); @@ -56654,10 +56802,10 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":class"), &_3, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Object :class", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); zephir_concat_self(&output, _2 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 168, variable); + ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 169, variable); zephir_check_call_status(); if (zephir_is_true(_13)) { ZEPHIR_INIT_NVAR(_12); @@ -56668,19 +56816,19 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_check_temp_parameter(_3); zephir_check_call_status(); zephir_array_update_string(&_12, SL(":style"), &_18, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 168, variable); + ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 169, variable); zephir_check_call_status(); zephir_array_update_string(&_12, SL(":parent"), &_18, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, " extends :parent", 0); - ZEPHIR_CALL_FUNCTION(&_18, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_18, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); zephir_concat_self(&output, _18 TSRMLS_CC); } zephir_concat_self_str(&output, SL(" (\n") TSRMLS_CC); _22 = zephir_fetch_nproperty_this(this_ptr, SL("_detailed"), PH_NOISY_CC); if (!(zephir_is_true(_22))) { - ZEPHIR_CALL_FUNCTION(&_10, "get_object_vars", NULL, 23, variable); + ZEPHIR_CALL_FUNCTION(&_10, "get_object_vars", NULL, 24, variable); zephir_check_call_status(); zephir_is_iterable(_10, &_24, &_23, 0, 0, "phalcon/debug/dump.zep", 171); for ( @@ -56691,7 +56839,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZEPHIR_GET_HVALUE(value, _25); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_13, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_13, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 3, 0 TSRMLS_CC); @@ -56705,7 +56853,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { add_assoc_stringl_ex(_12, SS(":type"), SL("public"), 1); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:key (:type) = ", 0); - ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _13, _26); @@ -56714,7 +56862,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5); + ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 168, value, _3, &_5); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); @@ -56724,7 +56872,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } else { do { Z_SET_ISREF_P(variable); - ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 169, variable); + ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 170, variable); Z_UNSET_ISREF_P(variable); zephir_check_call_status(); if (!(zephir_is_true(attr))) { @@ -56740,9 +56888,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZEPHIR_INIT_NVAR(_3); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "\\x00", 0); - ZEPHIR_CALL_FUNCTION(&_10, "ord", &_29, 130, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "ord", &_29, 132, &_5); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_13, "chr", &_30, 128, _10); + ZEPHIR_CALL_FUNCTION(&_13, "chr", &_30, 130, _10); zephir_check_call_status(); zephir_fast_explode(_3, _13, key, LONG_MAX TSRMLS_CC); ZEPHIR_CPY_WRT(key, _3); @@ -56759,7 +56907,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 3, 0 TSRMLS_CC); @@ -56770,14 +56918,14 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_check_call_status(); zephir_array_update_string(&_12, SL(":style"), &_26, PH_COPY | PH_SEPARATE); Z_SET_ISREF_P(key); - ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 170, key); + ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 171, key); Z_UNSET_ISREF_P(key); zephir_check_call_status(); zephir_array_update_string(&_12, SL(":key"), &_26, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_12, SL(":type"), &type, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:key (:type) = ", 0); - ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _18, _26); @@ -56786,7 +56934,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5); + ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 168, value, _3, &_5); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); @@ -56794,11 +56942,11 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_concat_self(&output, _20 TSRMLS_CC); } while (zephir_is_true(attr)); } - ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 171, variable); + ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 172, variable); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 3, 0 TSRMLS_CC); @@ -56814,7 +56962,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { add_assoc_long_ex(_12, SS(":count"), zephir_fast_count_int(attr TSRMLS_CC)); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, ":class methods: (:count) (\n", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _10, _13); @@ -56825,7 +56973,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { if (zephir_fast_in_array(_3, _33 TSRMLS_CC)) { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); ZEPHIR_CONCAT_VS(_20, _18, "[already listed]\n"); @@ -56843,7 +56991,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { if (ZEPHIR_IS_STRING(value, "__construct")) { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -56856,7 +57004,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_12, SL(":method"), &value, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:method(); [constructor]\n", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _10, _13); @@ -56864,7 +57012,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } else { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_FUNCTION(&_26, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_26, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_38); zephir_create_array(_38, 2, 0 TSRMLS_CC); @@ -56877,7 +57025,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_38, SL(":method"), &value, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:method();\n", 0); - ZEPHIR_CALL_FUNCTION(&_27, "strtr", &_6, 53, &_5, _38); + ZEPHIR_CALL_FUNCTION(&_27, "strtr", &_6, 54, &_5, _38); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_39); ZEPHIR_CONCAT_VV(_39, _26, _27); @@ -56886,7 +57034,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); ZEPHIR_CONCAT_VS(_20, _18, ")\n"); @@ -56894,7 +57042,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab - 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_CONCAT_VVS(return_value, output, _10, ")"); RETURN_MM(); @@ -56911,12 +57059,12 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Integer (:var)", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); } - ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 172, variable); + ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 173, variable); zephir_check_call_status(); if (zephir_is_true(_2)) { ZEPHIR_INIT_NVAR(_1); @@ -56930,7 +57078,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Float (:var)", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _13); RETURN_MM(); @@ -56948,7 +57096,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Numeric string (:length) \":var\"", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -56967,14 +57115,14 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_LONG(&_5, 4); ZEPHIR_SINIT_VAR(_40); ZVAL_STRING(&_40, "utf-8", 0); - ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 151, variable, &_5, &_40); + ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 152, variable, &_5, &_40); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_26, "nl2br", NULL, 173, _2); + ZEPHIR_CALL_FUNCTION(&_26, "nl2br", NULL, 174, _2); zephir_check_call_status(); zephir_array_update_string(&_1, SL(":var"), &_26, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "String (:length) \":var\"", 0); - ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _26); RETURN_MM(); @@ -56999,7 +57147,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &_14, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Boolean (:var)", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -57015,7 +57163,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":style"), &_2, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "NULL", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -57031,7 +57179,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "(:var)", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -57069,7 +57217,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, variable) { zephir_array_update_string(&_0, SL(":output"), &_1, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "
:output
", 0); - ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 53, &_3, _0); + ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 54, &_3, _0); zephir_check_call_status(); RETURN_MM(); @@ -57087,7 +57235,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, variables) { ZEPHIR_INIT_VAR(output); ZVAL_STRING(output, "", 1); - ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 166); + ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 167); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/debug/dump.zep", 290); for ( @@ -57196,7 +57344,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_ce, this_ptr, "__construct", &_0, 73); + ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_ce, this_ptr, "__construct", &_0, 75); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 21, 0 TSRMLS_CC); @@ -57208,7 +57356,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Router", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_VAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57221,7 +57369,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Dispatcher", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57234,7 +57382,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Url", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57247,7 +57395,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57260,7 +57408,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\MetaData\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57273,7 +57421,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Http\\Response", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57286,7 +57434,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Http\\Response\\Cookies", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57299,7 +57447,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Http\\Request", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57312,7 +57460,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Filter", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57325,7 +57473,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Escaper", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57338,7 +57486,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Security", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57351,7 +57499,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Crypt", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57364,7 +57512,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Annotations\\Adapter\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57377,7 +57525,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Flash\\Direct", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57390,7 +57538,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Flash\\Session", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57403,7 +57551,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Tag", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57416,7 +57564,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Session\\Adapter\\Files", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57427,7 +57575,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_3, "sessionBag", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_4); ZVAL_STRING(_4, "Phalcon\\Session\\Bag", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57440,7 +57588,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Events\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57448,12 +57596,12 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZEPHIR_INIT_NVAR(_2); object_init_ex(_2, phalcon_di_service_ce); ZEPHIR_INIT_NVAR(_3); - ZVAL_STRING(_3, "transactions", ZEPHIR_TEMP_PARAM_COPY); + ZVAL_STRING(_3, "transactionManager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_4); ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Transaction\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57466,7 +57614,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Assets\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -57846,7 +57994,7 @@ static PHP_METHOD(Phalcon_Di_Service, resolve) { ZEPHIR_CALL_METHOD(NULL, builder, "__construct", NULL, 0); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 175, dependencyInjector, definition, parameters); + ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 176, dependencyInjector, definition, parameters); zephir_check_call_status(); } else { found = 0; @@ -57969,7 +58117,7 @@ static PHP_METHOD(Phalcon_Di_Service, __set_state) { return; } object_init_ex(return_value, phalcon_di_service_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 61, name, definition, shared); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 63, name, definition, shared); zephir_check_call_status(); RETURN_MM(); @@ -58009,6 +58157,8 @@ ZEPHIR_DOC_METHOD(Phalcon_Di_ServiceInterface, getDefinition); ZEPHIR_DOC_METHOD(Phalcon_Di_ServiceInterface, resolve); +ZEPHIR_DOC_METHOD(Phalcon_Di_ServiceInterface, setParameter); + ZEPHIR_DOC_METHOD(Phalcon_Di_ServiceInterface, __set_state); @@ -58042,7 +58192,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 174); + ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 175); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 10, 0 TSRMLS_CC); @@ -58054,7 +58204,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\CLI\\Router", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_VAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58067,7 +58217,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\CLI\\Dispatcher", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58080,7 +58230,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58093,7 +58243,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\MetaData\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58106,7 +58256,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Filter", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58119,7 +58269,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Escaper", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58132,7 +58282,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Annotations\\Adapter\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58145,7 +58295,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Security", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58158,7 +58308,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Events\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58171,7 +58321,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Transaction\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -58344,7 +58494,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, _buildParameters) { ) { ZEPHIR_GET_HMKEY(position, _1, _0); ZEPHIR_GET_HVALUE(argument, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 176, dependencyInjector, position, argument); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 177, dependencyInjector, position, argument); zephir_check_call_status(); zephir_array_append(&buildArguments, _3, PH_SEPARATE, "phalcon/di/service/builder.zep", 117); } @@ -58389,7 +58539,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { } else { ZEPHIR_OBS_VAR(arguments); if (zephir_array_isset_string_fetch(&arguments, definition, SS("arguments"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 178, dependencyInjector, arguments); zephir_check_call_status(); ZEPHIR_INIT_NVAR(instance); ZEPHIR_LAST_CALL_STATUS = zephir_create_instance_params(instance, className, _0 TSRMLS_CC); @@ -58410,7 +58560,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "Setter injection parameters must be an array", "phalcon/di/service/builder.zep", 181); return; } - zephir_is_iterable(paramCalls, &_3, &_2, 0, 0, "phalcon/di/service/builder.zep", 235); + zephir_is_iterable(paramCalls, &_3, &_2, 0, 0, "phalcon/di/service/builder.zep", 233); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -58459,7 +58609,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { } if (zephir_fast_count_int(arguments TSRMLS_CC)) { ZEPHIR_INIT_NVAR(_5); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 178, dependencyInjector, arguments); zephir_check_call_status(); ZEPHIR_CALL_USER_FUNC_ARRAY(_5, methodCall, _0); zephir_check_call_status(); @@ -58474,14 +58624,14 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_OBS_NVAR(paramCalls); if (zephir_array_isset_string_fetch(¶mCalls, definition, SS("properties"), 0 TSRMLS_CC)) { if (Z_TYPE_P(instance) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "The definition has properties injection parameters but the constructor didn't return an instance", "phalcon/di/service/builder.zep", 243); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "The definition has properties injection parameters but the constructor didn't return an instance", "phalcon/di/service/builder.zep", 241); return; } if (Z_TYPE_P(paramCalls) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "Setter injection parameters must be an array", "phalcon/di/service/builder.zep", 247); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "Setter injection parameters must be an array", "phalcon/di/service/builder.zep", 245); return; } - zephir_is_iterable(paramCalls, &_9, &_8, 0, 0, "phalcon/di/service/builder.zep", 282); + zephir_is_iterable(paramCalls, &_9, &_8, 0, 0, "phalcon/di/service/builder.zep", 279); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) @@ -58495,7 +58645,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_CONCAT_SV(_6, "Property must be an array on position ", propertyPosition); ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_11, "phalcon/di/service/builder.zep", 259 TSRMLS_CC); + zephir_throw_exception_debug(_11, "phalcon/di/service/builder.zep", 257 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -58507,7 +58657,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_CONCAT_SV(_6, "The property name is required on position ", propertyPosition); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 266 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 264 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -58519,11 +58669,11 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_CONCAT_SV(_6, "The property value is required on position ", propertyPosition); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 273 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 271 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 176, dependencyInjector, propertyPosition, propertyValue); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 177, dependencyInjector, propertyPosition, propertyValue); zephir_check_call_status(); zephir_update_property_zval_zval(instance, propertyName, _0 TSRMLS_CC); } @@ -58588,13 +58738,17 @@ ZEPHIR_INIT_CLASS(Phalcon_Events_Event) { static PHP_METHOD(Phalcon_Events_Event, setType) { - zval *type; + zval *type_param = NULL; + zval *type = NULL; - zephir_fetch_params(0, 1, 0, &type); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &type_param); + zephir_get_strval(type, type_param); zephir_update_property_this(this_ptr, SL("_type"), type TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -58827,7 +58981,7 @@ static PHP_METHOD(Phalcon_Events_Manager, attach) { } ZEPHIR_INIT_VAR(_2); ZVAL_LONG(_2, 1); - ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 184, _2); + ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 185, _2); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_events"), eventType, priorityQueue TSRMLS_CC); } else { @@ -58837,7 +58991,7 @@ static PHP_METHOD(Phalcon_Events_Manager, attach) { if (Z_TYPE_P(priorityQueue) == IS_OBJECT) { ZEPHIR_INIT_NVAR(_2); ZVAL_LONG(_2, priority); - ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 185, handler, _2); + ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 186, handler, _2); zephir_check_call_status(); } else { zephir_array_append(&priorityQueue, handler, PH_SEPARATE, "phalcon/events/manager.zep", 82); @@ -58886,7 +59040,7 @@ static PHP_METHOD(Phalcon_Events_Manager, detach) { } ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 1); - ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 184, _1); + ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 185, _1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_1); ZVAL_LONG(_1, 3); @@ -58908,13 +59062,13 @@ static PHP_METHOD(Phalcon_Events_Manager, detach) { if (!ZEPHIR_IS_IDENTICAL(_5, handler)) { zephir_array_fetch_string(&_6, data, SL("data"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC); zephir_array_fetch_string(&_7, data, SL("priority"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 185, _6, _7); + ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 186, _6, _7); zephir_check_call_status(); } } zephir_update_property_array(this_ptr, SL("_events"), eventType, newPriorityQueue TSRMLS_CC); } else { - ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 186, handler, priorityQueue, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 187, handler, priorityQueue, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); if (!ZEPHIR_IS_FALSE_IDENTICAL(key)) { zephir_array_unset(&priorityQueue, key, PH_SEPARATE); @@ -59070,7 +59224,7 @@ static PHP_METHOD(Phalcon_Events_Manager, fireQueue) { zephir_get_class(_1, queue, 0 TSRMLS_CC); ZEPHIR_SINIT_VAR(_2); ZVAL_STRING(&_2, "Unexpected value type: expected object of type SplPriorityQueue, %s given", 0); - ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 187, &_2, _1); + ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 188, &_2, _1); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); @@ -59283,9 +59437,9 @@ static PHP_METHOD(Phalcon_Events_Manager, fire) { if (_3) { ZEPHIR_INIT_NVAR(event); object_init_ex(event, phalcon_events_event_ce); - ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 189, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event); + ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 190, fireEvents, event); zephir_check_call_status(); } } @@ -59299,10 +59453,10 @@ static PHP_METHOD(Phalcon_Events_Manager, fire) { if (Z_TYPE_P(event) == IS_NULL) { ZEPHIR_INIT_NVAR(event); object_init_ex(event, phalcon_events_event_ce); - ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 189, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event); + ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 190, fireEvents, event); zephir_check_call_status(); } } @@ -59515,7 +59669,7 @@ static PHP_METHOD(Phalcon_Flash_Direct, output) { } } if (remove) { - ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 196); + ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 197); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -59788,7 +59942,7 @@ static PHP_METHOD(Phalcon_Flash_Session, output) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 196); + ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 197); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -59806,7 +59960,7 @@ static PHP_METHOD(Phalcon_Flash_Session, clear) { ZVAL_BOOL(_0, 1); ZEPHIR_CALL_METHOD(NULL, this_ptr, "_getsessionmessages", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 196); + ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 197); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -60932,7 +61086,7 @@ static PHP_METHOD(Phalcon_Forms_Form, isValid) { } else { ZEPHIR_INIT_NVAR(validation); object_init_ex(validation, phalcon_validation_ce); - ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 210, preparedValidators); + ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 211, preparedValidators); zephir_check_call_status(); } ZEPHIR_CALL_METHOD(&filters, element, "getfilters", NULL, 0); @@ -60940,10 +61094,10 @@ static PHP_METHOD(Phalcon_Forms_Form, isValid) { if (Z_TYPE_P(filters) == IS_ARRAY) { ZEPHIR_CALL_METHOD(&_2, element, "getname", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 211, _2, filters); + ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 212, _2, filters); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 212, data, entity); + ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 213, data, entity); zephir_check_call_status(); if (zephir_fast_count_int(elementMessages TSRMLS_CC)) { ZEPHIR_CALL_METHOD(&_14, element, "getname", NULL, 0); @@ -61006,7 +61160,7 @@ static PHP_METHOD(Phalcon_Forms_Form, getMessages) { ; zephir_hash_move_forward_ex(_2, &_1) ) { ZEPHIR_GET_HVALUE(elementMessages, _3); - ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 213, elementMessages); + ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 214, elementMessages); zephir_check_call_status(); } } @@ -61476,7 +61630,7 @@ static PHP_METHOD(Phalcon_Forms_Form, rewind) { ZVAL_LONG(_0, 0); zephir_update_property_this(this_ptr, SL("_position"), _0 TSRMLS_CC); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_elements"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 214, _0); + ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 215, _0); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_elementsIndexed"), _1 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -61568,7 +61722,7 @@ static PHP_METHOD(Phalcon_Forms_Manager, create) { } ZEPHIR_INIT_VAR(form); object_init_ex(form, phalcon_forms_form_ce); - ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 215, entity); + ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 216, entity); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_forms"), name, form TSRMLS_CC); RETURN_CCTOR(form); @@ -61677,7 +61831,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Check, render) { ZVAL_BOOL(_2, 1); ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 197, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 198, _1); zephir_check_call_status(); RETURN_MM(); @@ -61722,7 +61876,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Date, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 198, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 199, _1); zephir_check_call_status(); RETURN_MM(); @@ -61767,7 +61921,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Email, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 199, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 200, _1); zephir_check_call_status(); RETURN_MM(); @@ -61812,7 +61966,7 @@ static PHP_METHOD(Phalcon_Forms_Element_File, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 200, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 201, _1); zephir_check_call_status(); RETURN_MM(); @@ -61857,7 +62011,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Hidden, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 201, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 202, _1); zephir_check_call_status(); RETURN_MM(); @@ -61902,7 +62056,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Numeric, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 202, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 203, _1); zephir_check_call_status(); RETURN_MM(); @@ -61947,7 +62101,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Password, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 203, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 204, _1); zephir_check_call_status(); RETURN_MM(); @@ -61994,7 +62148,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Radio, render) { ZVAL_BOOL(_2, 1); ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 204, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 205, _1); zephir_check_call_status(); RETURN_MM(); @@ -62045,7 +62199,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Select, __construct) { zephir_update_property_this(this_ptr, SL("_optionsValues"), options TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 205, name, attributes); + ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 206, name, attributes); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -62073,14 +62227,29 @@ static PHP_METHOD(Phalcon_Forms_Element_Select, getOptions) { static PHP_METHOD(Phalcon_Forms_Element_Select, addOption) { - zval *option; + HashTable *_1; + HashPosition _0; + zval *option, *key = NULL, *value = NULL, **_2; - zephir_fetch_params(0, 1, 0, &option); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &option); - zephir_update_property_array_append(this_ptr, SL("_optionsValues"), option TSRMLS_CC); - RETURN_THISW(); + if (Z_TYPE_P(option) == IS_ARRAY) { + zephir_is_iterable(option, &_1, &_0, 0, 0, "phalcon/forms/element/select.zep", 85); + for ( + ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS + ; zephir_hash_move_forward_ex(_1, &_0) + ) { + ZEPHIR_GET_HMKEY(key, _1, _0); + ZEPHIR_GET_HVALUE(value, _2); + zephir_update_property_array(this_ptr, SL("_optionsValues"), key, value TSRMLS_CC); + } + } else { + zephir_update_property_array_append(this_ptr, SL("_optionsValues"), option TSRMLS_CC); + } + RETURN_THIS(); } @@ -62101,7 +62270,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Select, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); _2 = zephir_fetch_nproperty_this(this_ptr, SL("_optionsValues"), PH_NOISY_CC); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, _1, _2); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 207, _1, _2); zephir_check_call_status(); RETURN_MM(); @@ -62146,7 +62315,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Submit, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 207, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 208, _1); zephir_check_call_status(); RETURN_MM(); @@ -62191,7 +62360,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Text, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 208, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 209, _1); zephir_check_call_status(); RETURN_MM(); @@ -62236,7 +62405,7 @@ static PHP_METHOD(Phalcon_Forms_Element_TextArea, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 209, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 210, _1); zephir_check_call_status(); RETURN_MM(); @@ -62284,6 +62453,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Http_Cookie) { zend_declare_property_bool(phalcon_http_cookie_ce, SL("_httpOnly"), 1, ZEND_ACC_PROTECTED TSRMLS_CC); + zend_class_implements(phalcon_http_cookie_ce TSRMLS_CC, 1, phalcon_http_cookieinterface_ce); zend_class_implements(phalcon_http_cookie_ce TSRMLS_CC, 1, phalcon_di_injectionawareinterface_ce); return SUCCESS; @@ -62516,16 +62686,20 @@ static PHP_METHOD(Phalcon_Http_Cookie, send) { zephir_check_temp_parameter(_1); zephir_check_call_status(); ZEPHIR_CPY_WRT(session, _0); - ZEPHIR_INIT_VAR(_2); - ZEPHIR_CONCAT_SV(_2, "_PHCOOKIE_", name); - ZEPHIR_CALL_METHOD(NULL, session, "set", NULL, 0, _2, definition); + ZEPHIR_CALL_METHOD(&_0, session, "isstarted", NULL, 0); zephir_check_call_status(); + if (zephir_is_true(_0)) { + ZEPHIR_INIT_VAR(_2); + ZEPHIR_CONCAT_SV(_2, "_PHCOOKIE_", name); + ZEPHIR_CALL_METHOD(NULL, session, "set", NULL, 0, _2, definition); + zephir_check_call_status(); + } } _3 = zephir_fetch_nproperty_this(this_ptr, SL("_useEncryption"), PH_NOISY_CC); if (zephir_is_true(_3)) { if (!(ZEPHIR_IS_EMPTY(value))) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "A dependency injection object is required to access the 'filter' service", "phalcon/http/cookie.zep", 258); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "A dependency injection object is required to access the 'filter' service", "phalcon/http/cookie.zep", 260); return; } ZEPHIR_INIT_NVAR(_1); @@ -62543,7 +62717,7 @@ static PHP_METHOD(Phalcon_Http_Cookie, send) { } else { ZEPHIR_CPY_WRT(encryptValue, value); } - ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, encryptValue, expire, path, domain, secure, httpOnly); + ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 217, name, encryptValue, expire, path, domain, secure, httpOnly); zephir_check_call_status(); RETURN_THIS(); @@ -62552,7 +62726,7 @@ static PHP_METHOD(Phalcon_Http_Cookie, send) { static PHP_METHOD(Phalcon_Http_Cookie, restore) { int ZEPHIR_LAST_CALL_STATUS; - zval *dependencyInjector, *expire, *domain, *path, *secure, *httpOnly, *session = NULL, *definition = NULL, *_0, *_1, *_2, *_3; + zval *dependencyInjector, *expire, *domain, *path, *secure, *httpOnly, *session = NULL, *definition = NULL, *_0, *_1, *_2 = NULL, *_3, *_4; ZEPHIR_MM_GROW(); @@ -62566,26 +62740,30 @@ static PHP_METHOD(Phalcon_Http_Cookie, restore) { ZEPHIR_CALL_METHOD(&session, dependencyInjector, "getshared", NULL, 0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_3); - ZEPHIR_CONCAT_SV(_3, "_PHCOOKIE_", _2); - ZEPHIR_CALL_METHOD(&definition, session, "get", NULL, 0, _3); + ZEPHIR_CALL_METHOD(&_2, session, "isstarted", NULL, 0); zephir_check_call_status(); - if (Z_TYPE_P(definition) == IS_ARRAY) { - if (zephir_array_isset_string_fetch(&expire, definition, SS("expire"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_expire"), expire TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&domain, definition, SS("domain"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_domain"), domain TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&path, definition, SS("path"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_path"), path TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&secure, definition, SS("secure"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_secure"), secure TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&httpOnly, definition, SS("httpOnly"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_httpOnly"), httpOnly TSRMLS_CC); + if (zephir_is_true(_2)) { + _3 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); + ZEPHIR_INIT_VAR(_4); + ZEPHIR_CONCAT_SV(_4, "_PHCOOKIE_", _3); + ZEPHIR_CALL_METHOD(&definition, session, "get", NULL, 0, _4); + zephir_check_call_status(); + if (Z_TYPE_P(definition) == IS_ARRAY) { + if (zephir_array_isset_string_fetch(&expire, definition, SS("expire"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_expire"), expire TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&domain, definition, SS("domain"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_domain"), domain TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&path, definition, SS("path"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_path"), path TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&secure, definition, SS("secure"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_secure"), secure TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&httpOnly, definition, SS("httpOnly"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_httpOnly"), httpOnly TSRMLS_CC); + } } } } @@ -62621,17 +62799,21 @@ static PHP_METHOD(Phalcon_Http_Cookie, delete) { zephir_check_temp_parameter(_2); zephir_check_call_status(); ZEPHIR_CPY_WRT(session, _1); - ZEPHIR_INIT_VAR(_3); - ZEPHIR_CONCAT_SV(_3, "_PHCOOKIE_", name); - ZEPHIR_CALL_METHOD(NULL, session, "remove", NULL, 0, _3); + ZEPHIR_CALL_METHOD(&_1, session, "isstarted", NULL, 0); zephir_check_call_status(); + if (zephir_is_true(_1)) { + ZEPHIR_INIT_VAR(_3); + ZEPHIR_CONCAT_SV(_3, "_PHCOOKIE_", name); + ZEPHIR_CALL_METHOD(NULL, session, "remove", NULL, 0, _3); + zephir_check_call_status(); + } } zephir_update_property_this(this_ptr, SL("_value"), ZEPHIR_GLOBAL(global_null) TSRMLS_CC); ZEPHIR_INIT_NVAR(_2); zephir_time(_2); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, (zephir_get_numberval(_2) - 691200)); - ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly); + ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 217, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -62895,6 +63077,60 @@ static PHP_METHOD(Phalcon_Http_Cookie, __toString) { +#ifdef HAVE_CONFIG_H +#endif + +#include + +#include + + + +ZEPHIR_INIT_CLASS(Phalcon_Http_CookieInterface) { + + ZEPHIR_REGISTER_INTERFACE(Phalcon\\Http, CookieInterface, phalcon, http_cookieinterface, phalcon_http_cookieinterface_method_entry); + + return SUCCESS; + +} + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setValue); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getValue); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, send); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, delete); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, useEncryption); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, isUsingEncryption); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setExpiration); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getExpiration); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setPath); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getName); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getPath); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setDomain); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getDomain); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setSecure); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getSecure); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setHttpOnly); + +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getHttpOnly); + + + + #ifdef HAVE_CONFIG_H #endif @@ -62988,7 +63224,7 @@ static PHP_METHOD(Phalcon_Http_Request, get) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -63039,7 +63275,7 @@ static PHP_METHOD(Phalcon_Http_Request, getPost) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -63097,12 +63333,12 @@ static PHP_METHOD(Phalcon_Http_Request, getPut) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getrawbody", NULL, 0); zephir_check_call_status(); Z_SET_ISREF_P(put); - ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 218, _0, put); + ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 219, _0, put); Z_UNSET_ISREF_P(put); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_putCache"), put TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -63153,7 +63389,7 @@ static PHP_METHOD(Phalcon_Http_Request, getQuery) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -63435,7 +63671,7 @@ static PHP_METHOD(Phalcon_Http_Request, getHeader) { ZVAL_STRING(&_0, "-", 0); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "_", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, header, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, header, &_0, &_1); zephir_check_call_status(); ZEPHIR_INIT_VAR(name); zephir_fast_strtoupper(name, _2); @@ -63590,7 +63826,7 @@ static PHP_METHOD(Phalcon_Http_Request, getServerAddress) { } ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "localhost", 0); - ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 219, &_0); + ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 220, &_0); zephir_check_call_status(); RETURN_MM(); @@ -63781,7 +64017,7 @@ static PHP_METHOD(Phalcon_Http_Request, isMethod) { } - ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); if (Z_TYPE_P(methods) == IS_STRING) { _0 = strict; @@ -63853,7 +64089,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPost) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "POST")); @@ -63866,7 +64102,7 @@ static PHP_METHOD(Phalcon_Http_Request, isGet) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "GET")); @@ -63879,7 +64115,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPut) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PUT")); @@ -63892,7 +64128,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPatch) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PATCH")); @@ -63905,7 +64141,7 @@ static PHP_METHOD(Phalcon_Http_Request, isHead) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "HEAD")); @@ -63918,7 +64154,7 @@ static PHP_METHOD(Phalcon_Http_Request, isDelete) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "DELETE")); @@ -63931,7 +64167,7 @@ static PHP_METHOD(Phalcon_Http_Request, isOptions) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "OPTIONS")); @@ -63979,7 +64215,7 @@ static PHP_METHOD(Phalcon_Http_Request, hasFiles) { } } if (Z_TYPE_P(error) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 222, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); numberFiles += zephir_get_numberval(_4); } @@ -64023,7 +64259,7 @@ static PHP_METHOD(Phalcon_Http_Request, hasFileHelper) { } } if (Z_TYPE_P(value) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 222, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); numberFiles += zephir_get_numberval(_4); } @@ -64072,7 +64308,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) { zephir_array_fetch_string(&_6, input, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC); zephir_array_fetch_string(&_7, input, SL("size"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC); zephir_array_fetch_string(&_8, input, SL("error"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 222, _4, _5, _6, _7, _8, prefix); + ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 223, _4, _5, _6, _7, _8, prefix); zephir_check_call_status(); zephir_is_iterable(smoothInput, &_11, &_10, 0, 0, "phalcon/http/request.zep", 714); for ( @@ -64106,7 +64342,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) { ZEPHIR_INIT_NVAR(_16); object_init_ex(_16, phalcon_http_request_file_ce); zephir_array_fetch_string(&_17, file, SL("key"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 711 TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, dataFile, _17); + ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 224, dataFile, _17); zephir_check_call_status(); zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 711); } @@ -64120,7 +64356,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) { if (_13) { ZEPHIR_INIT_NVAR(_16); object_init_ex(_16, phalcon_http_request_file_ce); - ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, input, prefix); + ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 224, input, prefix); zephir_check_call_status(); zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 716); } @@ -64193,7 +64429,7 @@ static PHP_METHOD(Phalcon_Http_Request, smoothFiles) { zephir_array_fetch(&_7, tmp_names, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC); zephir_array_fetch(&_8, sizes, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC); zephir_array_fetch(&_9, errors, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 222, _5, _6, _7, _8, _9, p); + ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 223, _5, _6, _7, _8, _9, p); zephir_check_call_status(); zephir_is_iterable(parentFiles, &_12, &_11, 0, 0, "phalcon/http/request.zep", 755); for ( @@ -64247,7 +64483,7 @@ static PHP_METHOD(Phalcon_Http_Request, getHeaders) { ZVAL_STRING(&_8, " ", 0); zephir_fast_str_replace(&_4, &_7, &_8, _6 TSRMLS_CC); zephir_fast_strtolower(_3, _4); - ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3); + ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 225, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_10); ZEPHIR_SINIT_NVAR(_11); @@ -64266,7 +64502,7 @@ static PHP_METHOD(Phalcon_Http_Request, getHeaders) { ZVAL_STRING(&_7, " ", 0); zephir_fast_str_replace(&_4, &_5, &_7, name TSRMLS_CC); zephir_fast_strtolower(_3, _4); - ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3); + ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 225, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_6); ZEPHIR_SINIT_NVAR(_8); @@ -64341,7 +64577,7 @@ static PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) { ZVAL_LONG(&_2, -1); ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 1); - ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 225, &_1, _0, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 226, &_1, _0, &_2, &_3); zephir_check_call_status(); zephir_is_iterable(_4, &_7, &_6, 0, 0, "phalcon/http/request.zep", 827); for ( @@ -64359,7 +64595,7 @@ static PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) { ZVAL_LONG(&_2, -1); ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 1); - ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 225, &_1, _9, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 226, &_1, _9, &_2, &_3); zephir_check_call_status(); zephir_is_iterable(_10, &_12, &_11, 0, 0, "phalcon/http/request.zep", 824); for ( @@ -64490,7 +64726,7 @@ static PHP_METHOD(Phalcon_Http_Request, getAcceptableContent) { ZVAL_STRING(_0, "HTTP_ACCEPT", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 227, _0, _1); zephir_check_temp_parameter(_0); zephir_check_temp_parameter(_1); zephir_check_call_status(); @@ -64509,7 +64745,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestAccept) { zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 228, _0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -64527,7 +64763,7 @@ static PHP_METHOD(Phalcon_Http_Request, getClientCharsets) { ZVAL_STRING(_0, "HTTP_ACCEPT_CHARSET", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 227, _0, _1); zephir_check_temp_parameter(_0); zephir_check_temp_parameter(_1); zephir_check_call_status(); @@ -64546,7 +64782,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestCharset) { zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 228, _0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -64564,7 +64800,7 @@ static PHP_METHOD(Phalcon_Http_Request, getLanguages) { ZVAL_STRING(_0, "HTTP_ACCEPT_LANGUAGE", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 227, _0, _1); zephir_check_temp_parameter(_0); zephir_check_temp_parameter(_1); zephir_check_call_status(); @@ -64583,7 +64819,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestLanguage) { zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 228, _0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -64637,7 +64873,7 @@ static PHP_METHOD(Phalcon_Http_Request, getDigestAuth) { ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 2); Z_SET_ISREF_P(matches); - ZEPHIR_CALL_FUNCTION(&_2, "preg_match_all", NULL, 27, _0, digest, matches, _1); + ZEPHIR_CALL_FUNCTION(&_2, "preg_match_all", NULL, 28, _0, digest, matches, _1); zephir_check_temp_parameter(_0); Z_UNSET_ISREF_P(matches); zephir_check_call_status(); @@ -64903,7 +65139,7 @@ static PHP_METHOD(Phalcon_Http_Response, setStatusCode) { if (_4) { ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "HTTP/", 0); - ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 234, key, &_5); + ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 235, key, &_5); zephir_check_call_status(); _4 = zephir_is_true(_6); } @@ -65330,7 +65566,7 @@ static PHP_METHOD(Phalcon_Http_Response, redirect) { if (_0) { ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "://", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 234, location, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 235, location, &_1); zephir_check_call_status(); _0 = zephir_is_true(_2); } @@ -65550,7 +65786,7 @@ static PHP_METHOD(Phalcon_Http_Response, send) { _1 = (zephir_fast_strlen_ev(file)) ? 1 : 0; } if (_1) { - ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 235, file); + ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 236, file); zephir_check_call_status(); } } @@ -65790,12 +66026,12 @@ static PHP_METHOD(Phalcon_Http_Request_File, __construct) { zephir_update_property_this(this_ptr, SL("_name"), name TSRMLS_CC); ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "PATHINFO_EXTENSION", 0); - ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 228, &_0); + ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 229, &_0); zephir_check_call_status(); if (zephir_is_true(_1)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_LONG(&_0, 4); - ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 69, name, &_0); + ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 71, name, &_0); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_extension"), _2 TSRMLS_CC); } @@ -65856,15 +66092,15 @@ static PHP_METHOD(Phalcon_Http_Request_File, getRealType) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 16); - ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 229, &_0); + ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 230, &_0); zephir_check_call_status(); if (Z_TYPE_P(finfo) != IS_RESOURCE) { RETURN_MM_STRING("", 1); } _1 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, finfo, _1); + ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 231, finfo, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, finfo); + ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 232, finfo); zephir_check_call_status(); RETURN_CCTOR(mime); @@ -65882,7 +66118,7 @@ static PHP_METHOD(Phalcon_Http_Request_File, isUploadedFile) { zephir_check_call_status(); _0 = Z_TYPE_P(tmp) == IS_STRING; if (_0) { - ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 232, tmp); + ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 233, tmp); zephir_check_call_status(); _0 = zephir_is_true(_1); } @@ -65913,7 +66149,7 @@ static PHP_METHOD(Phalcon_Http_Request_File, moveTo) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC); - ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 233, _0, destination); + ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 234, _0, destination); zephir_check_call_status(); RETURN_MM(); @@ -66028,12 +66264,14 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, isUsingEncryption) { static PHP_METHOD(Phalcon_Http_Response_Cookies, set) { + zval *_3; + zend_bool secure, httpOnly; int expire, ZEPHIR_LAST_CALL_STATUS; - zval *name_param = NULL, *value = NULL, *expire_param = NULL, *path_param = NULL, *secure = NULL, *domain_param = NULL, *httpOnly = NULL, *cookie = NULL, *encryption, *dependencyInjector, *response = NULL, *_0, *_1 = NULL, *_2; + zval *name_param = NULL, *value = NULL, *expire_param = NULL, *path_param = NULL, *secure_param = NULL, *domain_param = NULL, *httpOnly_param = NULL, *cookie = NULL, *encryption, *dependencyInjector, *response = NULL, *_0, *_1, *_2 = NULL, *_4 = NULL, *_5; zval *name = NULL, *path = NULL, *domain = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 6, &name_param, &value, &expire_param, &path_param, &secure, &domain_param, &httpOnly); + zephir_fetch_params(1, 1, 6, &name_param, &value, &expire_param, &path_param, &secure_param, &domain_param, &httpOnly_param); if (unlikely(Z_TYPE_P(name_param) != IS_STRING && Z_TYPE_P(name_param) != IS_NULL)) { zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'name' must be a string") TSRMLS_CC); @@ -66060,8 +66298,10 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, set) { } else { zephir_get_strval(path, path_param); } - if (!secure) { - secure = ZEPHIR_GLOBAL(global_null); + if (!secure_param) { + secure = 0; + } else { + secure = zephir_get_boolval(secure_param); } if (!domain_param) { ZEPHIR_INIT_VAR(domain); @@ -66079,8 +66319,10 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, set) { ZVAL_EMPTY_STRING(domain); } } - if (!httpOnly) { - httpOnly = ZEPHIR_GLOBAL(global_null); + if (!httpOnly_param) { + httpOnly = 0; + } else { + httpOnly = zephir_get_boolval(httpOnly_param); } @@ -66089,48 +66331,64 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, set) { ZEPHIR_OBS_VAR(cookie); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_cookies"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&cookie, _0, name, 0 TSRMLS_CC))) { - ZEPHIR_INIT_NVAR(cookie); - object_init_ex(cookie, phalcon_http_cookie_ce); - ZEPHIR_INIT_VAR(_1); - ZVAL_LONG(_1, expire); - ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name, value, _1, path, secure, domain, httpOnly); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); + ZEPHIR_INIT_VAR(_3); + zephir_create_array(_3, 7, 0 TSRMLS_CC); + zephir_array_fast_append(_3, name); + zephir_array_fast_append(_3, value); + ZEPHIR_INIT_VAR(_4); + ZVAL_LONG(_4, expire); + zephir_array_fast_append(_3, _4); + zephir_array_fast_append(_3, path); + ZEPHIR_INIT_NVAR(_4); + ZVAL_BOOL(_4, secure); + zephir_array_fast_append(_3, _4); + zephir_array_fast_append(_3, domain); + ZEPHIR_INIT_NVAR(_4); + ZVAL_BOOL(_4, httpOnly); + zephir_array_fast_append(_3, _4); + ZEPHIR_INIT_NVAR(_4); + ZVAL_STRING(_4, "Phalcon\\Http\\Cookie", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&_2, _1, "get", NULL, 0, _4, _3); + zephir_check_temp_parameter(_4); zephir_check_call_status(); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, _2); + ZEPHIR_CPY_WRT(cookie, _2); + _5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 0, _5); zephir_check_call_status(); if (zephir_is_true(encryption)) { - ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption); + ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 0, encryption); zephir_check_call_status(); } zephir_update_property_array(this_ptr, SL("_cookies"), name, cookie TSRMLS_CC); } else { - ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 239, value); + ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 0, value); zephir_check_call_status(); - ZEPHIR_INIT_NVAR(_1); - ZVAL_LONG(_1, expire); - ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 240, _1); + ZEPHIR_INIT_NVAR(_4); + ZVAL_LONG(_4, expire); + ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 0, _4); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 241, path); + ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 0, path); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 242, secure); + ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 0, (secure ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 243, domain); + ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 0, domain); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 244, httpOnly); + ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 0, (httpOnly ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_registered"), PH_NOISY_CC); - if (ZEPHIR_IS_FALSE_IDENTICAL(_2)) { + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_registered"), PH_NOISY_CC); + if (ZEPHIR_IS_FALSE_IDENTICAL(_1)) { ZEPHIR_OBS_VAR(dependencyInjector); zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_cookie_exception_ce, "A dependency injection object is required to access the 'response' service", "phalcon/http/response/cookies.zep", 138); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_cookie_exception_ce, "A dependency injection object is required to access the 'response' service", "phalcon/http/response/cookies.zep", 130); return; } - ZEPHIR_INIT_NVAR(_1); - ZVAL_STRING(_1, "response", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&response, dependencyInjector, "getshared", NULL, 0, _1); - zephir_check_temp_parameter(_1); + ZEPHIR_INIT_NVAR(_4); + ZVAL_STRING(_4, "response", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&response, dependencyInjector, "getshared", NULL, 0, _4); + zephir_check_temp_parameter(_4); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, response, "setcookies", NULL, 0, this_ptr); zephir_check_call_status(); @@ -66142,7 +66400,8 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, set) { static PHP_METHOD(Phalcon_Http_Response_Cookies, get) { int ZEPHIR_LAST_CALL_STATUS; - zval *name_param = NULL, *dependencyInjector, *encryption, *cookie = NULL, *_0; + zval *_3; + zval *name_param = NULL, *dependencyInjector, *encryption, *cookie = NULL, *_0, *_1, *_2 = NULL, *_4; zval *name = NULL; ZEPHIR_MM_GROW(); @@ -66166,19 +66425,25 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, get) { if (zephir_array_isset_fetch(&cookie, _0, name, 0 TSRMLS_CC)) { RETURN_CCTOR(cookie); } - ZEPHIR_INIT_NVAR(cookie); - object_init_ex(cookie, phalcon_http_cookie_ce); - ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); + ZEPHIR_INIT_VAR(_3); + zephir_create_array(_3, 1, 0 TSRMLS_CC); + zephir_array_fast_append(_3, name); + ZEPHIR_INIT_VAR(_4); + ZVAL_STRING(_4, "Phalcon\\Http\\Cookie", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&_2, _1, "get", NULL, 0, _4, _3); + zephir_check_temp_parameter(_4); zephir_check_call_status(); + ZEPHIR_CPY_WRT(cookie, _2); ZEPHIR_OBS_VAR(dependencyInjector); zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) { - ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 0, dependencyInjector); zephir_check_call_status(); ZEPHIR_OBS_VAR(encryption); zephir_read_property_this(&encryption, this_ptr, SL("_useEncryption"), PH_NOISY_CC); if (zephir_is_true(encryption)) { - ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption); + ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 0, encryption); zephir_check_call_status(); } } @@ -66262,11 +66527,11 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, send) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 54); + ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 55); zephir_check_call_status(); if (!(zephir_is_true(_0))) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_cookies"), PH_NOISY_CC); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/cookies.zep", 243); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/cookies.zep", 236); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -66381,41 +66646,53 @@ ZEPHIR_INIT_CLASS(Phalcon_Http_Response_Headers) { static PHP_METHOD(Phalcon_Http_Response_Headers, set) { - zval *name, *value; + zval *name_param = NULL, *value_param = NULL; + zval *name = NULL, *value = NULL; - zephir_fetch_params(0, 2, 0, &name, &value); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 2, 0, &name_param, &value_param); + zephir_get_strval(name, name_param); + zephir_get_strval(value, value_param); zephir_update_property_array(this_ptr, SL("_headers"), name, value TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } static PHP_METHOD(Phalcon_Http_Response_Headers, get) { - zval *name, *headers, *headerValue; + zval *name_param = NULL, *headers, *headerValue; + zval *name = NULL; - zephir_fetch_params(0, 1, 0, &name); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &name_param); + zephir_get_strval(name, name_param); headers = zephir_fetch_nproperty_this(this_ptr, SL("_headers"), PH_NOISY_CC); if (zephir_array_isset_fetch(&headerValue, headers, name, 1 TSRMLS_CC)) { - RETURN_CTORW(headerValue); + RETURN_CTOR(headerValue); } - RETURN_BOOL(0); + RETURN_MM_BOOL(0); } static PHP_METHOD(Phalcon_Http_Response_Headers, setRaw) { - zval *header; + zval *header_param = NULL; + zval *header = NULL; - zephir_fetch_params(0, 1, 0, &header); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &header_param); + zephir_get_strval(header, header_param); zephir_update_property_array(this_ptr, SL("_headers"), header, ZEPHIR_GLOBAL(global_null) TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -66448,11 +66725,11 @@ static PHP_METHOD(Phalcon_Http_Response_Headers, send) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 54); + ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 55); zephir_check_call_status(); if (!(zephir_is_true(_0))) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_headers"), PH_NOISY_CC); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/headers.zep", 98); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/headers.zep", 90); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -66462,10 +66739,10 @@ static PHP_METHOD(Phalcon_Http_Response_Headers, send) { if (!(ZEPHIR_IS_EMPTY(value))) { ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_VSV(_5, header, ": ", value); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, _5, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 237, _5, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, header, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 237, header, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); } } @@ -66519,14 +66796,14 @@ static PHP_METHOD(Phalcon_Http_Response_Headers, __set_state) { } ZEPHIR_OBS_VAR(dataHeaders); if (zephir_array_isset_string_fetch(&dataHeaders, data, SS("_headers"), 0 TSRMLS_CC)) { - zephir_is_iterable(dataHeaders, &_1, &_0, 0, 0, "phalcon/http/response/headers.zep", 130); + zephir_is_iterable(dataHeaders, &_1, &_0, 0, 0, "phalcon/http/response/headers.zep", 122); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HMKEY(key, _1, _0); ZEPHIR_GET_HVALUE(value, _2); - ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 246, key, value); + ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 238, key, value); zephir_check_call_status(); } } @@ -66815,7 +67092,7 @@ static PHP_METHOD(Phalcon_Image_Adapter, resize) { zephir_round(_8, &_9, NULL, NULL TSRMLS_CC); ZEPHIR_INIT_VAR(_10); ZVAL_LONG(_10, 1); - ZEPHIR_CALL_FUNCTION(&_11, "max", &_12, 66, _8, _10); + ZEPHIR_CALL_FUNCTION(&_11, "max", &_12, 68, _8, _10); zephir_check_call_status(); width = zephir_get_intval(_11); ZEPHIR_INIT_NVAR(_10); @@ -66824,7 +67101,7 @@ static PHP_METHOD(Phalcon_Image_Adapter, resize) { zephir_round(_10, &_13, NULL, NULL TSRMLS_CC); ZEPHIR_INIT_VAR(_14); ZVAL_LONG(_14, 1); - ZEPHIR_CALL_FUNCTION(&_15, "max", &_12, 66, _10, _14); + ZEPHIR_CALL_FUNCTION(&_15, "max", &_12, 68, _10, _14); zephir_check_call_status(); height = zephir_get_intval(_15); ZEPHIR_INIT_NVAR(_14); @@ -67150,23 +67427,19 @@ static PHP_METHOD(Phalcon_Image_Adapter, watermark) { static PHP_METHOD(Phalcon_Image_Adapter, text) { zend_bool _0; - int offsetX, offsetY, opacity, size, ZEPHIR_LAST_CALL_STATUS; - zval *text_param = NULL, *offsetX_param = NULL, *offsetY_param = NULL, *opacity_param = NULL, *color_param = NULL, *size_param = NULL, *fontfile_param = NULL, *colors = NULL, _1, _2, *_3, _4 = zval_used_for_init, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8, *_9, *_10, *_11, *_12; + int opacity, size, ZEPHIR_LAST_CALL_STATUS; + zval *text_param = NULL, *offsetX = NULL, *offsetY = NULL, *opacity_param = NULL, *color_param = NULL, *size_param = NULL, *fontfile_param = NULL, *colors = NULL, _1, _2, *_3, _4 = zval_used_for_init, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8, *_9, *_10; zval *text = NULL, *color = NULL, *fontfile = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 6, &text_param, &offsetX_param, &offsetY_param, &opacity_param, &color_param, &size_param, &fontfile_param); + zephir_fetch_params(1, 1, 6, &text_param, &offsetX, &offsetY, &opacity_param, &color_param, &size_param, &fontfile_param); zephir_get_strval(text, text_param); - if (!offsetX_param) { - offsetX = 0; - } else { - offsetX = zephir_get_intval(offsetX_param); + if (!offsetX) { + offsetX = ZEPHIR_GLOBAL(global_false); } - if (!offsetY_param) { - offsetY = 0; - } else { - offsetY = zephir_get_intval(offsetY_param); + if (!offsetY) { + offsetY = ZEPHIR_GLOBAL(global_false); } if (!opacity_param) { opacity = 100; @@ -67194,8 +67467,10 @@ static PHP_METHOD(Phalcon_Image_Adapter, text) { if (opacity < 0) { opacity = 0; - } else if (opacity > 100) { - opacity = 100; + } else { + if (opacity > 100) { + opacity = 100; + } } _0 = zephir_fast_strlen_ev(color) > 1; if (_0) { @@ -67219,7 +67494,7 @@ static PHP_METHOD(Phalcon_Image_Adapter, text) { ZVAL_STRING(_5, "/./", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "$0$0", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 28, _5, _6, color); + ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 29, _5, _6, color); zephir_check_temp_parameter(_5); zephir_check_temp_parameter(_6); zephir_check_call_status(); @@ -67227,24 +67502,20 @@ static PHP_METHOD(Phalcon_Image_Adapter, text) { } ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 2); - ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 67, color, &_4); + ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 69, color, &_4); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_STRING(&_4, "hexdec", 0); - ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 68, &_4, _7); + ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 70, &_4, _7); zephir_check_call_status(); - zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 333 TSRMLS_CC); - zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 333 TSRMLS_CC); - zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 333 TSRMLS_CC); + zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 335 TSRMLS_CC); + zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 335 TSRMLS_CC); + zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 335 TSRMLS_CC); ZEPHIR_INIT_NVAR(_5); - ZVAL_LONG(_5, offsetX); + ZVAL_LONG(_5, opacity); ZEPHIR_INIT_NVAR(_6); - ZVAL_LONG(_6, offsetY); - ZEPHIR_INIT_VAR(_11); - ZVAL_LONG(_11, opacity); - ZEPHIR_INIT_VAR(_12); - ZVAL_LONG(_12, size); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_text", NULL, 0, text, _5, _6, _11, _8, _9, _10, _12, fontfile); + ZVAL_LONG(_6, size); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_text", NULL, 0, text, offsetX, offsetY, _5, _8, _9, _10, _6, fontfile); zephir_check_call_status(); RETURN_THIS(); @@ -67306,7 +67577,7 @@ static PHP_METHOD(Phalcon_Image_Adapter, background) { ZVAL_STRING(_5, "/./", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "$0$0", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 28, _5, _6, color); + ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 29, _5, _6, color); zephir_check_temp_parameter(_5); zephir_check_temp_parameter(_6); zephir_check_call_status(); @@ -67314,15 +67585,15 @@ static PHP_METHOD(Phalcon_Image_Adapter, background) { } ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 2); - ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 67, color, &_4); + ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 69, color, &_4); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_STRING(&_4, "hexdec", 0); - ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 68, &_4, _7); + ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 70, &_4, _7); zephir_check_call_status(); - zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 364 TSRMLS_CC); - zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 364 TSRMLS_CC); - zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 364 TSRMLS_CC); + zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 366 TSRMLS_CC); + zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 366 TSRMLS_CC); + zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 366 TSRMLS_CC); ZEPHIR_INIT_NVAR(_5); ZVAL_LONG(_5, opacity); ZEPHIR_CALL_METHOD(NULL, this_ptr, "_background", NULL, 0, _8, _9, _10, _5); @@ -67444,7 +67715,7 @@ static PHP_METHOD(Phalcon_Image_Adapter, render) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 4); - ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 69, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 71, _0, &_1); zephir_check_call_status(); zephir_get_strval(_3, _2); ZEPHIR_CPY_WRT(ext, _3); @@ -67580,13 +67851,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, check) { ZVAL_NULL(version); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "GD_VERSION", 0); - ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 228, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 229, &_1); zephir_check_call_status(); if (zephir_is_true(_2)) { ZEPHIR_INIT_NVAR(version); ZEPHIR_GET_CONSTANT(version, "GD_VERSION"); } else { - ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 247); + ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 239); zephir_check_call_status(); ZEPHIR_INIT_VAR(matches); ZVAL_NULL(matches); @@ -67604,7 +67875,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, check) { ZVAL_STRING(&_5, "2.0.1", 0); ZEPHIR_SINIT_VAR(_6); ZVAL_STRING(&_6, ">=", 0); - ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 248, version, &_5, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 240, version, &_5, &_6); zephir_check_call_status(); if (!(zephir_is_true(_7))) { ZEPHIR_INIT_NVAR(_3); @@ -67666,11 +67937,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); if ((zephir_file_exists(_1 TSRMLS_CC) == SUCCESS)) { _2 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_3, "realpath", NULL, 60, _2); + ZEPHIR_CALL_FUNCTION(&_3, "realpath", NULL, 62, _2); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_realpath"), _3 TSRMLS_CC); _4 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 249, _4); + ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 241, _4); zephir_check_call_status(); if (zephir_is_true(imageinfo)) { zephir_array_fetch_long(&_5, imageinfo, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 77 TSRMLS_CC); @@ -67686,35 +67957,35 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { do { if (ZEPHIR_IS_LONG(_9, 1)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 250, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 242, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 2)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 251, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 243, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 3)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 252, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 244, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 15)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 253, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 245, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 16)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 254, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 246, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; @@ -67739,7 +68010,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { } while(0); _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _10, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 247, _10, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); } else { _16 = !width; @@ -67762,14 +68033,14 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { ZVAL_LONG(&_17, width); ZEPHIR_SINIT_VAR(_18); ZVAL_LONG(&_18, height); - ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 256, &_17, &_18); + ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 248, &_17, &_18); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _3 TSRMLS_CC); _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _4, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, _4, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _9, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 247, _9, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); zephir_update_property_this(this_ptr, SL("_realpath"), _10 TSRMLS_CC); @@ -67808,7 +68079,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION"); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "5.5.0", 0); - ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 240, _0, &_1); zephir_check_call_status(); if (ZEPHIR_LT_LONG(_2, 0)) { ZEPHIR_OBS_VAR(pre_width); @@ -67856,11 +68127,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZVAL_LONG(&_14, 0); ZEPHIR_SINIT_VAR(_15); ZVAL_LONG(&_15, 0); - ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 258, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11); + ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 250, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11); zephir_check_call_status(); if (zephir_is_true(_16)) { _17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _17); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 251, _17); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); } @@ -67884,17 +68155,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZVAL_LONG(&_15, width); ZEPHIR_SINIT_VAR(_21); ZVAL_LONG(&_21, height); - ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 260, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height); + ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 252, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height); zephir_check_call_status(); if (zephir_is_true(_16)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _10); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 251, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 261, image); + ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _22 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 262, image); + ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _24 TSRMLS_CC); } @@ -67904,16 +68175,16 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZVAL_LONG(&_6, width); ZEPHIR_SINIT_NVAR(_12); ZVAL_LONG(&_12, height); - ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 263, _3, &_6, &_12); + ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 255, _3, &_6, &_12); zephir_check_call_status(); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _5); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 251, _5); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 261, image); + ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 262, image); + ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _22 TSRMLS_CC); } @@ -67940,7 +68211,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) { ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION"); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "5.5.0", 0); - ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 240, _0, &_1); zephir_check_call_status(); if (ZEPHIR_LT_LONG(_2, 0)) { ZEPHIR_INIT_VAR(_3); @@ -67966,17 +68237,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) { ZVAL_LONG(&_11, width); ZEPHIR_SINIT_VAR(_12); ZVAL_LONG(&_12, height); - ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 260, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12); + ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 252, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12); zephir_check_call_status(); if (zephir_is_true(_13)) { _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 251, _14); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 261, image); + ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 262, image); + ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _18 TSRMLS_CC); } @@ -67996,16 +68267,16 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) { ZVAL_LONG(_3, height); zephir_array_update_string(&rect, SL("height"), &_3, PH_COPY | PH_SEPARATE); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 264, _5, rect); + ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 256, _5, rect); zephir_check_call_status(); _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 251, _14); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 261, image); + ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _13 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 262, image); + ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _16 TSRMLS_CC); } @@ -68033,20 +68304,20 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) { ZVAL_LONG(&_3, 0); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, 127); - ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 265, _0, &_1, &_2, &_3, &_4); + ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 257, _0, &_1, &_2, &_3, &_4); zephir_check_call_status(); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (360 - degrees)); ZEPHIR_SINIT_NVAR(_2); ZVAL_LONG(&_2, 1); - ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 266, _5, &_1, transparent, &_2); + ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 258, _5, &_1, transparent, &_2); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 247, image, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 261, image); + ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 253, image); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 262, image); + ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 254, image); zephir_check_call_status(); _6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); @@ -68059,11 +68330,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) { ZVAL_LONG(&_4, 0); ZEPHIR_SINIT_VAR(_7); ZVAL_LONG(&_7, 100); - ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 267, _6, image, &_1, &_2, &_3, &_4, width, height, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 259, _6, image, &_1, &_2, &_3, &_4, width, height, &_7); zephir_check_call_status(); if (zephir_is_true(_8)) { _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _9); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _9); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_width"), width TSRMLS_CC); @@ -68089,7 +68360,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION"); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "5.5.0", 0); - ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 240, _0, &_1); zephir_check_call_status(); if (ZEPHIR_LT_LONG(_2, 0)) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); @@ -68117,7 +68388,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { ZVAL_LONG(&_11, 0); ZEPHIR_SINIT_NVAR(_12); ZVAL_LONG(&_12, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, &_12, _8); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, image, _6, &_1, &_9, &_10, &_11, &_12, _8); zephir_check_call_status(); } } else { @@ -68141,18 +68412,18 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { ZVAL_LONG(&_11, ((zephir_get_numberval(_7) - x) - 1)); ZEPHIR_SINIT_NVAR(_12); ZVAL_LONG(&_12, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, _8, &_12); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, image, _6, &_1, &_9, &_10, &_11, _8, &_12); zephir_check_call_status(); } } _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _5); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _5); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 261, image); + ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _14 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 262, image); + ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _15 TSRMLS_CC); } else { @@ -68160,13 +68431,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _3, &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 261, _3, &_1); zephir_check_call_status(); } else { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 2); - ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _4, &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 261, _4, &_1); zephir_check_call_status(); } } @@ -68189,7 +68460,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) { ZEPHIR_INIT_VAR(_0); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, (-18 + ((amount * 0.08)))); - ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 193, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 2); @@ -68238,15 +68509,15 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) { ZVAL_LONG(&_6, (amount - 8)); ZEPHIR_SINIT_VAR(_7); ZVAL_LONG(&_7, 0); - ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 270, _5, matrix, &_6, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 262, _5, matrix, &_6, &_7); zephir_check_call_status(); if (zephir_is_true(_8)) { _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 261, _9); + ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 253, _9); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _10 TSRMLS_CC); _11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 262, _11); + ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 254, _11); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _12 TSRMLS_CC); } @@ -68272,7 +68543,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZEPHIR_INIT_VAR(_0); ZEPHIR_SINIT_VAR(_1); ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127))); - ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 193, &_1); zephir_check_call_status(); zephir_round(_0, _2, NULL, NULL TSRMLS_CC); opacity = zephir_get_intval(_0); @@ -68298,7 +68569,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_11, 0); ZEPHIR_SINIT_VAR(_12); ZVAL_LONG(&_12, 0); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, _7, &_1, &_10, &_11, &_12, _8, _9); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, reflection, _7, &_1, &_10, &_11, &_12, _8, _9); zephir_check_call_status(); offset = 0; while (1) { @@ -68339,7 +68610,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_21, src_y); ZEPHIR_SINIT_NVAR(_22); ZVAL_LONG(&_22, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, line, _18, &_11, &_12, &_20, &_21, _19, &_22); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, line, _18, &_11, &_12, &_20, &_21, _19, &_22); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_11); ZVAL_LONG(&_11, 4); @@ -68351,7 +68622,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_21, 0); ZEPHIR_SINIT_NVAR(_22); ZVAL_LONG(&_22, dst_opacity); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 271, line, &_11, &_12, &_20, &_21, &_22); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 263, line, &_11, &_12, &_20, &_21, &_22); zephir_check_call_status(); _24 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_11); @@ -68364,18 +68635,18 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_21, 0); ZEPHIR_SINIT_NVAR(_22); ZVAL_LONG(&_22, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, line, &_11, &_12, &_20, &_21, _24, &_22); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, reflection, line, &_11, &_12, &_20, &_21, _24, &_22); zephir_check_call_status(); offset++; } _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _14); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), reflection TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 261, reflection); + ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 253, reflection); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _25 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 262, reflection); + ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 254, reflection); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _26 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -68397,21 +68668,21 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZEPHIR_CALL_METHOD(&_0, watermark, "render", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 272, _0); + ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 264, _0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, overlay, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 247, overlay, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, overlay); + ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 253, overlay); zephir_check_call_status(); width = zephir_get_intval(_1); - ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, overlay); + ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 254, overlay); zephir_check_call_status(); height = zephir_get_intval(_2); if (opacity < 100) { ZEPHIR_INIT_VAR(_3); ZEPHIR_SINIT_VAR(_4); ZVAL_DOUBLE(&_4, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127))); - ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 192, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 193, &_4); zephir_check_call_status(); zephir_round(_3, _5, NULL, NULL TSRMLS_CC); opacity = zephir_get_intval(_3); @@ -68423,11 +68694,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZVAL_LONG(&_7, 127); ZEPHIR_SINIT_VAR(_8); ZVAL_LONG(&_8, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, overlay, &_4, &_6, &_7, &_8); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 257, overlay, &_4, &_6, &_7, &_8); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 3); - ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 273, overlay, &_4); + ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 265, overlay, &_4); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 0); @@ -68437,11 +68708,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZVAL_LONG(&_7, width); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, height); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 274, overlay, &_4, &_6, &_7, &_8, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 266, overlay, &_4, &_6, &_7, &_8, color); zephir_check_call_status(); } _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _9, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, _9, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_4); @@ -68456,10 +68727,10 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZVAL_LONG(&_11, width); ZEPHIR_SINIT_VAR(_12); ZVAL_LONG(&_12, height); - ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 268, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12); + ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 260, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12); zephir_check_call_status(); if (zephir_is_true(_5)) { - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, overlay); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, overlay); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -68491,7 +68762,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZEPHIR_INIT_VAR(_0); ZEPHIR_SINIT_VAR(_1); ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127))); - ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 193, &_1); zephir_check_call_status(); zephir_round(_0, _2, NULL, NULL TSRMLS_CC); opacity = zephir_get_intval(_0); @@ -68500,7 +68771,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_1, size); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, 0); - ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 275, &_1, &_4, fontfile, text); + ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 267, &_1, &_4, fontfile, text); zephir_check_call_status(); if (zephir_array_isset_long(space, 0)) { ZEPHIR_OBS_VAR(_5); @@ -68534,12 +68805,12 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { } ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (s4 - s0)); - ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 193, &_1); zephir_check_call_status(); width = (zephir_get_numberval(_12) + 10); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (s5 - s1)); - ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 193, &_1); zephir_check_call_status(); height = (zephir_get_numberval(_13) + 10); if (offsetX < 0) { @@ -68559,7 +68830,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_15, b); ZEPHIR_SINIT_VAR(_16); ZVAL_LONG(&_16, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 257, _14, &_1, &_4, &_15, &_16); zephir_check_call_status(); angle = 0; _18 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -68571,17 +68842,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_15, offsetX); ZEPHIR_SINIT_NVAR(_16); ZVAL_LONG(&_16, offsetY); - ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 276, _18, &_1, &_4, &_15, &_16, color, fontfile, text); + ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 268, _18, &_1, &_4, &_15, &_16, color, fontfile, text); zephir_check_call_status(); } else { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, size); - ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 277, &_1); + ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 269, &_1); zephir_check_call_status(); width = (zephir_get_intval(_12) * zephir_fast_strlen_ev(text)); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, size); - ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 278, &_1); + ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 270, &_1); zephir_check_call_status(); height = zephir_get_intval(_13); if (offsetX < 0) { @@ -68601,7 +68872,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_15, b); ZEPHIR_SINIT_NVAR(_16); ZVAL_LONG(&_16, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 257, _14, &_1, &_4, &_15, &_16); zephir_check_call_status(); _19 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); @@ -68610,7 +68881,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_4, offsetX); ZEPHIR_SINIT_NVAR(_15); ZVAL_LONG(&_15, offsetY); - ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 279, _19, &_1, &_4, &_15, text, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 271, _19, &_1, &_4, &_15, text, color); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -68631,22 +68902,22 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZEPHIR_CALL_METHOD(&_0, mask, "render", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 272, _0); + ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 264, _0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, maskImage); + ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 253, maskImage); zephir_check_call_status(); mask_width = zephir_get_intval(_1); - ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, maskImage); + ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 254, maskImage); zephir_check_call_status(); mask_height = zephir_get_intval(_2); alpha = 127; - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, maskImage, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 247, maskImage, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _4 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); ZEPHIR_CALL_METHOD(&newimage, this_ptr, "_create", NULL, 0, _4, _5); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, newimage, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 247, newimage, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_6); ZVAL_LONG(&_6, 0); @@ -68656,13 +68927,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_8, 0); ZEPHIR_SINIT_VAR(_9); ZVAL_LONG(&_9, alpha); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, &_6, &_7, &_8, &_9); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 257, newimage, &_6, &_7, &_8, &_9); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_6); ZVAL_LONG(&_6, 0); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, 0); - ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 280, newimage, &_6, &_7, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 272, newimage, &_6, &_7, color); zephir_check_call_status(); _11 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _12 = !ZEPHIR_IS_LONG(_11, mask_width); @@ -68673,7 +68944,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { if (_12) { _14 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _15 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 256, _14, _15); + ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 248, _14, _15); zephir_check_call_status(); _16 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _17 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); @@ -68689,9 +68960,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_18, mask_width); ZEPHIR_SINIT_VAR(_19); ZVAL_LONG(&_19, mask_height); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 260, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 252, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 251, maskImage); zephir_check_call_status(); ZEPHIR_CPY_WRT(maskImage, tempImage); } @@ -68711,9 +68982,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_6, x); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, y); - ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, maskImage, &_6, &_7); + ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 273, maskImage, &_6, &_7); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, maskImage, index); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 274, maskImage, index); zephir_check_call_status(); if (zephir_array_isset_string(color, SS("red"))) { zephir_array_fetch_string(&_23, color, SL("red"), PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 431 TSRMLS_CC); @@ -68726,10 +68997,10 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_7, x); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, y); - ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, _16, &_7, &_8); + ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 273, _16, &_7, &_8); zephir_check_call_status(); _17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, _17, index); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 274, _17, index); zephir_check_call_status(); ZEPHIR_OBS_NVAR(r); zephir_array_fetch_string(&r, color, SL("red"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC); @@ -68739,22 +69010,22 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { zephir_array_fetch_string(&b, color, SL("blue"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, alpha); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, r, g, b, &_7); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 257, newimage, r, g, b, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, x); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, y); - ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 283, newimage, &_7, &_8, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 275, newimage, &_7, &_8, color); zephir_check_call_status(); y++; } x++; } _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 251, _14); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 251, maskImage); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), newimage TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -68788,9 +69059,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) { ZVAL_LONG(&_4, b); ZEPHIR_SINIT_VAR(_5); ZVAL_LONG(&_5, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, background, &_2, &_3, &_4, &_5); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 257, background, &_2, &_3, &_4, &_5); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, background, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, background, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); @@ -68803,11 +69074,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) { ZVAL_LONG(&_4, 0); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, 0); - ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 268, background, _6, &_2, &_3, &_4, &_5, _7, _8); + ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 260, background, _6, &_2, &_3, &_4, &_5, _7, _8); zephir_check_call_status(); if (zephir_is_true(_9)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _10); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), background TSRMLS_CC); } @@ -68835,7 +69106,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _blur) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 7); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 271, _0, &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 263, _0, &_1); zephir_check_call_status(); i++; } @@ -68874,7 +69145,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) { ZVAL_LONG(&_3, x1); ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, y1); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 281, _2, &_3, &_4); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 273, _2, &_3, &_4); zephir_check_call_status(); x2 = (x + amount); y2 = (y + amount); @@ -68887,7 +69158,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) { ZVAL_LONG(&_7, x2); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, y2); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 274, _6, &_3, &_4, &_7, &_8, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 266, _6, &_3, &_4, &_7, &_8, color); zephir_check_call_status(); y += amount; } @@ -68900,9 +69171,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) { static PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) { zend_bool _8; - zephir_fcall_cache_entry *_3 = NULL, *_6 = NULL; + zephir_fcall_cache_entry *_4 = NULL, *_6 = NULL; int quality, ZEPHIR_LAST_CALL_STATUS; - zval *file_param = NULL, *quality_param = NULL, *ext, _0 = zval_used_for_init, *_1 = NULL, *_2 = NULL, *_4, *_5 = NULL, *_7, *_9 = NULL, *_10 = NULL, *_11, *_12; + zval *file_param = NULL, *quality_param = NULL, *ext = NULL, _0 = zval_used_for_init, *_1, *_2 = NULL, *_3 = NULL, *_5 = NULL, *_7, *_9 = NULL, *_10 = NULL, *_11; zval *file = NULL; ZEPHIR_MM_GROW(); @@ -68914,112 +69185,118 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 4); - ZEPHIR_CALL_FUNCTION(&_1, "pathinfo", NULL, 69, file, &_0); + ZEPHIR_CALL_FUNCTION(&ext, "pathinfo", NULL, 71, file, &_0); zephir_check_call_status(); - ZEPHIR_INIT_VAR(ext); - zephir_fast_strtolower(ext, _1); + if (!(zephir_is_true(ext))) { + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&ext, "image_type_to_extension", NULL, 276, _1, ZEPHIR_GLOBAL(global_false)); + zephir_check_call_status(); + } + ZEPHIR_INIT_VAR(_2); + zephir_fast_strtolower(_2, ext); + ZEPHIR_CPY_WRT(ext, _2); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_3, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); - if (ZEPHIR_IS_LONG(_2, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 1); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 285, _4); + if (ZEPHIR_IS_LONG(_3, 0)) { + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 1); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _5 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 279, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); _8 = ZEPHIR_IS_LONG(_5, 0); if (!(_8)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); _8 = ZEPHIR_IS_LONG(_9, 0); } if (_8) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 2); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 2); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_LONG(&_0, quality); - ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _7, file, &_0); + ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 280, _7, file, &_0); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "png", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_5, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 3); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 3); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 281, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "wbmp", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_5, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 15); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 15); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 282, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "xbm", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_5, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 16); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 16); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 283, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } + ZEPHIR_INIT_NVAR(_2); + object_init_ex(_2, phalcon_image_exception_ce); ZEPHIR_INIT_VAR(_11); - object_init_ex(_11, phalcon_image_exception_ce); - ZEPHIR_INIT_VAR(_12); - ZEPHIR_CONCAT_SVS(_12, "Installed GD does not support '", ext, "' images"); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", NULL, 9, _12); + ZEPHIR_CONCAT_SVS(_11, "Installed GD does not support '", ext, "' images"); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _11); zephir_check_call_status(); - zephir_throw_exception_debug(_11, "phalcon/image/adapter/gd.zep", 537 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/image/adapter/gd.zep", 544 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -69043,29 +69320,29 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) { ZEPHIR_INIT_VAR(_0); zephir_fast_strtolower(_0, ext); zephir_get_strval(ext, _0); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_2, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _4); + ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 279, _4); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG(_6, 0); if (!(_7)) { ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG(_8, 0); } @@ -69073,45 +69350,45 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, quality); - ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _4, ZEPHIR_GLOBAL(global_null), &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 280, _4, ZEPHIR_GLOBAL(global_null), &_1); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "png", 0); - ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_9, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _4); + ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 281, _4); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "wbmp", 0); - ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_10, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _4); + ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 282, _4); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "xbm", 0); - ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_11, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _4, ZEPHIR_GLOBAL(global_null)); + ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 283, _4, ZEPHIR_GLOBAL(global_null)); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } @@ -69121,7 +69398,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) { ZEPHIR_CONCAT_SVS(_13, "Installed GD does not support '", ext, "' images"); ZEPHIR_CALL_METHOD(NULL, _12, "__construct", NULL, 9, _13); zephir_check_call_status(); - zephir_throw_exception_debug(_12, "phalcon/image/adapter/gd.zep", 565 TSRMLS_CC); + zephir_throw_exception_debug(_12, "phalcon/image/adapter/gd.zep", 572 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -69143,11 +69420,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _create) { ZVAL_LONG(&_0, width); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, height); - ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 256, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 248, &_0, &_1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, image, ZEPHIR_GLOBAL(global_false)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, image, ZEPHIR_GLOBAL(global_false)); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 247, image, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); RETURN_CCTOR(image); @@ -69163,7 +69440,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __destruct) { ZEPHIR_OBS_VAR(image); zephir_read_property_this(&image, this_ptr, SL("_image"), PH_NOISY_CC); if (Z_TYPE_P(image) == IS_RESOURCE) { - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, image); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, image); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -69216,12 +69493,12 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, check) { } ZEPHIR_SINIT_VAR(_2); ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0); - ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 228, &_2); + ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 229, &_2); zephir_check_call_status(); if (zephir_is_true(_3)) { ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0); - ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_2); + ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 191, &_2); zephir_check_call_status(); zephir_update_static_property_ce(phalcon_image_adapter_imagick_ce, SL("_version"), &_4 TSRMLS_CC); } @@ -69280,7 +69557,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, __construct) { _2 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); if ((zephir_file_exists(_2 TSRMLS_CC) == SUCCESS)) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_4, "realpath", NULL, 60, _3); + ZEPHIR_CALL_FUNCTION(&_4, "realpath", NULL, 62, _3); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_realpath"), _4 TSRMLS_CC); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -69306,7 +69583,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, __construct) { _12 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_13); ZVAL_STRING(&_13, "Imagick::ALPHACHANNEL_SET", 0); - ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 190, &_13); + ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 191, &_13); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _12, "setimagealphachannel", NULL, 0, _14); zephir_check_call_status(); @@ -69778,7 +70055,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { while (1) { ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::COMPOSITE_DSTOUT", 0); - ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, 0); @@ -69792,11 +70069,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { } ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::EVALUATE_MULTIPLY", 0); - ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::CHANNEL_ALPHA", 0); - ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, opacity); @@ -69839,7 +70116,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::ALPHACHANNEL_SET", 0); - ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, image, "setimagealphachannel", &_25, 0, _9); zephir_check_call_status(); @@ -69856,7 +70133,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { _30 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::COMPOSITE_SRC", 0); - ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, 0); @@ -69886,7 +70163,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { while (1) { ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::COMPOSITE_OVER", 0); - ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 191, &_14); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); ZEPHIR_INIT_NVAR(_3); @@ -69968,7 +70245,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _watermark) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_4); ZVAL_STRING(&_4, "Imagick::COMPOSITE_OVER", 0); - ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 190, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 191, &_4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_1); ZVAL_LONG(_1, offsetX); @@ -69997,17 +70274,18 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _watermark) { static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) { - zephir_fcall_cache_entry *_6 = NULL, *_8 = NULL; - int offsetX, offsetY, opacity, r, g, b, size, ZEPHIR_LAST_CALL_STATUS; - zval *text_param = NULL, *offsetX_param = NULL, *offsetY_param = NULL, *opacity_param = NULL, *r_param = NULL, *g_param = NULL, *b_param = NULL, *size_param = NULL, *fontfile_param = NULL, *draw, *color = NULL, *pixel, *gravity = NULL, _0 = zval_used_for_init, _1, _2, _3, *_4 = NULL, *_5 = NULL, *_7 = NULL, *_9, *_10, *_11 = NULL, *_12 = NULL, *_13; + zephir_fcall_cache_entry *_7 = NULL; + zend_bool _6; + int opacity, r, g, b, size, x, y, ZEPHIR_LAST_CALL_STATUS; + zval *text_param = NULL, *offsetX = NULL, *offsetY = NULL, *opacity_param = NULL, *r_param = NULL, *g_param = NULL, *b_param = NULL, *size_param = NULL, *fontfile_param = NULL, *draw, *color = NULL, *gravity = NULL, _0 = zval_used_for_init, _1, _2, _3, *_4, *_5 = NULL, *_8, *_9, *_10, *_11 = NULL; zval *text = NULL, *fontfile = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 9, 0, &text_param, &offsetX_param, &offsetY_param, &opacity_param, &r_param, &g_param, &b_param, &size_param, &fontfile_param); + zephir_fetch_params(1, 9, 0, &text_param, &offsetX, &offsetY, &opacity_param, &r_param, &g_param, &b_param, &size_param, &fontfile_param); zephir_get_strval(text, text_param); - offsetX = zephir_get_intval(offsetX_param); - offsetY = zephir_get_intval(offsetY_param); + ZEPHIR_SEPARATE_PARAM(offsetX); + ZEPHIR_SEPARATE_PARAM(offsetY); opacity = zephir_get_intval(opacity_param); r = zephir_get_intval(r_param); g = zephir_get_intval(g_param); @@ -70031,76 +70309,210 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) { ZVAL_LONG(&_2, g); ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, b); - ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 188, &_0, &_1, &_2, &_3); zephir_check_call_status(); - ZEPHIR_INIT_VAR(pixel); - object_init_ex(pixel, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC)); - if (zephir_has_constructor(pixel TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(NULL, pixel, "__construct", NULL, 0, color); + ZEPHIR_INIT_VAR(_4); + object_init_ex(_4, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC)); + if (zephir_has_constructor(_4 TSRMLS_CC)) { + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 0, color); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, draw, "setfillcolor", NULL, 0, pixel); + ZEPHIR_CALL_METHOD(NULL, draw, "setfillcolor", NULL, 0, _4); zephir_check_call_status(); if (fontfile && Z_STRLEN_P(fontfile)) { ZEPHIR_CALL_METHOD(NULL, draw, "setfont", NULL, 0, fontfile); zephir_check_call_status(); } if (size) { - ZEPHIR_INIT_VAR(_4); - ZVAL_LONG(_4, size); - ZEPHIR_CALL_METHOD(NULL, draw, "setfontsize", NULL, 0, _4); + ZEPHIR_INIT_VAR(_5); + ZVAL_LONG(_5, size); + ZEPHIR_CALL_METHOD(NULL, draw, "setfontsize", NULL, 0, _5); zephir_check_call_status(); } if (opacity) { - ZEPHIR_INIT_NVAR(_4); - ZVAL_LONG(_4, opacity); - ZEPHIR_CALL_METHOD(NULL, draw, "setfillopacity", NULL, 0, _4); - zephir_check_call_status(); - } - if (offsetX < 0) { - ZEPHIR_SINIT_NVAR(_0); - ZVAL_LONG(&_0, offsetX); - ZEPHIR_CALL_FUNCTION(&_5, "abs", &_6, 192, &_0); - zephir_check_call_status(); - offsetX = zephir_get_numberval(_5); - if (offsetY < 0) { - ZEPHIR_SINIT_NVAR(_0); - ZVAL_LONG(&_0, offsetY); - ZEPHIR_CALL_FUNCTION(&_7, "abs", &_6, 192, &_0); - zephir_check_call_status(); - offsetY = zephir_get_numberval(_7); - ZEPHIR_SINIT_NVAR(_0); - ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); - ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0); - zephir_check_call_status(); + ZEPHIR_INIT_NVAR(_5); + ZVAL_LONG(_5, opacity); + ZEPHIR_CALL_METHOD(NULL, draw, "setfillopacity", NULL, 0, _5); + zephir_check_call_status(); + } + ZEPHIR_INIT_VAR(gravity); + ZVAL_NULL(gravity); + if (Z_TYPE_P(offsetX) == IS_BOOL) { + if (Z_TYPE_P(offsetY) == IS_BOOL) { + ZEPHIR_INIT_NVAR(offsetX); + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, 0); + _6 = zephir_is_true(offsetX); + if (_6) { + _6 = zephir_is_true(offsetY); + } + if (_6) { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + if (zephir_is_true(offsetX)) { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_EAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + if (zephir_is_true(offsetY)) { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_CENTER", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } } else { - ZEPHIR_SINIT_NVAR(_0); - ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0); - ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0); - zephir_check_call_status(); + if (Z_TYPE_P(offsetY) == IS_LONG) { + y = zephir_get_intval(offsetY); + if (zephir_is_true(offsetX)) { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } else { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } + } + } else { + if (Z_TYPE_P(offsetX) == IS_LONG) { + x = zephir_get_intval(offsetX); + if (zephir_is_true(offsetX)) { + if (Z_TYPE_P(offsetY) == IS_BOOL) { + if (zephir_is_true(offsetY)) { + ZEPHIR_INIT_NVAR(offsetY); + if (x < 0) { + ZEPHIR_INIT_NVAR(offsetX); + ZVAL_LONG(offsetX, (x * -1)); + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } else { + ZEPHIR_INIT_NVAR(offsetY); + if (x < 0) { + ZEPHIR_INIT_NVAR(offsetX); + ZVAL_LONG(offsetX, (x * -1)); + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_EAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_WEST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } else { + if (Z_TYPE_P(offsetY) == IS_LONG) { + x = zephir_get_intval(offsetX); + y = zephir_get_intval(offsetY); + if (x < 0) { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, (x * -1)); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, (x * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } else { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHWEST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHWEST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } + } + } } } ZEPHIR_CALL_METHOD(NULL, draw, "setgravity", NULL, 0, gravity); zephir_check_call_status(); - _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_INIT_NVAR(_4); - ZVAL_LONG(_4, 0); - ZEPHIR_CALL_METHOD(NULL, _9, "setiteratorindex", NULL, 0, _4); + _8 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); + ZEPHIR_INIT_NVAR(_5); + ZVAL_LONG(_5, 0); + ZEPHIR_CALL_METHOD(NULL, _8, "setiteratorindex", NULL, 0, _5); zephir_check_call_status(); while (1) { - _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_INIT_NVAR(_4); - ZVAL_LONG(_4, offsetX); - ZEPHIR_INIT_NVAR(_11); - ZVAL_LONG(_11, offsetY); - ZEPHIR_INIT_NVAR(_12); - ZVAL_LONG(_12, 0); - ZEPHIR_CALL_METHOD(NULL, _10, "annotateimage", NULL, 0, draw, _4, _11, _12, text); + _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); + ZEPHIR_INIT_NVAR(_5); + ZVAL_LONG(_5, 0); + ZEPHIR_CALL_METHOD(NULL, _9, "annotateimage", NULL, 0, draw, offsetX, offsetY, _5, text); zephir_check_call_status(); - _13 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(&_5, _13, "nextimage", NULL, 0); + _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(&_11, _10, "nextimage", NULL, 0); zephir_check_call_status(); - if (ZEPHIR_IS_FALSE_IDENTICAL(_5)) { + if (ZEPHIR_IS_FALSE_IDENTICAL(_11)) { break; } } @@ -70145,7 +70557,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _mask) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Imagick::COMPOSITE_DSTIN", 0); - ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 190, &_5); + ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 191, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_2); ZVAL_LONG(_2, 0); @@ -70154,7 +70566,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _mask) { ZEPHIR_CALL_METHOD(&ret, _4, "compositeimage", NULL, 0, mask, _6, _2, _8); zephir_check_call_status(); if (!ZEPHIR_IS_TRUE_IDENTICAL(ret)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 453); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 531); return; } _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -70195,7 +70607,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { ZVAL_LONG(&_2, g); ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, b); - ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 188, &_0, &_1, &_2, &_3); zephir_check_call_status(); ZEPHIR_INIT_VAR(pixel1); object_init_ex(pixel1, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC)); @@ -70234,7 +70646,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { if (!(zephir_is_true(_9))) { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::ALPHACHANNEL_SET", 0); - ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, background, "setimagealphachannel", &_13, 0, _11); zephir_check_call_status(); @@ -70243,11 +70655,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::EVALUATE_MULTIPLY", 0); - ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::CHANNEL_ALPHA", 0); - ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_4); ZVAL_LONG(_4, opacity); @@ -70261,7 +70673,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { _20 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::COMPOSITE_DISSOLVE", 0); - ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_4); ZVAL_LONG(_4, 0); @@ -70270,7 +70682,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { ZEPHIR_CALL_METHOD(&ret, background, "compositeimage", &_23, 0, _20, _21, _4, _22); zephir_check_call_status(); if (!ZEPHIR_IS_TRUE_IDENTICAL(ret)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 492); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 570); return; } _24 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -70387,7 +70799,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 4); - ZEPHIR_CALL_FUNCTION(&ext, "pathinfo", NULL, 69, file, &_0); + ZEPHIR_CALL_FUNCTION(&ext, "pathinfo", NULL, 71, file, &_0); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_CALL_METHOD(NULL, _1, "setformat", NULL, 0, ext); @@ -70407,7 +70819,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { zephir_update_property_this(this_ptr, SL("_mime"), _7 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_9, 140, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_9, 19, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_8, 0)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -70415,7 +70827,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "w", 0); - ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 292, file, &_0); + ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 285, file, &_0); zephir_check_call_status(); _11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_CALL_METHOD(NULL, _11, "writeimagesfile", NULL, 0, fp); @@ -70425,13 +70837,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { } else { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_12, "strcasecmp", &_9, 140, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_12, "strcasecmp", &_9, 19, ext, &_0); zephir_check_call_status(); _13 = ZEPHIR_IS_LONG(_12, 0); if (!(_13)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_14, "strcasecmp", &_9, 140, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_14, "strcasecmp", &_9, 19, ext, &_0); zephir_check_call_status(); _13 = ZEPHIR_IS_LONG(_14, 0); } @@ -70439,7 +70851,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::COMPRESSION_JPEG", 0); - ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 191, &_0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _10, "setimagecompression", NULL, 0, _15); zephir_check_call_status(); @@ -70490,7 +70902,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _render) { zephir_update_property_this(this_ptr, SL("_mime"), _2 TSRMLS_CC); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_4, "strcasecmp", &_5, 140, extension, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "strcasecmp", &_5, 19, extension, &_3); zephir_check_call_status(); if (ZEPHIR_IS_LONG_IDENTICAL(_4, 0)) { ZEPHIR_CALL_METHOD(NULL, image, "optimizeimagelayers", NULL, 0); @@ -70498,20 +70910,20 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _render) { } else { ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_6, "strcasecmp", &_5, 140, extension, &_3); + ZEPHIR_CALL_FUNCTION(&_6, "strcasecmp", &_5, 19, extension, &_3); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG_IDENTICAL(_6, 0); if (!(_7)) { ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_5, 140, extension, &_3); + ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_5, 19, extension, &_3); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG_IDENTICAL(_8, 0); } if (_7) { ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "Imagick::COMPRESSION_JPEG", 0); - ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 190, &_3); + ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 191, &_3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, image, "setimagecompression", NULL, 0, _9); zephir_check_call_status(); @@ -71094,7 +71506,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter, log) { if (zephir_is_true(_3)) { ZEPHIR_INIT_VAR(_4); object_init_ex(_4, phalcon_logger_item_ce); - ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 52, toggledMessage, toggledType, timestamp, context); + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 53, toggledMessage, toggledType, timestamp, context); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_queue"), _4 TSRMLS_CC); } else { @@ -71285,7 +71697,7 @@ static PHP_METHOD(Phalcon_Logger_Formatter, interpolate) { ZEPHIR_CONCAT_SVS(_4, "{", key, "}"); zephir_array_update_zval(&replace, _4, &value, PH_COPY | PH_SEPARATE); } - ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 53, message, replace); + ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 54, message, replace); zephir_check_call_status(); RETURN_MM(); } @@ -71910,7 +72322,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, __construct) { ZEPHIR_INIT_NVAR(mode); ZVAL_STRING(mode, "ab", 1); } - ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 292, name, mode); + ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 285, name, mode); zephir_check_call_status(); if (Z_TYPE_P(handler) != IS_RESOURCE) { ZEPHIR_INIT_VAR(_0); @@ -71942,7 +72354,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, getFormatter) { if (Z_TYPE_P(_0) != IS_OBJECT) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_logger_formatter_line_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 289); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC); } @@ -72022,7 +72434,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, __wakeup) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_logger_exception_ce, "Logger must be opened in append or write mode", "phalcon/logger/adapter/file.zep", 152); return; } - ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 292, path, mode); + ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 285, path, mode); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_fileHandler"), _1 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -72107,15 +72519,15 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) { if (!ZEPHIR_IS_TRUE_IDENTICAL(_1)) { ZEPHIR_SINIT_VAR(_2); ZVAL_STRING(&_2, "X-Wf-Protocol-1: http://meta.wildfirehq.org/Protocol/JsonStream/0.2", 0); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, &_2); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "X-Wf-1-Plugin-1: http://meta.firephp.org/Wildfire/Plugin/FirePHP/Library-FirePHPCore/0.3", 0); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, &_2); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "X-Wf-Structure-1: http://meta.firephp.org/Wildfire/Structure/FirePHP/FirebugConsole/0.1", 0); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, &_2); zephir_check_call_status(); zephir_update_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_initialized"), &(ZEPHIR_GLOBAL(global_true)) TSRMLS_CC); } @@ -72129,7 +72541,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_LONG(&_2, 4500); - ZEPHIR_CALL_FUNCTION(&chunk, "str_split", NULL, 67, format, &_2); + ZEPHIR_CALL_FUNCTION(&chunk, "str_split", NULL, 69, format, &_2); zephir_check_call_status(); zephir_is_iterable(chunk, &_8, &_7, 0, 0, "phalcon/logger/adapter/firephp.zep", 102); for ( @@ -72145,7 +72557,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) { if (zephir_array_isset_long(chunk, (zephir_get_numberval(key) + 1))) { zephir_concat_self_str(&content, SL("|\\") TSRMLS_CC); } - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, content); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, content); zephir_check_call_status(); _10 = zephir_fetch_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_index") TSRMLS_CC); ZEPHIR_INIT_ZVAL_NREF(_11); @@ -72223,7 +72635,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Stream, __construct) { ZEPHIR_INIT_NVAR(mode); ZVAL_STRING(mode, "ab", 1); } - ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 292, name, mode); + ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 285, name, mode); zephir_check_call_status(); if (!(zephir_is_true(stream))) { ZEPHIR_INIT_VAR(_0); @@ -72253,7 +72665,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Stream, getFormatter) { if (Z_TYPE_P(_0) != IS_OBJECT) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_logger_formatter_line_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 289); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC); } @@ -72355,7 +72767,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, __construct) { ZEPHIR_INIT_NVAR(facility); ZVAL_LONG(facility, 8); } - ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 297, name, option, facility); + ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 290, name, option, facility); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_opened"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } @@ -72415,7 +72827,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, logInternal) { } zephir_array_fetch_long(&_3, appliedFormat, 0, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC); zephir_array_fetch_long(&_4, appliedFormat, 1, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 298, _3, _4); + ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 291, _3, _4); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -72430,7 +72842,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, close) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_opened"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 299); + ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 292); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -72587,15 +72999,15 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Firephp, format) { ZVAL_STRING(&_3, "5.3.6", 0); ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "<", 0); - ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 248, _1, &_3, &_4); + ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 240, _1, &_3, &_4); zephir_check_call_status(); if (!(zephir_is_true(_0))) { param = (2) ? 1 : 0; } - ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 150, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 151, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); Z_SET_ISREF_P(backtrace); - ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 170, backtrace); + ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 171, backtrace); Z_UNSET_ISREF_P(backtrace); zephir_check_call_status(); if (zephir_array_isset_string(lastTrace, SS("file"))) { @@ -72766,13 +73178,17 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, getDateFormat) { static PHP_METHOD(Phalcon_Logger_Formatter_Line, setDateFormat) { - zval *dateFormat; + zval *dateFormat_param = NULL; + zval *dateFormat = NULL; - zephir_fetch_params(0, 1, 0, &dateFormat); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &dateFormat_param); + zephir_get_strval(dateFormat, dateFormat_param); zephir_update_property_this(this_ptr, SL("_dateFormat"), dateFormat TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -72785,13 +73201,17 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, getFormat) { static PHP_METHOD(Phalcon_Logger_Formatter_Line, setFormat) { - zval *format; + zval *format_param = NULL; + zval *format = NULL; - zephir_fetch_params(0, 1, 0, &format); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &format_param); + zephir_get_strval(format, format_param); zephir_update_property_this(this_ptr, SL("_format"), format TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -72842,7 +73262,7 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, format) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dateFormat"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_2); ZVAL_LONG(&_2, timestamp); - ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 300, _1, &_2); + ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 293, _1, &_2); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "%date%", 0); @@ -73896,7 +74316,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, _getResultset) { } ZEPHIR_INIT_VAR(collections); array_init(collections); - ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 301, documentsCursor); + ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 294, documentsCursor); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/collection.zep", 440); for ( @@ -74359,7 +74779,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, save) { zephir_update_property_this(this_ptr, SL("_errorMessages"), _1 TSRMLS_CC); ZEPHIR_OBS_VAR(disableEvents); zephir_read_static_property_ce(&disableEvents, phalcon_mvc_collection_ce, SL("_disableEvents") TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 302, dependencyInjector, disableEvents, exists); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 295, dependencyInjector, disableEvents, exists); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(_2)) { RETURN_MM_BOOL(0); @@ -74388,7 +74808,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, save) { } else { success = 0; } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 303, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 296, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists); zephir_check_call_status(); RETURN_MM(); @@ -74806,7 +75226,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, toArray) { zephir_check_call_status(); ZEPHIR_INIT_VAR(data); array_init(data); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, this_ptr); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/collection.zep", 1244); for ( @@ -74838,7 +75258,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, serialize) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "toarray", NULL, 0); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -74869,7 +75289,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, unserialize) { } - ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(attributes) == IS_ARRAY) { ZEPHIR_CALL_CE_STATIC(&dependencyInjector, phalcon_di_ce, "getdefault", &_0, 1); @@ -75717,7 +76137,7 @@ static PHP_METHOD(Phalcon_Mvc_Micro, mount) { if (zephir_is_true(_0)) { ZEPHIR_INIT_VAR(lazyHandler); object_init_ex(lazyHandler, phalcon_mvc_micro_lazyloader_ce); - ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 304, mainHandler); + ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 297, mainHandler); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(lazyHandler, mainHandler); @@ -75866,11 +76286,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, setService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 305, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 298, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -75903,11 +76323,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, hasService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 306, serviceName); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 299, serviceName); zephir_check_call_status(); RETURN_MM(); @@ -75940,11 +76360,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, getService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 307, serviceName); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 300, serviceName); zephir_check_call_status(); RETURN_MM(); @@ -75965,11 +76385,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, getSharedService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 308, serviceName); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 301, serviceName); zephir_check_call_status(); RETURN_MM(); @@ -76533,7 +76953,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __construct) { zephir_check_call_status(); } if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 135); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 134); return; } zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); @@ -76545,7 +76965,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __construct) { zephir_check_call_status(); ZEPHIR_CPY_WRT(modelsManager, _1); if (Z_TYPE_P(modelsManager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 146); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 145); return; } } @@ -76623,7 +77043,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getModelsMetaData) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _0); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 215); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 214); return; } ZEPHIR_INIT_VAR(_2); @@ -76633,7 +77053,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getModelsMetaData) { zephir_check_call_status(); ZEPHIR_CPY_WRT(metaData, _1); if (Z_TYPE_P(metaData) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsMetadata' is not valid", "phalcon/mvc/model.zep", 223); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsMetadata' is not valid", "phalcon/mvc/model.zep", 222); return; } zephir_update_property_this(this_ptr, SL("_modelsMetaData"), metaData TSRMLS_CC); @@ -76947,7 +77367,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, assign) { if (Z_TYPE_P(dataColumnMap) == IS_ARRAY) { ZEPHIR_INIT_VAR(dataMapped); array_init(dataMapped); - zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 437); + zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 436); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -76976,7 +77396,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, assign) { } ZEPHIR_CALL_METHOD(&_3, metaData, "getattributes", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(_3, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 489); + zephir_is_iterable(_3, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 488); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -76992,7 +77412,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, assign) { ZEPHIR_CONCAT_SVS(_8, "Column '", attribute, "' doesn\\'t make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_9, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_7, "phalcon/mvc/model.zep", 459 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model.zep", 458 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -77060,7 +77480,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { ZVAL_LONG(_0, dirtyState); ZEPHIR_CALL_METHOD(NULL, instance, "setdirtystate", NULL, 0, _0); zephir_check_call_status(); - zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 589); + zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 588); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -77081,7 +77501,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model.zep", 532 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model.zep", 531 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -77097,12 +77517,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { _6 = Z_TYPE_P(value) != IS_NULL; } if (_6) { - zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 544 TSRMLS_CC); + zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 543 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_7, 0)) { ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, 10); - ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_9, 25, value, &_8); + ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_9, 26, value, &_8); zephir_check_call_status(); break; } @@ -77121,7 +77541,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { } while(0); } else { - zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 565 TSRMLS_CC); + zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 564 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_7, 0) || ZEPHIR_IS_LONG(_7, 9) || ZEPHIR_IS_LONG(_7, 3) || ZEPHIR_IS_LONG(_7, 7) || ZEPHIR_IS_LONG(_7, 8)) { ZEPHIR_INIT_NVAR(castValue); @@ -77134,7 +77554,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { } ZEPHIR_OBS_NVAR(attributeName); - zephir_array_fetch_long(&attributeName, attribute, 0, PH_NOISY, "phalcon/mvc/model.zep", 581 TSRMLS_CC); + zephir_array_fetch_long(&attributeName, attribute, 0, PH_NOISY, "phalcon/mvc/model.zep", 580 TSRMLS_CC); zephir_update_property_zval_zval(instance, attributeName, castValue TSRMLS_CC); } } @@ -77179,7 +77599,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMapHydrate) { ZEPHIR_INIT_VAR(hydrateObject); object_init(hydrateObject); } - zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 663); + zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 662); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -77197,7 +77617,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResultMapHydrate) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 642 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 641 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -77253,7 +77673,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResult) { ZVAL_LONG(_0, dirtyState); ZEPHIR_CALL_METHOD(NULL, instance, "setdirtystate", NULL, 0, _0); zephir_check_call_status(); - zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 710); + zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 709); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -77261,7 +77681,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, cloneResult) { ZEPHIR_GET_HMKEY(key, _2, _1); ZEPHIR_GET_HVALUE(value, _3); if (Z_TYPE_P(key) != IS_STRING) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid key in array data provided to dumpResult()", "phalcon/mvc/model.zep", 702); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid key in array data provided to dumpResult()", "phalcon/mvc/model.zep", 701); return; } zephir_update_property_zval_zval(instance, key, value TSRMLS_CC); @@ -77300,7 +77720,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, find) { ZEPHIR_INIT_VAR(params); array_init(params); if (Z_TYPE_P(parameters) != IS_NULL) { - zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 756); + zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 755); } } else { ZEPHIR_CPY_WRT(params, parameters); @@ -77375,7 +77795,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, findFirst) { ZEPHIR_INIT_VAR(params); array_init(params); if (Z_TYPE_P(parameters) != IS_NULL) { - zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 843); + zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 842); } } else { ZEPHIR_CPY_WRT(params, parameters); @@ -77459,12 +77879,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, query) { ZEPHIR_CALL_METHOD(NULL, criteria, "__construct", NULL, 0); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 309, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 302, dependencyInjector); zephir_check_call_status(); } ZEPHIR_INIT_NVAR(_2); zephir_get_called_class(_2 TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, _2); + ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 303, _2); zephir_check_call_status(); RETURN_CCTOR(criteria); @@ -77682,7 +78102,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _groupResult) { ZEPHIR_INIT_VAR(params); array_init(params); if (Z_TYPE_P(parameters) != IS_NULL) { - zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 1092); + zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 1093); } } else { ZEPHIR_CPY_WRT(params, parameters); @@ -77690,7 +78110,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _groupResult) { ZEPHIR_OBS_VAR(groupColumn); if (!(zephir_array_isset_string_fetch(&groupColumn, params, SS("column"), 0 TSRMLS_CC))) { ZEPHIR_INIT_NVAR(groupColumn); - ZVAL_LONG(groupColumn, '*'); + ZVAL_STRING(groupColumn, "*", 1); } ZEPHIR_OBS_VAR(distinctColumn); if (zephir_array_isset_string_fetch(&distinctColumn, params, SS("distinct"), 0 TSRMLS_CC)) { @@ -77998,7 +78418,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, validate) { if (ZEPHIR_IS_FALSE_IDENTICAL(_0)) { ZEPHIR_CALL_METHOD(&_1, validator, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1392); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1393); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -78050,7 +78470,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getMessages) { ZEPHIR_INIT_VAR(filtered); array_init(filtered); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_errorMessages"), PH_NOISY_CC); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1458); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1459); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -78059,7 +78479,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getMessages) { ZEPHIR_CALL_METHOD(&_5, message, "getfield", NULL, 0); zephir_check_call_status(); if (ZEPHIR_IS_EQUAL(_5, filter)) { - zephir_array_append(&filtered, message, PH_SEPARATE, "phalcon/mvc/model.zep", 1455); + zephir_array_append(&filtered, message, PH_SEPARATE, "phalcon/mvc/model.zep", 1456); } } RETURN_CCTOR(filtered); @@ -78086,7 +78506,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { zephir_check_call_status(); if (zephir_fast_count_int(belongsTo TSRMLS_CC)) { error = 0; - zephir_is_iterable(belongsTo, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1601); + zephir_is_iterable(belongsTo, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1602); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -78099,7 +78519,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { if (Z_TYPE_P(foreignKey) == IS_ARRAY) { if (zephir_array_isset_string(foreignKey, SS("action"))) { ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1502 TSRMLS_CC); + zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1503 TSRMLS_CC); action = zephir_get_intval(_4); } } @@ -78118,7 +78538,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { ZEPHIR_CALL_METHOD(&referencedFields, relation, "getreferencedfields", NULL, 0); zephir_check_call_status(); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1538); + zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1539); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) @@ -78127,11 +78547,11 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { ZEPHIR_GET_HVALUE(field, _9); ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, field, PH_SILENT_CC); - zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1531 TSRMLS_CC); + zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1532 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVSV(_11, "[", _10, "] = ?", position); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1531); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1532); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1532); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1533); if (Z_TYPE_P(value) == IS_NULL) { numberNull++; } @@ -78142,15 +78562,15 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { zephir_fetch_property_zval(&value, this_ptr, fields, PH_SILENT_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVS(_11, "[", referencedFields, "] = ?0"); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1543); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1544); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1544); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1545); if (Z_TYPE_P(value) == IS_NULL) { validateWithNulls = 1; } } ZEPHIR_OBS_NVAR(extraConditions); if (zephir_array_isset_string_fetch(&extraConditions, foreignKey, SS("conditions"), 0 TSRMLS_CC)) { - zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1555); + zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1556); } if (validateWithNulls) { ZEPHIR_OBS_NVAR(allowNulls); @@ -78232,7 +78652,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { ZEPHIR_CALL_METHOD(&relations, manager, "gethasoneandhasmany", NULL, 0, this_ptr); zephir_check_call_status(); if (zephir_fast_count_int(relations TSRMLS_CC)) { - zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1715); + zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1716); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -78245,7 +78665,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { if (Z_TYPE_P(foreignKey) == IS_ARRAY) { if (zephir_array_isset_string(foreignKey, SS("action"))) { ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1654 TSRMLS_CC); + zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1655 TSRMLS_CC); action = zephir_get_intval(_4); } } @@ -78263,7 +78683,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { ZEPHIR_INIT_NVAR(bindParams); array_init(bindParams); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1682); + zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1683); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) @@ -78272,23 +78692,23 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { ZEPHIR_GET_HVALUE(field, _9); ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, field, PH_SILENT_CC); - zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1679 TSRMLS_CC); + zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1680 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVSV(_11, "[", _10, "] = ?", position); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1679); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1680); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1680); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1681); } } else { ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, fields, PH_SILENT_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVS(_11, "[", referencedFields, "] = ?0"); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1684); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1685); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1685); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1686); } ZEPHIR_OBS_NVAR(extraConditions); if (zephir_array_isset_string_fetch(&extraConditions, foreignKey, SS("conditions"), 0 TSRMLS_CC)) { - zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1692); + zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1693); } ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -78329,7 +78749,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { zephir_check_call_status(); if (zephir_fast_count_int(relations TSRMLS_CC)) { error = 0; - zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1834); + zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1835); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -78342,7 +78762,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { if (Z_TYPE_P(foreignKey) == IS_ARRAY) { if (zephir_array_isset_string(foreignKey, SS("action"))) { ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1762 TSRMLS_CC); + zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1763 TSRMLS_CC); action = zephir_get_intval(_4); } } @@ -78360,7 +78780,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { ZEPHIR_INIT_NVAR(bindParams); array_init(bindParams); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/mvc/model.zep", 1794); + zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/mvc/model.zep", 1795); for ( ; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS ; zephir_hash_move_forward_ex(_7, &_6) @@ -78369,23 +78789,23 @@ static PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { ZEPHIR_GET_HVALUE(field, _8); ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, field, PH_SILENT_CC); - zephir_array_fetch(&_9, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1790 TSRMLS_CC); + zephir_array_fetch(&_9, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1791 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVSV(_10, "[", _9, "] = ?", position); - zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1790); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1791); + zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1791); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1792); } } else { ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, fields, PH_SILENT_CC); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVS(_10, "[", referencedFields, "] = ?0"); - zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1796); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1797); + zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1797); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1798); } ZEPHIR_OBS_NVAR(extraConditions); if (zephir_array_isset_string_fetch(&extraConditions, foreignKey, SS("conditions"), 0 TSRMLS_CC)) { - zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1804); + zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1805); } ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -78509,7 +78929,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSave) { ZEPHIR_CALL_METHOD(&emptyStringValues, metaData, "getemptystringattributes", NULL, 0, this_ptr); zephir_check_call_status(); error = 0; - zephir_is_iterable(notNull, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 2000); + zephir_is_iterable(notNull, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 2001); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -78526,7 +78946,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSave) { ZEPHIR_CONCAT_SVS(_7, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 1936 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 1937 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -78746,7 +79166,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_INIT_NVAR(columnMap); ZVAL_NULL(columnMap); } - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 2184); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 2185); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -78762,7 +79182,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2138 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2139 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -78788,23 +79208,23 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Column '", field, "' have not defined a bind data type"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2162 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2163 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2165); - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2165); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2165); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2166); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2166); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2166); } else { if (zephir_array_isset(defaultValues, field)) { ZEPHIR_CALL_METHOD(&_8, connection, "getdefaultvalue", &_9, 0); zephir_check_call_status(); - zephir_array_append(&values, _8, PH_SEPARATE, "phalcon/mvc/model.zep", 2170); + zephir_array_append(&values, _8, PH_SEPARATE, "phalcon/mvc/model.zep", 2171); } else { - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2172); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2173); } - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2175); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2175); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2176); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2176); } } } @@ -78816,7 +79236,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { zephir_check_call_status(); useExplicitIdentity = zephir_get_boolval(_8); if (useExplicitIdentity) { - zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2193); + zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2194); } if (Z_TYPE_P(columnMap) == IS_ARRAY) { ZEPHIR_OBS_NVAR(attributeField); @@ -78827,7 +79247,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Identity column '", identityField, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2201 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2202 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -78842,12 +79262,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { } if (_6) { if (useExplicitIdentity) { - zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2214); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2214); + zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2215); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2215); } } else { if (!(useExplicitIdentity)) { - zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2222); + zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2223); } ZEPHIR_OBS_NVAR(bindType); if (!(zephir_array_isset_fetch(&bindType, bindDataTypes, identityField, 0 TSRMLS_CC))) { @@ -78857,17 +79277,17 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Identity column '", identityField, "' isn\\'t part of the table columns"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2229 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2230 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2232); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2232); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2233); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2233); } } else { if (useExplicitIdentity) { - zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2236); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2236); + zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2237); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2237); } } } @@ -78957,7 +79377,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_INIT_NVAR(columnMap); ZVAL_NULL(columnMap); } - zephir_is_iterable(nonPrimary, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 2436); + zephir_is_iterable(nonPrimary, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 2437); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -78972,7 +79392,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CONCAT_SVS(_6, "Column '", field, "' have not defined a bind data type"); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2335 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2336 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -78985,7 +79405,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CONCAT_SVS(_6, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2343 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2344 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -78995,9 +79415,9 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_OBS_NVAR(value); if (zephir_fetch_property_zval(&value, this_ptr, attributeField, PH_SILENT_CC)) { if (!(useDynamicUpdate)) { - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2359); - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2359); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2360); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2360); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2360); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2361); } else { ZEPHIR_OBS_NVAR(snapshotValue); if (!(zephir_array_isset_fetch(&snapshotValue, snapshot, attributeField, 0 TSRMLS_CC))) { @@ -79019,9 +79439,9 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { break; } if (ZEPHIR_IS_LONG(bindType, 3) || ZEPHIR_IS_LONG(bindType, 7)) { - ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 311, snapshotValue); + ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 304, snapshotValue); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 311, value); + ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 304, value); zephir_check_call_status(); changed = !ZEPHIR_IS_IDENTICAL(_1, _9); break; @@ -79039,15 +79459,15 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { } } if (changed) { - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2422); - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2422); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2423); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2423); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2423); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2424); } } } else { - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2428); - zephir_array_append(&values, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2428); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2428); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2429); + zephir_array_append(&values, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2429); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2429); } } } @@ -79064,12 +79484,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CALL_METHOD(&primaryKeys, metaData, "getprimarykeyattributes", NULL, 0, this_ptr); zephir_check_call_status(); if (!(zephir_fast_count_int(primaryKeys TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 2455); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 2456); return; } ZEPHIR_INIT_NVAR(uniqueParams); array_init(uniqueParams); - zephir_is_iterable(primaryKeys, &_13, &_12, 0, 0, "phalcon/mvc/model.zep", 2478); + zephir_is_iterable(primaryKeys, &_13, &_12, 0, 0, "phalcon/mvc/model.zep", 2479); for ( ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS ; zephir_hash_move_forward_ex(_13, &_12) @@ -79084,7 +79504,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CONCAT_SVS(_6, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2466 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2467 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79093,9 +79513,9 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { } ZEPHIR_OBS_NVAR(value); if (zephir_fetch_property_zval(&value, this_ptr, attributeField, PH_SILENT_CC)) { - zephir_array_append(&uniqueParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2473); + zephir_array_append(&uniqueParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2474); } else { - zephir_array_append(&uniqueParams, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2475); + zephir_array_append(&uniqueParams, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2476); } } } @@ -79132,7 +79552,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmodelsmanager", NULL, 0); zephir_check_call_status(); ZEPHIR_CPY_WRT(manager, _0); - zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2584); + zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2585); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -79149,7 +79569,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { if (Z_TYPE_P(record) != IS_OBJECT) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_5, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects can be stored as part of belongs-to relations", "phalcon/mvc/model.zep", 2533); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects can be stored as part of belongs-to relations", "phalcon/mvc/model.zep", 2534); return; } ZEPHIR_CALL_METHOD(&columns, relation, "getfields", NULL, 0); @@ -79161,7 +79581,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { if (Z_TYPE_P(columns) == IS_ARRAY) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_6, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2542); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2543); return; } ZEPHIR_CALL_METHOD(&_0, record, "save", NULL, 0); @@ -79169,7 +79589,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { if (!(zephir_is_true(_0))) { ZEPHIR_CALL_METHOD(&_7, record, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_7, &_9, &_8, 0, 0, "phalcon/mvc/model.zep", 2571); + zephir_is_iterable(_7, &_9, &_8, 0, 0, "phalcon/mvc/model.zep", 2572); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) @@ -79216,7 +79636,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmodelsmanager", NULL, 0); zephir_check_call_status(); ZEPHIR_CPY_WRT(manager, _0); - zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2772); + zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2773); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -79239,7 +79659,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (_5) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_6, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects/arrays can be stored as part of has-many/has-one/has-many-to-many relations", "phalcon/mvc/model.zep", 2623); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects/arrays can be stored as part of has-many/has-one/has-many-to-many relations", "phalcon/mvc/model.zep", 2624); return; } ZEPHIR_CALL_METHOD(&columns, relation, "getfields", NULL, 0); @@ -79251,7 +79671,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (Z_TYPE_P(columns) == IS_ARRAY) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_7, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2632); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2633); return; } if (Z_TYPE_P(record) == IS_OBJECT) { @@ -79271,7 +79691,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CONCAT_SVS(_10, "The column '", columns, "' needs to be present in the model"); ZEPHIR_CALL_METHOD(NULL, _9, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2646 TSRMLS_CC); + zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2647 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79286,7 +79706,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CALL_METHOD(&intermediateReferencedFields, relation, "getintermediatereferencedfields", NULL, 0); zephir_check_call_status(); } - zephir_is_iterable(relatedRecords, &_14, &_13, 0, 0, "phalcon/mvc/model.zep", 2761); + zephir_is_iterable(relatedRecords, &_14, &_13, 0, 0, "phalcon/mvc/model.zep", 2762); for ( ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS ; zephir_hash_move_forward_ex(_14, &_13) @@ -79301,7 +79721,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (!(zephir_is_true(_12))) { ZEPHIR_CALL_METHOD(&_16, recordAfter, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_16, &_18, &_17, 0, 0, "phalcon/mvc/model.zep", 2703); + zephir_is_iterable(_16, &_18, &_17, 0, 0, "phalcon/mvc/model.zep", 2704); for ( ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS ; zephir_hash_move_forward_ex(_18, &_17) @@ -79334,7 +79754,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (!(zephir_is_true(_16))) { ZEPHIR_CALL_METHOD(&_23, intermediateModel, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_23, &_25, &_24, 0, 0, "phalcon/mvc/model.zep", 2755); + zephir_is_iterable(_23, &_25, &_24, 0, 0, "phalcon/mvc/model.zep", 2756); for ( ; zephir_hash_get_current_data_ex(_25, (void**) &_26, &_24) == SUCCESS ; zephir_hash_move_forward_ex(_25, &_24) @@ -79363,7 +79783,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CONCAT_SVSVS(_10, "There are no defined relations for the model '", className, "' using alias '", name, "'"); ZEPHIR_CALL_METHOD(NULL, _9, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2764 TSRMLS_CC); + zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2765 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79458,9 +79878,9 @@ static PHP_METHOD(Phalcon_Mvc_Model, save) { ZEPHIR_INIT_NVAR(_4); object_init_ex(_4, phalcon_mvc_model_validationfailed_ce); _3 = zephir_fetch_nproperty_this(this_ptr, SL("_errorMessages"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 312, this_ptr, _3); + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 305, this_ptr, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 2877 TSRMLS_CC); + zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 2878 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79478,11 +79898,6 @@ static PHP_METHOD(Phalcon_Mvc_Model, save) { ZVAL_LONG(_3, 0); zephir_update_property_this(this_ptr, SL("_dirtyState"), _3 TSRMLS_CC); } - if (ZEPHIR_GLOBAL(orm).events) { - ZEPHIR_CALL_METHOD(&_2, this_ptr, "_postsave", NULL, 0, success, exists); - zephir_check_call_status(); - ZEPHIR_CPY_WRT(success, _2); - } if (Z_TYPE_P(related) == IS_ARRAY) { if (ZEPHIR_IS_FALSE_IDENTICAL(success)) { ZEPHIR_INIT_NVAR(_1); @@ -79494,6 +79909,11 @@ static PHP_METHOD(Phalcon_Mvc_Model, save) { zephir_check_call_status(); } } + if (ZEPHIR_GLOBAL(orm).events) { + ZEPHIR_CALL_METHOD(&_2, this_ptr, "_postsave", NULL, 0, success, exists); + zephir_check_call_status(); + ZEPHIR_CPY_WRT(success, _2); + } if (ZEPHIR_IS_FALSE_IDENTICAL(success)) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "_canceloperation", NULL, 0); zephir_check_call_status(); @@ -79652,10 +80072,10 @@ static PHP_METHOD(Phalcon_Mvc_Model, delete) { ZVAL_NULL(columnMap); } if (!(zephir_fast_count_int(primaryKeys TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 3061); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 3062); return; } - zephir_is_iterable(primaryKeys, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 3102); + zephir_is_iterable(primaryKeys, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 3103); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -79669,7 +80089,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, delete) { ZEPHIR_CONCAT_SVS(_7, "Column '", primaryKey, "' have not defined a bind data type"); ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3073 TSRMLS_CC); + zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3074 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79682,7 +80102,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, delete) { ZEPHIR_CONCAT_SVS(_7, "Column '", primaryKey, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3081 TSRMLS_CC); + zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3082 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -79697,17 +80117,17 @@ static PHP_METHOD(Phalcon_Mvc_Model, delete) { ZEPHIR_CONCAT_SVS(_7, "Cannot delete the record because the primary key attribute: '", attributeField, "' wasn't set"); ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3091 TSRMLS_CC); + zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3092 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 3097); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 3098); ZEPHIR_CALL_METHOD(&_2, writeConnection, "escapeidentifier", &_9, 0, primaryKey); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_VS(_7, _2, " = ?"); - zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model.zep", 3098); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 3099); + zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model.zep", 3099); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 3100); } if (ZEPHIR_GLOBAL(orm).events) { zephir_update_property_this(this_ptr, SL("_skipped"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); @@ -79783,7 +80203,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, refresh) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC); if (!ZEPHIR_IS_LONG(_0, 0)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3177); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3178); return; } ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0); @@ -79808,7 +80228,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, refresh) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "_exists", NULL, 0, metaData, readConnection, table); zephir_check_call_status(); if (!(zephir_is_true(_1))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3199); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3200); return; } ZEPHIR_OBS_NVAR(uniqueKey); @@ -79817,14 +80237,14 @@ static PHP_METHOD(Phalcon_Mvc_Model, refresh) { ZEPHIR_OBS_VAR(uniqueParams); zephir_read_property_this(&uniqueParams, this_ptr, SL("_uniqueParams"), PH_NOISY_CC); if (Z_TYPE_P(uniqueParams) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3207); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3208); return; } ZEPHIR_INIT_VAR(fields); array_init(fields); ZEPHIR_CALL_METHOD(&_1, metaData, "getattributes", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3221); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3222); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -79833,7 +80253,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, refresh) { ZEPHIR_INIT_NVAR(_5); zephir_create_array(_5, 1, 0 TSRMLS_CC); zephir_array_fast_append(_5, attribute); - zephir_array_append(&fields, _5, PH_SEPARATE, "phalcon/mvc/model.zep", 3215); + zephir_array_append(&fields, _5, PH_SEPARATE, "phalcon/mvc/model.zep", 3216); } ZEPHIR_CALL_METHOD(&dialect, readConnection, "getdialect", NULL, 0); zephir_check_call_status(); @@ -79948,7 +80368,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, skipAttributes) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3302); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3303); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -79983,7 +80403,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, skipAttributesOnCreate) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3333); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3334); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -80016,7 +80436,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, skipAttributesOnUpdate) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3362); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3363); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -80049,7 +80469,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, allowEmptyStringValues) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3391); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3392); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -80262,7 +80682,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) { if (Z_TYPE_P(columnMap) == IS_ARRAY) { ZEPHIR_INIT_VAR(snapshot); array_init(snapshot); - zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3605); + zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3606); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -80281,7 +80701,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3586 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3587 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -80298,7 +80718,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3595 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3596 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -80351,12 +80771,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_OBS_VAR(snapshot); zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC); if (Z_TYPE_P(snapshot) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3644); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3645); return; } _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC); if (!ZEPHIR_IS_LONG(_0, 0)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3651); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3652); return; } ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0); @@ -80378,7 +80798,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3683 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3684 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80390,7 +80810,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3687 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3688 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80403,7 +80823,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not defined on the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3695 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3696 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80415,14 +80835,14 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_3, "The field '", fieldName, "' was not found in the snapshot"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3702 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3703 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } RETURN_MM_BOOL(!ZEPHIR_IS_EQUAL(value, originalValue)); } ZEPHIR_INIT_NVAR(_1); - zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3738); + zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3739); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -80457,12 +80877,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) { ZEPHIR_OBS_VAR(snapshot); zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC); if (Z_TYPE_P(snapshot) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3751); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3752); return; } _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC); if (!ZEPHIR_IS_LONG(_0, 0)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3758); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3759); return; } ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0); @@ -80478,7 +80898,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) { ZEPHIR_INIT_VAR(changed); array_init(changed); ZEPHIR_INIT_VAR(_1); - zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3812); + zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3813); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -80486,17 +80906,17 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) { ZEPHIR_GET_HMKEY(name, _3, _2); ZEPHIR_GET_HVALUE(_1, _4); if (!(zephir_array_isset(snapshot, name))) { - zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3791); + zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3792); continue; } ZEPHIR_OBS_NVAR(value); if (!(zephir_fetch_property_zval(&value, this_ptr, name, PH_SILENT_CC))) { - zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3799); + zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3800); continue; } - zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3806 TSRMLS_CC); + zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3807 TSRMLS_CC); if (!ZEPHIR_IS_EQUAL(value, _5)) { - zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3807); + zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3808); continue; } } @@ -80553,7 +80973,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getRelated) { ZEPHIR_CONCAT_SVSVS(_3, "There is no defined relations for the model '", className, "' using alias '", alias, "'"); ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3854 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3855 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80691,7 +81111,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __call) { ZEPHIR_CONCAT_SVSVS(_2, "The method '", method, "' doesn't exist on model '", modelName, "'"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3946 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3947 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -80702,16 +81122,13 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { zval *_6, *_7; zend_class_entry *_5, *_8; int ZEPHIR_LAST_CALL_STATUS; - zval *method_param = NULL, *arguments = NULL, *extraMethod = NULL, *type = NULL, *modelName, *value, *model, *attributes = NULL, *field = NULL, *extraMethodFirst = NULL, *metaData = NULL, _0 = zval_used_for_init, *_1 = NULL, *_2 = NULL, *_4 = NULL; + zval *method_param = NULL, *arguments, *extraMethod = NULL, *type = NULL, *modelName, *value, *model, *attributes = NULL, *field = NULL, *extraMethodFirst = NULL, *metaData = NULL, _0 = zval_used_for_init, *_1 = NULL, *_2 = NULL, *_4 = NULL; zval *method = NULL, *_3; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 1, &method_param, &arguments); + zephir_fetch_params(1, 2, 0, &method_param, &arguments); zephir_get_strval(method, method_param); - if (!arguments) { - arguments = ZEPHIR_GLOBAL(global_null); - } ZEPHIR_INIT_VAR(extraMethod); @@ -80753,7 +81170,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { ZEPHIR_CONCAT_SVSVS(_2, "The static method '", method, "' doesn't exist on model '", modelName, "'"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3997 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3998 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80765,7 +81182,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { ZEPHIR_CONCAT_SVS(_3, "The static method '", method, "' requires one argument"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4001 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4002 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80788,7 +81205,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { if (zephir_array_isset(attributes, extraMethod)) { ZEPHIR_CPY_WRT(field, extraMethod); } else { - ZEPHIR_CALL_FUNCTION(&extraMethodFirst, "lcfirst", NULL, 65, extraMethod); + ZEPHIR_CALL_FUNCTION(&extraMethodFirst, "lcfirst", NULL, 67, extraMethod); zephir_check_call_status(); if (zephir_array_isset(attributes, extraMethodFirst)) { ZEPHIR_CPY_WRT(field, extraMethodFirst); @@ -80802,7 +81219,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { ZEPHIR_CONCAT_SVS(_2, "Cannot resolve attribute '", extraMethod, "' in the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4035 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4036 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -80861,7 +81278,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __set) { zephir_check_call_status(); ZEPHIR_INIT_VAR(related); array_init(related); - zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4099); + zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4100); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -80870,7 +81287,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __set) { ZEPHIR_GET_HVALUE(item, _3); if (Z_TYPE_P(item) == IS_OBJECT) { if (zephir_instance_of_ev(item, phalcon_mvc_modelinterface_ce TSRMLS_CC)) { - zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4086); + zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4087); } } else { ZEPHIR_INIT_NVAR(lowerKey); @@ -81020,7 +81437,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, serialize) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "toarray", NULL, 0); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -81051,13 +81468,13 @@ static PHP_METHOD(Phalcon_Mvc_Model, unserialize) { } - ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(attributes) == IS_ARRAY) { ZEPHIR_CALL_CE_STATIC(&dependencyInjector, phalcon_di_ce, "getdefault", &_0, 1); zephir_check_call_status(); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4223); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4224); return; } zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); @@ -81068,13 +81485,13 @@ static PHP_METHOD(Phalcon_Mvc_Model, unserialize) { zephir_check_call_status(); ZEPHIR_CPY_WRT(manager, _1); if (Z_TYPE_P(manager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4236); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4237); return; } zephir_update_property_this(this_ptr, SL("_modelsManager"), manager TSRMLS_CC); ZEPHIR_CALL_METHOD(NULL, manager, "initialize", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4255); + zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4256); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -81094,7 +81511,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, dump) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 23, this_ptr); + ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM(); @@ -81124,7 +81541,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, toArray) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_0, metaData, "getattributes", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4319); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4320); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -81140,7 +81557,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, toArray) { ZEPHIR_CONCAT_SVS(_5, "Column '", attribute, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _4, "__construct", &_6, 9, _5); zephir_check_call_status(); - zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4297 TSRMLS_CC); + zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4298 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -81452,7 +81869,7 @@ static PHP_METHOD(Phalcon_Mvc_Router, __construct) { add_assoc_long_ex(_1, SS("controller"), 1); ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "#^/([\\w0-9\\_\\-]+)[/]{0,1}$#u", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 74, _2, _1); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 76, _2, _1); zephir_check_temp_parameter(_2); zephir_check_call_status(); zephir_array_append(&routes, _0, PH_SEPARATE, "phalcon/mvc/router.zep", 120); @@ -81465,7 +81882,7 @@ static PHP_METHOD(Phalcon_Mvc_Router, __construct) { add_assoc_long_ex(_4, SS("params"), 3); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "#^/([\\w0-9\\_\\-]+)/([\\w0-9\\.\\_]+)(/.*)*$#u", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 74, _5, _4); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 76, _5, _4); zephir_check_temp_parameter(_5); zephir_check_call_status(); zephir_array_append(&routes, _2, PH_SEPARATE, "phalcon/mvc/router.zep", 126); @@ -81990,7 +82407,7 @@ static PHP_METHOD(Phalcon_Mvc_Router, handle) { ZEPHIR_OBS_VAR(notFoundPaths); zephir_read_property_this(¬FoundPaths, this_ptr, SL("_notFoundPaths"), PH_NOISY_CC); if (Z_TYPE_P(notFoundPaths) != IS_NULL) { - ZEPHIR_CALL_CE_STATIC(&parts, phalcon_mvc_router_route_ce, "getroutepaths", &_20, 75, notFoundPaths); + ZEPHIR_CALL_CE_STATIC(&parts, phalcon_mvc_router_route_ce, "getroutepaths", &_20, 77, notFoundPaths); zephir_check_call_status(); ZEPHIR_INIT_NVAR(routeFound); ZVAL_BOOL(routeFound, 1); @@ -82103,7 +82520,7 @@ static PHP_METHOD(Phalcon_Mvc_Router, add) { ZEPHIR_INIT_VAR(route); object_init_ex(route, phalcon_mvc_router_route_ce); - ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 74, pattern, paths, httpMethods); + ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 76, pattern, paths, httpMethods); zephir_check_call_status(); do { if (ZEPHIR_IS_LONG(position, 1)) { @@ -82890,11 +83307,11 @@ static PHP_METHOD(Phalcon_Mvc_Url, getBasePath) { static PHP_METHOD(Phalcon_Mvc_Url, get) { - unsigned char _10, _12; + unsigned char _10, _12, _15; int ZEPHIR_LAST_CALL_STATUS; - zend_bool _0, _1, _11; + zend_bool _0, _1, _11, _13, _14; zval *strUri = NULL, *_9 = NULL; - zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_13; + zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_16; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 0, 4, &uri, &args, &local, &baseUri); @@ -83011,19 +83428,33 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) { _12 = ZEPHIR_STRING_OFFSET(strUri, 1); _11 = _12 != '/'; } - ZEPHIR_INIT_NVAR(uri); if (_11) { ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 1); ZEPHIR_INIT_NVAR(_3); zephir_substr(_3, strUri, 1 , 0, ZEPHIR_SUBSTR_NO_LENGTH); + ZEPHIR_INIT_NVAR(uri); ZEPHIR_CONCAT_VV(uri, baseUri, _3); } else { - ZEPHIR_CONCAT_VV(uri, baseUri, strUri); + _13 = ZEPHIR_IS_STRING(baseUri, "/"); + if (_13) { + _13 = zephir_fast_strlen_ev(strUri) == 1; + } + _14 = _13; + if (_14) { + _15 = ZEPHIR_STRING_OFFSET(strUri, 0); + _14 = _15 == '/'; + } + if (_14) { + ZEPHIR_CPY_WRT(uri, baseUri); + } else { + ZEPHIR_INIT_NVAR(uri); + ZEPHIR_CONCAT_VV(uri, baseUri, strUri); + } } } if (zephir_is_true(args)) { - ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 369, args); + ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 362, args); zephir_check_call_status(); _0 = Z_TYPE_P(queryString) == IS_STRING; if (_0) { @@ -83039,9 +83470,9 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) { ZEPHIR_CONCAT_SV(_7, "&", queryString); zephir_concat_self(&uri, _7 TSRMLS_CC); } else { - ZEPHIR_INIT_VAR(_13); - ZEPHIR_CONCAT_SV(_13, "?", queryString); - zephir_concat_self(&uri, _13 TSRMLS_CC); + ZEPHIR_INIT_VAR(_16); + ZEPHIR_CONCAT_SV(_16, "?", queryString); + zephir_concat_self(&uri, _16 TSRMLS_CC); } } } @@ -83645,7 +84076,7 @@ static PHP_METHOD(Phalcon_Mvc_View, start) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_content"), ZEPHIR_GLOBAL(global_null) TSRMLS_CC); RETURN_THIS(); @@ -83674,7 +84105,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _loadTemplateEngines) { if (Z_TYPE_P(registeredEngines) != IS_ARRAY) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_mvc_view_engine_php_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 370, this_ptr, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 363, this_ptr, dependencyInjector); zephir_check_call_status(); zephir_array_update_string(&engines, SL(".phtml"), &_1, PH_COPY | PH_SEPARATE); } else { @@ -83982,7 +84413,7 @@ static PHP_METHOD(Phalcon_Mvc_View, render) { zephir_update_property_this(this_ptr, SL("_currentRenderLevel"), _0 TSRMLS_CC); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_disabled"), PH_NOISY_CC); if (!ZEPHIR_IS_FALSE(_0)) { - ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 117); + ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 119); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_content"), _1 TSRMLS_CC); RETURN_MM_BOOL(0); @@ -84042,7 +84473,7 @@ static PHP_METHOD(Phalcon_Mvc_View, render) { RETURN_MM_BOOL(0); } } - ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 117); + ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 119); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_content"), _1 TSRMLS_CC); mustClean = 1; @@ -84221,11 +84652,11 @@ static PHP_METHOD(Phalcon_Mvc_View, getPartial) { } - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, this_ptr, "partial", NULL, 0, partialPath, params); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 284); zephir_check_call_status(); RETURN_MM(); @@ -84350,7 +84781,7 @@ static PHP_METHOD(Phalcon_Mvc_View, getRender) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, view, "render", NULL, 0, controllerName, actionName); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(view, "getcontent", NULL, 0); zephir_check_call_status(); @@ -84364,7 +84795,7 @@ static PHP_METHOD(Phalcon_Mvc_View, finish) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); RETURN_THIS(); @@ -85123,7 +85554,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection_Document, toArray) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 23, this_ptr); + ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM(); @@ -85806,7 +86237,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection_Behavior_Timestampable, notify) { ZVAL_NULL(timestamp); ZEPHIR_OBS_VAR(format); if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format); + ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 293, format); zephir_check_call_status(); } else { ZEPHIR_OBS_VAR(generator); @@ -87250,9 +87681,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, betweenWhere) { ZEPHIR_INIT_VAR(nextHiddenParam); ZVAL_LONG(nextHiddenParam, (zephir_get_numberval(hiddenParam) + 1)); ZEPHIR_INIT_VAR(minimumKey); - ZEPHIR_CONCAT_SV(minimumKey, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(minimumKey, "ACP", hiddenParam); ZEPHIR_INIT_VAR(maximumKey); - ZEPHIR_CONCAT_SV(maximumKey, "AP", nextHiddenParam); + ZEPHIR_CONCAT_SV(maximumKey, "ACP", nextHiddenParam); ZEPHIR_INIT_VAR(_0); ZEPHIR_CONCAT_VSVSVS(_0, expr, " BETWEEN :", minimumKey, ": AND :", maximumKey, ":"); ZEPHIR_INIT_VAR(_1); @@ -87296,9 +87727,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, notBetweenWhere) { ZEPHIR_INIT_VAR(nextHiddenParam); ZVAL_LONG(nextHiddenParam, (zephir_get_numberval(hiddenParam) + 1)); ZEPHIR_INIT_VAR(minimumKey); - ZEPHIR_CONCAT_SV(minimumKey, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(minimumKey, "ACP", hiddenParam); ZEPHIR_INIT_VAR(maximumKey); - ZEPHIR_CONCAT_SV(maximumKey, "AP", nextHiddenParam); + ZEPHIR_CONCAT_SV(maximumKey, "ACP", nextHiddenParam); ZEPHIR_INIT_VAR(_0); ZEPHIR_CONCAT_VSVSVS(_0, expr, " NOT BETWEEN :", minimumKey, ": AND :", maximumKey, ":"); ZEPHIR_INIT_VAR(_1); @@ -87347,17 +87778,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, inWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 451); + zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 450); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(value, _2); ZEPHIR_INIT_NVAR(key); - ZEPHIR_CONCAT_SV(key, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(key, "ACP", hiddenParam); ZEPHIR_INIT_NVAR(queryKey); ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":"); - zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 442); + zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 441); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); ZEPHIR_SEPARATE(hiddenParam); zephir_increment(hiddenParam); @@ -87406,17 +87837,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, notInWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 488); + zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 487); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(value, _2); ZEPHIR_INIT_NVAR(key); - ZEPHIR_CONCAT_SV(key, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(key, "ACP", hiddenParam); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVS(_3, ":", key, ":"); - zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 478); + zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 477); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); ZEPHIR_SEPARATE(hiddenParam); zephir_increment(hiddenParam); @@ -87751,11 +88182,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { zend_class_entry *_2; int ZEPHIR_LAST_CALL_STATUS; zval *data = NULL; - zval *modelName = NULL; - zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *attribute = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *columnMap = NULL, *_0 = NULL, *_1 = NULL, **_5, *_8 = NULL, *_9 = NULL; + zval *modelName = NULL, *operator = NULL, *_10; + zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *operator_param = NULL, *attribute = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *columnMap = NULL, *_0 = NULL, *_1 = NULL, **_5, *_8 = NULL, *_9 = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 3, 0, &dependencyInjector, &modelName_param, &data_param); + zephir_fetch_params(1, 3, 1, &dependencyInjector, &modelName_param, &data_param, &operator_param); if (unlikely(Z_TYPE_P(modelName_param) != IS_STRING && Z_TYPE_P(modelName_param) != IS_NULL)) { zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'modelName' must be a string") TSRMLS_CC); @@ -87770,6 +88201,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } data = data_param; + if (!operator_param) { + ZEPHIR_INIT_VAR(operator); + ZVAL_STRING(operator, "AND", 1); + } else { + if (unlikely(Z_TYPE_P(operator_param) != IS_STRING && Z_TYPE_P(operator_param) != IS_NULL)) { + zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'operator' must be a string") TSRMLS_CC); + RETURN_MM_NULL(); + } + + if (likely(Z_TYPE_P(operator_param) == IS_STRING)) { + zephir_get_strval(operator, operator_param); + } else { + ZEPHIR_INIT_VAR(operator); + ZVAL_EMPTY_STRING(operator); + } + } ZEPHIR_INIT_VAR(conditions); @@ -87794,7 +88241,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { zephir_check_call_status(); ZEPHIR_INIT_VAR(bind); array_init(bind); - zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 732); + zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 731); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -87807,7 +88254,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } if (_6) { ZEPHIR_OBS_NVAR(attribute); - zephir_array_fetch(&attribute, columnMap, field, PH_NOISY, "phalcon/mvc/model/criteria.zep", 709 TSRMLS_CC); + zephir_array_fetch(&attribute, columnMap, field, PH_NOISY, "phalcon/mvc/model/criteria.zep", 708 TSRMLS_CC); } else { ZEPHIR_CPY_WRT(attribute, field); } @@ -87821,7 +88268,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { if (ZEPHIR_IS_LONG(type, 2)) { ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] LIKE :", field, ":"); - zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 721); + zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 720); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, "%", value, "%"); zephir_array_update_zval(&bind, field, &_9, PH_COPY | PH_SEPARATE); @@ -87829,7 +88276,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] = :", field, ":"); - zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 728); + zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 727); zephir_array_update_zval(&bind, field, &value, PH_COPY | PH_SEPARATE); } } @@ -87843,13 +88290,15 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } if (zephir_fast_count_int(conditions TSRMLS_CC)) { ZEPHIR_INIT_NVAR(_0); - zephir_fast_join_str(_0, SL(" AND "), conditions TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 313, _0); + ZEPHIR_INIT_VAR(_10); + ZEPHIR_CONCAT_SVS(_10, " ", operator, " "); + zephir_fast_join(_0, _10, conditions TSRMLS_CC); + ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 306, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 314, bind); + ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 307, bind); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, modelName); + ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 303, modelName); zephir_check_call_status(); RETURN_CCTOR(criteria); @@ -87866,7 +88315,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, execute) { ZEPHIR_CALL_METHOD(&model, this_ptr, "getmodelname", NULL, 0); zephir_check_call_status(); if (Z_TYPE_P(model) != IS_STRING) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 756); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 755); return; } ZEPHIR_CALL_METHOD(&_0, this_ptr, "getparams", NULL, 0); @@ -87940,8 +88389,6 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, getOrder); ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, getParams); -ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, fromInput); - ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, execute); @@ -88871,7 +89318,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasOne) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 1); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _1, referencedModel, fields, referencedFields, options); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -88948,7 +89395,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addBelongsTo) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 0); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _1, referencedModel, fields, referencedFields, options); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -89026,7 +89473,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasMany) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, 2); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _0, referencedModel, fields, referencedFields, options); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -89123,9 +89570,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasManyToMany) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, 4); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _0, referencedModel, fields, referencedFields, options); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 316, intermediateFields, intermediateModel, intermediateReferencedFields); + ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 309, intermediateFields, intermediateModel, intermediateReferencedFields); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -89423,7 +89870,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { ZEPHIR_INIT_VAR(findParams); array_init(findParams); if (Z_TYPE_P(findParamsOne) == IS_ARRAY) { - zephir_is_iterable(findParamsOne, &_3, &_2, 0, 0, "phalcon/mvc/model/manager.zep", 1140); + zephir_is_iterable(findParamsOne, &_3, &_2, 0, 0, "phalcon/mvc/model/manager.zep", 1137); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -89436,12 +89883,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } if (_5) { if (!(zephir_array_isset_long(findParams, 0))) { - zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1131); + zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1128); } else { - zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1133 TSRMLS_CC); + zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1130 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSV(_1, "(", _6, ") AND ", value); - zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1133); + zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1130); } continue; } @@ -89455,7 +89902,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } } if (Z_TYPE_P(findParamsTwo) == IS_ARRAY) { - zephir_is_iterable(findParamsTwo, &_8, &_7, 0, 0, "phalcon/mvc/model/manager.zep", 1174); + zephir_is_iterable(findParamsTwo, &_8, &_7, 0, 0, "phalcon/mvc/model/manager.zep", 1171); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) @@ -89468,12 +89915,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } if (_5) { if (!(zephir_array_isset_long(findParams, 0))) { - zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1152); + zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1149); } else { - zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1154 TSRMLS_CC); + zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1151 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSV(_1, "(", _6, ") AND ", value); - zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1154); + zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1151); } continue; } @@ -89489,7 +89936,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } else { if (Z_TYPE_P(value) == IS_ARRAY) { ZEPHIR_INIT_NVAR(_11); - zephir_array_fetch(&_6, findParams, key, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1166 TSRMLS_CC); + zephir_array_fetch(&_6, findParams, key, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1163 TSRMLS_CC); zephir_fast_array_merge(_11, &(_6), &(value) TSRMLS_CC); zephir_array_update_zval(&findParams, key, &_11, PH_COPY | PH_SEPARATE); } @@ -89501,12 +89948,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } else { if (Z_TYPE_P(findParamsTwo) == IS_STRING) { if (!(zephir_array_isset_long(findParams, 0))) { - zephir_array_update_long(&findParams, 0, &findParamsTwo, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1177); + zephir_array_update_long(&findParams, 0, &findParamsTwo, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1174); } else { - zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1179 TSRMLS_CC); + zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1176 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSV(_1, "(", _6, ") AND ", findParamsTwo); - zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1179); + zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1176); } } } @@ -89564,12 +90011,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { if (Z_TYPE_P(fields) != IS_ARRAY) { ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVSVS(_1, "[", intermediateModel, "].[", intermediateFields, "] = :APR0:"); - zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1230); + zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1227); ZEPHIR_CALL_METHOD(&_2, record, "readattribute", NULL, 0, fields); zephir_check_call_status(); zephir_array_update_string(&placeholders, SL("APR0"), &_2, PH_COPY | PH_SEPARATE); } else { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1233); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1230); return; } ZEPHIR_INIT_VAR(joinConditions); @@ -89581,12 +90028,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSVSVSVS(_1, "[", intermediateModel, "].[", intermediateFields, "] = [", referencedModel, "].[", _2, "]"); - zephir_array_append(&joinConditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1243); + zephir_array_append(&joinConditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1240); } else { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1245); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1242); return; } - ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 317, extraParameters, parameters); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 310, extraParameters, parameters); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&builder, this_ptr, "createbuilder", NULL, 0, _2); zephir_check_call_status(); @@ -89615,7 +90062,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "[", _6, "] = :APR0:"); - zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1272); + zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1269); ZEPHIR_CALL_METHOD(&_7, record, "readattribute", NULL, 0, fields); zephir_check_call_status(); zephir_array_update_string(&placeholders, SL("APR0"), &_7, PH_COPY | PH_SEPARATE); @@ -89624,17 +90071,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_6, relation, "getreferencedfields", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_6, &_9, &_8, 0, 0, "phalcon/mvc/model/manager.zep", 1284); + zephir_is_iterable(_6, &_9, &_8, 0, 0, "phalcon/mvc/model/manager.zep", 1281); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) ) { ZEPHIR_GET_HMKEY(refPosition, _9, _8); ZEPHIR_GET_HVALUE(field, _10); - zephir_array_fetch(&_11, referencedFields, refPosition, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1281 TSRMLS_CC); + zephir_array_fetch(&_11, referencedFields, refPosition, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1278 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SVSVS(_12, "[", _11, "] = :APR", refPosition, ":"); - zephir_array_append(&conditions, _12, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1281); + zephir_array_append(&conditions, _12, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1278); ZEPHIR_CALL_METHOD(&_7, record, "readattribute", &_13, 0, field); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); @@ -89651,10 +90098,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { ZEPHIR_CALL_METHOD(&_2, record, "getdi", NULL, 0); zephir_check_call_status(); zephir_array_update_string(&findParams, SL("di"), &_2, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 317, findParams, parameters); + ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 310, findParams, parameters); zephir_check_call_status(); if (Z_TYPE_P(extraParameters) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 317, findArguments, extraParameters); + ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 310, findArguments, extraParameters); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(findParams, findArguments); @@ -89673,7 +90120,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { ZVAL_STRING(retrieveMethod, "find", 1); break; } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown relation type", "phalcon/mvc/model/manager.zep", 1320); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown relation type", "phalcon/mvc/model/manager.zep", 1317); return; } while(0); @@ -89849,8 +90296,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getBelongsToRecords) { RETURN_MM_BOOL(0); } ZEPHIR_OBS_VAR(relations); - zephir_array_fetch(&relations, belongsTo, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1407 TSRMLS_CC); - zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1408 TSRMLS_CC); + zephir_array_fetch(&relations, belongsTo, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1404 TSRMLS_CC); + zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1405 TSRMLS_CC); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getrelationrecords", NULL, 0, _2, method, record, parameters); zephir_check_call_status(); RETURN_MM(); @@ -89908,8 +90355,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getHasManyRecords) { RETURN_MM_BOOL(0); } ZEPHIR_OBS_VAR(relations); - zephir_array_fetch(&relations, hasMany, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1437 TSRMLS_CC); - zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1438 TSRMLS_CC); + zephir_array_fetch(&relations, hasMany, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1434 TSRMLS_CC); + zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1435 TSRMLS_CC); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getrelationrecords", NULL, 0, _2, method, record, parameters); zephir_check_call_status(); RETURN_MM(); @@ -89967,8 +90414,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getHasOneRecords) { RETURN_MM_BOOL(0); } ZEPHIR_OBS_VAR(relations); - zephir_array_fetch(&relations, hasOne, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1467 TSRMLS_CC); - zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1468 TSRMLS_CC); + zephir_array_fetch(&relations, hasOne, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1464 TSRMLS_CC); + zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1465 TSRMLS_CC); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getrelationrecords", NULL, 0, _2, method, record, parameters); zephir_check_call_status(); RETURN_MM(); @@ -90115,13 +90562,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelations) { if (Z_TYPE_P(belongsTo) == IS_ARRAY) { ZEPHIR_OBS_VAR(relations); if (zephir_array_isset_fetch(&relations, belongsTo, entityName, 0 TSRMLS_CC)) { - zephir_is_iterable(relations, &_1, &_0, 0, 0, "phalcon/mvc/model/manager.zep", 1567); + zephir_is_iterable(relations, &_1, &_0, 0, 0, "phalcon/mvc/model/manager.zep", 1564); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(relation, _2); - zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1565); + zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1562); } } } @@ -90129,13 +90576,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelations) { if (Z_TYPE_P(hasMany) == IS_ARRAY) { ZEPHIR_OBS_NVAR(relations); if (zephir_array_isset_fetch(&relations, hasMany, entityName, 0 TSRMLS_CC)) { - zephir_is_iterable(relations, &_4, &_3, 0, 0, "phalcon/mvc/model/manager.zep", 1579); + zephir_is_iterable(relations, &_4, &_3, 0, 0, "phalcon/mvc/model/manager.zep", 1576); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) ) { ZEPHIR_GET_HVALUE(relation, _5); - zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1577); + zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1574); } } } @@ -90143,13 +90590,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelations) { if (Z_TYPE_P(hasOne) == IS_ARRAY) { ZEPHIR_OBS_NVAR(relations); if (zephir_array_isset_fetch(&relations, hasOne, entityName, 0 TSRMLS_CC)) { - zephir_is_iterable(relations, &_7, &_6, 0, 0, "phalcon/mvc/model/manager.zep", 1591); + zephir_is_iterable(relations, &_7, &_6, 0, 0, "phalcon/mvc/model/manager.zep", 1588); for ( ; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS ; zephir_hash_move_forward_ex(_7, &_6) ) { ZEPHIR_GET_HVALUE(relation, _8); - zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1589); + zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1586); } } } @@ -90246,7 +90693,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, createQuery) { ZEPHIR_OBS_VAR(dependencyInjector); zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1648); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1645); return; } ZEPHIR_INIT_VAR(_1); @@ -90296,7 +90743,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, executeQuery) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _0); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1668); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1665); return; } ZEPHIR_INIT_VAR(_2); @@ -90341,7 +90788,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, createBuilder) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _0); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1700); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1697); return; } ZEPHIR_INIT_VAR(_2); @@ -90414,7 +90861,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getNamespaceAlias) { ZEPHIR_CONCAT_SVS(_2, "Namespace alias '", alias, "' is not registered"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/manager.zep", 1735 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/manager.zep", 1732 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -91684,7 +92131,7 @@ static void phalcon_orm_singlequotes(zval *return_value, zval *str TSRMLS_DC) { if (Z_TYPE_P(str) != IS_STRING) { RETURN_ZVAL(str, 1, 0); - } + } marker = Z_STRVAL_P(str); @@ -91709,10 +92156,10 @@ static void phalcon_orm_singlequotes(zval *return_value, zval *str TSRMLS_DC) { if (escaped_str.len) { RETURN_STRINGL(escaped_str.c, escaped_str.len, 0); - } else { - smart_str_free(&escaped_str); - RETURN_EMPTY_STRING(); } + + smart_str_free(&escaped_str); + RETURN_EMPTY_STRING(); } @@ -91770,6 +92217,8 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_Query) { zend_declare_property_null(phalcon_mvc_model_query_ce, SL("_bindTypes"), ZEND_ACC_PROTECTED TSRMLS_CC); + zend_declare_property_null(phalcon_mvc_model_query_ce, SL("_enableImplicitJoins"), ZEND_ACC_PROTECTED TSRMLS_CC); + zend_declare_property_null(phalcon_mvc_model_query_ce, SL("_irPhqlCache"), ZEND_ACC_STATIC|ZEND_ACC_PROTECTED TSRMLS_CC); zend_declare_class_constant_long(phalcon_mvc_model_query_ce, SL("TYPE_SELECT"), 309 TSRMLS_CC); @@ -91788,11 +92237,12 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_Query) { static PHP_METHOD(Phalcon_Mvc_Model_Query, __construct) { + zend_bool _0; int ZEPHIR_LAST_CALL_STATUS; - zval *phql = NULL, *dependencyInjector = NULL; + zval *phql = NULL, *dependencyInjector = NULL, *options = NULL, *enableImplicitJoins; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 0, 2, &phql, &dependencyInjector); + zephir_fetch_params(1, 0, 3, &phql, &dependencyInjector, &options); if (!phql) { phql = ZEPHIR_GLOBAL(global_null); @@ -91800,6 +92250,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, __construct) { if (!dependencyInjector) { dependencyInjector = ZEPHIR_GLOBAL(global_null); } + if (!options) { + options = ZEPHIR_GLOBAL(global_null); + } if (Z_TYPE_P(phql) != IS_NULL) { @@ -91809,6 +92262,16 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, __construct) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdi", NULL, 0, dependencyInjector); zephir_check_call_status(); } + _0 = Z_TYPE_P(options) == IS_ARRAY; + if (_0) { + ZEPHIR_OBS_VAR(enableImplicitJoins); + _0 = zephir_array_isset_string_fetch(&enableImplicitJoins, options, SS("enable_implicit_joins"), 0 TSRMLS_CC); + } + if (_0) { + zephir_update_property_this(this_ptr, SL("_enableImplicitJoins"), (ZEPHIR_IS_TRUE(enableImplicitJoins)) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); + } else { + zephir_update_property_this(this_ptr, SL("_enableImplicitJoins"), (ZEPHIR_GLOBAL(orm).enable_implicit_joins) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); + } ZEPHIR_MM_RESTORE(); } @@ -91829,7 +92292,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, setDI) { zephir_check_temp_parameter(_0); zephir_check_call_status(); if (Z_TYPE_P(manager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsManager' is invalid", "phalcon/mvc/model/query.zep", 137); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsManager' is invalid", "phalcon/mvc/model/query.zep", 147); return; } ZEPHIR_INIT_NVAR(_0); @@ -91838,7 +92301,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, setDI) { zephir_check_temp_parameter(_0); zephir_check_call_status(); if (Z_TYPE_P(metaData) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsMetaData' is invalid", "phalcon/mvc/model/query.zep", 142); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsMetaData' is invalid", "phalcon/mvc/model/query.zep", 152); return; } zephir_update_property_this(this_ptr, SL("_manager"), manager TSRMLS_CC); @@ -91894,7 +92357,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_OBS_VAR(columnName); - zephir_array_fetch_string(&columnName, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 186 TSRMLS_CC); + zephir_array_fetch_string(&columnName, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 196 TSRMLS_CC); ZEPHIR_OBS_VAR(sqlColumnAliases); zephir_read_property_this(&sqlColumnAliases, this_ptr, SL("_sqlColumnAliases"), PH_NOISY_CC); if (zephir_array_isset(sqlColumnAliases, columnName)) { @@ -91918,7 +92381,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Unknown model or alias '", columnDomain, "' (11), when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 212 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 222 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -91934,7 +92397,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "There is no model related to model or alias '", columnDomain, "', when executing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 229 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 239 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -91954,7 +92417,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSVSV(_2, "Column '", columnName, "' doesn't belong to the model or alias '", columnDomain, "', when executing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 239 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 249 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -91966,7 +92429,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_INIT_VAR(hasModel); ZVAL_BOOL(hasModel, 0); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); - zephir_is_iterable(_1, &_4, &_3, 0, 0, "phalcon/mvc/model/query.zep", 269); + zephir_is_iterable(_1, &_4, &_3, 0, 0, "phalcon/mvc/model/query.zep", 279); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -91984,7 +92447,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "The column '", columnName, "' is ambiguous, when preparing: ", _8); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 260 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 270 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -91999,14 +92462,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Column '", columnName, "' doesn't belong to any of the selected models (1), when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 270 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 280 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_VAR(models); zephir_read_property_this(&models, this_ptr, SL("_models"), PH_NOISY_CC); if (Z_TYPE_P(models) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The models list was not loaded correctly", "phalcon/mvc/model/query.zep", 278); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The models list was not loaded correctly", "phalcon/mvc/model/query.zep", 288); return; } ZEPHIR_INIT_VAR(className); @@ -92020,7 +92483,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Can't obtain model's source from models list: '", className, "', when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 286 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 296 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -92041,7 +92504,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Column '", columnName, "' doesn't belong to any of the selected models (3), when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 303 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 313 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -92071,13 +92534,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCallArgument) { - zephir_array_fetch_string(&_0, argument, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 326 TSRMLS_CC); + zephir_array_fetch_string(&_0, argument, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 336 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 352)) { zephir_create_array(return_value, 1, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("all"), 1); RETURN_MM(); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 323, argument); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 316, argument); zephir_check_call_status(); RETURN_MM(); @@ -92101,8 +92564,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) { ZEPHIR_INIT_VAR(whenClauses); array_init(whenClauses); - zephir_array_fetch_string(&_0, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 340 TSRMLS_CC); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 355); + zephir_array_fetch_string(&_0, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 350 TSRMLS_CC); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 365); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -92112,30 +92575,30 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) { ZEPHIR_INIT_NVAR(_4); zephir_create_array(_4, 3, 0 TSRMLS_CC); add_assoc_stringl_ex(_4, SS("type"), SL("when"), 1); - zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 344 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6); + zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 354 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _6); zephir_check_call_status(); zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE); - zephir_array_fetch_string(&_8, whenExpr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 345 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _8); + zephir_array_fetch_string(&_8, whenExpr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 355 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _8); zephir_check_call_status(); zephir_array_update_string(&_4, SL("then"), &_5, PH_COPY | PH_SEPARATE); - zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 346); + zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 356); } else { ZEPHIR_INIT_NVAR(_4); zephir_create_array(_4, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(_4, SS("type"), SL("else"), 1); - zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 350 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6); + zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 360 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _6); zephir_check_call_status(); zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE); - zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 351); + zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 361); } } zephir_create_array(return_value, 3, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("case"), 1); - zephir_array_fetch_string(&_6, expr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 357 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6); + zephir_array_fetch_string(&_6, expr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 367 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _6); zephir_check_call_status(); zephir_array_update_string(&return_value, SL("expr"), &_5, PH_COPY | PH_SEPARATE); zephir_array_update_string(&return_value, SL("when-clauses"), &whenClauses, PH_COPY | PH_SEPARATE); @@ -92169,19 +92632,19 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { ZEPHIR_INIT_VAR(functionArgs); if (zephir_array_isset_long(arguments, 0)) { array_init(functionArgs); - zephir_is_iterable(arguments, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 383); + zephir_is_iterable(arguments, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 393); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(argument, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, argument); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 317, argument); zephir_check_call_status(); - zephir_array_append(&functionArgs, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 381); + zephir_array_append(&functionArgs, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 391); } } else { zephir_create_array(functionArgs, 1, 0 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, arguments); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 317, arguments); zephir_check_call_status(); zephir_array_fast_append(functionArgs, _3); } @@ -92189,7 +92652,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { zephir_create_array(return_value, 4, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("functionCall"), 1); ZEPHIR_OBS_VAR(_5); - zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 391 TSRMLS_CC); + zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 401 TSRMLS_CC); zephir_array_update_string(&return_value, SL("name"), &_5, PH_COPY | PH_SEPARATE); zephir_array_update_string(&return_value, SL("arguments"), &functionArgs, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_6); @@ -92200,7 +92663,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { zephir_create_array(return_value, 3, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("functionCall"), 1); ZEPHIR_OBS_NVAR(_5); - zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 398 TSRMLS_CC); + zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 408 TSRMLS_CC); zephir_array_update_string(&return_value, SL("name"), &_5, PH_COPY | PH_SEPARATE); zephir_array_update_string(&return_value, SL("arguments"), &functionArgs, PH_COPY | PH_SEPARATE); RETURN_MM(); @@ -92209,7 +92672,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { zephir_create_array(return_value, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("functionCall"), 1); ZEPHIR_OBS_NVAR(_5); - zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 407 TSRMLS_CC); + zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 417 TSRMLS_CC); zephir_array_update_string(&return_value, SL("name"), &_5, PH_COPY | PH_SEPARATE); RETURN_MM(); @@ -92244,12 +92707,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { if (!ZEPHIR_IS_LONG(exprType, 409)) { ZEPHIR_OBS_VAR(exprLeft); if (zephir_array_isset_string_fetch(&exprLeft, expr, SS("left"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 323, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 316, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } ZEPHIR_OBS_VAR(exprRight); if (zephir_array_isset_string_fetch(&exprRight, expr, SS("right"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 323, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 316, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } } @@ -92327,7 +92790,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { break; } if (ZEPHIR_IS_LONG(exprType, 355)) { - ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 325, expr); + ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 318, expr); zephir_check_call_status(); break; } @@ -92414,7 +92877,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("literal"), 1); ZEPHIR_OBS_VAR(_2); - zephir_array_fetch_string(&_2, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 525 TSRMLS_CC); + zephir_array_fetch_string(&_2, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 535 TSRMLS_CC); zephir_array_update_string(&exprReturn, SL("value"), &_2, PH_COPY | PH_SEPARATE); break; } @@ -92434,9 +92897,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { } if (ZEPHIR_IS_LONG(exprType, 260)) { ZEPHIR_OBS_VAR(value); - zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 537 TSRMLS_CC); + zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 547 TSRMLS_CC); if (quoting == 1) { - if (zephir_memnstr_str(value, SL("'"), "phalcon/mvc/model/query.zep", 542)) { + if (zephir_memnstr_str(value, SL("'"), "phalcon/mvc/model/query.zep", 552)) { ZEPHIR_INIT_VAR(escapedValue); phalcon_orm_singlequotes(escapedValue, value TSRMLS_CC); } else { @@ -92458,7 +92921,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("placeholder"), 1); ZEPHIR_INIT_VAR(_3); - zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 555 TSRMLS_CC); + zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 565 TSRMLS_CC); ZEPHIR_SINIT_VAR(_5); ZVAL_STRING(&_5, "?", 0); ZEPHIR_SINIT_VAR(_6); @@ -92471,7 +92934,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_INIT_NVAR(exprReturn); zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("placeholder"), 1); - zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 559 TSRMLS_CC); + zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 569 TSRMLS_CC); ZEPHIR_INIT_VAR(_7); ZEPHIR_CONCAT_SV(_7, ":", _4); zephir_array_update_string(&exprReturn, SL("value"), &_7, PH_COPY | PH_SEPARATE); @@ -92479,14 +92942,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { } if (ZEPHIR_IS_LONG(exprType, 277)) { ZEPHIR_OBS_NVAR(value); - zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 563 TSRMLS_CC); - if (zephir_memnstr_str(value, SL(":"), "phalcon/mvc/model/query.zep", 564)) { + zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 573 TSRMLS_CC); + if (zephir_memnstr_str(value, SL(":"), "phalcon/mvc/model/query.zep", 574)) { ZEPHIR_INIT_VAR(valueParts); zephir_fast_explode_str(valueParts, SL(":"), value, LONG_MAX TSRMLS_CC); ZEPHIR_OBS_VAR(name); - zephir_array_fetch_long(&name, valueParts, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 567 TSRMLS_CC); + zephir_array_fetch_long(&name, valueParts, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 577 TSRMLS_CC); ZEPHIR_OBS_VAR(bindType); - zephir_array_fetch_long(&bindType, valueParts, 1, PH_NOISY, "phalcon/mvc/model/query.zep", 568 TSRMLS_CC); + zephir_array_fetch_long(&bindType, valueParts, 1, PH_NOISY, "phalcon/mvc/model/query.zep", 578 TSRMLS_CC); do { if (ZEPHIR_IS_STRING(bindType, "str")) { ZEPHIR_INIT_NVAR(_3); @@ -92570,7 +93033,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_7, "Bind value is required for array type placeholder: ", name); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 607 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 617 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -92581,7 +93044,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_10, "Bind type requires an array in placeholder: ", name); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 611 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 621 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -92592,7 +93055,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_10, "At least one value must be bound in placeholder: ", name); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 615 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 625 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -92612,7 +93075,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_10, "Unknown bind type: ", bindType); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 627 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 637 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -92767,17 +93230,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("literal"), 1); ZEPHIR_OBS_NVAR(_2); - zephir_array_fetch_string(&_2, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 700 TSRMLS_CC); + zephir_array_fetch_string(&_2, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 710 TSRMLS_CC); zephir_array_update_string(&exprReturn, SL("value"), &_2, PH_COPY | PH_SEPARATE); break; } if (ZEPHIR_IS_LONG(exprType, 350)) { - ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 326, expr); + ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 319, expr); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(exprType, 409)) { - ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 327, expr); + ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 320, expr); zephir_check_call_status(); break; } @@ -92787,7 +93250,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { add_assoc_stringl_ex(exprReturn, SS("type"), SL("select"), 1); ZEPHIR_INIT_NVAR(_3); ZVAL_BOOL(_3, 1); - ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 328, expr, _3); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 321, expr, _3); zephir_check_call_status(); zephir_array_update_string(&exprReturn, SL("value"), &_12, PH_COPY | PH_SEPARATE); break; @@ -92798,7 +93261,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_7, "Unknown expression type ", exprType); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 716 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 726 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -92806,29 +93269,29 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { RETURN_CCTOR(exprReturn); } if (zephir_array_isset_string(expr, SS("domain"))) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 325, expr); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 318, expr); zephir_check_call_status(); RETURN_MM(); } if (zephir_array_isset_long(expr, 0)) { ZEPHIR_INIT_VAR(listItems); array_init(listItems); - zephir_is_iterable(expr, &_14, &_13, 0, 0, "phalcon/mvc/model/query.zep", 737); + zephir_is_iterable(expr, &_14, &_13, 0, 0, "phalcon/mvc/model/query.zep", 747); for ( ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS ; zephir_hash_move_forward_ex(_14, &_13) ) { ZEPHIR_GET_HVALUE(exprListItem, _15); - ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 323, exprListItem); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 316, exprListItem); zephir_check_call_status(); - zephir_array_append(&listItems, _12, PH_SEPARATE, "phalcon/mvc/model/query.zep", 735); + zephir_array_append(&listItems, _12, PH_SEPARATE, "phalcon/mvc/model/query.zep", 745); } zephir_create_array(return_value, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("list"), 1); zephir_array_fast_append(return_value, listItems); RETURN_MM(); } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown expression", "phalcon/mvc/model/query.zep", 740); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown expression", "phalcon/mvc/model/query.zep", 750); return; } @@ -92836,10 +93299,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSelectColumn) { int ZEPHIR_LAST_CALL_STATUS; + zephir_fcall_cache_entry *_5 = NULL; HashTable *_2; HashPosition _1; - zval *column_param = NULL, *sqlColumns, *columnType, *sqlAliases, *modelName = NULL, *source = NULL, *columnDomain, *sqlColumnAlias = NULL, *preparedAlias = NULL, *sqlExprColumn = NULL, *sqlAliasesModels, *sqlColumn, *columnData, *balias, *_0, **_3, *_5 = NULL, *_6 = NULL; - zval *column = NULL, *_4 = NULL; + zval *column_param = NULL, *sqlColumns, *columnType, *sqlAliases, *modelName = NULL, *source = NULL, *columnDomain, *sqlColumnAlias = NULL, *preparedAlias = NULL, *sqlExprColumn = NULL, *sqlAliasesModels, *sqlColumn = NULL, *columnData, *balias, *eager, *_0, **_3, *_4 = NULL, *_6, *_7 = NULL, *_8 = NULL, *_9; + zval *column = NULL; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 1, 0, &column_param); @@ -92850,95 +93314,119 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSelectColumn) { ZEPHIR_OBS_VAR(columnType); if (!(zephir_array_isset_string_fetch(&columnType, column, SS("type"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 757); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 764); return; } ZEPHIR_INIT_VAR(sqlColumns); array_init(sqlColumns); + ZEPHIR_OBS_VAR(eager); + zephir_array_isset_string_fetch(&eager, column, SS("eager"), 0 TSRMLS_CC); if (ZEPHIR_IS_LONG(columnType, 352)) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_models"), PH_NOISY_CC); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 773); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 794); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) ) { ZEPHIR_GET_HMKEY(modelName, _2, _1); ZEPHIR_GET_HVALUE(source, _3); - ZEPHIR_INIT_NVAR(_4); - zephir_create_array(_4, 3, 0 TSRMLS_CC); - add_assoc_stringl_ex(_4, SS("type"), SL("object"), 1); - zephir_array_update_string(&_4, SL("model"), &modelName, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_4, SL("column"), &source, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 771); + ZEPHIR_INIT_NVAR(sqlColumn); + zephir_create_array(sqlColumn, 4, 0 TSRMLS_CC); + add_assoc_stringl_ex(sqlColumn, SS("type"), SL("object"), 1); + zephir_array_update_string(&sqlColumn, SL("model"), &modelName, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlColumn, SL("column"), &source, PH_COPY | PH_SEPARATE); + ZEPHIR_CALL_FUNCTION(&_4, "lcfirst", &_5, 67, modelName); + zephir_check_call_status(); + zephir_array_update_string(&sqlColumn, SL("balias"), &_4, PH_COPY | PH_SEPARATE); + if (Z_TYPE_P(eager) != IS_NULL) { + zephir_array_update_string(&sqlColumn, SL("eager"), &eager, PH_COPY | PH_SEPARATE); + zephir_array_fetch_string(&_6, column, SL("eagerType"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 789 TSRMLS_CC); + zephir_array_update_string(&sqlColumn, SL("eagerType"), &_6, PH_COPY | PH_SEPARATE); + } + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 792); } RETURN_CCTOR(sqlColumns); } if (!(zephir_array_isset_string(column, SS("column")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 777); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 798); return; } if (ZEPHIR_IS_LONG(columnType, 353)) { ZEPHIR_OBS_VAR(sqlAliases); zephir_read_property_this(&sqlAliases, this_ptr, SL("_sqlAliases"), PH_NOISY_CC); ZEPHIR_OBS_VAR(columnDomain); - zephir_array_fetch_string(&columnDomain, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 790 TSRMLS_CC); + zephir_array_fetch_string(&columnDomain, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 811 TSRMLS_CC); ZEPHIR_OBS_VAR(source); if (!(zephir_array_isset_fetch(&source, sqlAliases, columnDomain, 0 TSRMLS_CC))) { - ZEPHIR_INIT_VAR(_5); - object_init_ex(_5, phalcon_mvc_model_exception_ce); + ZEPHIR_INIT_VAR(_7); + object_init_ex(_7, phalcon_mvc_model_exception_ce); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_6); - ZEPHIR_CONCAT_SVSV(_6, "Unknown model or alias '", columnDomain, "' (2), when preparing: ", _0); - ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 9, _6); + ZEPHIR_INIT_VAR(_8); + ZEPHIR_CONCAT_SVSV(_8, "Unknown model or alias '", columnDomain, "' (2), when preparing: ", _0); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", NULL, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 793 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 814 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_CPY_WRT(sqlColumnAlias, source); + ZEPHIR_OBS_VAR(preparedAlias); + zephir_array_isset_string_fetch(&preparedAlias, column, SS("balias"), 0 TSRMLS_CC); ZEPHIR_OBS_VAR(sqlAliasesModels); zephir_read_property_this(&sqlAliasesModels, this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch(&modelName, sqlAliasesModels, columnDomain, PH_NOISY, "phalcon/mvc/model/query.zep", 805 TSRMLS_CC); - if (ZEPHIR_IS_EQUAL(columnDomain, modelName)) { - ZEPHIR_CALL_FUNCTION(&preparedAlias, "lcfirst", NULL, 65, modelName); - zephir_check_call_status(); - } else { - ZEPHIR_CPY_WRT(preparedAlias, columnDomain); + zephir_array_fetch(&modelName, sqlAliasesModels, columnDomain, PH_NOISY, "phalcon/mvc/model/query.zep", 828 TSRMLS_CC); + if (Z_TYPE_P(preparedAlias) != IS_STRING) { + if (ZEPHIR_IS_EQUAL(columnDomain, modelName)) { + ZEPHIR_CALL_FUNCTION(&preparedAlias, "lcfirst", &_5, 67, modelName); + zephir_check_call_status(); + } else { + ZEPHIR_CPY_WRT(preparedAlias, columnDomain); + } } - ZEPHIR_INIT_NVAR(_4); - zephir_create_array(_4, 4, 0 TSRMLS_CC); - add_assoc_stringl_ex(_4, SS("type"), SL("object"), 1); - zephir_array_update_string(&_4, SL("model"), &modelName, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_4, SL("column"), &sqlColumnAlias, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_4, SL("balias"), &preparedAlias, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 824); + ZEPHIR_INIT_NVAR(sqlColumn); + zephir_create_array(sqlColumn, 4, 0 TSRMLS_CC); + add_assoc_stringl_ex(sqlColumn, SS("type"), SL("object"), 1); + zephir_array_update_string(&sqlColumn, SL("model"), &modelName, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlColumn, SL("column"), &sqlColumnAlias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlColumn, SL("balias"), &preparedAlias, PH_COPY | PH_SEPARATE); + if (Z_TYPE_P(eager) != IS_NULL) { + zephir_array_update_string(&sqlColumn, SL("eager"), &eager, PH_COPY | PH_SEPARATE); + zephir_array_fetch_string(&_6, column, SL("eagerType"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 854 TSRMLS_CC); + zephir_array_update_string(&sqlColumn, SL("eagerType"), &_6, PH_COPY | PH_SEPARATE); + } + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 857); RETURN_CCTOR(sqlColumns); } if (ZEPHIR_IS_LONG(columnType, 354)) { - ZEPHIR_INIT_VAR(sqlColumn); + ZEPHIR_INIT_NVAR(sqlColumn); zephir_create_array(sqlColumn, 1, 0 TSRMLS_CC); add_assoc_stringl_ex(sqlColumn, SS("type"), SL("scalar"), 1); ZEPHIR_OBS_VAR(columnData); - zephir_array_fetch_string(&columnData, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 838 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 323, columnData); + zephir_array_fetch_string(&columnData, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 871 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 316, columnData); zephir_check_call_status(); ZEPHIR_OBS_VAR(balias); if (zephir_array_isset_string_fetch(&balias, sqlExprColumn, SS("balias"), 0 TSRMLS_CC)) { zephir_array_update_string(&sqlColumn, SL("balias"), &balias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&sqlColumn, SL("sqlAlias"), &balias, PH_COPY | PH_SEPARATE); } + if (Z_TYPE_P(eager) != IS_NULL) { + zephir_array_update_string(&sqlColumn, SL("eager"), &eager, PH_COPY | PH_SEPARATE); + zephir_array_fetch_string(&_9, column, SL("eagerType"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 884 TSRMLS_CC); + zephir_array_update_string(&sqlColumn, SL("eagerType"), &_9, PH_COPY | PH_SEPARATE); + } zephir_array_update_string(&sqlColumn, SL("column"), &sqlExprColumn, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 850); + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 888); RETURN_CCTOR(sqlColumns); } - ZEPHIR_INIT_NVAR(_5); - object_init_ex(_5, phalcon_mvc_model_exception_ce); - ZEPHIR_INIT_LNVAR(_6); - ZEPHIR_CONCAT_SV(_6, "Unknown type of column ", columnType); - ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 9, _6); + ZEPHIR_INIT_NVAR(_7); + object_init_ex(_7, phalcon_mvc_model_exception_ce); + ZEPHIR_INIT_LNVAR(_8); + ZEPHIR_CONCAT_SV(_8, "Unknown type of column ", columnType); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", NULL, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 855 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 893 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -92956,7 +93444,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getTable) { ZEPHIR_OBS_VAR(modelName); if (!(zephir_array_isset_string_fetch(&modelName, qualifiedName, SS("name"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 870); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 908); return; } ZEPHIR_CALL_METHOD(&model, manager, "load", NULL, 0, modelName); @@ -92987,17 +93475,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoin) { ZEPHIR_OBS_VAR(qualified); if (zephir_array_isset_string_fetch(&qualified, join, SS("qualified"), 0 TSRMLS_CC)) { - zephir_array_fetch_string(&_0, qualified, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 897 TSRMLS_CC); + zephir_array_fetch_string(&_0, qualified, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 932 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 355)) { ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_string(&modelName, qualified, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 899 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 901)) { + zephir_array_fetch_string(&modelName, qualified, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 934 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 936)) { ZEPHIR_INIT_VAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_2, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 903 TSRMLS_CC); + zephir_array_fetch_long(&_2, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 938 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_1, manager, "getnamespacealias", NULL, 0, _2); zephir_check_call_status(); - zephir_array_fetch_long(&_3, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 903 TSRMLS_CC); + zephir_array_fetch_long(&_3, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 938 TSRMLS_CC); ZEPHIR_INIT_VAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _1, "\\", _3); } else { @@ -93019,7 +93507,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoin) { RETURN_MM(); } } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 921); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 956); return; } @@ -93036,7 +93524,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoinType) { ZEPHIR_OBS_VAR(type); if (!(zephir_array_isset_string_fetch(&type, join, SS("type"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 935); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 970); return; } do { @@ -93064,7 +93552,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoinType) { ZEPHIR_CONCAT_SVSV(_2, "Unknown join type ", type, ", when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 956 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 991 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -93114,7 +93602,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_long_ex(_2, SS("type"), 355); zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_2, SL("name"), &fields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _2); zephir_check_call_status(); zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_4); @@ -93122,14 +93610,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _4); zephir_check_call_status(); zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE); zephir_array_fast_append(sqlJoinConditions, _0); } else { ZEPHIR_INIT_VAR(sqlJoinPartialConditions); array_init(sqlJoinPartialConditions); - zephir_is_iterable(fields, &_6, &_5, 0, 0, "phalcon/mvc/model/query.zep", 1044); + zephir_is_iterable(fields, &_6, &_5, 0, 0, "phalcon/mvc/model/query.zep", 1079); for ( ; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS ; zephir_hash_move_forward_ex(_6, &_5) @@ -93145,7 +93633,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { ZEPHIR_CONCAT_SVSVSV(_10, "The number of fields must be equal to the number of referenced fields in join ", modelAlias, "-", joinAlias, ", when preparing: ", _9); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 1020 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 1055 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -93158,7 +93646,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_long_ex(_2, SS("type"), 355); zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_2, SL("name"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _2); zephir_check_call_status(); zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_NVAR(_4); @@ -93166,10 +93654,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("name"), &referencedField, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _4); zephir_check_call_status(); zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlJoinPartialConditions, _0, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1041); + zephir_array_append(&sqlJoinPartialConditions, _0, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1076); } } zephir_create_array(return_value, 3, 0 TSRMLS_CC); @@ -93219,7 +93707,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { ZEPHIR_CALL_METHOD(&referencedModelName, relation, "getreferencedmodel", NULL, 0); zephir_check_call_status(); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1169); + zephir_is_iterable(fields, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1204); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -93234,12 +93722,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { ZEPHIR_CONCAT_SVSVSV(_5, "The number of fields must be equal to the number of referenced fields in join ", modelAlias, "-", joinAlias, ", when preparing: ", _4); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_6, 9, _5); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 1140 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 1175 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_NVAR(intermediateField); - zephir_array_fetch(&intermediateField, intermediateFields, position, PH_NOISY, "phalcon/mvc/model/query.zep", 1146 TSRMLS_CC); + zephir_array_fetch(&intermediateField, intermediateFields, position, PH_NOISY, "phalcon/mvc/model/query.zep", 1181 TSRMLS_CC); ZEPHIR_INIT_NVAR(sqlEqualsJoinCondition); zephir_create_array(sqlEqualsJoinCondition, 4, 0 TSRMLS_CC); add_assoc_stringl_ex(sqlEqualsJoinCondition, SS("type"), SL("binary-op"), 1); @@ -93249,7 +93737,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_long_ex(_8, SS("type"), 355); zephir_array_update_string(&_8, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_8, SL("name"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _8); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _8); zephir_check_call_status(); zephir_array_update_string(&sqlEqualsJoinCondition, SL("left"), &_7, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_NVAR(_10); @@ -93257,7 +93745,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_stringl_ex(_10, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_10, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_10, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _10); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _10); zephir_check_call_status(); zephir_array_update_string(&sqlEqualsJoinCondition, SL("right"), &_7, PH_COPY | PH_SEPARATE); } @@ -93279,7 +93767,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_long_ex(_12, SS("type"), 355); zephir_array_update_string(&_12, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_12, SL("name"), &fields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _12); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _12); zephir_check_call_status(); zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_13); @@ -93287,7 +93775,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_stringl_ex(_13, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_13, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_13, SL("name"), &intermediateFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _13); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _13); zephir_check_call_status(); zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE); zephir_array_fast_append(_10, _11); @@ -93308,7 +93796,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_long_ex(_14, SS("type"), 355); zephir_array_update_string(&_14, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_14, SL("name"), &intermediateReferencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _14); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _14); zephir_check_call_status(); zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_15); @@ -93316,7 +93804,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_stringl_ex(_15, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_15, SL("domain"), &referencedModelName, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_15, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _15); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _15); zephir_check_call_status(); zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE); zephir_array_fast_append(_10, _11); @@ -93329,12 +93817,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { - zval *_28 = NULL, *_29 = NULL; - zephir_fcall_cache_entry *_3 = NULL, *_4 = NULL, *_8 = NULL, *_13 = NULL, *_20 = NULL, *_21 = NULL, *_23 = NULL, *_24 = NULL; + zval *_17 = NULL, *_18 = NULL, *_40 = NULL; + zephir_fcall_cache_entry *_3 = NULL, *_4 = NULL, *_8 = NULL, *_13 = NULL, *_31 = NULL, *_32 = NULL, *_35 = NULL, *_36 = NULL; int ZEPHIR_LAST_CALL_STATUS; - HashTable *_1, *_10, *_15, *_18, *_26; - HashPosition _0, _9, _14, _17, _25; - zval *select, *models, *sqlAliases, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *modelsInstances, *fromModels = NULL, *sqlJoins, *joinModels, *joinSources, *joinTypes, *joinPreCondition, *joinPrepared, *manager = NULL, *selectJoins = NULL, *joinItem = NULL, *joins, *joinData = NULL, *schema = NULL, *source = NULL, *model = NULL, *realModelName = NULL, *completeSource = NULL, *joinType = NULL, *aliasExpr = NULL, *alias = NULL, *joinAliasName = NULL, *joinExpr = NULL, *fromModelName = NULL, *joinAlias = NULL, *joinModel = NULL, *joinSource = NULL, *preCondition = NULL, *modelNameAlias = NULL, *relation = NULL, *relations = NULL, *modelAlias = NULL, *sqlJoin = NULL, *sqlJoinItem = NULL, **_2, *_5 = NULL, *_6, *_7 = NULL, **_11, *_12 = NULL, **_16, **_19, *_22 = NULL, **_27; + HashTable *_1, *_10, *_15, *_20, *_26, *_29, *_38; + HashPosition _0, _9, _14, _19, _25, _28, _37; + zval *select, *models, *sqlAliases, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *modelsInstances, *fromModels = NULL, *sqlJoins, *joinModels, *joinSources, *joinTypes, *joinPreCondition, *joinPrepared, *manager, *selectJoins = NULL, *joinItem = NULL, *joins, *joinData = NULL, *schema = NULL, *source = NULL, *model = NULL, *realModelName = NULL, *completeSource = NULL, *joinType = NULL, *aliasExpr = NULL, *alias = NULL, *joinAliasName = NULL, *joinExpr = NULL, *fromModelName = NULL, *joinAlias = NULL, *joinModel = NULL, *joinSource = NULL, *preCondition = NULL, *modelNameAlias = NULL, *relation = NULL, *relations = NULL, *modelAlias = NULL, *sqlJoin = NULL, *sqlJoinItem = NULL, *selectTables = NULL, *tables, *tableItem = NULL, **_2, *_5 = NULL, *_6, *_7 = NULL, **_11, *_12 = NULL, **_16, **_21, *_22, *_23 = NULL, *_24 = NULL, **_27, **_30, *_33 = NULL, *_34, **_39; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 1, 0, &select); @@ -93368,8 +93856,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { array_init(joinPrepared); ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tables); + zephir_array_fetch_string(&tables, select, SL("tables"), PH_NOISY, "phalcon/mvc/model/query.zep", 1295 TSRMLS_CC); + if (!(zephir_array_isset_long(tables, 0))) { + ZEPHIR_INIT_VAR(selectTables); + zephir_create_array(selectTables, 1, 0 TSRMLS_CC); + zephir_array_fast_append(selectTables, tables); + } else { + ZEPHIR_CPY_WRT(selectTables, tables); + } ZEPHIR_OBS_VAR(joins); - zephir_array_fetch_string(&joins, select, SL("joins"), PH_NOISY, "phalcon/mvc/model/query.zep", 1260 TSRMLS_CC); + zephir_array_fetch_string(&joins, select, SL("joins"), PH_NOISY, "phalcon/mvc/model/query.zep", 1302 TSRMLS_CC); if (!(zephir_array_isset_long(joins, 0))) { ZEPHIR_INIT_VAR(selectJoins); zephir_create_array(selectJoins, 1, 0 TSRMLS_CC); @@ -93377,32 +93874,32 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { } else { ZEPHIR_CPY_WRT(selectJoins, joins); } - zephir_is_iterable(selectJoins, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1409); + zephir_is_iterable(selectJoins, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1451); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(joinItem, _2); - ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 329, manager, joinItem); + ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 322, manager, joinItem); zephir_check_call_status(); ZEPHIR_OBS_NVAR(source); - zephir_array_fetch_string(&source, joinData, SL("source"), PH_NOISY, "phalcon/mvc/model/query.zep", 1273 TSRMLS_CC); + zephir_array_fetch_string(&source, joinData, SL("source"), PH_NOISY, "phalcon/mvc/model/query.zep", 1315 TSRMLS_CC); ZEPHIR_OBS_NVAR(schema); - zephir_array_fetch_string(&schema, joinData, SL("schema"), PH_NOISY, "phalcon/mvc/model/query.zep", 1274 TSRMLS_CC); + zephir_array_fetch_string(&schema, joinData, SL("schema"), PH_NOISY, "phalcon/mvc/model/query.zep", 1316 TSRMLS_CC); ZEPHIR_OBS_NVAR(model); - zephir_array_fetch_string(&model, joinData, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 1275 TSRMLS_CC); + zephir_array_fetch_string(&model, joinData, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 1317 TSRMLS_CC); ZEPHIR_OBS_NVAR(realModelName); - zephir_array_fetch_string(&realModelName, joinData, SL("modelName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1276 TSRMLS_CC); + zephir_array_fetch_string(&realModelName, joinData, SL("modelName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1318 TSRMLS_CC); ZEPHIR_INIT_NVAR(completeSource); zephir_create_array(completeSource, 2, 0 TSRMLS_CC); zephir_array_fast_append(completeSource, source); zephir_array_fast_append(completeSource, schema); - ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 330, joinItem); + ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 323, joinItem); zephir_check_call_status(); ZEPHIR_OBS_NVAR(aliasExpr); if (zephir_array_isset_string_fetch(&aliasExpr, joinItem, SS("alias"), 0 TSRMLS_CC)) { ZEPHIR_OBS_NVAR(alias); - zephir_array_fetch_string(&alias, aliasExpr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1289 TSRMLS_CC); + zephir_array_fetch_string(&alias, aliasExpr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1331 TSRMLS_CC); if (zephir_array_isset(joinModels, alias)) { ZEPHIR_INIT_NVAR(_5); object_init_ex(_5, phalcon_mvc_model_exception_ce); @@ -93411,11 +93908,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { ZEPHIR_CONCAT_SVSV(_7, "Cannot use '", alias, "' as join alias because it was already used, when preparing: ", _6); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1295 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1337 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1301); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1343); zephir_array_update_zval(&joinTypes, alias, &joinType, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliases, alias, &alias, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&joinModels, alias, &realModelName, PH_COPY | PH_SEPARATE); @@ -93434,7 +93931,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { ZEPHIR_CONCAT_SVSV(_7, "Cannot use '", realModelName, "' as join alias because it was already used, when preparing: ", _6); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1354 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1396 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -93456,7 +93953,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), sqlModelsAliases TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), sqlAliasesModelsInstances TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_modelsInstances"), modelsInstances TSRMLS_CC); - zephir_is_iterable(joinPrepared, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 1429); + zephir_is_iterable(joinPrepared, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 1471); for ( ; zephir_hash_get_current_data_ex(_10, (void**) &_11, &_9) == SUCCESS ; zephir_hash_move_forward_ex(_10, &_9) @@ -93465,102 +93962,141 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { ZEPHIR_GET_HVALUE(joinItem, _11); ZEPHIR_OBS_NVAR(joinExpr); if (zephir_array_isset_string_fetch(&joinExpr, joinItem, SS("conditions"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 323, joinExpr); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 316, joinExpr); zephir_check_call_status(); zephir_array_update_zval(&joinPreCondition, joinAliasName, &_12, PH_COPY | PH_SEPARATE); } } - ZEPHIR_OBS_NVAR(manager); - zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); - ZEPHIR_INIT_NVAR(_5); - zephir_is_iterable(fromModels, &_15, &_14, 0, 0, "phalcon/mvc/model/query.zep", 1537); + _6 = zephir_fetch_nproperty_this(this_ptr, SL("_enableImplicitJoins"), PH_NOISY_CC); + if (!(zephir_is_true(_6))) { + ZEPHIR_INIT_NVAR(_5); + zephir_is_iterable(joinPrepared, &_15, &_14, 0, 0, "phalcon/mvc/model/query.zep", 1482); + for ( + ; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS + ; zephir_hash_move_forward_ex(_15, &_14) + ) { + ZEPHIR_GET_HMKEY(joinAliasName, _15, _14); + ZEPHIR_GET_HVALUE(_5, _16); + ZEPHIR_OBS_NVAR(joinType); + zephir_array_fetch(&joinType, joinTypes, joinAliasName, PH_NOISY, "phalcon/mvc/model/query.zep", 1473 TSRMLS_CC); + ZEPHIR_OBS_NVAR(joinSource); + zephir_array_fetch(&joinSource, joinSources, joinAliasName, PH_NOISY, "phalcon/mvc/model/query.zep", 1474 TSRMLS_CC); + ZEPHIR_OBS_NVAR(preCondition); + zephir_array_fetch(&preCondition, joinPreCondition, joinAliasName, PH_NOISY, "phalcon/mvc/model/query.zep", 1475 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_17); + zephir_create_array(_17, 3, 0 TSRMLS_CC); + zephir_array_update_string(&_17, SL("type"), &joinType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_17, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_18); + zephir_create_array(_18, 1, 0 TSRMLS_CC); + zephir_array_fast_append(_18, preCondition); + zephir_array_update_string(&_17, SL("conditions"), &_18, PH_COPY | PH_SEPARATE); + zephir_array_append(&sqlJoins, _17, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1480); + } + RETURN_CCTOR(sqlJoins); + } + ZEPHIR_INIT_NVAR(fromModels); + array_init(fromModels); + zephir_is_iterable(selectTables, &_20, &_19, 0, 0, "phalcon/mvc/model/query.zep", 1496); for ( - ; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS - ; zephir_hash_move_forward_ex(_15, &_14) + ; zephir_hash_get_current_data_ex(_20, (void**) &_21, &_19) == SUCCESS + ; zephir_hash_move_forward_ex(_20, &_19) + ) { + ZEPHIR_GET_HVALUE(tableItem, _21); + zephir_array_fetch_string(&_22, tableItem, SL("qualifiedName"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1490 TSRMLS_CC); + ZEPHIR_OBS_NVAR(_23); + zephir_array_fetch_string(&_23, _22, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1490 TSRMLS_CC); + zephir_array_update_zval(&fromModels, _23, &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE); + } + ZEPHIR_INIT_VAR(_24); + zephir_is_iterable(fromModels, &_26, &_25, 0, 0, "phalcon/mvc/model/query.zep", 1602); + for ( + ; zephir_hash_get_current_data_ex(_26, (void**) &_27, &_25) == SUCCESS + ; zephir_hash_move_forward_ex(_26, &_25) ) { - ZEPHIR_GET_HMKEY(fromModelName, _15, _14); - ZEPHIR_GET_HVALUE(_5, _16); - zephir_is_iterable(joinModels, &_18, &_17, 0, 0, "phalcon/mvc/model/query.zep", 1535); + ZEPHIR_GET_HMKEY(fromModelName, _26, _25); + ZEPHIR_GET_HVALUE(_24, _27); + zephir_is_iterable(joinModels, &_29, &_28, 0, 0, "phalcon/mvc/model/query.zep", 1600); for ( - ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS - ; zephir_hash_move_forward_ex(_18, &_17) + ; zephir_hash_get_current_data_ex(_29, (void**) &_30, &_28) == SUCCESS + ; zephir_hash_move_forward_ex(_29, &_28) ) { - ZEPHIR_GET_HMKEY(joinAlias, _18, _17); - ZEPHIR_GET_HVALUE(joinModel, _19); + ZEPHIR_GET_HMKEY(joinAlias, _29, _28); + ZEPHIR_GET_HVALUE(joinModel, _30); ZEPHIR_OBS_NVAR(joinSource); - zephir_array_fetch(&joinSource, joinSources, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1438 TSRMLS_CC); + zephir_array_fetch(&joinSource, joinSources, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1503 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinType); - zephir_array_fetch(&joinType, joinTypes, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1443 TSRMLS_CC); + zephir_array_fetch(&joinType, joinTypes, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1508 TSRMLS_CC); ZEPHIR_OBS_NVAR(preCondition); if (!(zephir_array_isset_fetch(&preCondition, joinPreCondition, joinAlias, 0 TSRMLS_CC))) { ZEPHIR_OBS_NVAR(modelNameAlias); - zephir_array_fetch(&modelNameAlias, sqlAliasesModels, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1453 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&relation, manager, "getrelationbyalias", &_20, 0, fromModelName, modelNameAlias); + zephir_array_fetch(&modelNameAlias, sqlAliasesModels, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1518 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&relation, manager, "getrelationbyalias", &_31, 0, fromModelName, modelNameAlias); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(relation)) { - ZEPHIR_CALL_METHOD(&relations, manager, "getrelationsbetween", &_21, 0, fromModelName, modelNameAlias); + ZEPHIR_CALL_METHOD(&relations, manager, "getrelationsbetween", &_32, 0, fromModelName, modelNameAlias); zephir_check_call_status(); if (Z_TYPE_P(relations) == IS_ARRAY) { if (zephir_fast_count_int(relations TSRMLS_CC) != 1) { - ZEPHIR_INIT_NVAR(_22); - object_init_ex(_22, phalcon_mvc_model_exception_ce); - _6 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); + ZEPHIR_INIT_NVAR(_33); + object_init_ex(_33, phalcon_mvc_model_exception_ce); + _34 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); ZEPHIR_INIT_LNVAR(_7); - ZEPHIR_CONCAT_SVSVSV(_7, "There is more than one relation between models '", fromModelName, "' and '", joinModel, "', the join must be done using an alias, when preparing: ", _6); - ZEPHIR_CALL_METHOD(NULL, _22, "__construct", &_8, 9, _7); + ZEPHIR_CONCAT_SVSVSV(_7, "There is more than one relation between models '", fromModelName, "' and '", joinModel, "', the join must be done using an alias, when preparing: ", _34); + ZEPHIR_CALL_METHOD(NULL, _33, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_22, "phalcon/mvc/model/query.zep", 1471 TSRMLS_CC); + zephir_throw_exception_debug(_33, "phalcon/mvc/model/query.zep", 1536 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_NVAR(relation); - zephir_array_fetch_long(&relation, relations, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 1477 TSRMLS_CC); + zephir_array_fetch_long(&relation, relations, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 1542 TSRMLS_CC); } } if (Z_TYPE_P(relation) == IS_OBJECT) { ZEPHIR_OBS_NVAR(modelAlias); - zephir_array_fetch(&modelAlias, sqlModelsAliases, fromModelName, PH_NOISY, "phalcon/mvc/model/query.zep", 1489 TSRMLS_CC); + zephir_array_fetch(&modelAlias, sqlModelsAliases, fromModelName, PH_NOISY, "phalcon/mvc/model/query.zep", 1554 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_12, relation, "isthrough", NULL, 0); zephir_check_call_status(); if (!(zephir_is_true(_12))) { - ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_23, 331, joinType, joinSource, modelAlias, joinAlias, relation); + ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_35, 324, joinType, joinSource, modelAlias, joinAlias, relation); zephir_check_call_status(); } else { - ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_24, 332, joinType, joinSource, modelAlias, joinAlias, relation); + ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_36, 325, joinType, joinSource, modelAlias, joinAlias, relation); zephir_check_call_status(); } if (zephir_array_isset_long(sqlJoin, 0)) { - zephir_is_iterable(sqlJoin, &_26, &_25, 0, 0, "phalcon/mvc/model/query.zep", 1507); + zephir_is_iterable(sqlJoin, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 1572); for ( - ; zephir_hash_get_current_data_ex(_26, (void**) &_27, &_25) == SUCCESS - ; zephir_hash_move_forward_ex(_26, &_25) + ; zephir_hash_get_current_data_ex(_38, (void**) &_39, &_37) == SUCCESS + ; zephir_hash_move_forward_ex(_38, &_37) ) { - ZEPHIR_GET_HVALUE(sqlJoinItem, _27); - zephir_array_append(&sqlJoins, sqlJoinItem, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1505); + ZEPHIR_GET_HVALUE(sqlJoinItem, _39); + zephir_array_append(&sqlJoins, sqlJoinItem, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1570); } } else { - zephir_array_append(&sqlJoins, sqlJoin, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1508); + zephir_array_append(&sqlJoins, sqlJoin, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1573); } } else { - ZEPHIR_INIT_NVAR(_28); - zephir_create_array(_28, 3, 0 TSRMLS_CC); - zephir_array_update_string(&_28, SL("type"), &joinType, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_28, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); - ZEPHIR_INIT_NVAR(_22); - array_init(_22); - zephir_array_update_string(&_28, SL("conditions"), &_22, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlJoins, _28, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1520); + ZEPHIR_INIT_NVAR(_17); + zephir_create_array(_17, 3, 0 TSRMLS_CC); + zephir_array_update_string(&_17, SL("type"), &joinType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_17, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_33); + array_init(_33); + zephir_array_update_string(&_17, SL("conditions"), &_33, PH_COPY | PH_SEPARATE); + zephir_array_append(&sqlJoins, _17, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1585); } } else { - ZEPHIR_INIT_NVAR(_28); - zephir_create_array(_28, 3, 0 TSRMLS_CC); - zephir_array_update_string(&_28, SL("type"), &joinType, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_28, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); - ZEPHIR_INIT_NVAR(_29); - zephir_create_array(_29, 1, 0 TSRMLS_CC); - zephir_array_fast_append(_29, preCondition); - zephir_array_update_string(&_28, SL("conditions"), &_29, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlJoins, _28, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1532); + ZEPHIR_INIT_NVAR(_18); + zephir_create_array(_18, 3, 0 TSRMLS_CC); + zephir_array_update_string(&_18, SL("type"), &joinType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_18, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_40); + zephir_create_array(_40, 1, 0 TSRMLS_CC); + zephir_array_fast_append(_40, preCondition); + zephir_array_update_string(&_18, SL("conditions"), &_40, PH_COPY | PH_SEPARATE); + zephir_array_append(&sqlJoins, _18, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1597); } } } @@ -93590,14 +94126,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getOrderClause) { } ZEPHIR_INIT_VAR(orderParts); array_init(orderParts); - zephir_is_iterable(orderColumns, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1578); + zephir_is_iterable(orderColumns, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1643); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(orderItem, _2); - zephir_array_fetch_string(&_3, orderItem, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1560 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 323, _3); + zephir_array_fetch_string(&_3, orderItem, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1625 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 316, _3); zephir_check_call_status(); if (zephir_array_isset_string_fetch(&orderSort, orderItem, SS("sort"), 1 TSRMLS_CC)) { ZEPHIR_INIT_NVAR(orderPartSort); @@ -93619,7 +94155,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getOrderClause) { zephir_create_array(orderPartSort, 1, 0 TSRMLS_CC); zephir_array_fast_append(orderPartSort, orderPartExpr); } - zephir_array_append(&orderParts, orderPartSort, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1575); + zephir_array_append(&orderParts, orderPartSort, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1640); } RETURN_CCTOR(orderParts); @@ -93644,19 +94180,19 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getGroupClause) { ZEPHIR_INIT_VAR(groupParts); if (zephir_array_isset_long(group, 0)) { array_init(groupParts); - zephir_is_iterable(group, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1596); + zephir_is_iterable(group, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1661); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(groupItem, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, groupItem); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 316, groupItem); zephir_check_call_status(); - zephir_array_append(&groupParts, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1594); + zephir_array_append(&groupParts, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1659); } } else { zephir_create_array(groupParts, 1, 0 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, group); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 316, group); zephir_check_call_status(); zephir_array_fast_append(groupParts, _3); } @@ -93682,13 +94218,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getLimitClause) { ZEPHIR_OBS_VAR(number); if (zephir_array_isset_string_fetch(&number, limitClause, SS("number"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, number); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 316, number); zephir_check_call_status(); zephir_array_update_string(&limit, SL("number"), &_0, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(offset); if (zephir_array_isset_string_fetch(&offset, limitClause, SS("offset"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, offset); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 316, offset); zephir_check_call_status(); zephir_array_update_string(&limit, SL("offset"), &_0, PH_COPY | PH_SEPARATE); } @@ -93698,12 +94234,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getLimitClause) { static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { - zval *_30 = NULL; - zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_11 = NULL, *_25 = NULL, *_31 = NULL; - HashTable *_1, *_23, *_27; - HashPosition _0, _22, _26; - int position, ZEPHIR_LAST_CALL_STATUS; - zval *ast = NULL, *merge = NULL, *sqlModels, *sqlTables, *sqlAliases, *sqlColumns, *select = NULL, *tables, *columns, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *models, *modelsInstances, *selectedModels = NULL, *manager, *metaData, *selectedModel = NULL, *qualifiedName = NULL, *modelName = NULL, *nsAlias = NULL, *realModelName = NULL, *model = NULL, *schema = NULL, *source = NULL, *completeSource = NULL, *alias = NULL, *joins, *sqlJoins = NULL, *selectColumns = NULL, *sqlColumnAliases, *column = NULL, *sqlColumn = NULL, *sqlSelect, *distinct, *having, *where, *groupBy, *order, *limit, **_2, *_3 = NULL, *_4, *_6, *_7 = NULL, *_9, *_10 = NULL, *_12, *_13, *_14, *_15, *_16, *_17, *_18, *_19, *_20, *_21, **_24, **_28, _29 = zval_used_for_init, *_32 = NULL; + zval *_19 = NULL, *_20 = NULL, *_21 = NULL; + zval *_16 = NULL; + zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_11 = NULL, *_17 = NULL, *_18 = NULL, *_32 = NULL, *_36 = NULL, *_40 = NULL; + HashTable *_1, *_13, *_34, *_38; + HashPosition _0, _12, _33, _37; + int position, number, ZEPHIR_LAST_CALL_STATUS; + zval *ast = NULL, *merge = NULL, *sqlModels, *sqlTables, *sqlAliases, *sqlColumns, *select = NULL, *tables, *columns, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *models, *modelsInstances, *selectedModels = NULL, *manager, *metaData, *selectedModel = NULL, *qualifiedName = NULL, *modelName = NULL, *nsAlias = NULL, *realModelName = NULL, *model = NULL, *schema = NULL, *source = NULL, *completeSource = NULL, *alias = NULL, *joins, *sqlJoins = NULL, *selectColumns = NULL, *sqlColumnAliases, *column = NULL, *sqlColumn = NULL, *sqlSelect, *distinct, *having, *where, *groupBy, *order, *limit, *tempModels, *tempModelsInstances, *tempSqlAliases, *tempSqlModelsAliases, *tempSqlAliasesModelsInstances, *tempSqlAliasesModels, *with = NULL, *withs = NULL, *withItem = NULL, *automaticJoins, *relation = NULL, *joinAlias = NULL, *relationModel = NULL, *bestAlias = NULL, *eagerType = NULL, **_2, *_3 = NULL, *_4, *_6, *_7 = NULL, *_9, *_10 = NULL, **_14, _15 = zval_used_for_init, *_22, *_23, *_24, *_25, *_26, *_27, *_28, *_29, *_30, *_31, **_35, **_39, *_41 = NULL; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 0, 2, &ast, &merge); @@ -93734,22 +94271,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } ZEPHIR_OBS_VAR(tables); if (!(zephir_array_isset_string_fetch(&tables, select, SS("tables"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1648); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1716); return; } ZEPHIR_OBS_VAR(columns); if (!(zephir_array_isset_string_fetch(&columns, select, SS("columns"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1652); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1720); return; } ZEPHIR_INIT_VAR(sqlModels); array_init(sqlModels); ZEPHIR_INIT_VAR(sqlTables); array_init(sqlTables); - ZEPHIR_INIT_VAR(sqlAliases); - array_init(sqlAliases); ZEPHIR_INIT_VAR(sqlColumns); array_init(sqlColumns); + ZEPHIR_INIT_VAR(sqlAliases); + array_init(sqlAliases); ZEPHIR_INIT_VAR(sqlAliasesModels); array_init(sqlAliasesModels); ZEPHIR_INIT_VAR(sqlModelsAliases); @@ -93767,35 +94304,45 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } else { ZEPHIR_CPY_WRT(selectedModels, tables); } + if (!(zephir_array_isset_long(columns, 0))) { + ZEPHIR_INIT_VAR(selectColumns); + zephir_create_array(selectColumns, 1, 0 TSRMLS_CC); + zephir_array_fast_append(selectColumns, columns); + } else { + ZEPHIR_CPY_WRT(selectColumns, columns); + } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); ZEPHIR_OBS_VAR(metaData); zephir_read_property_this(&metaData, this_ptr, SL("_metaData"), PH_NOISY_CC); if (Z_TYPE_P(manager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A models-manager is required to execute the query", "phalcon/mvc/model/query.zep", 1706); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A models-manager is required to execute the query", "phalcon/mvc/model/query.zep", 1782); return; } if (Z_TYPE_P(metaData) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A meta-data is required to execute the query", "phalcon/mvc/model/query.zep", 1710); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A meta-data is required to execute the query", "phalcon/mvc/model/query.zep", 1786); return; } - zephir_is_iterable(selectedModels, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1784); + number = 0; + ZEPHIR_INIT_VAR(automaticJoins); + array_init(automaticJoins); + zephir_is_iterable(selectedModels, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1913); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(selectedModel, _2); ZEPHIR_OBS_NVAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, selectedModel, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1716 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, selectedModel, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1795 TSRMLS_CC); ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1717 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 1722)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1796 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 1799)) { ZEPHIR_INIT_NVAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1724 TSRMLS_CC); + zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1801 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, manager, "getnamespacealias", &_5, 0, _4); zephir_check_call_status(); - zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1724 TSRMLS_CC); + zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1801 TSRMLS_CC); ZEPHIR_INIT_NVAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _3, "\\", _6); } else { @@ -93824,10 +94371,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { object_init_ex(_7, phalcon_mvc_model_exception_ce); _9 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); ZEPHIR_INIT_LNVAR(_10); - ZEPHIR_CONCAT_SVSV(_10, "Alias '", alias, "' is already used, when preparing: ", _9); + ZEPHIR_CONCAT_SVSV(_10, "Alias '", alias, "' is used more than once, when preparing: ", _9); ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 1752 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 1825 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -93836,7 +94383,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { zephir_array_update_zval(&sqlModelsAliases, realModelName, &alias, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, alias, &model, PH_COPY | PH_SEPARATE); if (Z_TYPE_P(completeSource) == IS_ARRAY) { - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1764); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1837); } else { ZEPHIR_INIT_NVAR(completeSource); zephir_create_array(completeSource, 3, 0 TSRMLS_CC); @@ -93846,14 +94393,100 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } zephir_array_update_zval(&models, realModelName, &alias, PH_COPY | PH_SEPARATE); } else { + ZEPHIR_CPY_WRT(alias, source); zephir_array_update_zval(&sqlAliases, realModelName, &source, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModels, realModelName, &realModelName, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlModelsAliases, realModelName, &realModelName, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&models, realModelName, &source, PH_COPY | PH_SEPARATE); } - zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1778); - zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1779); + ZEPHIR_OBS_NVAR(with); + if (zephir_array_isset_string_fetch(&with, selectedModel, SS("with"), 0 TSRMLS_CC)) { + if (!(zephir_array_isset_long(with, 0))) { + ZEPHIR_INIT_NVAR(withs); + zephir_create_array(withs, 1, 0 TSRMLS_CC); + zephir_array_fast_append(withs, with); + } else { + ZEPHIR_CPY_WRT(withs, with); + } + zephir_is_iterable(withs, &_13, &_12, 0, 0, "phalcon/mvc/model/query.zep", 1905); + for ( + ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS + ; zephir_hash_move_forward_ex(_13, &_12) + ) { + ZEPHIR_GET_HVALUE(withItem, _14); + ZEPHIR_SINIT_NVAR(_15); + ZVAL_LONG(&_15, number); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SV(_16, "AA", &_15); + ZEPHIR_CPY_WRT(joinAlias, _16); + ZEPHIR_OBS_NVAR(relationModel); + zephir_array_fetch_string(&relationModel, withItem, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1865 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&relation, manager, "getrelationbyalias", &_17, 0, realModelName, relationModel); + zephir_check_call_status(); + if (Z_TYPE_P(relation) == IS_OBJECT) { + ZEPHIR_INIT_NVAR(_7); + ZVAL_STRING(_7, "alias", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&bestAlias, relation, "getoption", NULL, 0, _7); + zephir_check_temp_parameter(_7); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&relationModel, relation, "getreferencedmodel", NULL, 0); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&eagerType, relation, "gettype", NULL, 0); + zephir_check_call_status(); + } else { + ZEPHIR_CALL_METHOD(&relation, manager, "getrelationsbetween", &_18, 0, realModelName, relationModel); + zephir_check_call_status(); + if (Z_TYPE_P(relation) == IS_OBJECT) { + ZEPHIR_INIT_NVAR(_7); + ZVAL_STRING(_7, "alias", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&bestAlias, relation, "getoption", NULL, 0, _7); + zephir_check_temp_parameter(_7); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&relationModel, relation, "getreferencedmodel", NULL, 0); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&eagerType, relation, "gettype", NULL, 0); + zephir_check_call_status(); + } else { + ZEPHIR_INIT_NVAR(_7); + object_init_ex(_7, phalcon_mvc_model_exception_ce); + _9 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); + ZEPHIR_INIT_LNVAR(_10); + ZEPHIR_CONCAT_SVSVSV(_10, "Can't find a relationship between '", realModelName, "' and '", relationModel, "' when preparing: ", _9); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_11, 9, _10); + zephir_check_call_status(); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 1879 TSRMLS_CC); + ZEPHIR_MM_RESTORE(); + return; + } + } + ZEPHIR_INIT_NVAR(_19); + zephir_create_array(_19, 5, 0 TSRMLS_CC); + add_assoc_long_ex(_19, SS("type"), 353); + zephir_array_update_string(&_19, SL("column"), &joinAlias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_19, SL("eager"), &alias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_19, SL("eagerType"), &eagerType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_19, SL("balias"), &bestAlias, PH_COPY | PH_SEPARATE); + zephir_array_append(&selectColumns, _19, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1889); + ZEPHIR_INIT_NVAR(_20); + zephir_create_array(_20, 3, 0 TSRMLS_CC); + add_assoc_long_ex(_20, SS("type"), 360); + ZEPHIR_INIT_NVAR(_21); + zephir_create_array(_21, 2, 0 TSRMLS_CC); + add_assoc_long_ex(_21, SS("type"), 355); + zephir_array_update_string(&_21, SL("name"), &relationModel, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_20, SL("qualified"), &_21, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_21); + zephir_create_array(_21, 2, 0 TSRMLS_CC); + add_assoc_long_ex(_21, SS("type"), 355); + zephir_array_update_string(&_21, SL("name"), &joinAlias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_20, SL("alias"), &_21, PH_COPY | PH_SEPARATE); + zephir_array_append(&automaticJoins, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1901); + number++; + } + } + zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1907); + zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1908); zephir_array_update_zval(&modelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); } if (!(zephir_is_true(merge))) { @@ -93864,68 +94497,85 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), sqlModelsAliases TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), sqlAliasesModelsInstances TSRMLS_CC); } else { + ZEPHIR_OBS_VAR(tempModels); + zephir_read_property_this(&tempModels, this_ptr, SL("_models"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempModelsInstances); + zephir_read_property_this(&tempModelsInstances, this_ptr, SL("_modelsInstances"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlAliases); + zephir_read_property_this(&tempSqlAliases, this_ptr, SL("_sqlAliases"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlAliasesModels); + zephir_read_property_this(&tempSqlAliasesModels, this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlModelsAliases); + zephir_read_property_this(&tempSqlModelsAliases, this_ptr, SL("_sqlModelsAliases"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlAliasesModelsInstances); + zephir_read_property_this(&tempSqlAliasesModelsInstances, this_ptr, SL("_sqlAliasesModelsInstances"), PH_NOISY_CC); ZEPHIR_INIT_NVAR(_7); _9 = zephir_fetch_nproperty_this(this_ptr, SL("_models"), PH_NOISY_CC); zephir_fast_array_merge(_7, &(_9), &(models) TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_models"), _7 TSRMLS_CC); - ZEPHIR_INIT_VAR(_12); - _13 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); - zephir_fast_array_merge(_12, &(_13), &(modelsInstances) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_modelsInstances"), _12 TSRMLS_CC); - ZEPHIR_INIT_VAR(_14); - _15 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliases"), PH_NOISY_CC); - zephir_fast_array_merge(_14, &(_15), &(sqlAliases) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlAliases"), _14 TSRMLS_CC); - ZEPHIR_INIT_VAR(_16); - _17 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); - zephir_fast_array_merge(_16, &(_17), &(sqlAliasesModels) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlAliasesModels"), _16 TSRMLS_CC); - ZEPHIR_INIT_VAR(_18); - _19 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlModelsAliases"), PH_NOISY_CC); - zephir_fast_array_merge(_18, &(_19), &(sqlModelsAliases) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), _18 TSRMLS_CC); - ZEPHIR_INIT_VAR(_20); - _21 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModelsInstances"), PH_NOISY_CC); - zephir_fast_array_merge(_20, &(_21), &(sqlAliasesModelsInstances) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), _20 TSRMLS_CC); + ZEPHIR_INIT_VAR(_22); + _23 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); + zephir_fast_array_merge(_22, &(_23), &(modelsInstances) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_modelsInstances"), _22 TSRMLS_CC); + ZEPHIR_INIT_VAR(_24); + _25 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliases"), PH_NOISY_CC); + zephir_fast_array_merge(_24, &(_25), &(sqlAliases) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliases"), _24 TSRMLS_CC); + ZEPHIR_INIT_VAR(_26); + _27 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); + zephir_fast_array_merge(_26, &(_27), &(sqlAliasesModels) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModels"), _26 TSRMLS_CC); + ZEPHIR_INIT_VAR(_28); + _29 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlModelsAliases"), PH_NOISY_CC); + zephir_fast_array_merge(_28, &(_29), &(sqlModelsAliases) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), _28 TSRMLS_CC); + ZEPHIR_INIT_VAR(_30); + _31 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModelsInstances"), PH_NOISY_CC); + zephir_fast_array_merge(_30, &(_31), &(sqlAliasesModelsInstances) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), _30 TSRMLS_CC); } ZEPHIR_OBS_VAR(joins); - if (zephir_array_isset_string_fetch(&joins, select, SS("joins"), 0 TSRMLS_CC)) { - if (zephir_fast_count_int(joins TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", NULL, 333, select); + zephir_array_isset_string_fetch(&joins, select, SS("joins"), 0 TSRMLS_CC); + if (zephir_fast_count_int(joins TSRMLS_CC)) { + if (zephir_fast_count_int(automaticJoins TSRMLS_CC)) { + if (zephir_array_isset_long(joins, 0)) { + ZEPHIR_INIT_NVAR(_7); + zephir_fast_array_merge(_7, &(joins), &(automaticJoins) TSRMLS_CC); + zephir_array_update_string(&select, SL("joins"), &_7, PH_COPY | PH_SEPARATE); + } else { + zephir_array_append(&automaticJoins, joins, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1945); + zephir_array_update_string(&select, SL("joins"), &automaticJoins, PH_COPY | PH_SEPARATE); + } + } + ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", &_32, 326, select); + zephir_check_call_status(); + } else { + if (zephir_fast_count_int(automaticJoins TSRMLS_CC)) { + zephir_array_update_string(&select, SL("joins"), &automaticJoins, PH_COPY | PH_SEPARATE); + ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", &_32, 326, select); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(sqlJoins); array_init(sqlJoins); } - } else { - ZEPHIR_INIT_NVAR(sqlJoins); - array_init(sqlJoins); - } - if (!(zephir_array_isset_long(columns, 0))) { - ZEPHIR_INIT_VAR(selectColumns); - zephir_create_array(selectColumns, 1, 0 TSRMLS_CC); - zephir_array_fast_append(selectColumns, columns); - } else { - ZEPHIR_CPY_WRT(selectColumns, columns); } position = 0; ZEPHIR_INIT_VAR(sqlColumnAliases); array_init(sqlColumnAliases); - zephir_is_iterable(selectColumns, &_23, &_22, 0, 0, "phalcon/mvc/model/query.zep", 1857); + zephir_is_iterable(selectColumns, &_34, &_33, 0, 0, "phalcon/mvc/model/query.zep", 1998); for ( - ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS - ; zephir_hash_move_forward_ex(_23, &_22) + ; zephir_hash_get_current_data_ex(_34, (void**) &_35, &_33) == SUCCESS + ; zephir_hash_move_forward_ex(_34, &_33) ) { - ZEPHIR_GET_HVALUE(column, _24); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_25, 334, column); + ZEPHIR_GET_HVALUE(column, _35); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_36, 327, column); zephir_check_call_status(); - zephir_is_iterable(_3, &_27, &_26, 0, 0, "phalcon/mvc/model/query.zep", 1856); + zephir_is_iterable(_3, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 1997); for ( - ; zephir_hash_get_current_data_ex(_27, (void**) &_28, &_26) == SUCCESS - ; zephir_hash_move_forward_ex(_27, &_26) + ; zephir_hash_get_current_data_ex(_38, (void**) &_39, &_37) == SUCCESS + ; zephir_hash_move_forward_ex(_38, &_37) ) { - ZEPHIR_GET_HVALUE(sqlColumn, _28); + ZEPHIR_GET_HVALUE(sqlColumn, _39); ZEPHIR_OBS_NVAR(alias); if (zephir_array_isset_string_fetch(&alias, column, SS("alias"), 0 TSRMLS_CC)) { zephir_array_update_string(&sqlColumn, SL("balias"), &alias, PH_COPY | PH_SEPARATE); @@ -93937,15 +94587,15 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { if (zephir_array_isset_string_fetch(&alias, sqlColumn, SS("balias"), 0 TSRMLS_CC)) { zephir_array_update_zval(&sqlColumns, alias, &sqlColumn, PH_COPY | PH_SEPARATE); } else { - zephir_array_fetch_string(&_4, sqlColumn, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1846 TSRMLS_CC); + zephir_array_fetch_string(&_4, sqlColumn, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1987 TSRMLS_CC); if (ZEPHIR_IS_STRING(_4, "scalar")) { - ZEPHIR_SINIT_NVAR(_29); - ZVAL_LONG(&_29, position); - ZEPHIR_INIT_LNVAR(_30); - ZEPHIR_CONCAT_SV(_30, "_", &_29); - zephir_array_update_zval(&sqlColumns, _30, &sqlColumn, PH_COPY | PH_SEPARATE); + ZEPHIR_SINIT_NVAR(_15); + ZVAL_LONG(&_15, position); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SV(_16, "_", &_15); + zephir_array_update_zval(&sqlColumns, _16, &sqlColumn, PH_COPY | PH_SEPARATE); } else { - zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1849); + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1990); } } } @@ -93967,37 +94617,45 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } ZEPHIR_OBS_VAR(where); if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_31, 323, where); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_40, 316, where); zephir_check_call_status(); zephir_array_update_string(&sqlSelect, SL("where"), &_3, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(groupBy); if (zephir_array_isset_string_fetch(&groupBy, ast, SS("groupBy"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getgroupclause", NULL, 335, groupBy); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getgroupclause", NULL, 328, groupBy); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("group"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("group"), &_41, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(having); if (zephir_array_isset_string_fetch(&having, ast, SS("having"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getexpression", &_31, 323, having); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getexpression", &_40, 316, having); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("having"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("having"), &_41, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(order); if (zephir_array_isset_string_fetch(&order, ast, SS("orderBy"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getorderclause", NULL, 336, order); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getorderclause", NULL, 329, order); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("order"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("order"), &_41, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(limit); if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getlimitclause", NULL, 337, limit); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getlimitclause", NULL, 330, limit); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("limit"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("limit"), &_41, PH_COPY | PH_SEPARATE); } if (zephir_array_isset_string(ast, SS("forUpdate"))) { zephir_array_update_string(&sqlSelect, SL("forUpdate"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE); } + if (zephir_is_true(merge)) { + zephir_update_property_this(this_ptr, SL("_models"), tempModels TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_modelsInstances"), tempModelsInstances TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliases"), tempSqlAliases TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModels"), tempSqlAliasesModels TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), tempSqlModelsAliases TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), tempSqlAliasesModelsInstances TSRMLS_CC); + } RETURN_CCTOR(sqlSelect); } @@ -94017,30 +94675,30 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { ZEPHIR_OBS_VAR(ast); zephir_read_property_this(&ast, this_ptr, SL("_ast"), PH_NOISY_CC); if (!(zephir_array_isset_string(ast, SS("qualifiedName")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 1920); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 2070); return; } if (!(zephir_array_isset_string(ast, SS("values")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 1924); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 2074); return; } ZEPHIR_OBS_VAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, ast, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1927 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, ast, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2077 TSRMLS_CC); if (!(zephir_array_isset_string(qualifiedName, SS("name")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 1931); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 2081); return; } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1935 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 1938)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2085 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2088)) { ZEPHIR_INIT_VAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_1, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1940 TSRMLS_CC); + zephir_array_fetch_long(&_1, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2090 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_0, manager, "getnamespacealias", NULL, 0, _1); zephir_check_call_status(); - zephir_array_fetch_long(&_2, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1940 TSRMLS_CC); + zephir_array_fetch_long(&_2, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2090 TSRMLS_CC); ZEPHIR_INIT_VAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _0, "\\", _2); } else { @@ -94063,8 +94721,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { notQuoting = 0; ZEPHIR_INIT_VAR(exprValues); array_init(exprValues); - zephir_array_fetch_string(&_1, ast, SL("values"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1956 TSRMLS_CC); - zephir_is_iterable(_1, &_5, &_4, 0, 0, "phalcon/mvc/model/query.zep", 1965); + zephir_array_fetch_string(&_1, ast, SL("values"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2106 TSRMLS_CC); + zephir_is_iterable(_1, &_5, &_4, 0, 0, "phalcon/mvc/model/query.zep", 2115); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -94073,12 +94731,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { ZEPHIR_INIT_NVAR(_7); zephir_create_array(_7, 2, 0 TSRMLS_CC); ZEPHIR_OBS_NVAR(_8); - zephir_array_fetch_string(&_8, exprValue, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 1960 TSRMLS_CC); + zephir_array_fetch_string(&_8, exprValue, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2110 TSRMLS_CC); zephir_array_update_string(&_7, SL("type"), &_8, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 323, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 316, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_array_update_string(&_7, SL("value"), &_0, PH_COPY | PH_SEPARATE); - zephir_array_append(&exprValues, _7, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1962); + zephir_array_append(&exprValues, _7, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2112); } ZEPHIR_INIT_VAR(sqlInsert); zephir_create_array(sqlInsert, 2, 0 TSRMLS_CC); @@ -94090,14 +94748,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { if (zephir_array_isset_string_fetch(&fields, ast, SS("fields"), 0 TSRMLS_CC)) { ZEPHIR_INIT_VAR(sqlFields); array_init(sqlFields); - zephir_is_iterable(fields, &_11, &_10, 0, 0, "phalcon/mvc/model/query.zep", 1987); + zephir_is_iterable(fields, &_11, &_10, 0, 0, "phalcon/mvc/model/query.zep", 2137); for ( ; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS ; zephir_hash_move_forward_ex(_11, &_10) ) { ZEPHIR_GET_HVALUE(field, _12); ZEPHIR_OBS_NVAR(name); - zephir_array_fetch_string(&name, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1976 TSRMLS_CC); + zephir_array_fetch_string(&name, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2126 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_0, metaData, "hasattribute", &_13, 0, model, name); zephir_check_call_status(); if (!(zephir_is_true(_0))) { @@ -94108,11 +94766,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { ZEPHIR_CONCAT_SVSVSV(_15, "The model '", modelName, "' doesn't have the attribute '", name, "', when preparing: ", _14); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_16, 9, _15); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 1980 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 2130 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&sqlFields, name, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1984); + zephir_array_append(&sqlFields, name, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2134); } zephir_array_update_string(&sqlInsert, SL("fields"), &sqlFields, PH_COPY | PH_SEPARATE); } @@ -94137,17 +94795,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { zephir_read_property_this(&ast, this_ptr, SL("_ast"), PH_NOISY_CC); ZEPHIR_OBS_VAR(update); if (!(zephir_array_isset_string_fetch(&update, ast, SS("update"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2011); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2161); return; } ZEPHIR_OBS_VAR(tables); if (!(zephir_array_isset_string_fetch(&tables, update, SS("tables"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2015); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2165); return; } ZEPHIR_OBS_VAR(values); if (!(zephir_array_isset_string_fetch(&values, update, SS("values"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2019); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2169); return; } ZEPHIR_INIT_VAR(models); @@ -94171,23 +94829,23 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); - zephir_is_iterable(updateTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2094); + zephir_is_iterable(updateTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2244); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(table, _2); ZEPHIR_OBS_NVAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2042 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2192 TSRMLS_CC); ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2043 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2048)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2193 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2198)) { ZEPHIR_INIT_NVAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2050 TSRMLS_CC); + zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2200 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, manager, "getnamespacealias", &_5, 0, _4); zephir_check_call_status(); - zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2050 TSRMLS_CC); + zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2200 TSRMLS_CC); ZEPHIR_INIT_NVAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _3, "\\", _6); } else { @@ -94214,17 +94872,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { ZEPHIR_OBS_NVAR(alias); if (zephir_array_isset_string_fetch(&alias, table, SS("alias"), 0 TSRMLS_CC)) { zephir_array_update_zval(&sqlAliases, alias, &alias, PH_COPY | PH_SEPARATE); - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2076); - zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2077); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2226); + zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2227); zephir_array_update_zval(&sqlAliasesModelsInstances, alias, &model, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&models, alias, &realModelName, PH_COPY | PH_SEPARATE); } else { zephir_array_update_zval(&sqlAliases, realModelName, &source, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2083); + zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2233); zephir_array_update_zval(&models, realModelName, &source, PH_COPY | PH_SEPARATE); } - zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2087); + zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2237); zephir_array_update_zval(&modelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); } zephir_update_property_this(this_ptr, SL("_models"), models TSRMLS_CC); @@ -94243,27 +94901,27 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { ZEPHIR_CPY_WRT(updateValues, values); } notQuoting = 0; - zephir_is_iterable(updateValues, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 2119); + zephir_is_iterable(updateValues, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 2268); for ( ; zephir_hash_get_current_data_ex(_10, (void**) &_11, &_9) == SUCCESS ; zephir_hash_move_forward_ex(_10, &_9) ) { ZEPHIR_GET_HVALUE(updateValue, _11); - zephir_array_fetch_string(&_4, updateValue, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2110 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 323, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_4, updateValue, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2260 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 316, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - zephir_array_append(&sqlFields, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2110); + zephir_array_append(&sqlFields, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2260); ZEPHIR_OBS_NVAR(exprColumn); - zephir_array_fetch_string(&exprColumn, updateValue, SL("expr"), PH_NOISY, "phalcon/mvc/model/query.zep", 2111 TSRMLS_CC); + zephir_array_fetch_string(&exprColumn, updateValue, SL("expr"), PH_NOISY, "phalcon/mvc/model/query.zep", 2261 TSRMLS_CC); ZEPHIR_INIT_NVAR(_13); zephir_create_array(_13, 2, 0 TSRMLS_CC); ZEPHIR_OBS_NVAR(_14); - zephir_array_fetch_string(&_14, exprColumn, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2113 TSRMLS_CC); + zephir_array_fetch_string(&_14, exprColumn, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2263 TSRMLS_CC); zephir_array_update_string(&_13, SL("type"), &_14, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 316, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_array_update_string(&_13, SL("value"), &_15, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlValues, _13, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2115); + zephir_array_append(&sqlValues, _13, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2265); } ZEPHIR_INIT_VAR(sqlUpdate); zephir_create_array(sqlUpdate, 4, 0 TSRMLS_CC); @@ -94275,13 +94933,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) { ZEPHIR_SINIT_VAR(_16); ZVAL_BOOL(&_16, 1); - ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, where, &_16); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 316, where, &_16); zephir_check_call_status(); zephir_array_update_string(&sqlUpdate, SL("where"), &_15, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(limit); if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 337, limit); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 330, limit); zephir_check_call_status(); zephir_array_update_string(&sqlUpdate, SL("limit"), &_15, PH_COPY | PH_SEPARATE); } @@ -94303,12 +94961,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { zephir_read_property_this(&ast, this_ptr, SL("_ast"), PH_NOISY_CC); ZEPHIR_OBS_VAR(delete); if (!(zephir_array_isset_string_fetch(&delete, ast, SS("delete"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2151); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2300); return; } ZEPHIR_OBS_VAR(tables); if (!(zephir_array_isset_string_fetch(&tables, delete, SS("tables"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2155); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2304); return; } ZEPHIR_INIT_VAR(models); @@ -94332,23 +94990,23 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); - zephir_is_iterable(deleteTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2226); + zephir_is_iterable(deleteTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2374); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(table, _2); ZEPHIR_OBS_NVAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2177 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2328 TSRMLS_CC); ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2178 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2186)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2329 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2334)) { ZEPHIR_INIT_NVAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2188 TSRMLS_CC); + zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2336 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, manager, "getnamespacealias", &_5, 0, _4); zephir_check_call_status(); - zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2188 TSRMLS_CC); + zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2336 TSRMLS_CC); ZEPHIR_INIT_NVAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _3, "\\", _6); } else { @@ -94375,17 +95033,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { ZEPHIR_OBS_NVAR(alias); if (zephir_array_isset_string_fetch(&alias, table, SS("alias"), 0 TSRMLS_CC)) { zephir_array_update_zval(&sqlAliases, alias, &alias, PH_COPY | PH_SEPARATE); - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2208); - zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2209); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2356); + zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2357); zephir_array_update_zval(&sqlAliasesModelsInstances, alias, &model, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&models, alias, &realModelName, PH_COPY | PH_SEPARATE); } else { zephir_array_update_zval(&sqlAliases, realModelName, &source, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2215); + zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2363); zephir_array_update_zval(&models, realModelName, &source, PH_COPY | PH_SEPARATE); } - zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2219); + zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2367); zephir_array_update_zval(&modelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); } zephir_update_property_this(this_ptr, SL("_models"), models TSRMLS_CC); @@ -94400,13 +95058,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) { ZEPHIR_SINIT_VAR(_9); ZVAL_BOOL(&_9, 1); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 323, where, &_9); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 316, where, &_9); zephir_check_call_status(); zephir_array_update_string(&sqlDelete, SL("where"), &_3, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(limit); if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 337, limit); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 330, limit); zephir_check_call_status(); zephir_array_update_string(&sqlDelete, SL("limit"), &_10, PH_COPY | PH_SEPARATE); } @@ -94442,7 +95100,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { _0 = zephir_fetch_static_property_ce(phalcon_mvc_model_query_ce, SL("_irPhqlCache") TSRMLS_CC); if (zephir_array_isset_fetch(&irPhql, _0, uniqueId, 0 TSRMLS_CC)) { if (Z_TYPE_P(irPhql) == IS_ARRAY) { - zephir_array_fetch_string(&_1, ast, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2277 TSRMLS_CC); + zephir_array_fetch_string(&_1, ast, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2425 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); RETURN_CCTOR(irPhql); } @@ -94454,22 +95112,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { zephir_update_property_this(this_ptr, SL("_type"), type TSRMLS_CC); do { if (ZEPHIR_IS_LONG(type, 309)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 328); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 321); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 306)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 338); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 331); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 300)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 339); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 332); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 303)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 340); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 333); zephir_check_call_status(); break; } @@ -94479,7 +95137,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { ZEPHIR_CONCAT_SVSV(_3, "Unknown statement ", type, ", when preparing: ", phql); ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/mvc/model/query.zep", 2310 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/mvc/model/query.zep", 2458 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -94487,7 +95145,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { } } if (Z_TYPE_P(irPhql) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted AST", "phalcon/mvc/model/query.zep", 2316); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted AST", "phalcon/mvc/model/query.zep", 2464); return; } if (Z_TYPE_P(uniqueId) == IS_LONG) { @@ -94531,8 +95189,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_INIT_VAR(connectionTypes); array_init(connectionTypes); ZEPHIR_OBS_VAR(models); - zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2359 TSRMLS_CC); - zephir_is_iterable(models, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2387); + zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2507 TSRMLS_CC); + zephir_is_iterable(models, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2535); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -94551,7 +95209,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_CALL_METHOD(&connection, model, "selectreadconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectReadConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2374); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectReadConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2522); return; } } else { @@ -94562,28 +95220,28 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_check_call_status(); zephir_array_update_zval(&connectionTypes, _6, &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE); if (zephir_fast_count_int(connectionTypes TSRMLS_CC) == 2) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot use models of different database systems in the same query", "phalcon/mvc/model/query.zep", 2383); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot use models of different database systems in the same query", "phalcon/mvc/model/query.zep", 2531); return; } } ZEPHIR_OBS_VAR(columns); - zephir_array_fetch_string(&columns, intermediate, SL("columns"), PH_NOISY, "phalcon/mvc/model/query.zep", 2387 TSRMLS_CC); + zephir_array_fetch_string(&columns, intermediate, SL("columns"), PH_NOISY, "phalcon/mvc/model/query.zep", 2535 TSRMLS_CC); haveObjects = 0; haveScalars = 0; isComplex = 0; numberObjects = 0; ZEPHIR_CPY_WRT(columns1, columns); - zephir_is_iterable(columns, &_8, &_7, 0, 0, "phalcon/mvc/model/query.zep", 2414); + zephir_is_iterable(columns, &_8, &_7, 0, 0, "phalcon/mvc/model/query.zep", 2562); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) ) { ZEPHIR_GET_HVALUE(column, _9); if (Z_TYPE_P(column) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid column definition", "phalcon/mvc/model/query.zep", 2400); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid column definition", "phalcon/mvc/model/query.zep", 2548); return; } - zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2403 TSRMLS_CC); + zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2551 TSRMLS_CC); if (ZEPHIR_IS_STRING(_10, "scalar")) { if (!(zephir_array_isset_string(column, SS("balias")))) { isComplex = 1; @@ -94617,7 +95275,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { array_init(simpleColumnMap); ZEPHIR_OBS_VAR(metaData); zephir_read_property_this(&metaData, this_ptr, SL("_metaData"), PH_NOISY_CC); - zephir_is_iterable(columns, &_12, &_11, 0, 0, "phalcon/mvc/model/query.zep", 2513); + zephir_is_iterable(columns, &_12, &_11, 0, 0, "phalcon/mvc/model/query.zep", 2661); for ( ; zephir_hash_get_current_data_ex(_12, (void**) &_13, &_11) == SUCCESS ; zephir_hash_move_forward_ex(_12, &_11) @@ -94625,11 +95283,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_GET_HMKEY(aliasCopy, _12, _11); ZEPHIR_GET_HVALUE(column, _13); ZEPHIR_OBS_NVAR(sqlColumn); - zephir_array_fetch_string(&sqlColumn, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 2438 TSRMLS_CC); - zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2441 TSRMLS_CC); + zephir_array_fetch_string(&sqlColumn, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 2586 TSRMLS_CC); + zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2589 TSRMLS_CC); if (ZEPHIR_IS_STRING(_10, "object")) { ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, column, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2443 TSRMLS_CC); + zephir_array_fetch_string(&modelName, column, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2591 TSRMLS_CC); ZEPHIR_OBS_NVAR(instance); _3 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&instance, _3, modelName, 0 TSRMLS_CC))) { @@ -94647,7 +95305,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_INIT_NVAR(columnMap); ZVAL_NULL(columnMap); } - zephir_is_iterable(attributes, &_18, &_17, 0, 0, "phalcon/mvc/model/query.zep", 2469); + zephir_is_iterable(attributes, &_18, &_17, 0, 0, "phalcon/mvc/model/query.zep", 2617); for ( ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS ; zephir_hash_move_forward_ex(_18, &_17) @@ -94660,7 +95318,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_INIT_LNVAR(_21); ZEPHIR_CONCAT_SVSV(_21, "_", sqlColumn, "_", attribute); zephir_array_fast_append(_20, _21); - zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2465); + zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2613); } zephir_array_update_multi(&columns1, &instance TSRMLS_CC, SL("zs"), 3, aliasCopy, SL("instance")); zephir_array_update_multi(&columns1, &attributes TSRMLS_CC, SL("zs"), 3, aliasCopy, SL("attributes")); @@ -94674,7 +95332,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_array_update_multi(&columns1, &_4 TSRMLS_CC, SL("zs"), 3, aliasCopy, SL("keepSnapshots")); } } else { - zephir_is_iterable(attributes, &_24, &_23, 0, 0, "phalcon/mvc/model/query.zep", 2487); + zephir_is_iterable(attributes, &_24, &_23, 0, 0, "phalcon/mvc/model/query.zep", 2635); for ( ; zephir_hash_get_current_data_ex(_24, (void**) &_25, &_23) == SUCCESS ; zephir_hash_move_forward_ex(_24, &_23) @@ -94684,7 +95342,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_create_array(_20, 2, 0 TSRMLS_CC); zephir_array_fast_append(_20, attribute); zephir_array_fast_append(_20, sqlColumn); - zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2485); + zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2633); } } } else { @@ -94699,7 +95357,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_array_fast_append(columnAlias, ZEPHIR_GLOBAL(global_null)); zephir_array_fast_append(columnAlias, aliasCopy); } - zephir_array_append(&selectColumns, columnAlias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2498); + zephir_array_append(&selectColumns, columnAlias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2646); } _26 = isComplex == 0; if (_26) { @@ -94720,7 +95378,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { if (Z_TYPE_P(bindParams) == IS_ARRAY) { ZEPHIR_INIT_VAR(processed); array_init(processed); - zephir_is_iterable(bindParams, &_28, &_27, 0, 0, "phalcon/mvc/model/query.zep", 2534); + zephir_is_iterable(bindParams, &_28, &_27, 0, 0, "phalcon/mvc/model/query.zep", 2682); for ( ; zephir_hash_get_current_data_ex(_28, (void**) &_29, &_27) == SUCCESS ; zephir_hash_move_forward_ex(_28, &_27) @@ -94746,7 +95404,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { if (Z_TYPE_P(bindTypes) == IS_ARRAY) { ZEPHIR_INIT_VAR(processedTypes); array_init(processedTypes); - zephir_is_iterable(bindTypes, &_31, &_30, 0, 0, "phalcon/mvc/model/query.zep", 2550); + zephir_is_iterable(bindTypes, &_31, &_30, 0, 0, "phalcon/mvc/model/query.zep", 2698); for ( ; zephir_hash_get_current_data_ex(_31, (void**) &_32, &_30) == SUCCESS ; zephir_hash_move_forward_ex(_31, &_30) @@ -94818,7 +95476,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { array_init(simpleColumnMap); ZEPHIR_CALL_METHOD(&_6, metaData, "getattributes", NULL, 0, model); zephir_check_call_status(); - zephir_is_iterable(_6, &_34, &_33, 0, 0, "phalcon/mvc/model/query.zep", 2633); + zephir_is_iterable(_6, &_34, &_33, 0, 0, "phalcon/mvc/model/query.zep", 2781); for ( ; zephir_hash_get_current_data_ex(_34, (void**) &_35, &_33) == SUCCESS ; zephir_hash_move_forward_ex(_34, &_33) @@ -94828,13 +95486,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_create_array(_20, 2, 0 TSRMLS_CC); zephir_array_fast_append(_20, attribute); ZEPHIR_OBS_NVAR(_36); - zephir_array_fetch(&_36, typesColumnMap, attribute, PH_NOISY, "phalcon/mvc/model/query.zep", 2631 TSRMLS_CC); + zephir_array_fetch(&_36, typesColumnMap, attribute, PH_NOISY, "phalcon/mvc/model/query.zep", 2779 TSRMLS_CC); zephir_array_fast_append(_20, _36); zephir_array_update_zval(&simpleColumnMap, attribute, &_20, PH_COPY | PH_SEPARATE); } } else { array_init(simpleColumnMap); - zephir_is_iterable(columnMap, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 2638); + zephir_is_iterable(columnMap, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 2786); for ( ; zephir_hash_get_current_data_ex(_38, (void**) &_39, &_37) == SUCCESS ; zephir_hash_move_forward_ex(_38, &_37) @@ -94845,7 +95503,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_create_array(_20, 2, 0 TSRMLS_CC); zephir_array_fast_append(_20, attribute); ZEPHIR_OBS_NVAR(_36); - zephir_array_fetch(&_36, typesColumnMap, column, PH_NOISY, "phalcon/mvc/model/query.zep", 2636 TSRMLS_CC); + zephir_array_fetch(&_36, typesColumnMap, column, PH_NOISY, "phalcon/mvc/model/query.zep", 2784 TSRMLS_CC); zephir_array_fast_append(_20, _36); zephir_array_update_zval(&simpleColumnMap, column, &_20, PH_COPY | PH_SEPARATE); } @@ -94856,12 +95514,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { isKeepingSnapshots = zephir_get_boolval(_40); } object_init_ex(return_value, phalcon_mvc_model_resultset_simple_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 341, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 334, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); } object_init_ex(return_value, phalcon_mvc_model_resultset_complex_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 342, columns1, resultData, cache); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 335, columns1, resultData, cache); zephir_check_call_status(); RETURN_MM(); @@ -94882,7 +95540,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_string(&modelName, intermediate, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2675 TSRMLS_CC); + zephir_array_fetch_string(&modelName, intermediate, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2823 TSRMLS_CC); ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); ZEPHIR_OBS_VAR(model); @@ -94897,7 +95555,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2688); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2836); return; } } else { @@ -94922,16 +95580,16 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { } } ZEPHIR_OBS_VAR(values); - zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2711 TSRMLS_CC); + zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2859 TSRMLS_CC); if (zephir_fast_count_int(fields TSRMLS_CC) != zephir_fast_count_int(values TSRMLS_CC)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The column count does not match the values count", "phalcon/mvc/model/query.zep", 2717); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The column count does not match the values count", "phalcon/mvc/model/query.zep", 2865); return; } ZEPHIR_CALL_METHOD(&dialect, connection, "getdialect", NULL, 0); zephir_check_call_status(); ZEPHIR_INIT_VAR(insertValues); array_init(insertValues); - zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 2785); + zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 2933); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -94939,8 +95597,8 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_GET_HMKEY(number, _3, _2); ZEPHIR_GET_HVALUE(value, _4); ZEPHIR_OBS_NVAR(exprValue); - zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 2728 TSRMLS_CC); - zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2729 TSRMLS_CC); + zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 2876 TSRMLS_CC); + zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2877 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_5, 260) || ZEPHIR_IS_LONG(_5, 258) || ZEPHIR_IS_LONG(_5, 259)) { ZEPHIR_CALL_METHOD(&insertValue, dialect, "getsqlexpression", &_6, 0, exprValue); @@ -94954,7 +95612,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { } if (ZEPHIR_IS_LONG(_5, 273) || ZEPHIR_IS_LONG(_5, 274) || ZEPHIR_IS_LONG(_5, 277)) { if (Z_TYPE_P(bindParams) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 2746); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 2894); return; } ZEPHIR_CALL_METHOD(&_7, dialect, "getsqlexpression", &_8, 0, exprValue); @@ -94973,7 +95631,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_CONCAT_SVS(_11, "Bound parameter '", wildcard, "' cannot be replaced because it isn't in the placeholders list"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_12, 9, _11); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2751 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2899 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -94989,7 +95647,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { } while(0); ZEPHIR_OBS_NVAR(fieldName); - zephir_array_fetch(&fieldName, fields, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2761 TSRMLS_CC); + zephir_array_fetch(&fieldName, fields, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2909 TSRMLS_CC); if (automaticFields == 1) { if (Z_TYPE_P(columnMap) == IS_ARRAY) { ZEPHIR_OBS_NVAR(attributeName); @@ -95000,7 +95658,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_CONCAT_SVS(_11, "Column '", fieldName, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_12, 9, _11); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2769 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2917 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -95021,7 +95679,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_CALL_METHOD(&_15, insertModel, "create", NULL, 0, insertValues); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 343, _15, insertModel); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 336, _15, insertModel); zephir_check_call_status(); RETURN_MM(); @@ -95042,13 +95700,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_OBS_VAR(models); - zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2809 TSRMLS_CC); + zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2957 TSRMLS_CC); if (zephir_array_isset_long(models, 1)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Updating several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 2812); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Updating several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 2960); return; } ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 2815 TSRMLS_CC); + zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 2963 TSRMLS_CC); ZEPHIR_OBS_VAR(model); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&model, _0, modelName, 0 TSRMLS_CC))) { @@ -95060,7 +95718,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2827); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2975); return; } } else { @@ -95070,14 +95728,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CALL_METHOD(&dialect, connection, "getdialect", NULL, 0); zephir_check_call_status(); ZEPHIR_OBS_VAR(fields); - zephir_array_fetch_string(&fields, intermediate, SL("fields"), PH_NOISY, "phalcon/mvc/model/query.zep", 2835 TSRMLS_CC); + zephir_array_fetch_string(&fields, intermediate, SL("fields"), PH_NOISY, "phalcon/mvc/model/query.zep", 2983 TSRMLS_CC); ZEPHIR_OBS_VAR(values); - zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2836 TSRMLS_CC); + zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2984 TSRMLS_CC); ZEPHIR_INIT_VAR(updateValues); array_init(updateValues); ZEPHIR_CPY_WRT(selectBindParams, bindParams); ZEPHIR_CPY_WRT(selectBindTypes, bindTypes); - zephir_is_iterable(fields, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 2903); + zephir_is_iterable(fields, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 3051); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -95085,17 +95743,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_GET_HMKEY(number, _3, _2); ZEPHIR_GET_HVALUE(field, _4); ZEPHIR_OBS_NVAR(value); - zephir_array_fetch(&value, values, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2851 TSRMLS_CC); + zephir_array_fetch(&value, values, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2999 TSRMLS_CC); ZEPHIR_OBS_NVAR(exprValue); - zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 2852 TSRMLS_CC); + zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 3000 TSRMLS_CC); if (zephir_array_isset_string(field, SS("balias"))) { ZEPHIR_OBS_NVAR(fieldName); - zephir_array_fetch_string(&fieldName, field, SL("balias"), PH_NOISY, "phalcon/mvc/model/query.zep", 2855 TSRMLS_CC); + zephir_array_fetch_string(&fieldName, field, SL("balias"), PH_NOISY, "phalcon/mvc/model/query.zep", 3003 TSRMLS_CC); } else { ZEPHIR_OBS_NVAR(fieldName); - zephir_array_fetch_string(&fieldName, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2857 TSRMLS_CC); + zephir_array_fetch_string(&fieldName, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 3005 TSRMLS_CC); } - zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2860 TSRMLS_CC); + zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 3008 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_5, 260) || ZEPHIR_IS_LONG(_5, 258) || ZEPHIR_IS_LONG(_5, 259)) { ZEPHIR_CALL_METHOD(&updateValue, dialect, "getsqlexpression", &_6, 0, exprValue); @@ -95109,7 +95767,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { } if (ZEPHIR_IS_LONG(_5, 273) || ZEPHIR_IS_LONG(_5, 274) || ZEPHIR_IS_LONG(_5, 277)) { if (Z_TYPE_P(bindParams) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 2877); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 3025); return; } ZEPHIR_CALL_METHOD(&_7, dialect, "getsqlexpression", &_8, 0, exprValue); @@ -95131,14 +95789,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CONCAT_SVS(_12, "Bound parameter '", wildcard, "' cannot be replaced because it's not in the placeholders list"); ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_13, 9, _12); zephir_check_call_status(); - zephir_throw_exception_debug(_11, "phalcon/mvc/model/query.zep", 2885 TSRMLS_CC); + zephir_throw_exception_debug(_11, "phalcon/mvc/model/query.zep", 3033 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } break; } if (ZEPHIR_IS_LONG(_5, 277)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/query.zep", 2890); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/query.zep", 3038); return; } ZEPHIR_INIT_NVAR(updateValue); @@ -95152,13 +95810,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { zephir_array_update_zval(&updateValues, fieldName, &updateValue, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, selectBindParams, selectBindTypes); + ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 337, model, intermediate, selectBindParams, selectBindTypes); zephir_check_call_status(); if (!(zephir_fast_count_int(records TSRMLS_CC))) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_11); ZVAL_BOOL(_11, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 336, _11); zephir_check_call_status(); RETURN_MM(); } @@ -95166,7 +95824,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2915); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 3063); return; } } else { @@ -95191,7 +95849,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_11); ZVAL_BOOL(_11, 0); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11, record); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 336, _11, record); zephir_check_call_status(); RETURN_MM(); } @@ -95202,7 +95860,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_11); ZVAL_BOOL(_11, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 336, _11); zephir_check_call_status(); RETURN_MM(); @@ -95221,13 +95879,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { ZEPHIR_OBS_VAR(models); - zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2962 TSRMLS_CC); + zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 3110 TSRMLS_CC); if (zephir_array_isset_long(models, 1)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Delete from several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 2965); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Delete from several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 3113); return; } ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 2968 TSRMLS_CC); + zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 3116 TSRMLS_CC); ZEPHIR_OBS_VAR(model); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&model, _0, modelName, 0 TSRMLS_CC))) { @@ -95235,13 +95893,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { ZEPHIR_CALL_METHOD(&model, _1, "load", NULL, 0, modelName); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, bindParams, bindTypes); + ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 337, model, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (!(zephir_fast_count_int(records TSRMLS_CC))) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_VAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 336, _2); zephir_check_call_status(); RETURN_MM(); } @@ -95249,7 +95907,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2992); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 3140); return; } } else { @@ -95274,7 +95932,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_2); ZVAL_BOOL(_2, 0); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2, record); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 336, _2, record); zephir_check_call_status(); RETURN_MM(); } @@ -95285,7 +95943,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 336, _2); zephir_check_call_status(); RETURN_MM(); @@ -95318,10 +95976,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getRelatedRecords) { zephir_array_fast_append(_0, _1); zephir_array_update_string(&selectIr, SL("columns"), &_0, PH_COPY | PH_SEPARATE); ZEPHIR_OBS_VAR(_4); - zephir_array_fetch_string(&_4, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 3053 TSRMLS_CC); + zephir_array_fetch_string(&_4, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 3201 TSRMLS_CC); zephir_array_update_string(&selectIr, SL("models"), &_4, PH_COPY | PH_SEPARATE); ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, intermediate, SL("tables"), PH_NOISY, "phalcon/mvc/model/query.zep", 3055 TSRMLS_CC); + zephir_array_fetch_string(&_4, intermediate, SL("tables"), PH_NOISY, "phalcon/mvc/model/query.zep", 3203 TSRMLS_CC); zephir_array_update_string(&selectIr, SL("tables"), &_4, PH_COPY | PH_SEPARATE); ZEPHIR_OBS_VAR(whereConditions); if (zephir_array_isset_string_fetch(&whereConditions, intermediate, SS("where"), 0 TSRMLS_CC)) { @@ -95333,18 +95991,18 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getRelatedRecords) { } ZEPHIR_INIT_VAR(query); object_init_ex(query, phalcon_mvc_model_query_ce); - ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345); + ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 338); zephir_check_call_status(); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 346, _5); + ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 339, _5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_2); ZVAL_LONG(_2, 309); - ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 347, _2); + ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 340, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 348, selectIr); + ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 341, selectIr); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 349, bindParams, bindTypes); + ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 342, bindParams, bindTypes); zephir_check_call_status(); RETURN_MM(); @@ -95373,12 +96031,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { zephir_read_property_this(&cacheOptions, this_ptr, SL("_cacheOptions"), PH_NOISY_CC); if (Z_TYPE_P(cacheOptions) != IS_NULL) { if (Z_TYPE_P(cacheOptions) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid caching options", "phalcon/mvc/model/query.zep", 3101); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid caching options", "phalcon/mvc/model/query.zep", 3249); return; } ZEPHIR_OBS_VAR(key); if (!(zephir_array_isset_string_fetch(&key, cacheOptions, SS("key"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A cache key must be provided to identify the cached resultset in the cache backend", "phalcon/mvc/model/query.zep", 3108); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A cache key must be provided to identify the cached resultset in the cache backend", "phalcon/mvc/model/query.zep", 3256); return; } ZEPHIR_OBS_VAR(lifetime); @@ -95395,14 +96053,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { ZEPHIR_CALL_METHOD(&cache, _0, "getshared", NULL, 0, cacheService); zephir_check_call_status(); if (Z_TYPE_P(cache) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache service must be an object", "phalcon/mvc/model/query.zep", 3127); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache service must be an object", "phalcon/mvc/model/query.zep", 3275); return; } ZEPHIR_CALL_METHOD(&result, cache, "get", NULL, 0, key, lifetime); zephir_check_call_status(); if (Z_TYPE_P(result) != IS_NULL) { if (Z_TYPE_P(result) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache didn't return a valid resultset", "phalcon/mvc/model/query.zep", 3134); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache didn't return a valid resultset", "phalcon/mvc/model/query.zep", 3282); return; } ZEPHIR_INIT_VAR(_1); @@ -95450,7 +96108,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { _2 = Z_TYPE_P(mergedParams) != IS_ARRAY; } if (_2) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameters must be an array", "phalcon/mvc/model/query.zep", 3188); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameters must be an array", "phalcon/mvc/model/query.zep", 3336); return; } _3 = Z_TYPE_P(mergedTypes) != IS_NULL; @@ -95458,29 +96116,29 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { _3 = Z_TYPE_P(mergedTypes) != IS_ARRAY; } if (_3) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter types must be an array", "phalcon/mvc/model/query.zep", 3192); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter types must be an array", "phalcon/mvc/model/query.zep", 3340); return; } ZEPHIR_OBS_VAR(type); zephir_read_property_this(&type, this_ptr, SL("_type"), PH_NOISY_CC); do { if (ZEPHIR_IS_LONG(type, 309)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 350, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 343, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 306)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 351, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 344, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 300)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 352, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 345, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 303)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 353, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 346, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } @@ -95490,14 +96148,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { ZEPHIR_CONCAT_SV(_4, "Unknown statement ", type); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 3215 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 3363 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); if (Z_TYPE_P(cacheOptions) != IS_NULL) { if (!ZEPHIR_IS_LONG(type, 309)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only PHQL statements that return resultsets can be cached", "phalcon/mvc/model/query.zep", 3227); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only PHQL statements that return resultsets can be cached", "phalcon/mvc/model/query.zep", 3375); return; } ZEPHIR_CALL_METHOD(NULL, cache, "save", NULL, 0, key, result, lifetime); @@ -95535,7 +96193,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, getSingleResult) { zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 349, bindParams, bindTypes); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 342, bindParams, bindTypes); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(_1, "getfirst", NULL, 0); zephir_check_call_status(); @@ -95707,11 +96365,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, getSql) { _2 = zephir_fetch_nproperty_this(this_ptr, SL("_bindTypes"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_3); ZVAL_BOOL(&_3, 1); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 350, intermediate, _1, _2, &_3); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 343, intermediate, _1, _2, &_3); zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "This type of statement generates multiple SQL statements", "phalcon/mvc/model/query.zep", 3397); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "This type of statement generates multiple SQL statements", "phalcon/mvc/model/query.zep", 3545); return; } @@ -95899,6 +96557,35 @@ static PHP_METHOD(Phalcon_Mvc_Model_Relation, getOptions) { } +static PHP_METHOD(Phalcon_Mvc_Model_Relation, getOption) { + + zval *name_param = NULL, *option, *_0; + zval *name = NULL; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &name_param); + + if (unlikely(Z_TYPE_P(name_param) != IS_STRING && Z_TYPE_P(name_param) != IS_NULL)) { + zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'name' must be a string") TSRMLS_CC); + RETURN_MM_NULL(); + } + + if (likely(Z_TYPE_P(name_param) == IS_STRING)) { + zephir_get_strval(name, name_param); + } else { + ZEPHIR_INIT_VAR(name); + ZVAL_EMPTY_STRING(name); + } + + + _0 = zephir_fetch_nproperty_this(this_ptr, SL("_options"), PH_NOISY_CC); + if (zephir_array_isset_fetch(&option, _0, name, 1 TSRMLS_CC)) { + RETURN_CTOR(option); + } + RETURN_MM_NULL(); + +} + static PHP_METHOD(Phalcon_Mvc_Model_Relation, isForeignKey) { zval *options; @@ -96191,7 +96878,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, next) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_pointer"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, (zephir_get_numberval(_0) + 1)); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_1); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -96231,7 +96918,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, rewind) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 0); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_0); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_0); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -96358,7 +97045,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, offsetGet) { if (ZEPHIR_GT_LONG(_0, index)) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, index); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_1); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_1); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "current", NULL, 0); zephir_check_call_status(); @@ -96428,7 +97115,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, getFirst) { } ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_1); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_1); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "current", NULL, 0); zephir_check_call_status(); @@ -96450,7 +97137,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, getLast) { } ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, (zephir_get_numberval(count) - 1)); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_0); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_0); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "current", NULL, 0); zephir_check_call_status(); @@ -96880,7 +97567,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Row, toArray) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 23, this_ptr); + ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM(); @@ -97068,7 +97755,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction, rollback) { ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_mvc_model_transaction_failed_ce); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackRecord"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 360, rollbackMessage, _5); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 353, rollbackMessage, _5); zephir_check_call_status(); zephir_throw_exception_debug(_0, "phalcon/mvc/model/transaction.zep", 160 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -97087,7 +97774,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction, getConnection) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackOnAbort"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 361); + ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 354); zephir_check_call_status(); if (zephir_is_true(_1)) { ZEPHIR_INIT_VAR(_2); @@ -97657,7 +98344,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Behavior_Timestampable, notify) { ZVAL_NULL(timestamp); ZEPHIR_OBS_VAR(format); if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format); + ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 293, format); zephir_check_call_status(); } else { ZEPHIR_OBS_VAR(generator); @@ -97773,7 +98460,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Apc, read) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_prefix"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); - ZEPHIR_CALL_FUNCTION(&data, "apc_fetch", NULL, 79, _1); + ZEPHIR_CALL_FUNCTION(&data, "apc_fetch", NULL, 81, _1); zephir_check_call_status(); if (Z_TYPE_P(data) == IS_ARRAY) { RETURN_CCTOR(data); @@ -97808,7 +98495,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Apc, write) { ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); _2 = zephir_fetch_nproperty_this(this_ptr, SL("_ttl"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "apc_store", NULL, 80, _1, data, _2); + ZEPHIR_CALL_FUNCTION(NULL, "apc_store", NULL, 82, _1, data, _2); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -98013,9 +98700,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 312, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -98114,7 +98801,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, reset) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 320); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 313); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -98199,9 +98886,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 314, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -98300,7 +98987,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, reset) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 320); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 313); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -98477,9 +99164,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 315, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -98578,7 +99265,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, reset) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_redis_ce, this_ptr, "reset", &_5, 320); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_redis_ce, this_ptr, "reset", &_5, 313); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -98794,7 +99481,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Xcache, read) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_prefix"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); - ZEPHIR_CALL_FUNCTION(&data, "xcache_get", NULL, 81, _1); + ZEPHIR_CALL_FUNCTION(&data, "xcache_get", NULL, 83, _1); zephir_check_call_status(); if (Z_TYPE_P(data) == IS_ARRAY) { RETURN_CCTOR(data); @@ -98829,7 +99516,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Xcache, write) { ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); _2 = zephir_fetch_nproperty_this(this_ptr, SL("_ttl"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, _1, data, _2); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, _1, data, _2); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -99697,14 +100384,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, from) { static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, addFrom) { - zval *model, *alias = NULL, *models = NULL, *currentModel = NULL; + zval *model, *alias = NULL, *with = NULL, *models = NULL, *currentModel = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 1, &model, &alias); + zephir_fetch_params(1, 1, 2, &model, &alias, &with); if (!alias) { alias = ZEPHIR_GLOBAL(global_null); } + if (!with) { + with = ZEPHIR_GLOBAL(global_null); + } ZEPHIR_OBS_VAR(models); @@ -99723,7 +100413,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, addFrom) { if (Z_TYPE_P(alias) == IS_STRING) { zephir_array_update_zval(&models, alias, &model, PH_COPY | PH_SEPARATE); } else { - zephir_array_append(&models, model, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 388); + zephir_array_append(&models, model, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 395); } zephir_update_property_this(this_ptr, SL("_models"), models TSRMLS_CC); RETURN_THIS(); @@ -100194,7 +100884,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, inWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 757); + zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 776); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -100207,7 +100897,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, inWhere) { ZEPHIR_CPY_WRT(key, _0); ZEPHIR_INIT_NVAR(queryKey); ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":"); - zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 748); + zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 767); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); hiddenParam++; } @@ -100266,7 +100956,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, notInWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 800); + zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 819); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -100279,7 +100969,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, notInWhere) { ZEPHIR_CPY_WRT(key, _0); ZEPHIR_INIT_NVAR(queryKey); ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":"); - zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 791); + zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 810); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); hiddenParam++; } @@ -100455,13 +101145,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getGroupBy) { static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { - HashTable *_7, *_10, *_14, *_18, *_21, *_26, *_32; - HashPosition _6, _9, _13, _17, _20, _25, _31; + HashTable *_7, *_10, *_13, *_18, *_23, *_29; + HashPosition _6, _9, _12, _17, _22, _28; zend_class_entry *_3; int ZEPHIR_LAST_CALL_STATUS; - zephir_fcall_cache_entry *_0 = NULL, *_35 = NULL; + zephir_fcall_cache_entry *_0 = NULL, *_32 = NULL; zend_bool noPrimary, _5; - zval *dependencyInjector = NULL, *models, *conditions = NULL, *model = NULL, *metaData = NULL, *modelInstance, *primaryKeys = NULL, *firstPrimaryKey, *columnMap = NULL, *modelAlias = NULL, *attributeField = NULL, *phql = NULL, *column = NULL, *columns, *selectedColumns = NULL, *selectedColumn = NULL, *selectedModel = NULL, *selectedModels, *columnAlias = NULL, *modelColumnAlias = NULL, *joins, *join = NULL, *joinModel = NULL, *joinConditions = NULL, *joinAlias = NULL, *joinType = NULL, *group = NULL, *groupItems = NULL, *groupItem = NULL, *having, *order, *orderItems, *orderItem = NULL, *limit, *number = NULL, *offset = NULL, *forUpdate, *distinct, *withModels, *hiddenParam, *_1 = NULL, *_2 = NULL, *_4 = NULL, **_8, **_11, *_12 = NULL, **_15, *_16 = NULL, **_19, **_22, *_23 = NULL, *_24 = NULL, **_27, *_28 = NULL, _29 = zval_used_for_init, _30, **_33, *_34 = NULL, *_36, *_37; + zval *dependencyInjector = NULL, *models, *conditions = NULL, *model = NULL, *metaData = NULL, *modelInstance, *primaryKeys = NULL, *firstPrimaryKey, *columnMap = NULL, *modelAlias = NULL, *attributeField = NULL, *phql = NULL, *column = NULL, *columns, *selectedColumns = NULL, *selectedColumn = NULL, *selectedModel = NULL, *selectedModels, *columnAlias = NULL, *modelColumnAlias = NULL, *joins, *join = NULL, *joinModel = NULL, *joinConditions = NULL, *joinAlias = NULL, *joinType = NULL, *group = NULL, *groupItems = NULL, *groupItem = NULL, *having, *order, *orderItems, *orderItem = NULL, *limit, *number = NULL, *offset = NULL, *forUpdate, *distinct, *_1 = NULL, *_2 = NULL, *_4 = NULL, **_8, **_11, **_14, *_15 = NULL, *_16 = NULL, **_19, *_20 = NULL, *_21 = NULL, **_24, *_25 = NULL, _26 = zval_used_for_init, _27, **_30, *_31 = NULL, *_33, *_34, *_35, *_36; ZEPHIR_MM_GROW(); @@ -100476,12 +101166,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { zephir_read_property_this(&models, this_ptr, SL("_models"), PH_NOISY_CC); if (Z_TYPE_P(models) == IS_ARRAY) { if (!(zephir_fast_count_int(models TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 981); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 1000); return; } } else { if (!(zephir_is_true(models))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 985); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 1004); return; } } @@ -100490,11 +101180,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (zephir_is_numeric(conditions)) { if (Z_TYPE_P(models) == IS_ARRAY) { if (zephir_fast_count_int(models TSRMLS_CC) > 1) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot build the query. Invalid condition", "phalcon/mvc/model/query/builder.zep", 997); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot build the query. Invalid condition", "phalcon/mvc/model/query/builder.zep", 1017); return; } ZEPHIR_OBS_VAR(model); - zephir_array_fetch_long(&model, models, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 999 TSRMLS_CC); + zephir_array_fetch_long(&model, models, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1019 TSRMLS_CC); } else { ZEPHIR_CPY_WRT(model, models); } @@ -100533,7 +101223,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZEPHIR_CONCAT_SVS(_4, "Column '", firstPrimaryKey, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query/builder.zep", 1027 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query/builder.zep", 1047 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -100547,7 +101237,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { } } if (noPrimary == 1) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Source related to this model does not have a primary key defined", "phalcon/mvc/model/query/builder.zep", 1042); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Source related to this model does not have a primary key defined", "phalcon/mvc/model/query/builder.zep", 1062); return; } } @@ -100574,7 +101264,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(columns) == IS_ARRAY) { ZEPHIR_INIT_VAR(selectedColumns); array_init(selectedColumns); - zephir_is_iterable(columns, &_7, &_6, 0, 0, "phalcon/mvc/model/query/builder.zep", 1074); + zephir_is_iterable(columns, &_7, &_6, 0, 0, "phalcon/mvc/model/query/builder.zep", 1098); for ( ; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS ; zephir_hash_move_forward_ex(_7, &_6) @@ -100582,11 +101272,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZEPHIR_GET_HMKEY(columnAlias, _7, _6); ZEPHIR_GET_HVALUE(column, _8); if (Z_TYPE_P(columnAlias) == IS_LONG) { - zephir_array_append(&selectedColumns, column, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1068); + zephir_array_append(&selectedColumns, column, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1088); } else { - ZEPHIR_INIT_LNVAR(_4); - ZEPHIR_CONCAT_VSV(_4, column, " AS ", columnAlias); - zephir_array_append(&selectedColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1070); + if (zephir_memnstr_str(columnAlias, SL("["), "phalcon/mvc/model/query/builder.zep", 1090)) { + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_VSV(_4, column, " AS ", columnAlias); + zephir_array_append(&selectedColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1091); + } else { + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_VSVS(_4, column, " AS [", columnAlias, "]"); + zephir_array_append(&selectedColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1093); + } } } ZEPHIR_INIT_NVAR(_1); @@ -100599,7 +101295,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(models) == IS_ARRAY) { ZEPHIR_INIT_NVAR(selectedColumns); array_init(selectedColumns); - zephir_is_iterable(models, &_10, &_9, 0, 0, "phalcon/mvc/model/query/builder.zep", 1097); + zephir_is_iterable(models, &_10, &_9, 0, 0, "phalcon/mvc/model/query/builder.zep", 1121); for ( ; zephir_hash_get_current_data_ex(_10, (void**) &_11, &_9) == SUCCESS ; zephir_hash_move_forward_ex(_10, &_9) @@ -100612,136 +101308,115 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { } else { ZEPHIR_CONCAT_SVS(selectedColumn, "[", modelColumnAlias, "].*"); } - zephir_array_append(&selectedColumns, selectedColumn, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1094); + zephir_array_append(&selectedColumns, selectedColumn, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1118); } ZEPHIR_INIT_NVAR(_1); zephir_fast_join_str(_1, SL(", "), selectedColumns TSRMLS_CC); zephir_concat_self(&phql, _1 TSRMLS_CC); } else { - ZEPHIR_INIT_VAR(_12); - ZEPHIR_CONCAT_SVS(_12, "[", models, "].*"); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_SVS(_4, "[", models, "].*"); + zephir_concat_self(&phql, _4 TSRMLS_CC); } } if (Z_TYPE_P(models) == IS_ARRAY) { ZEPHIR_INIT_VAR(selectedModels); array_init(selectedModels); - zephir_is_iterable(models, &_14, &_13, 0, 0, "phalcon/mvc/model/query/builder.zep", 1128); + zephir_is_iterable(models, &_13, &_12, 0, 0, "phalcon/mvc/model/query/builder.zep", 1152); for ( - ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS - ; zephir_hash_move_forward_ex(_14, &_13) + ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS + ; zephir_hash_move_forward_ex(_13, &_12) ) { - ZEPHIR_GET_HMKEY(modelAlias, _14, _13); - ZEPHIR_GET_HVALUE(model, _15); + ZEPHIR_GET_HMKEY(modelAlias, _13, _12); + ZEPHIR_GET_HVALUE(model, _14); if (Z_TYPE_P(modelAlias) == IS_STRING) { ZEPHIR_INIT_NVAR(selectedModel); - if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1112)) { + if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1136)) { ZEPHIR_CONCAT_VSVS(selectedModel, model, " AS [", modelAlias, "]"); } else { ZEPHIR_CONCAT_SVSVS(selectedModel, "[", model, "] AS [", modelAlias, "]"); } } else { - if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1118)) { + if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1142)) { ZEPHIR_CPY_WRT(selectedModel, model); } else { ZEPHIR_INIT_NVAR(selectedModel); ZEPHIR_CONCAT_SVS(selectedModel, "[", model, "]"); } } - zephir_array_append(&selectedModels, selectedModel, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1125); + zephir_array_append(&selectedModels, selectedModel, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1149); } ZEPHIR_INIT_NVAR(_1); zephir_fast_join_str(_1, SL(", "), selectedModels TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " FROM ", _1); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_VAR(_15); + ZEPHIR_CONCAT_SV(_15, " FROM ", _1); + zephir_concat_self(&phql, _15 TSRMLS_CC); } else { - if (zephir_memnstr_str(models, SL("["), "phalcon/mvc/model/query/builder.zep", 1132)) { + if (zephir_memnstr_str(models, SL("["), "phalcon/mvc/model/query/builder.zep", 1156)) { + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SVS(_15, " FROM ", models, ""); + zephir_concat_self(&phql, _15 TSRMLS_CC); + } else { ZEPHIR_INIT_VAR(_16); - ZEPHIR_CONCAT_SVS(_16, " FROM ", models, ""); + ZEPHIR_CONCAT_SVS(_16, " FROM [", models, "]"); zephir_concat_self(&phql, _16 TSRMLS_CC); - } else { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SVS(_12, " FROM [", models, "]"); - zephir_concat_self(&phql, _12 TSRMLS_CC); } } - ZEPHIR_OBS_VAR(withModels); - zephir_read_property_this(&withModels, this_ptr, SL("_with"), PH_NOISY_CC); - if (Z_TYPE_P(withModels) == IS_ARRAY) { - ZEPHIR_INIT_NVAR(selectedColumns); - array_init(selectedColumns); - zephir_is_iterable(withModels, &_18, &_17, 0, 0, "phalcon/mvc/model/query/builder.zep", 1150); - for ( - ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS - ; zephir_hash_move_forward_ex(_18, &_17) - ) { - ZEPHIR_GET_HVALUE(model, _19); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SVS(_12, "[", model, "]"); - zephir_array_append(&selectedColumns, _12, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1147); - } - ZEPHIR_INIT_NVAR(_1); - zephir_fast_join_str(_1, SL(", "), selectedColumns TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " WITH ", _1); - zephir_concat_self(&phql, _12 TSRMLS_CC); - } ZEPHIR_OBS_VAR(joins); zephir_read_property_this(&joins, this_ptr, SL("_joins"), PH_NOISY_CC); if (Z_TYPE_P(joins) == IS_ARRAY) { - zephir_is_iterable(joins, &_21, &_20, 0, 0, "phalcon/mvc/model/query/builder.zep", 1212); + zephir_is_iterable(joins, &_18, &_17, 0, 0, "phalcon/mvc/model/query/builder.zep", 1222); for ( - ; zephir_hash_get_current_data_ex(_21, (void**) &_22, &_20) == SUCCESS - ; zephir_hash_move_forward_ex(_21, &_20) + ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS + ; zephir_hash_move_forward_ex(_18, &_17) ) { - ZEPHIR_GET_HVALUE(join, _22); + ZEPHIR_GET_HVALUE(join, _19); ZEPHIR_OBS_NVAR(joinModel); - zephir_array_fetch_long(&joinModel, join, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1164 TSRMLS_CC); + zephir_array_fetch_long(&joinModel, join, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1174 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinConditions); - zephir_array_fetch_long(&joinConditions, join, 1, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1169 TSRMLS_CC); + zephir_array_fetch_long(&joinConditions, join, 1, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1179 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinAlias); - zephir_array_fetch_long(&joinAlias, join, 2, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1174 TSRMLS_CC); + zephir_array_fetch_long(&joinAlias, join, 2, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1184 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinType); - zephir_array_fetch_long(&joinType, join, 3, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1179 TSRMLS_CC); + zephir_array_fetch_long(&joinType, join, 3, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1189 TSRMLS_CC); if (zephir_is_true(joinType)) { - if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1185)) { + if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1195)) { + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SVSV(_15, " ", joinType, " JOIN ", joinModel); + zephir_concat_self(&phql, _15 TSRMLS_CC); + } else { ZEPHIR_INIT_LNVAR(_16); - ZEPHIR_CONCAT_SVSV(_16, " ", joinType, " JOIN ", joinModel); + ZEPHIR_CONCAT_SVSVS(_16, " ", joinType, " JOIN [", joinModel, "]"); zephir_concat_self(&phql, _16 TSRMLS_CC); - } else { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVSVS(_23, " ", joinType, " JOIN [", joinModel, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); } } else { - if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1191)) { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " JOIN ", joinModel, ""); - zephir_concat_self(&phql, _23 TSRMLS_CC); + if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1201)) { + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " JOIN ", joinModel, ""); + zephir_concat_self(&phql, _20 TSRMLS_CC); } else { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " JOIN [", joinModel, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " JOIN [", joinModel, "]"); + zephir_concat_self(&phql, _20 TSRMLS_CC); } } if (zephir_is_true(joinAlias)) { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " AS [", joinAlias, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " AS [", joinAlias, "]"); + zephir_concat_self(&phql, _20 TSRMLS_CC); } if (zephir_is_true(joinConditions)) { - ZEPHIR_INIT_LNVAR(_24); - ZEPHIR_CONCAT_SV(_24, " ON ", joinConditions); - zephir_concat_self(&phql, _24 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_21); + ZEPHIR_CONCAT_SV(_21, " ON ", joinConditions); + zephir_concat_self(&phql, _21 TSRMLS_CC); } } } if (Z_TYPE_P(conditions) == IS_STRING) { if (!(ZEPHIR_IS_EMPTY(conditions))) { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " WHERE ", conditions); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SV(_15, " WHERE ", conditions); + zephir_concat_self(&phql, _15 TSRMLS_CC); } } ZEPHIR_OBS_VAR(group); @@ -100750,21 +101425,21 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(group) == IS_ARRAY) { ZEPHIR_INIT_VAR(groupItems); array_init(groupItems); - zephir_is_iterable(group, &_26, &_25, 0, 0, "phalcon/mvc/model/query/builder.zep", 1239); + zephir_is_iterable(group, &_23, &_22, 0, 0, "phalcon/mvc/model/query/builder.zep", 1249); for ( - ; zephir_hash_get_current_data_ex(_26, (void**) &_27, &_25) == SUCCESS - ; zephir_hash_move_forward_ex(_26, &_25) + ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS + ; zephir_hash_move_forward_ex(_23, &_22) ) { - ZEPHIR_GET_HVALUE(groupItem, _27); + ZEPHIR_GET_HVALUE(groupItem, _24); if (zephir_is_numeric(groupItem)) { - zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1230); + zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1240); } else { - if (zephir_memnstr_str(groupItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1232)) { - zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1233); + if (zephir_memnstr_str(groupItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1242)) { + zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1243); } else { ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, "[", groupItem, "]"); - zephir_array_append(&groupItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1235); + zephir_array_append(&groupItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1245); } } } @@ -100775,30 +101450,30 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { zephir_concat_self(&phql, _4 TSRMLS_CC); } else { if (zephir_is_numeric(group)) { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " GROUP BY ", group); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SV(_15, " GROUP BY ", group); + zephir_concat_self(&phql, _15 TSRMLS_CC); } else { - if (zephir_memnstr_str(group, SL("."), "phalcon/mvc/model/query/builder.zep", 1244)) { + if (zephir_memnstr_str(group, SL("."), "phalcon/mvc/model/query/builder.zep", 1254)) { ZEPHIR_INIT_LNVAR(_16); ZEPHIR_CONCAT_SV(_16, " GROUP BY ", group); zephir_concat_self(&phql, _16 TSRMLS_CC); } else { - if (zephir_memnstr_str(group, SL(","), "phalcon/mvc/model/query/builder.zep", 1247)) { - ZEPHIR_INIT_VAR(_28); - ZEPHIR_SINIT_VAR(_29); - ZVAL_STRING(&_29, " ", 0); - ZEPHIR_SINIT_VAR(_30); - ZVAL_STRING(&_30, "", 0); - zephir_fast_str_replace(&_28, &_29, &_30, group TSRMLS_CC); - ZEPHIR_CPY_WRT(group, _28); + if (zephir_memnstr_str(group, SL(","), "phalcon/mvc/model/query/builder.zep", 1257)) { + ZEPHIR_INIT_VAR(_25); + ZEPHIR_SINIT_VAR(_26); + ZVAL_STRING(&_26, " ", 0); + ZEPHIR_SINIT_VAR(_27); + ZVAL_STRING(&_27, "", 0); + zephir_fast_str_replace(&_25, &_26, &_27, group TSRMLS_CC); + ZEPHIR_CPY_WRT(group, _25); ZEPHIR_INIT_NVAR(groupItems); zephir_fast_explode_str(groupItems, SL(","), group, LONG_MAX TSRMLS_CC); - ZEPHIR_INIT_NVAR(_28); - zephir_fast_join_str(_28, SL("], ["), groupItems TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " GROUP BY [", _28, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_25); + zephir_fast_join_str(_25, SL("], ["), groupItems TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " GROUP BY [", _25, "]"); + zephir_concat_self(&phql, _20 TSRMLS_CC); } else { ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, " GROUP BY [", group, "]"); @@ -100823,21 +101498,21 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(order) == IS_ARRAY) { ZEPHIR_INIT_VAR(orderItems); array_init(orderItems); - zephir_is_iterable(order, &_32, &_31, 0, 0, "phalcon/mvc/model/query/builder.zep", 1284); + zephir_is_iterable(order, &_29, &_28, 0, 0, "phalcon/mvc/model/query/builder.zep", 1294); for ( - ; zephir_hash_get_current_data_ex(_32, (void**) &_33, &_31) == SUCCESS - ; zephir_hash_move_forward_ex(_32, &_31) + ; zephir_hash_get_current_data_ex(_29, (void**) &_30, &_28) == SUCCESS + ; zephir_hash_move_forward_ex(_29, &_28) ) { - ZEPHIR_GET_HVALUE(orderItem, _33); + ZEPHIR_GET_HVALUE(orderItem, _30); if (zephir_is_numeric(orderItem)) { - zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1275); + zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1285); } else { - if (zephir_memnstr_str(orderItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1277)) { - zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1278); + if (zephir_memnstr_str(orderItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1287)) { + zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1288); } else { ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, "[", orderItem, "]"); - zephir_array_append(&orderItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1280); + zephir_array_append(&orderItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1290); } } } @@ -100847,9 +101522,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZEPHIR_CONCAT_SV(_4, " ORDER BY ", _1); zephir_concat_self(&phql, _4 TSRMLS_CC); } else { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " ORDER BY ", order); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SV(_15, " ORDER BY ", order); + zephir_concat_self(&phql, _15 TSRMLS_CC); } } ZEPHIR_OBS_VAR(limit); @@ -100859,7 +101534,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZVAL_NULL(number); if (Z_TYPE_P(limit) == IS_ARRAY) { ZEPHIR_OBS_NVAR(number); - zephir_array_fetch_string(&number, limit, SL("number"), PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1299 TSRMLS_CC); + zephir_array_fetch_string(&number, limit, SL("number"), PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1309 TSRMLS_CC); ZEPHIR_OBS_VAR(offset); if (zephir_array_isset_string_fetch(&offset, limit, SS("offset"), 0 TSRMLS_CC)) { if (!(zephir_is_numeric(offset))) { @@ -100881,45 +101556,34 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { } } if (zephir_is_numeric(number)) { - ZEPHIR_OBS_VAR(hiddenParam); - zephir_read_property_this(&hiddenParam, this_ptr, SL("_hiddenParamNumber"), PH_NOISY_CC); - ZEPHIR_INIT_LNVAR(_4); - ZEPHIR_CONCAT_SVS(_4, " LIMIT :AP", hiddenParam, ":"); - zephir_concat_self(&phql, _4 TSRMLS_CC); - ZEPHIR_SINIT_NVAR(_29); - ZVAL_LONG(&_29, 10); - ZEPHIR_CALL_FUNCTION(&_34, "intval", &_35, 25, number, &_29); + zephir_concat_self_str(&phql, SL(" LIMIT :APL0:") TSRMLS_CC); + ZEPHIR_SINIT_NVAR(_26); + ZVAL_LONG(&_26, 10); + ZEPHIR_CALL_FUNCTION(&_31, "intval", &_32, 26, number, &_26); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, "AP", hiddenParam); - zephir_update_property_array(this_ptr, SL("_bindParams"), _12, _34 TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_16); - ZEPHIR_CONCAT_SV(_16, "AP", hiddenParam); ZEPHIR_INIT_NVAR(_1); - ZVAL_LONG(_1, 1); - zephir_update_property_array(this_ptr, SL("_bindTypes"), _16, _1 TSRMLS_CC); + ZVAL_STRING(_1, "APL0", 1); + zephir_update_property_array(this_ptr, SL("_bindParams"), _1, _31 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_25); + ZVAL_STRING(_25, "APL0", 1); + ZEPHIR_INIT_VAR(_33); + ZVAL_LONG(_33, 1); + zephir_update_property_array(this_ptr, SL("_bindTypes"), _25, _33 TSRMLS_CC); if (zephir_is_numeric(offset)) { - ZEPHIR_SEPARATE(hiddenParam); - zephir_increment(hiddenParam); - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " OFFSET :AP", hiddenParam, ":"); - zephir_concat_self(&phql, _23 TSRMLS_CC); - ZEPHIR_SINIT_NVAR(_29); - ZVAL_LONG(&_29, 10); - ZEPHIR_CALL_FUNCTION(&_34, "intval", &_35, 25, offset, &_29); + zephir_concat_self_str(&phql, SL(" OFFSET :APL1:") TSRMLS_CC); + ZEPHIR_SINIT_NVAR(_26); + ZVAL_LONG(&_26, 10); + ZEPHIR_CALL_FUNCTION(&_31, "intval", &_32, 26, offset, &_26); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_24); - ZEPHIR_CONCAT_SV(_24, "AP", hiddenParam); - zephir_update_property_array(this_ptr, SL("_bindParams"), _24, _34 TSRMLS_CC); + ZEPHIR_INIT_VAR(_34); + ZVAL_STRING(_34, "APL1", 1); + zephir_update_property_array(this_ptr, SL("_bindParams"), _34, _31 TSRMLS_CC); + ZEPHIR_INIT_VAR(_35); + ZVAL_STRING(_35, "APL1", 1); ZEPHIR_INIT_VAR(_36); - ZEPHIR_CONCAT_SV(_36, "AP", hiddenParam); - ZEPHIR_INIT_NVAR(_28); - ZVAL_LONG(_28, 1); - zephir_update_property_array(this_ptr, SL("_bindTypes"), _36, _28 TSRMLS_CC); + ZVAL_LONG(_36, 1); + zephir_update_property_array(this_ptr, SL("_bindTypes"), _35, _36 TSRMLS_CC); } - ZEPHIR_INIT_ZVAL_NREF(_37); - ZVAL_LONG(_37, (zephir_get_numberval(hiddenParam) + 1)); - zephir_update_property_this(this_ptr, SL("_hiddenParamNumber"), _37 TSRMLS_CC); } } forUpdate = zephir_fetch_nproperty_this(this_ptr, SL("_forUpdate"), PH_NOISY_CC); @@ -100941,21 +101605,21 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getQuery) { ZEPHIR_INIT_VAR(query); object_init_ex(query, phalcon_mvc_model_query_ce); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 354); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 347); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345, _0, _1); + ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 338, _0, _1); zephir_check_call_status(); ZEPHIR_OBS_VAR(bindParams); zephir_read_property_this(&bindParams, this_ptr, SL("_bindParams"), PH_NOISY_CC); if (Z_TYPE_P(bindParams) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 355, bindParams); + ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 348, bindParams); zephir_check_call_status(); } ZEPHIR_OBS_VAR(bindTypes); zephir_read_property_this(&bindTypes, this_ptr, SL("_bindTypes"), PH_NOISY_CC); if (Z_TYPE_P(bindTypes) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 356, bindTypes); + ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 349, bindTypes); zephir_check_call_status(); } RETURN_CCTOR(query); @@ -101210,7 +101874,7 @@ static zval *phql_ret_select_statement(zval *S, zval *W, zval *O, zval *G, zval return ret; } -static zval *phql_ret_select_clause(zval *distinct, zval *columns, zval *tables, zval *with_list, zval *join_list) +static zval *phql_ret_select_clause(zval *distinct, zval *columns, zval *tables, zval *join_list) { zval *ret; @@ -101224,10 +101888,6 @@ static zval *phql_ret_select_clause(zval *distinct, zval *columns, zval *tables, add_assoc_zval(ret, "columns", columns); add_assoc_zval(ret, "tables", tables); - if (with_list) { - add_assoc_zval(ret, "with", with_list); - } - if (join_list) { add_assoc_zval(ret, "joins", join_list); } @@ -101446,7 +102106,7 @@ static zval *phql_ret_column_item(int type, zval *column, phql_parser_token *ide return ret; } -static zval *phql_ret_assoc_name(zval *qualified_name, phql_parser_token *alias) +static zval *phql_ret_assoc_name(zval *qualified_name, phql_parser_token *alias, zval *with) { zval *ret; @@ -101454,11 +102114,16 @@ static zval *phql_ret_assoc_name(zval *qualified_name, phql_parser_token *alias) MAKE_STD_ZVAL(ret); array_init(ret); add_assoc_zval(ret, "qualifiedName", qualified_name); + if (alias) { add_assoc_stringl(ret, "alias", alias->token, alias->token_len, 0); efree(alias); } + if (with) { + add_assoc_zval(ret, "with", with); + } + return ret; } @@ -101536,7 +102201,7 @@ static zval *phql_ret_func_call(phql_parser_token *name, zval *arguments, zval * } -// 459 "parser.c" +// 460 "parser.c" /* Next is all token values, in a form suitable for use by makeheaders. ** This section will be null unless lemon is run with the -m switch. */ @@ -101579,23 +102244,23 @@ static zval *phql_ret_func_call(phql_parser_token *name, zval *arguments, zval * ** defined, then do no error processing. */ #define PPCODETYPE unsigned char -#define PPNOCODE 135 +#define PPNOCODE 134 #define PPACTIONTYPE unsigned short int #define phql_TOKENTYPE phql_parser_token* typedef union { phql_TOKENTYPE pp0; - zval* pp244; - int pp269; + zval* pp162; + int pp267; } PPMINORTYPE; #define PPSTACKDEPTH 100 #define phql_ARG_SDECL phql_parser_status *status; #define phql_ARG_PDECL ,phql_parser_status *status #define phql_ARG_FETCH phql_parser_status *status = pppParser->status #define phql_ARG_STORE pppParser->status = status -#define PPNSTATE 280 -#define PPNRULE 157 +#define PPNSTATE 293 +#define PPNRULE 161 #define PPERRORSYMBOL 79 -#define PPERRSYMDT pp269 +#define PPERRSYMDT pp267 #define PP_NO_ACTION (PPNSTATE+PPNRULE+2) #define PP_ACCEPT_ACTION (PPNSTATE+PPNRULE+1) #define PP_ERROR_ACTION (PPNSTATE+PPNRULE) @@ -101648,254 +102313,266 @@ typedef union { ** pp_default[] Default action for each state. */ static PPACTIONTYPE pp_action[] = { - /* 0 */ 92, 98, 55, 57, 59, 61, 63, 65, 45, 47, + /* 0 */ 120, 126, 55, 57, 59, 61, 63, 65, 45, 47, /* 10 */ 67, 72, 49, 51, 53, 41, 39, 43, 37, 34, - /* 20 */ 94, 74, 69, 92, 98, 55, 57, 59, 61, 63, + /* 20 */ 122, 74, 69, 120, 126, 55, 57, 59, 61, 63, /* 30 */ 65, 45, 47, 67, 72, 49, 51, 53, 41, 39, - /* 40 */ 43, 37, 34, 94, 74, 69, 19, 20, 21, 22, - /* 50 */ 23, 106, 32, 33, 92, 98, 55, 57, 59, 61, - /* 60 */ 63, 65, 45, 47, 67, 72, 49, 51, 53, 41, - /* 70 */ 39, 43, 37, 34, 94, 74, 69, 94, 74, 69, - /* 80 */ 82, 70, 215, 207, 83, 205, 185, 85, 165, 86, - /* 90 */ 163, 193, 217, 126, 196, 160, 234, 92, 98, 55, + /* 40 */ 43, 37, 34, 122, 74, 69, 37, 34, 122, 74, + /* 50 */ 69, 166, 220, 92, 218, 45, 47, 67, 72, 49, + /* 60 */ 51, 53, 41, 39, 43, 37, 34, 122, 74, 69, + /* 70 */ 154, 429, 186, 91, 120, 126, 55, 57, 59, 61, + /* 80 */ 63, 65, 45, 47, 67, 72, 49, 51, 53, 41, + /* 90 */ 39, 43, 37, 34, 122, 74, 69, 120, 126, 55, /* 100 */ 57, 59, 61, 63, 65, 45, 47, 67, 72, 49, - /* 110 */ 51, 53, 41, 39, 43, 37, 34, 94, 74, 69, - /* 120 */ 92, 98, 55, 57, 59, 61, 63, 65, 45, 47, - /* 130 */ 67, 72, 49, 51, 53, 41, 39, 43, 37, 34, - /* 140 */ 94, 74, 69, 92, 98, 55, 57, 59, 61, 63, + /* 110 */ 51, 53, 41, 39, 43, 37, 34, 122, 74, 69, + /* 120 */ 19, 20, 21, 22, 23, 227, 32, 33, 67, 72, + /* 130 */ 49, 51, 53, 41, 39, 43, 37, 34, 122, 74, + /* 140 */ 69, 130, 238, 120, 126, 55, 57, 59, 61, 63, /* 150 */ 65, 45, 47, 67, 72, 49, 51, 53, 41, 39, - /* 160 */ 43, 37, 34, 94, 74, 69, 239, 247, 128, 45, - /* 170 */ 47, 67, 72, 49, 51, 53, 41, 39, 43, 37, - /* 180 */ 34, 94, 74, 69, 266, 273, 269, 118, 102, 92, - /* 190 */ 98, 55, 57, 59, 61, 63, 65, 45, 47, 67, - /* 200 */ 72, 49, 51, 53, 41, 39, 43, 37, 34, 94, - /* 210 */ 74, 69, 438, 1, 2, 3, 4, 5, 6, 198, - /* 220 */ 112, 79, 92, 98, 55, 57, 59, 61, 63, 65, + /* 160 */ 43, 37, 34, 122, 74, 69, 41, 39, 43, 37, + /* 170 */ 34, 122, 74, 69, 140, 8, 120, 126, 55, 57, + /* 180 */ 59, 61, 63, 65, 45, 47, 67, 72, 49, 51, + /* 190 */ 53, 41, 39, 43, 37, 34, 122, 74, 69, 120, + /* 200 */ 126, 55, 57, 59, 61, 63, 65, 45, 47, 67, + /* 210 */ 72, 49, 51, 53, 41, 39, 43, 37, 34, 122, + /* 220 */ 74, 69, 120, 126, 55, 57, 59, 61, 63, 65, /* 230 */ 45, 47, 67, 72, 49, 51, 53, 41, 39, 43, - /* 240 */ 37, 34, 94, 74, 69, 140, 107, 258, 35, 96, - /* 250 */ 6, 141, 143, 274, 124, 126, 248, 160, 131, 257, - /* 260 */ 67, 72, 49, 51, 53, 41, 39, 43, 37, 34, - /* 270 */ 94, 74, 69, 100, 413, 49, 51, 53, 41, 39, - /* 280 */ 43, 37, 34, 94, 74, 69, 268, 269, 146, 147, - /* 290 */ 153, 154, 155, 105, 109, 115, 367, 121, 84, 85, - /* 300 */ 95, 86, 150, 148, 149, 151, 152, 55, 57, 59, - /* 310 */ 61, 63, 65, 45, 47, 67, 72, 49, 51, 53, - /* 320 */ 41, 39, 43, 37, 34, 94, 74, 69, 140, 7, - /* 330 */ 254, 35, 134, 183, 141, 143, 181, 76, 191, 245, - /* 340 */ 189, 131, 41, 39, 43, 37, 34, 94, 74, 69, - /* 350 */ 252, 249, 145, 246, 261, 140, 100, 238, 35, 145, - /* 360 */ 137, 141, 143, 130, 179, 135, 156, 177, 131, 166, - /* 370 */ 130, 146, 147, 153, 154, 155, 105, 109, 115, 280, - /* 380 */ 121, 87, 186, 100, 281, 150, 148, 149, 151, 152, - /* 390 */ 192, 213, 221, 166, 282, 6, 6, 243, 146, 147, - /* 400 */ 153, 154, 155, 105, 109, 115, 138, 121, 134, 134, - /* 410 */ 123, 162, 150, 148, 149, 151, 152, 200, 242, 158, - /* 420 */ 35, 78, 283, 141, 143, 208, 204, 212, 145, 145, - /* 430 */ 201, 175, 284, 132, 173, 76, 211, 219, 227, 130, - /* 440 */ 130, 203, 156, 156, 8, 100, 145, 168, 184, 170, - /* 450 */ 172, 236, 176, 180, 159, 17, 263, 130, 277, 245, - /* 460 */ 146, 147, 153, 154, 155, 105, 109, 115, 232, 121, - /* 470 */ 241, 225, 202, 246, 150, 148, 149, 151, 152, 145, - /* 480 */ 9, 35, 209, 210, 141, 143, 132, 76, 145, 24, - /* 490 */ 130, 131, 103, 229, 233, 243, 6, 26, 138, 130, - /* 500 */ 134, 37, 34, 94, 74, 69, 100, 10, 35, 101, - /* 510 */ 15, 141, 143, 13, 11, 14, 253, 12, 131, 220, - /* 520 */ 145, 146, 147, 153, 154, 155, 105, 109, 115, 145, - /* 530 */ 121, 130, 16, 100, 139, 150, 148, 149, 151, 152, - /* 540 */ 130, 27, 18, 29, 25, 69, 77, 31, 146, 147, - /* 550 */ 153, 154, 155, 105, 109, 115, 75, 121, 81, 232, - /* 560 */ 167, 138, 150, 148, 149, 151, 152, 145, 31, 80, - /* 570 */ 28, 224, 88, 90, 197, 199, 204, 272, 130, 145, - /* 580 */ 89, 188, 412, 97, 38, 231, 104, 76, 145, 108, - /* 590 */ 130, 245, 30, 166, 40, 110, 145, 145, 271, 130, - /* 600 */ 42, 36, 113, 44, 145, 244, 216, 130, 130, 223, - /* 610 */ 114, 145, 119, 125, 145, 130, 157, 133, 46, 116, - /* 620 */ 145, 145, 130, 145, 226, 130, 145, 48, 50, 145, - /* 630 */ 235, 130, 130, 52, 130, 120, 54, 130, 145, 158, - /* 640 */ 130, 159, 136, 164, 145, 169, 313, 145, 145, 130, - /* 650 */ 145, 56, 58, 145, 60, 130, 145, 62, 130, 130, - /* 660 */ 171, 130, 314, 174, 130, 315, 111, 130, 187, 64, - /* 670 */ 66, 145, 145, 316, 145, 188, 117, 145, 68, 91, - /* 680 */ 178, 317, 130, 130, 71, 130, 145, 166, 130, 145, - /* 690 */ 145, 122, 73, 93, 161, 318, 145, 130, 145, 145, - /* 700 */ 130, 130, 182, 319, 145, 320, 321, 130, 99, 130, - /* 710 */ 130, 145, 145, 145, 145, 130, 190, 195, 206, 279, - /* 720 */ 144, 127, 130, 130, 130, 130, 188, 264, 145, 142, - /* 730 */ 129, 194, 228, 230, 188, 214, 218, 237, 166, 130, - /* 740 */ 145, 145, 222, 240, 324, 256, 166, 250, 325, 145, - /* 750 */ 145, 130, 130, 255, 251, 259, 260, 332, 366, 262, - /* 760 */ 130, 130, 265, 267, 270, 275, 276, 338, 278, + /* 240 */ 37, 34, 122, 74, 69, 168, 109, 156, 35, 95, + /* 250 */ 99, 169, 171, 26, 76, 151, 188, 81, 159, 160, + /* 260 */ 82, 111, 209, 113, 114, 17, 146, 285, 192, 208, + /* 270 */ 194, 196, 128, 200, 204, 222, 223, 455, 1, 2, + /* 280 */ 3, 4, 5, 6, 199, 173, 284, 197, 174, 175, + /* 290 */ 181, 182, 183, 133, 137, 143, 76, 149, 158, 24, + /* 300 */ 212, 217, 178, 176, 177, 179, 180, 168, 135, 271, + /* 310 */ 35, 249, 6, 169, 171, 287, 276, 110, 290, 173, + /* 320 */ 159, 49, 51, 53, 41, 39, 43, 37, 34, 122, + /* 330 */ 74, 69, 158, 384, 128, 430, 192, 208, 194, 196, + /* 340 */ 80, 200, 204, 292, 210, 122, 74, 69, 84, 84, + /* 350 */ 174, 175, 181, 182, 183, 133, 137, 143, 125, 149, + /* 360 */ 107, 107, 95, 90, 178, 176, 177, 179, 180, 55, + /* 370 */ 57, 59, 61, 63, 65, 45, 47, 67, 72, 49, + /* 380 */ 51, 53, 41, 39, 43, 37, 34, 122, 74, 69, + /* 390 */ 213, 274, 258, 35, 70, 228, 169, 171, 131, 109, + /* 400 */ 245, 265, 6, 214, 259, 230, 279, 286, 282, 234, + /* 410 */ 173, 83, 203, 6, 129, 201, 84, 128, 173, 152, + /* 420 */ 154, 207, 186, 158, 205, 162, 244, 96, 107, 85, + /* 430 */ 219, 158, 173, 174, 175, 181, 182, 183, 133, 137, + /* 440 */ 143, 94, 149, 173, 7, 158, 102, 178, 176, 177, + /* 450 */ 179, 180, 162, 232, 35, 89, 158, 169, 171, 184, + /* 460 */ 76, 112, 113, 114, 159, 211, 215, 79, 94, 78, + /* 470 */ 173, 226, 221, 217, 94, 6, 277, 240, 128, 160, + /* 480 */ 165, 84, 98, 158, 250, 163, 184, 162, 103, 95, + /* 490 */ 104, 173, 94, 107, 174, 175, 181, 182, 183, 133, + /* 500 */ 137, 143, 92, 149, 158, 173, 108, 155, 178, 176, + /* 510 */ 177, 179, 180, 168, 92, 224, 35, 258, 158, 169, + /* 520 */ 171, 184, 100, 27, 258, 173, 159, 166, 216, 257, + /* 530 */ 191, 115, 189, 254, 105, 173, 259, 124, 158, 69, + /* 540 */ 128, 110, 173, 107, 166, 281, 282, 225, 158, 252, + /* 550 */ 260, 31, 253, 10, 251, 158, 174, 175, 181, 182, + /* 560 */ 183, 133, 137, 143, 233, 149, 107, 106, 42, 173, + /* 570 */ 178, 176, 177, 179, 180, 30, 247, 35, 329, 245, + /* 580 */ 169, 171, 158, 147, 31, 229, 173, 159, 123, 328, + /* 590 */ 261, 332, 256, 270, 101, 327, 162, 173, 326, 158, + /* 600 */ 325, 128, 173, 173, 242, 246, 206, 28, 237, 18, + /* 610 */ 158, 50, 255, 202, 173, 158, 158, 174, 175, 181, + /* 620 */ 182, 183, 133, 137, 143, 121, 149, 158, 239, 173, + /* 630 */ 167, 178, 176, 177, 179, 180, 97, 269, 164, 119, + /* 640 */ 148, 263, 158, 173, 324, 264, 173, 71, 15, 132, + /* 650 */ 150, 267, 323, 161, 145, 256, 158, 173, 73, 158, + /* 660 */ 134, 170, 172, 198, 62, 173, 322, 333, 173, 60, + /* 670 */ 158, 262, 173, 66, 93, 266, 173, 195, 158, 173, + /* 680 */ 173, 158, 173, 187, 139, 158, 136, 173, 268, 158, + /* 690 */ 11, 173, 158, 158, 76, 158, 295, 185, 58, 340, + /* 700 */ 158, 173, 173, 56, 158, 272, 236, 36, 321, 54, + /* 710 */ 38, 383, 293, 157, 158, 158, 173, 127, 40, 273, + /* 720 */ 193, 173, 275, 278, 173, 173, 280, 173, 173, 158, + /* 730 */ 190, 173, 68, 52, 158, 173, 173, 158, 158, 138, + /* 740 */ 158, 158, 48, 283, 158, 13, 25, 88, 158, 158, + /* 750 */ 173, 173, 16, 248, 87, 86, 44, 46, 64, 297, + /* 760 */ 173, 294, 141, 158, 158, 296, 142, 288, 153, 289, + /* 770 */ 346, 173, 291, 158, 173, 173, 173, 12, 29, 75, + /* 780 */ 77, 144, 9, 235, 158, 117, 241, 158, 158, 158, + /* 790 */ 118, 231, 243, 296, 116, 14, }; static PPCODETYPE pp_lookahead[] = { /* 0 */ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, /* 10 */ 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, /* 20 */ 21, 22, 23, 1, 2, 3, 4, 5, 6, 7, /* 30 */ 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, - /* 40 */ 18, 19, 20, 21, 22, 23, 60, 61, 62, 63, - /* 50 */ 64, 45, 53, 54, 1, 2, 3, 4, 5, 6, - /* 60 */ 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, - /* 70 */ 17, 18, 19, 20, 21, 22, 23, 21, 22, 23, - /* 80 */ 97, 11, 12, 30, 101, 32, 103, 104, 30, 106, - /* 90 */ 32, 102, 22, 71, 105, 73, 50, 1, 2, 3, + /* 40 */ 18, 19, 20, 21, 22, 23, 19, 20, 21, 22, + /* 50 */ 23, 25, 30, 25, 32, 9, 10, 11, 12, 13, + /* 60 */ 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, + /* 70 */ 71, 45, 73, 45, 1, 2, 3, 4, 5, 6, + /* 80 */ 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, + /* 90 */ 17, 18, 19, 20, 21, 22, 23, 1, 2, 3, /* 100 */ 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, /* 110 */ 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, - /* 120 */ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, - /* 130 */ 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, - /* 140 */ 21, 22, 23, 1, 2, 3, 4, 5, 6, 7, + /* 120 */ 60, 61, 62, 63, 64, 45, 53, 54, 11, 12, + /* 130 */ 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, + /* 140 */ 23, 45, 56, 1, 2, 3, 4, 5, 6, 7, /* 150 */ 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, - /* 160 */ 18, 19, 20, 21, 22, 23, 44, 45, 72, 9, - /* 170 */ 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, - /* 180 */ 20, 21, 22, 23, 117, 118, 119, 68, 46, 1, - /* 190 */ 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, - /* 200 */ 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, - /* 210 */ 22, 23, 80, 81, 82, 83, 84, 85, 86, 25, - /* 220 */ 32, 27, 1, 2, 3, 4, 5, 6, 7, 8, + /* 160 */ 18, 19, 20, 21, 22, 23, 16, 17, 18, 19, + /* 170 */ 20, 21, 22, 23, 32, 88, 1, 2, 3, 4, + /* 180 */ 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, + /* 190 */ 15, 16, 17, 18, 19, 20, 21, 22, 23, 1, + /* 200 */ 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, + /* 210 */ 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, + /* 220 */ 22, 23, 1, 2, 3, 4, 5, 6, 7, 8, /* 230 */ 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, - /* 240 */ 19, 20, 21, 22, 23, 17, 82, 115, 20, 23, - /* 250 */ 86, 23, 24, 121, 70, 71, 111, 73, 30, 114, - /* 260 */ 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, - /* 270 */ 21, 22, 23, 45, 46, 13, 14, 15, 16, 17, - /* 280 */ 18, 19, 20, 21, 22, 23, 118, 119, 60, 61, - /* 290 */ 62, 63, 64, 65, 66, 67, 0, 69, 103, 104, - /* 300 */ 74, 106, 74, 75, 76, 77, 78, 3, 4, 5, - /* 310 */ 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, - /* 320 */ 16, 17, 18, 19, 20, 21, 22, 23, 17, 87, - /* 330 */ 25, 20, 99, 35, 23, 24, 38, 26, 30, 99, - /* 340 */ 32, 30, 16, 17, 18, 19, 20, 21, 22, 23, - /* 350 */ 110, 46, 119, 113, 58, 17, 45, 107, 20, 119, - /* 360 */ 127, 23, 24, 130, 35, 132, 133, 38, 30, 119, - /* 370 */ 130, 60, 61, 62, 63, 64, 65, 66, 67, 0, - /* 380 */ 69, 107, 25, 45, 0, 74, 75, 76, 77, 78, - /* 390 */ 33, 82, 82, 119, 0, 86, 86, 25, 60, 61, - /* 400 */ 62, 63, 64, 65, 66, 67, 25, 69, 99, 99, - /* 410 */ 128, 129, 74, 75, 76, 77, 78, 17, 46, 31, - /* 420 */ 20, 94, 0, 23, 24, 98, 99, 46, 119, 119, - /* 430 */ 30, 35, 0, 45, 38, 26, 127, 127, 55, 130, - /* 440 */ 130, 17, 133, 133, 88, 45, 119, 34, 35, 36, - /* 450 */ 37, 42, 39, 40, 30, 25, 47, 130, 49, 99, - /* 460 */ 60, 61, 62, 63, 64, 65, 66, 67, 99, 69, - /* 470 */ 110, 56, 31, 113, 74, 75, 76, 77, 78, 119, - /* 480 */ 89, 20, 28, 29, 23, 24, 45, 26, 119, 59, - /* 490 */ 130, 30, 82, 124, 125, 25, 86, 51, 25, 130, - /* 500 */ 99, 19, 20, 21, 22, 23, 45, 90, 20, 99, - /* 510 */ 58, 23, 24, 57, 91, 47, 46, 92, 30, 46, - /* 520 */ 119, 60, 61, 62, 63, 64, 65, 66, 67, 119, - /* 530 */ 69, 130, 126, 45, 133, 74, 75, 76, 77, 78, - /* 540 */ 130, 52, 126, 25, 126, 23, 93, 99, 60, 61, - /* 550 */ 62, 63, 64, 65, 66, 67, 45, 69, 96, 99, - /* 560 */ 30, 25, 74, 75, 76, 77, 78, 119, 99, 95, - /* 570 */ 122, 123, 108, 41, 100, 98, 99, 99, 130, 119, - /* 580 */ 109, 107, 46, 74, 99, 125, 46, 26, 119, 46, - /* 590 */ 130, 99, 123, 119, 99, 45, 119, 119, 120, 130, - /* 600 */ 99, 99, 30, 99, 119, 113, 99, 130, 130, 99, - /* 610 */ 46, 119, 30, 129, 119, 130, 28, 131, 99, 45, - /* 620 */ 119, 119, 130, 119, 99, 130, 119, 99, 99, 119, - /* 630 */ 99, 130, 130, 99, 130, 46, 99, 130, 119, 31, - /* 640 */ 130, 30, 46, 30, 119, 35, 30, 119, 119, 130, - /* 650 */ 119, 99, 99, 119, 99, 130, 119, 99, 130, 130, - /* 660 */ 35, 130, 30, 35, 130, 30, 99, 130, 100, 99, - /* 670 */ 99, 119, 119, 30, 119, 107, 99, 119, 99, 99, - /* 680 */ 35, 30, 130, 130, 99, 130, 119, 119, 130, 119, - /* 690 */ 119, 99, 99, 99, 99, 30, 119, 130, 119, 119, - /* 700 */ 130, 130, 35, 30, 119, 30, 30, 130, 99, 130, - /* 710 */ 130, 119, 119, 119, 119, 130, 30, 30, 30, 100, - /* 720 */ 99, 99, 130, 130, 130, 130, 107, 100, 119, 99, - /* 730 */ 99, 105, 52, 25, 107, 46, 45, 43, 119, 130, - /* 740 */ 119, 119, 46, 45, 0, 30, 119, 44, 0, 119, - /* 750 */ 119, 130, 130, 114, 45, 87, 116, 0, 0, 126, - /* 760 */ 130, 130, 48, 25, 3, 87, 116, 0, 27, + /* 240 */ 19, 20, 21, 22, 23, 17, 31, 72, 20, 119, + /* 250 */ 120, 23, 24, 51, 26, 127, 128, 96, 30, 44, + /* 260 */ 25, 100, 101, 102, 103, 25, 68, 98, 33, 34, + /* 270 */ 35, 36, 44, 38, 39, 28, 29, 80, 81, 82, + /* 280 */ 83, 84, 85, 86, 34, 116, 117, 37, 60, 61, + /* 290 */ 62, 63, 64, 65, 66, 67, 26, 69, 129, 59, + /* 300 */ 97, 98, 74, 75, 76, 77, 78, 17, 82, 112, + /* 310 */ 20, 41, 86, 23, 24, 118, 46, 30, 48, 116, + /* 320 */ 30, 13, 14, 15, 16, 17, 18, 19, 20, 21, + /* 330 */ 22, 23, 129, 0, 44, 45, 33, 34, 35, 36, + /* 340 */ 95, 38, 39, 99, 99, 21, 22, 23, 104, 104, + /* 350 */ 60, 61, 62, 63, 64, 65, 66, 67, 74, 69, + /* 360 */ 116, 116, 119, 120, 74, 75, 76, 77, 78, 3, + /* 370 */ 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, + /* 380 */ 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, + /* 390 */ 17, 58, 98, 20, 11, 12, 23, 24, 82, 31, + /* 400 */ 98, 107, 86, 30, 110, 22, 114, 115, 116, 82, + /* 410 */ 116, 99, 34, 86, 98, 37, 104, 44, 116, 70, + /* 420 */ 71, 34, 73, 129, 37, 98, 124, 30, 116, 32, + /* 430 */ 30, 129, 116, 60, 61, 62, 63, 64, 65, 66, + /* 440 */ 67, 30, 69, 116, 87, 129, 49, 74, 75, 76, + /* 450 */ 77, 78, 98, 126, 20, 44, 129, 23, 24, 132, + /* 460 */ 26, 101, 102, 103, 30, 25, 31, 27, 30, 94, + /* 470 */ 116, 82, 97, 98, 30, 86, 99, 55, 44, 44, + /* 480 */ 126, 104, 44, 129, 42, 131, 132, 98, 44, 119, + /* 490 */ 120, 116, 30, 116, 60, 61, 62, 63, 64, 65, + /* 500 */ 66, 67, 25, 69, 129, 116, 30, 98, 74, 75, + /* 510 */ 76, 77, 78, 17, 25, 126, 20, 98, 129, 23, + /* 520 */ 24, 132, 45, 52, 98, 116, 30, 25, 17, 110, + /* 530 */ 30, 104, 32, 107, 45, 116, 110, 23, 129, 23, + /* 540 */ 44, 30, 116, 116, 25, 115, 116, 45, 129, 43, + /* 550 */ 44, 98, 44, 90, 104, 129, 60, 61, 62, 63, + /* 560 */ 64, 65, 66, 67, 45, 69, 116, 119, 98, 116, + /* 570 */ 74, 75, 76, 77, 78, 122, 50, 20, 30, 98, + /* 580 */ 23, 24, 129, 30, 98, 98, 116, 30, 74, 30, + /* 590 */ 108, 0, 25, 111, 119, 30, 98, 116, 30, 129, + /* 600 */ 30, 44, 116, 116, 123, 124, 34, 121, 122, 125, + /* 610 */ 129, 98, 45, 34, 116, 129, 129, 60, 61, 62, + /* 620 */ 63, 64, 65, 66, 67, 98, 69, 129, 98, 116, + /* 630 */ 132, 74, 75, 76, 77, 78, 49, 30, 45, 98, + /* 640 */ 45, 43, 129, 116, 30, 44, 116, 98, 58, 45, + /* 650 */ 98, 25, 30, 130, 98, 25, 129, 116, 98, 129, + /* 660 */ 44, 98, 98, 34, 98, 116, 30, 0, 116, 98, + /* 670 */ 129, 45, 116, 98, 119, 45, 116, 34, 129, 116, + /* 680 */ 116, 129, 116, 98, 98, 129, 45, 116, 111, 129, + /* 690 */ 91, 116, 129, 129, 26, 129, 0, 28, 98, 0, + /* 700 */ 129, 116, 116, 98, 129, 87, 98, 98, 30, 98, + /* 710 */ 98, 0, 0, 98, 129, 129, 116, 98, 98, 113, + /* 720 */ 34, 116, 125, 47, 116, 116, 25, 116, 116, 129, + /* 730 */ 30, 116, 98, 98, 129, 116, 116, 129, 129, 44, + /* 740 */ 129, 129, 98, 3, 129, 57, 125, 119, 129, 129, + /* 750 */ 116, 116, 125, 98, 49, 30, 98, 98, 98, 0, + /* 760 */ 116, 0, 30, 129, 129, 0, 45, 87, 128, 113, + /* 770 */ 0, 116, 27, 129, 116, 116, 116, 92, 25, 44, + /* 780 */ 93, 44, 89, 45, 129, 106, 52, 129, 129, 129, + /* 790 */ 40, 44, 25, 133, 105, 46, }; -#define PP_SHIFT_USE_DFLT (-15) +#define PP_SHIFT_USE_DFLT (-2) static short pp_shift_ofst[] = { - /* 0 */ 409, 379, 384, 394, 422, 432, 46, 383, 415, 446, - /* 10 */ 452, 456, -15, 468, -15, -14, 430, -14, -15, -15, - /* 20 */ -15, -15, -15, -15, -14, -15, 489, 488, 518, 488, - /* 30 */ -15, -1, -15, -15, 488, 488, 56, 488, 56, 488, - /* 40 */ 482, 488, 482, 488, 482, 488, 249, 488, 249, 488, - /* 50 */ 326, 488, 326, 488, 326, 488, 160, 488, 160, 488, - /* 60 */ 160, 488, 160, 488, 160, 488, 160, 488, 262, 70, - /* 70 */ 488, 522, 488, 262, 511, 311, 454, 400, 194, 530, - /* 80 */ 357, 413, -15, 413, -15, -15, 530, 58, 532, -15, - /* 90 */ 488, 221, 488, 221, 226, -15, 509, -15, 488, 304, - /* 100 */ 461, 142, -15, 540, -15, 6, 561, 543, -15, 550, - /* 110 */ 488, 188, 572, 564, -15, 574, 488, 119, 582, 589, - /* 120 */ -15, 488, 22, 184, -15, -15, 488, 96, 488, 221, - /* 130 */ -15, 388, 588, 228, 221, 596, -15, 536, 338, -15, - /* 140 */ -15, 488, 522, 488, 522, -15, -15, -15, -15, -15, - /* 150 */ -15, -15, -15, -15, -15, -15, -15, -15, 611, -15, - /* 160 */ 488, 221, -15, 613, -15, -15, -15, 608, 610, 616, - /* 170 */ 625, 632, 396, 628, 635, 643, 329, 645, 651, 665, - /* 180 */ 298, 667, 673, 675, 676, -15, 530, -15, 308, 686, - /* 190 */ -15, -15, 687, 687, -15, -15, -15, -15, 400, -15, - /* 200 */ -15, 441, 424, -15, 53, 688, -15, -15, -15, -15, - /* 210 */ -15, 381, -15, 689, -15, 488, 522, 691, 311, 473, - /* 220 */ -15, 696, -15, 56, -15, 488, 221, 680, 488, 708, - /* 230 */ 488, -15, 221, -15, 488, 221, 694, 530, 122, 698, - /* 240 */ 488, 372, 744, 488, -15, 221, -15, 715, 305, 703, - /* 250 */ 709, 488, 470, 748, 715, -15, -15, -15, 46, 296, - /* 260 */ 757, -14, 758, 530, 714, 530, 738, 530, -15, 761, - /* 270 */ 488, -15, 221, -15, 46, 296, 767, 741, 530, -15, + /* 0 */ 270, 712, 761, 696, 765, 759, 526, 422, 86, 202, + /* 10 */ 590, 688, -2, 749, -2, 60, 240, 60, -2, -2, + /* 20 */ -2, -2, -2, -2, 60, -2, 471, 557, 753, 557, + /* 30 */ -2, 73, -2, -2, 557, 557, 324, 557, 324, 557, + /* 40 */ 27, 557, 27, 557, 27, 557, 117, 557, 117, 557, + /* 50 */ 150, 557, 150, 557, 150, 557, 46, 557, 46, 557, + /* 60 */ 46, 557, 46, 557, 46, 557, 46, 557, 308, 383, + /* 70 */ 557, 516, 557, 308, 735, 228, 247, 373, 440, 476, + /* 80 */ 235, -2, 476, -2, 397, 725, 705, 411, -2, 462, + /* 90 */ 28, -2, 462, -2, -2, -2, 587, 438, 462, 477, + /* 100 */ -2, -2, 444, 462, 489, -2, -2, -2, 368, 287, + /* 110 */ -2, 303, -2, -2, 476, 500, 750, -2, 557, 221, + /* 120 */ 557, 221, 514, -2, 284, -2, 557, 366, 434, 96, + /* 130 */ -2, 604, -2, 616, 668, 641, -2, 695, 557, 142, + /* 140 */ 732, 721, -2, 737, 557, 198, 553, 595, -2, 557, + /* 150 */ -1, 349, -2, -2, 557, 175, 557, 221, -2, 215, + /* 160 */ 669, 290, 221, 593, -2, 26, 496, -2, -2, 557, + /* 170 */ 516, 557, 516, -2, -2, -2, -2, -2, -2, -2, + /* 180 */ -2, -2, -2, -2, -2, -2, 557, 221, -2, 700, + /* 190 */ -2, -2, 686, 678, 643, 636, 250, 629, 622, 614, + /* 200 */ 378, 579, 570, 568, 387, 572, 565, 559, 548, -2, + /* 210 */ -2, 373, -2, -2, 435, 511, -2, 22, 400, -2, + /* 220 */ -2, -2, -2, -2, 502, -2, 80, -2, 557, 516, + /* 230 */ 747, 228, 519, -2, 738, -2, 324, -2, 557, 221, + /* 240 */ 734, 557, 767, 557, -2, 221, -2, 557, 221, 442, + /* 250 */ 476, 506, 508, 557, 567, 591, 557, -2, 221, -2, + /* 260 */ 607, 626, 598, 601, 557, 630, 667, 607, -2, -2, + /* 270 */ -2, 526, 333, 699, 60, 711, 476, 676, 476, 701, + /* 280 */ 476, -2, 740, 557, -2, 221, -2, 526, 333, 770, + /* 290 */ 745, 476, -2, }; -#define PP_REDUCE_USE_DFLT (-18) +#define PP_REDUCE_USE_DFLT (-1) static short pp_reduce_ofst[] = { - /* 0 */ 132, -18, -18, -18, -18, -18, 242, 356, 391, 417, - /* 10 */ 423, 425, -18, -18, -18, 406, -18, 416, -18, -18, - /* 20 */ -18, -18, -18, -18, 418, -18, -18, 448, -18, 469, - /* 30 */ -18, -18, -18, -18, 510, 502, -18, 485, -18, 495, - /* 40 */ -18, 501, -18, 504, -18, 519, -18, 528, -18, 529, - /* 50 */ -18, 534, -18, 537, -18, 552, -18, 553, -18, 555, - /* 60 */ -18, 558, -18, 570, -18, 571, -18, 579, -18, -18, - /* 70 */ 585, -18, 593, -18, -18, 309, 453, 327, -18, 474, - /* 80 */ 462, -17, -18, 195, -18, -18, 274, 464, 471, -18, - /* 90 */ 580, -18, 594, -18, -18, -18, -18, -18, 609, -18, - /* 100 */ 410, -18, -18, -18, -18, -18, 164, -18, -18, -18, - /* 110 */ 567, -18, -18, -18, -18, -18, 577, -18, -18, -18, - /* 120 */ -18, 592, 282, 484, -18, -18, 622, -18, 631, -18, - /* 130 */ -18, -18, 486, 233, -18, -18, -18, -18, 401, -18, - /* 140 */ -18, 630, -18, 621, -18, -18, -18, -18, -18, -18, - /* 150 */ -18, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 160 */ 595, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 170 */ -18, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 180 */ -18, -18, -18, -18, -18, -18, 568, -18, -18, -18, - /* 190 */ -18, -18, -11, 626, -18, -18, -18, -18, 477, -18, - /* 200 */ -18, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 210 */ -18, -18, -18, -18, -18, 507, -18, -18, 310, -18, - /* 220 */ -18, -18, -18, -18, -18, 525, -18, -18, 369, -18, - /* 230 */ 460, -18, -18, -18, 531, -18, -18, 250, -18, -18, - /* 240 */ 360, -18, -18, 492, -18, -18, -18, 145, -18, -18, - /* 250 */ -18, 240, -18, -18, 639, -18, -18, -18, 668, 640, - /* 260 */ -18, 633, -18, 627, -18, 67, -18, 168, -18, -18, - /* 270 */ 478, -18, -18, -18, 678, 650, -18, -18, 619, -18, + /* 0 */ 197, -1, -1, -1, -1, -1, 357, 87, 693, 463, + /* 10 */ 599, 685, -1, -1, -1, 627, -1, 484, -1, -1, + /* 20 */ -1, -1, -1, -1, 621, -1, -1, 486, -1, 453, + /* 30 */ -1, -1, -1, -1, 608, 609, -1, 612, -1, 620, + /* 40 */ -1, 470, -1, 658, -1, 659, -1, 644, -1, 513, + /* 50 */ -1, 635, -1, 611, -1, 605, -1, 600, -1, 571, + /* 60 */ -1, 566, -1, 660, -1, 575, -1, 634, -1, -1, + /* 70 */ 549, -1, 560, -1, -1, 389, 687, 375, -1, 245, + /* 80 */ 161, -1, 312, -1, -1, -1, -1, 628, -1, 243, + /* 90 */ -1, -1, 555, -1, -1, -1, -1, 475, 130, -1, + /* 100 */ -1, -1, 448, 370, -1, -1, -1, -1, -1, -1, + /* 110 */ -1, 360, -1, -1, 427, 689, 679, -1, 541, -1, + /* 120 */ 527, -1, -1, -1, -1, -1, 619, -1, 316, -1, + /* 130 */ -1, -1, -1, -1, 226, -1, -1, -1, 586, -1, + /* 140 */ -1, -1, -1, -1, 556, -1, -1, -1, -1, 552, + /* 150 */ 128, 640, -1, -1, 409, -1, 615, -1, -1, -1, + /* 160 */ 523, 354, -1, -1, -1, -1, 498, -1, -1, 563, + /* 170 */ -1, 564, -1, -1, -1, -1, -1, -1, -1, -1, + /* 180 */ -1, -1, -1, -1, -1, -1, 585, -1, -1, -1, + /* 190 */ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + /* 200 */ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + /* 210 */ -1, 203, -1, -1, -1, -1, -1, -1, -1, -1, + /* 220 */ -1, -1, -1, -1, -1, -1, -1, -1, 487, -1, + /* 230 */ -1, 327, -1, -1, -1, -1, -1, -1, 530, -1, + /* 240 */ -1, 481, -1, 302, -1, -1, -1, 655, -1, -1, + /* 250 */ 450, -1, -1, 426, -1, -1, 419, -1, -1, -1, + /* 260 */ 482, -1, -1, -1, 294, -1, -1, 577, -1, -1, + /* 270 */ -1, 618, 606, -1, 597, -1, 377, -1, 292, -1, + /* 280 */ 430, -1, -1, 169, -1, -1, -1, 680, 656, -1, + /* 290 */ -1, 244, -1, }; static PPACTIONTYPE pp_default[] = { - /* 0 */ 437, 437, 437, 437, 437, 437, 345, 354, 359, 347, - /* 10 */ 365, 361, 285, 437, 360, 437, 362, 437, 363, 368, - /* 20 */ 369, 370, 371, 372, 437, 364, 437, 437, 346, 437, - /* 30 */ 348, 350, 351, 352, 437, 437, 373, 437, 375, 437, - /* 40 */ 376, 437, 377, 437, 378, 437, 379, 437, 380, 437, - /* 50 */ 381, 437, 382, 437, 383, 437, 384, 437, 385, 437, - /* 60 */ 386, 437, 387, 437, 388, 437, 389, 437, 390, 437, - /* 70 */ 437, 391, 437, 392, 437, 437, 289, 437, 437, 437, - /* 80 */ 302, 300, 286, 299, 303, 305, 437, 312, 323, 309, - /* 90 */ 437, 322, 437, 400, 437, 418, 437, 419, 437, 420, - /* 100 */ 437, 437, 423, 437, 396, 437, 437, 437, 399, 437, - /* 110 */ 437, 437, 437, 437, 401, 437, 437, 437, 437, 437, - /* 120 */ 402, 437, 437, 437, 403, 404, 437, 437, 437, 406, - /* 130 */ 408, 436, 411, 437, 417, 437, 409, 437, 437, 414, - /* 140 */ 416, 437, 421, 437, 422, 424, 425, 426, 427, 428, - /* 150 */ 429, 430, 431, 432, 433, 434, 415, 410, 437, 435, - /* 160 */ 437, 407, 405, 437, 310, 311, 343, 436, 437, 437, - /* 170 */ 437, 437, 437, 437, 437, 437, 437, 437, 437, 437, - /* 180 */ 437, 437, 437, 437, 437, 304, 437, 297, 342, 437, - /* 190 */ 340, 341, 437, 301, 306, 308, 307, 298, 437, 290, - /* 200 */ 292, 436, 437, 293, 296, 437, 294, 295, 291, 287, - /* 210 */ 288, 437, 394, 437, 397, 437, 393, 437, 437, 437, - /* 220 */ 395, 437, 398, 374, 349, 437, 358, 437, 437, 353, - /* 230 */ 437, 355, 357, 356, 437, 344, 437, 437, 437, 437, - /* 240 */ 437, 437, 437, 437, 326, 328, 327, 437, 437, 437, - /* 250 */ 437, 437, 437, 437, 437, 329, 331, 330, 345, 437, - /* 260 */ 437, 437, 437, 437, 437, 437, 333, 437, 334, 437, - /* 270 */ 437, 336, 337, 335, 345, 437, 437, 437, 437, 339, + /* 0 */ 454, 454, 454, 454, 454, 454, 362, 371, 376, 364, + /* 10 */ 382, 378, 298, 454, 377, 454, 379, 454, 380, 385, + /* 20 */ 386, 387, 388, 389, 454, 381, 454, 454, 363, 454, + /* 30 */ 365, 367, 368, 369, 454, 454, 390, 454, 392, 454, + /* 40 */ 393, 454, 394, 454, 395, 454, 396, 454, 397, 454, + /* 50 */ 398, 454, 399, 454, 400, 454, 401, 454, 402, 454, + /* 60 */ 403, 454, 404, 454, 405, 454, 406, 454, 407, 454, + /* 70 */ 454, 408, 454, 409, 454, 454, 302, 454, 454, 454, + /* 80 */ 313, 299, 454, 310, 350, 454, 348, 454, 351, 454, + /* 90 */ 454, 352, 454, 357, 359, 358, 349, 454, 454, 454, + /* 100 */ 353, 354, 454, 454, 454, 355, 356, 360, 453, 454, + /* 110 */ 452, 312, 314, 316, 454, 320, 331, 317, 454, 330, + /* 120 */ 454, 417, 454, 435, 454, 436, 454, 437, 454, 454, + /* 130 */ 440, 454, 413, 454, 454, 454, 416, 454, 454, 454, + /* 140 */ 454, 454, 418, 454, 454, 454, 454, 454, 419, 454, + /* 150 */ 454, 454, 420, 421, 454, 454, 454, 423, 425, 453, + /* 160 */ 428, 454, 434, 454, 426, 454, 454, 431, 433, 454, + /* 170 */ 438, 454, 439, 441, 442, 443, 444, 445, 446, 447, + /* 180 */ 448, 449, 450, 451, 432, 427, 454, 424, 422, 454, + /* 190 */ 318, 319, 454, 454, 454, 454, 454, 454, 454, 454, + /* 200 */ 454, 454, 454, 454, 454, 454, 454, 454, 454, 315, + /* 210 */ 311, 454, 303, 305, 453, 454, 306, 309, 454, 307, + /* 220 */ 308, 304, 300, 301, 454, 411, 454, 414, 454, 410, + /* 230 */ 454, 454, 454, 412, 454, 415, 391, 366, 454, 375, + /* 240 */ 454, 454, 370, 454, 372, 374, 373, 454, 361, 454, + /* 250 */ 454, 454, 454, 454, 454, 454, 454, 334, 336, 335, + /* 260 */ 454, 454, 454, 454, 454, 454, 454, 454, 337, 339, + /* 270 */ 338, 362, 454, 454, 454, 454, 454, 454, 454, 341, + /* 280 */ 454, 342, 454, 454, 344, 345, 343, 362, 454, 454, + /* 290 */ 454, 454, 347, }; #define PP_SZ_ACTTAB (sizeof(pp_action)/sizeof(pp_action[0])) @@ -101972,11 +102649,11 @@ static const char *ppTokenName[] = { "MINUS", "IS", "IN", "NOT", "BITWISE_NOT", "COMMA", "SELECT", "FROM", "DISTINCT", "ALL", "IDENTIFIER", "DOT", - "AS", "WITH", "INNER", "JOIN", - "CROSS", "LEFT", "OUTER", "RIGHT", - "FULL", "ON", "INSERT", "INTO", - "VALUES", "PARENTHESES_OPEN", "PARENTHESES_CLOSE", "UPDATE", - "SET", "DELETE", "WHERE", "ORDER", + "AS", "INNER", "JOIN", "CROSS", + "LEFT", "OUTER", "RIGHT", "FULL", + "ON", "INSERT", "INTO", "VALUES", + "PARENTHESES_OPEN", "PARENTHESES_CLOSE", "UPDATE", "SET", + "DELETE", "WITH", "WHERE", "ORDER", "BY", "ASC", "DESC", "GROUP", "HAVING", "FOR", "LIMIT", "OFFSET", "INTEGER", "HINTEGER", "NPLACEHOLDER", "SPLACEHOLDER", @@ -101988,16 +102665,16 @@ static const char *ppTokenName[] = { "update_statement", "delete_statement", "select_clause", "where_clause", "group_clause", "having_clause", "order_clause", "select_limit_clause", "for_update_clause", "distinct_all", "column_list", "associated_name_list", - "with_list_or_null", "join_list_or_null", "column_item", "expr", - "associated_name", "join_list", "with_list", "join_item", - "join_clause", "with_item", "join_type", "aliased_or_qualified_name", - "join_associated_name", "join_conditions", "values_list", "field_list", - "value_list", "value_item", "field_item", "update_clause", - "limit_clause", "update_item_list", "update_item", "qualified_name", - "new_value", "delete_clause", "order_list", "order_item", - "group_list", "group_item", "integer_or_placeholder", "argument_list", - "when_clauses", "when_clause", "function_call", "distinct_or_null", - "argument_list_or_null", "argument_item", + "join_list_or_null", "column_item", "expr", "associated_name", + "join_list", "join_item", "join_clause", "join_type", + "aliased_or_qualified_name", "join_associated_name", "join_conditions", "values_list", + "field_list", "value_list", "value_item", "field_item", + "update_clause", "limit_clause", "update_item_list", "update_item", + "qualified_name", "new_value", "delete_clause", "with_item", + "with_list", "order_list", "order_item", "group_list", + "group_item", "integer_or_placeholder", "argument_list", "when_clauses", + "when_clause", "function_call", "distinct_or_null", "argument_list_or_null", + "argument_item", }; #endif /* NDEBUG */ @@ -102011,7 +102688,7 @@ static const char *ppRuleName[] = { /* 3 */ "query_language ::= update_statement", /* 4 */ "query_language ::= delete_statement", /* 5 */ "select_statement ::= select_clause where_clause group_clause having_clause order_clause select_limit_clause for_update_clause", - /* 6 */ "select_clause ::= SELECT distinct_all column_list FROM associated_name_list with_list_or_null join_list_or_null", + /* 6 */ "select_clause ::= SELECT distinct_all column_list FROM associated_name_list join_list_or_null", /* 7 */ "distinct_all ::= DISTINCT", /* 8 */ "distinct_all ::= ALL", /* 9 */ "distinct_all ::=", @@ -102026,142 +102703,146 @@ static const char *ppRuleName[] = { /* 18 */ "associated_name_list ::= associated_name", /* 19 */ "join_list_or_null ::= join_list", /* 20 */ "join_list_or_null ::=", - /* 21 */ "with_list_or_null ::= WITH with_list", - /* 22 */ "with_list_or_null ::=", - /* 23 */ "join_list ::= join_list join_item", - /* 24 */ "join_list ::= join_item", - /* 25 */ "join_item ::= join_clause", - /* 26 */ "with_list ::= with_list with_item", - /* 27 */ "with_list ::= with_item", - /* 28 */ "with_item ::= IDENTIFIER", - /* 29 */ "join_clause ::= join_type aliased_or_qualified_name join_associated_name join_conditions", - /* 30 */ "join_associated_name ::= AS IDENTIFIER", - /* 31 */ "join_associated_name ::= IDENTIFIER", - /* 32 */ "join_associated_name ::=", - /* 33 */ "join_type ::= INNER JOIN", - /* 34 */ "join_type ::= CROSS JOIN", - /* 35 */ "join_type ::= LEFT OUTER JOIN", - /* 36 */ "join_type ::= LEFT JOIN", - /* 37 */ "join_type ::= RIGHT OUTER JOIN", - /* 38 */ "join_type ::= RIGHT JOIN", - /* 39 */ "join_type ::= FULL OUTER JOIN", - /* 40 */ "join_type ::= FULL JOIN", - /* 41 */ "join_type ::= JOIN", - /* 42 */ "join_conditions ::= ON expr", - /* 43 */ "join_conditions ::=", - /* 44 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", - /* 45 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name PARENTHESES_OPEN field_list PARENTHESES_CLOSE VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", - /* 46 */ "values_list ::= values_list COMMA value_item", - /* 47 */ "values_list ::= value_item", - /* 48 */ "value_item ::= expr", - /* 49 */ "field_list ::= field_list COMMA field_item", - /* 50 */ "field_list ::= field_item", - /* 51 */ "field_item ::= IDENTIFIER", - /* 52 */ "update_statement ::= update_clause where_clause limit_clause", - /* 53 */ "update_clause ::= UPDATE associated_name SET update_item_list", - /* 54 */ "update_item_list ::= update_item_list COMMA update_item", - /* 55 */ "update_item_list ::= update_item", - /* 56 */ "update_item ::= qualified_name EQUALS new_value", - /* 57 */ "new_value ::= expr", - /* 58 */ "delete_statement ::= delete_clause where_clause limit_clause", - /* 59 */ "delete_clause ::= DELETE FROM associated_name", - /* 60 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER", - /* 61 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER", - /* 62 */ "associated_name ::= aliased_or_qualified_name", - /* 63 */ "aliased_or_qualified_name ::= qualified_name", - /* 64 */ "where_clause ::= WHERE expr", - /* 65 */ "where_clause ::=", - /* 66 */ "order_clause ::= ORDER BY order_list", - /* 67 */ "order_clause ::=", - /* 68 */ "order_list ::= order_list COMMA order_item", - /* 69 */ "order_list ::= order_item", - /* 70 */ "order_item ::= expr", - /* 71 */ "order_item ::= expr ASC", - /* 72 */ "order_item ::= expr DESC", - /* 73 */ "group_clause ::= GROUP BY group_list", - /* 74 */ "group_clause ::=", - /* 75 */ "group_list ::= group_list COMMA group_item", - /* 76 */ "group_list ::= group_item", - /* 77 */ "group_item ::= expr", - /* 78 */ "having_clause ::= HAVING expr", - /* 79 */ "having_clause ::=", - /* 80 */ "for_update_clause ::= FOR UPDATE", - /* 81 */ "for_update_clause ::=", - /* 82 */ "select_limit_clause ::= LIMIT integer_or_placeholder", - /* 83 */ "select_limit_clause ::= LIMIT integer_or_placeholder COMMA integer_or_placeholder", - /* 84 */ "select_limit_clause ::= LIMIT integer_or_placeholder OFFSET integer_or_placeholder", - /* 85 */ "select_limit_clause ::=", - /* 86 */ "limit_clause ::= LIMIT integer_or_placeholder", - /* 87 */ "limit_clause ::=", - /* 88 */ "integer_or_placeholder ::= INTEGER", - /* 89 */ "integer_or_placeholder ::= HINTEGER", - /* 90 */ "integer_or_placeholder ::= NPLACEHOLDER", - /* 91 */ "integer_or_placeholder ::= SPLACEHOLDER", - /* 92 */ "integer_or_placeholder ::= BPLACEHOLDER", - /* 93 */ "expr ::= MINUS expr", - /* 94 */ "expr ::= expr MINUS expr", - /* 95 */ "expr ::= expr PLUS expr", - /* 96 */ "expr ::= expr TIMES expr", - /* 97 */ "expr ::= expr DIVIDE expr", - /* 98 */ "expr ::= expr MOD expr", - /* 99 */ "expr ::= expr AND expr", - /* 100 */ "expr ::= expr OR expr", - /* 101 */ "expr ::= expr BITWISE_AND expr", - /* 102 */ "expr ::= expr BITWISE_OR expr", - /* 103 */ "expr ::= expr BITWISE_XOR expr", - /* 104 */ "expr ::= expr EQUALS expr", - /* 105 */ "expr ::= expr NOTEQUALS expr", - /* 106 */ "expr ::= expr LESS expr", - /* 107 */ "expr ::= expr GREATER expr", - /* 108 */ "expr ::= expr GREATEREQUAL expr", - /* 109 */ "expr ::= expr LESSEQUAL expr", - /* 110 */ "expr ::= expr LIKE expr", - /* 111 */ "expr ::= expr NOT LIKE expr", - /* 112 */ "expr ::= expr ILIKE expr", - /* 113 */ "expr ::= expr NOT ILIKE expr", - /* 114 */ "expr ::= expr IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", - /* 115 */ "expr ::= expr NOT IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", - /* 116 */ "expr ::= PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 117 */ "expr ::= expr IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 118 */ "expr ::= expr NOT IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 119 */ "expr ::= EXISTS PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 120 */ "expr ::= expr AGAINST expr", - /* 121 */ "expr ::= CAST PARENTHESES_OPEN expr AS IDENTIFIER PARENTHESES_CLOSE", - /* 122 */ "expr ::= CONVERT PARENTHESES_OPEN expr USING IDENTIFIER PARENTHESES_CLOSE", - /* 123 */ "expr ::= CASE expr when_clauses END", - /* 124 */ "when_clauses ::= when_clauses when_clause", - /* 125 */ "when_clauses ::= when_clause", - /* 126 */ "when_clause ::= WHEN expr THEN expr", - /* 127 */ "when_clause ::= ELSE expr", - /* 128 */ "expr ::= function_call", - /* 129 */ "function_call ::= IDENTIFIER PARENTHESES_OPEN distinct_or_null argument_list_or_null PARENTHESES_CLOSE", - /* 130 */ "distinct_or_null ::= DISTINCT", - /* 131 */ "distinct_or_null ::=", - /* 132 */ "argument_list_or_null ::= argument_list", - /* 133 */ "argument_list_or_null ::=", - /* 134 */ "argument_list ::= argument_list COMMA argument_item", - /* 135 */ "argument_list ::= argument_item", - /* 136 */ "argument_item ::= TIMES", - /* 137 */ "argument_item ::= expr", - /* 138 */ "expr ::= expr IS NULL", - /* 139 */ "expr ::= expr IS NOT NULL", - /* 140 */ "expr ::= expr BETWEEN expr", - /* 141 */ "expr ::= NOT expr", - /* 142 */ "expr ::= BITWISE_NOT expr", - /* 143 */ "expr ::= PARENTHESES_OPEN expr PARENTHESES_CLOSE", - /* 144 */ "expr ::= qualified_name", - /* 145 */ "expr ::= INTEGER", - /* 146 */ "expr ::= HINTEGER", - /* 147 */ "expr ::= STRING", - /* 148 */ "expr ::= DOUBLE", - /* 149 */ "expr ::= NULL", - /* 150 */ "expr ::= TRUE", - /* 151 */ "expr ::= FALSE", - /* 152 */ "expr ::= NPLACEHOLDER", - /* 153 */ "expr ::= SPLACEHOLDER", - /* 154 */ "expr ::= BPLACEHOLDER", - /* 155 */ "qualified_name ::= IDENTIFIER DOT IDENTIFIER", - /* 156 */ "qualified_name ::= IDENTIFIER", + /* 21 */ "join_list ::= join_list join_item", + /* 22 */ "join_list ::= join_item", + /* 23 */ "join_item ::= join_clause", + /* 24 */ "join_clause ::= join_type aliased_or_qualified_name join_associated_name join_conditions", + /* 25 */ "join_associated_name ::= AS IDENTIFIER", + /* 26 */ "join_associated_name ::= IDENTIFIER", + /* 27 */ "join_associated_name ::=", + /* 28 */ "join_type ::= INNER JOIN", + /* 29 */ "join_type ::= CROSS JOIN", + /* 30 */ "join_type ::= LEFT OUTER JOIN", + /* 31 */ "join_type ::= LEFT JOIN", + /* 32 */ "join_type ::= RIGHT OUTER JOIN", + /* 33 */ "join_type ::= RIGHT JOIN", + /* 34 */ "join_type ::= FULL OUTER JOIN", + /* 35 */ "join_type ::= FULL JOIN", + /* 36 */ "join_type ::= JOIN", + /* 37 */ "join_conditions ::= ON expr", + /* 38 */ "join_conditions ::=", + /* 39 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", + /* 40 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name PARENTHESES_OPEN field_list PARENTHESES_CLOSE VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", + /* 41 */ "values_list ::= values_list COMMA value_item", + /* 42 */ "values_list ::= value_item", + /* 43 */ "value_item ::= expr", + /* 44 */ "field_list ::= field_list COMMA field_item", + /* 45 */ "field_list ::= field_item", + /* 46 */ "field_item ::= IDENTIFIER", + /* 47 */ "update_statement ::= update_clause where_clause limit_clause", + /* 48 */ "update_clause ::= UPDATE associated_name SET update_item_list", + /* 49 */ "update_item_list ::= update_item_list COMMA update_item", + /* 50 */ "update_item_list ::= update_item", + /* 51 */ "update_item ::= qualified_name EQUALS new_value", + /* 52 */ "new_value ::= expr", + /* 53 */ "delete_statement ::= delete_clause where_clause limit_clause", + /* 54 */ "delete_clause ::= DELETE FROM associated_name", + /* 55 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER", + /* 56 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER", + /* 57 */ "associated_name ::= aliased_or_qualified_name", + /* 58 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER WITH with_item", + /* 59 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER WITH PARENTHESES_OPEN with_list PARENTHESES_CLOSE", + /* 60 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER WITH PARENTHESES_OPEN with_list PARENTHESES_CLOSE", + /* 61 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER WITH with_item", + /* 62 */ "associated_name ::= aliased_or_qualified_name WITH PARENTHESES_OPEN with_list PARENTHESES_CLOSE", + /* 63 */ "associated_name ::= aliased_or_qualified_name WITH with_item", + /* 64 */ "with_list ::= with_list COMMA with_item", + /* 65 */ "with_list ::= with_item", + /* 66 */ "with_item ::= IDENTIFIER", + /* 67 */ "aliased_or_qualified_name ::= qualified_name", + /* 68 */ "where_clause ::= WHERE expr", + /* 69 */ "where_clause ::=", + /* 70 */ "order_clause ::= ORDER BY order_list", + /* 71 */ "order_clause ::=", + /* 72 */ "order_list ::= order_list COMMA order_item", + /* 73 */ "order_list ::= order_item", + /* 74 */ "order_item ::= expr", + /* 75 */ "order_item ::= expr ASC", + /* 76 */ "order_item ::= expr DESC", + /* 77 */ "group_clause ::= GROUP BY group_list", + /* 78 */ "group_clause ::=", + /* 79 */ "group_list ::= group_list COMMA group_item", + /* 80 */ "group_list ::= group_item", + /* 81 */ "group_item ::= expr", + /* 82 */ "having_clause ::= HAVING expr", + /* 83 */ "having_clause ::=", + /* 84 */ "for_update_clause ::= FOR UPDATE", + /* 85 */ "for_update_clause ::=", + /* 86 */ "select_limit_clause ::= LIMIT integer_or_placeholder", + /* 87 */ "select_limit_clause ::= LIMIT integer_or_placeholder COMMA integer_or_placeholder", + /* 88 */ "select_limit_clause ::= LIMIT integer_or_placeholder OFFSET integer_or_placeholder", + /* 89 */ "select_limit_clause ::=", + /* 90 */ "limit_clause ::= LIMIT integer_or_placeholder", + /* 91 */ "limit_clause ::=", + /* 92 */ "integer_or_placeholder ::= INTEGER", + /* 93 */ "integer_or_placeholder ::= HINTEGER", + /* 94 */ "integer_or_placeholder ::= NPLACEHOLDER", + /* 95 */ "integer_or_placeholder ::= SPLACEHOLDER", + /* 96 */ "integer_or_placeholder ::= BPLACEHOLDER", + /* 97 */ "expr ::= MINUS expr", + /* 98 */ "expr ::= expr MINUS expr", + /* 99 */ "expr ::= expr PLUS expr", + /* 100 */ "expr ::= expr TIMES expr", + /* 101 */ "expr ::= expr DIVIDE expr", + /* 102 */ "expr ::= expr MOD expr", + /* 103 */ "expr ::= expr AND expr", + /* 104 */ "expr ::= expr OR expr", + /* 105 */ "expr ::= expr BITWISE_AND expr", + /* 106 */ "expr ::= expr BITWISE_OR expr", + /* 107 */ "expr ::= expr BITWISE_XOR expr", + /* 108 */ "expr ::= expr EQUALS expr", + /* 109 */ "expr ::= expr NOTEQUALS expr", + /* 110 */ "expr ::= expr LESS expr", + /* 111 */ "expr ::= expr GREATER expr", + /* 112 */ "expr ::= expr GREATEREQUAL expr", + /* 113 */ "expr ::= expr LESSEQUAL expr", + /* 114 */ "expr ::= expr LIKE expr", + /* 115 */ "expr ::= expr NOT LIKE expr", + /* 116 */ "expr ::= expr ILIKE expr", + /* 117 */ "expr ::= expr NOT ILIKE expr", + /* 118 */ "expr ::= expr IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", + /* 119 */ "expr ::= expr NOT IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", + /* 120 */ "expr ::= PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 121 */ "expr ::= expr IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 122 */ "expr ::= expr NOT IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 123 */ "expr ::= EXISTS PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 124 */ "expr ::= expr AGAINST expr", + /* 125 */ "expr ::= CAST PARENTHESES_OPEN expr AS IDENTIFIER PARENTHESES_CLOSE", + /* 126 */ "expr ::= CONVERT PARENTHESES_OPEN expr USING IDENTIFIER PARENTHESES_CLOSE", + /* 127 */ "expr ::= CASE expr when_clauses END", + /* 128 */ "when_clauses ::= when_clauses when_clause", + /* 129 */ "when_clauses ::= when_clause", + /* 130 */ "when_clause ::= WHEN expr THEN expr", + /* 131 */ "when_clause ::= ELSE expr", + /* 132 */ "expr ::= function_call", + /* 133 */ "function_call ::= IDENTIFIER PARENTHESES_OPEN distinct_or_null argument_list_or_null PARENTHESES_CLOSE", + /* 134 */ "distinct_or_null ::= DISTINCT", + /* 135 */ "distinct_or_null ::=", + /* 136 */ "argument_list_or_null ::= argument_list", + /* 137 */ "argument_list_or_null ::=", + /* 138 */ "argument_list ::= argument_list COMMA argument_item", + /* 139 */ "argument_list ::= argument_item", + /* 140 */ "argument_item ::= TIMES", + /* 141 */ "argument_item ::= expr", + /* 142 */ "expr ::= expr IS NULL", + /* 143 */ "expr ::= expr IS NOT NULL", + /* 144 */ "expr ::= expr BETWEEN expr", + /* 145 */ "expr ::= NOT expr", + /* 146 */ "expr ::= BITWISE_NOT expr", + /* 147 */ "expr ::= PARENTHESES_OPEN expr PARENTHESES_CLOSE", + /* 148 */ "expr ::= qualified_name", + /* 149 */ "expr ::= INTEGER", + /* 150 */ "expr ::= HINTEGER", + /* 151 */ "expr ::= STRING", + /* 152 */ "expr ::= DOUBLE", + /* 153 */ "expr ::= NULL", + /* 154 */ "expr ::= TRUE", + /* 155 */ "expr ::= FALSE", + /* 156 */ "expr ::= NPLACEHOLDER", + /* 157 */ "expr ::= SPLACEHOLDER", + /* 158 */ "expr ::= BPLACEHOLDER", + /* 159 */ "qualified_name ::= IDENTIFIER DOT IDENTIFIER", + /* 160 */ "qualified_name ::= IDENTIFIER", }; #endif /* NDEBUG */ @@ -102281,7 +102962,7 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 76: case 77: case 78: -// 557 "parser.lemon" +// 558 "parser.lemon" { if ((pppminor->pp0)) { if ((pppminor->pp0)->free_flag) { @@ -102290,7 +102971,7 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ efree((pppminor->pp0)); } } -// 1253 "parser.c" +// 1270 "parser.c" break; case 81: case 82: @@ -102300,6 +102981,7 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 86: case 94: case 95: + case 97: case 98: case 99: case 100: @@ -102307,27 +102989,26 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 102: case 103: case 104: - case 105: - case 106: - case 107: + case 108: + case 109: case 111: case 112: case 114: case 115: - case 117: + case 116: case 118: case 119: + case 120: case 121: case 122: case 123: case 124: - case 125: - case 127: - case 130: - case 133: -// 570 "parser.lemon" -{ zval_ptr_dtor(&(pppminor->pp244)); } -// 1290 "parser.c" + case 126: + case 129: + case 132: +// 571 "parser.lemon" +{ zval_ptr_dtor(&(pppminor->pp162)); } +// 1307 "parser.c" break; case 87: case 88: @@ -102336,14 +103017,14 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 91: case 92: case 93: - case 108: - case 109: - case 116: + case 105: + case 106: + case 113: + case 130: case 131: - case 132: -// 882 "parser.lemon" -{ zephir_safe_zval_ptr_dtor((pppminor->pp244)); } -// 1306 "parser.c" +// 899 "parser.lemon" +{ zephir_safe_zval_ptr_dtor((pppminor->pp162)); } +// 1323 "parser.c" break; default: break; /* If no destructor action specified: do nothing */ } @@ -102486,78 +103167,82 @@ static struct { { 81, 1 }, { 81, 1 }, { 82, 7 }, - { 86, 7 }, + { 86, 6 }, { 93, 1 }, { 93, 1 }, { 93, 0 }, { 94, 3 }, { 94, 1 }, - { 98, 1 }, - { 98, 3 }, - { 98, 3 }, - { 98, 2 }, - { 98, 1 }, + { 97, 1 }, + { 97, 3 }, + { 97, 3 }, + { 97, 2 }, + { 97, 1 }, { 95, 3 }, { 95, 1 }, - { 97, 1 }, - { 97, 0 }, - { 96, 2 }, + { 96, 1 }, { 96, 0 }, - { 101, 2 }, + { 100, 2 }, + { 100, 1 }, { 101, 1 }, - { 103, 1 }, - { 102, 2 }, - { 102, 1 }, + { 102, 4 }, + { 105, 2 }, { 105, 1 }, - { 104, 4 }, - { 108, 2 }, - { 108, 1 }, - { 108, 0 }, - { 106, 2 }, - { 106, 2 }, - { 106, 3 }, - { 106, 2 }, - { 106, 3 }, - { 106, 2 }, - { 106, 3 }, + { 105, 0 }, + { 103, 2 }, + { 103, 2 }, + { 103, 3 }, + { 103, 2 }, + { 103, 3 }, + { 103, 2 }, + { 103, 3 }, + { 103, 2 }, + { 103, 1 }, { 106, 2 }, - { 106, 1 }, - { 109, 2 }, - { 109, 0 }, + { 106, 0 }, { 83, 7 }, { 83, 10 }, - { 110, 3 }, + { 107, 3 }, + { 107, 1 }, { 110, 1 }, - { 113, 1 }, - { 111, 3 }, + { 108, 3 }, + { 108, 1 }, { 111, 1 }, - { 114, 1 }, { 84, 3 }, - { 115, 4 }, - { 117, 3 }, + { 112, 4 }, + { 114, 3 }, + { 114, 1 }, + { 115, 3 }, { 117, 1 }, + { 85, 3 }, { 118, 3 }, + { 99, 3 }, + { 99, 2 }, + { 99, 1 }, + { 99, 5 }, + { 99, 7 }, + { 99, 6 }, + { 99, 4 }, + { 99, 5 }, + { 99, 3 }, + { 120, 3 }, { 120, 1 }, - { 85, 3 }, - { 121, 3 }, - { 100, 3 }, - { 100, 2 }, - { 100, 1 }, - { 107, 1 }, + { 119, 1 }, + { 104, 1 }, { 87, 2 }, { 87, 0 }, { 90, 3 }, { 90, 0 }, - { 122, 3 }, + { 121, 3 }, + { 121, 1 }, { 122, 1 }, - { 123, 1 }, - { 123, 2 }, - { 123, 2 }, + { 122, 2 }, + { 122, 2 }, { 88, 3 }, { 88, 0 }, - { 124, 3 }, + { 123, 3 }, + { 123, 1 }, { 124, 1 }, - { 125, 1 }, { 89, 2 }, { 89, 0 }, { 92, 2 }, @@ -102566,77 +103251,77 @@ static struct { { 91, 4 }, { 91, 4 }, { 91, 0 }, - { 116, 2 }, - { 116, 0 }, - { 126, 1 }, - { 126, 1 }, - { 126, 1 }, - { 126, 1 }, - { 126, 1 }, - { 99, 2 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 4 }, - { 99, 3 }, - { 99, 4 }, - { 99, 5 }, - { 99, 6 }, - { 99, 3 }, - { 99, 5 }, - { 99, 6 }, - { 99, 4 }, - { 99, 3 }, - { 99, 6 }, - { 99, 6 }, - { 99, 4 }, + { 113, 2 }, + { 113, 0 }, + { 125, 1 }, + { 125, 1 }, + { 125, 1 }, + { 125, 1 }, + { 125, 1 }, + { 98, 2 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 4 }, + { 98, 3 }, + { 98, 4 }, + { 98, 5 }, + { 98, 6 }, + { 98, 3 }, + { 98, 5 }, + { 98, 6 }, + { 98, 4 }, + { 98, 3 }, + { 98, 6 }, + { 98, 6 }, + { 98, 4 }, + { 127, 2 }, + { 127, 1 }, + { 128, 4 }, { 128, 2 }, - { 128, 1 }, - { 129, 4 }, - { 129, 2 }, - { 99, 1 }, - { 130, 5 }, + { 98, 1 }, + { 129, 5 }, + { 130, 1 }, + { 130, 0 }, { 131, 1 }, { 131, 0 }, + { 126, 3 }, + { 126, 1 }, { 132, 1 }, - { 132, 0 }, - { 127, 3 }, - { 127, 1 }, - { 133, 1 }, - { 133, 1 }, - { 99, 3 }, - { 99, 4 }, - { 99, 3 }, - { 99, 2 }, - { 99, 2 }, - { 99, 3 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 119, 3 }, - { 119, 1 }, + { 132, 1 }, + { 98, 3 }, + { 98, 4 }, + { 98, 3 }, + { 98, 2 }, + { 98, 2 }, + { 98, 3 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 116, 3 }, + { 116, 1 }, }; static void pp_accept(ppParser*); /* Forward Declaration */ @@ -102670,11 +103355,11 @@ static void pp_reduce( ** break; */ case 0: -// 566 "parser.lemon" +// 567 "parser.lemon" { - status->ret = ppmsp[0].minor.pp244; + status->ret = ppmsp[0].minor.pp162; } -// 1680 "parser.c" +// 1701 "parser.c" break; case 1: case 2: @@ -102682,880 +103367,927 @@ static void pp_reduce( case 4: case 18: case 19: - case 24: - case 25: - case 27: - case 48: - case 55: - case 57: - case 63: - case 69: - case 76: - case 77: - case 128: + case 22: + case 23: + case 43: + case 50: + case 52: + case 65: + case 67: + case 73: + case 80: + case 81: case 132: - case 137: - case 144: -// 572 "parser.lemon" + case 136: + case 141: + case 148: +// 573 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; } -// 1706 "parser.c" +// 1727 "parser.c" break; case 5: -// 590 "parser.lemon" +// 591 "parser.lemon" { - ppgotominor.pp244 = phql_ret_select_statement(ppmsp[-6].minor.pp244, ppmsp[-5].minor.pp244, ppmsp[-2].minor.pp244, ppmsp[-4].minor.pp244, ppmsp[-3].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_select_statement(ppmsp[-6].minor.pp162, ppmsp[-5].minor.pp162, ppmsp[-2].minor.pp162, ppmsp[-4].minor.pp162, ppmsp[-3].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1713 "parser.c" +// 1734 "parser.c" break; case 6: -// 596 "parser.lemon" +// 597 "parser.lemon" { - ppgotominor.pp244 = phql_ret_select_clause(ppmsp[-5].minor.pp244, ppmsp[-4].minor.pp244, ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); - pp_destructor(26,&ppmsp[-6].minor); - pp_destructor(27,&ppmsp[-3].minor); + ppgotominor.pp162 = phql_ret_select_clause(ppmsp[-4].minor.pp162, ppmsp[-3].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); + pp_destructor(26,&ppmsp[-5].minor); + pp_destructor(27,&ppmsp[-2].minor); } -// 1722 "parser.c" +// 1743 "parser.c" break; case 7: -// 602 "parser.lemon" +// 603 "parser.lemon" { - ppgotominor.pp244 = phql_ret_distinct_all(1); + ppgotominor.pp162 = phql_ret_distinct_all(1); pp_destructor(28,&ppmsp[0].minor); } -// 1730 "parser.c" +// 1751 "parser.c" break; case 8: -// 606 "parser.lemon" +// 607 "parser.lemon" { - ppgotominor.pp244 = phql_ret_distinct_all(0); + ppgotominor.pp162 = phql_ret_distinct_all(0); pp_destructor(29,&ppmsp[0].minor); } -// 1738 "parser.c" +// 1759 "parser.c" break; case 9: case 20: - case 22: - case 32: - case 43: - case 65: - case 67: - case 74: - case 79: - case 81: + case 27: + case 38: + case 69: + case 71: + case 78: + case 83: case 85: - case 87: - case 131: - case 133: -// 610 "parser.lemon" + case 89: + case 91: + case 135: + case 137: +// 611 "parser.lemon" { - ppgotominor.pp244 = NULL; + ppgotominor.pp162 = NULL; } -// 1758 "parser.c" +// 1778 "parser.c" break; case 10: case 17: - case 46: + case 41: + case 44: case 49: - case 54: - case 68: - case 75: - case 134: -// 616 "parser.lemon" + case 64: + case 72: + case 79: + case 138: +// 617 "parser.lemon" { - ppgotominor.pp244 = phql_ret_zval_list(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_zval_list(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(25,&ppmsp[-1].minor); } -// 1773 "parser.c" +// 1794 "parser.c" break; case 11: - case 47: - case 50: - case 125: - case 135: -// 620 "parser.lemon" + case 42: + case 45: + case 129: + case 139: +// 621 "parser.lemon" { - ppgotominor.pp244 = phql_ret_zval_list(ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_zval_list(ppmsp[0].minor.pp162, NULL); } -// 1784 "parser.c" +// 1805 "parser.c" break; case 12: - case 136: -// 626 "parser.lemon" + case 140: +// 627 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_STARALL, NULL, NULL, NULL); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_STARALL, NULL, NULL, NULL); pp_destructor(17,&ppmsp[0].minor); } -// 1793 "parser.c" +// 1814 "parser.c" break; case 13: -// 630 "parser.lemon" +// 631 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_DOMAINALL, NULL, ppmsp[-2].minor.pp0, NULL); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_DOMAINALL, NULL, ppmsp[-2].minor.pp0, NULL); pp_destructor(31,&ppmsp[-1].minor); pp_destructor(17,&ppmsp[0].minor); } -// 1802 "parser.c" +// 1823 "parser.c" break; case 14: -// 634 "parser.lemon" +// 635 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-2].minor.pp244, NULL, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-2].minor.pp162, NULL, ppmsp[0].minor.pp0); pp_destructor(32,&ppmsp[-1].minor); } -// 1810 "parser.c" +// 1831 "parser.c" break; case 15: -// 638 "parser.lemon" +// 639 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-1].minor.pp244, NULL, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-1].minor.pp162, NULL, ppmsp[0].minor.pp0); } -// 1817 "parser.c" +// 1838 "parser.c" break; case 16: -// 642 "parser.lemon" +// 643 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[0].minor.pp244, NULL, NULL); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[0].minor.pp162, NULL, NULL); } -// 1824 "parser.c" +// 1845 "parser.c" break; case 21: -// 664 "parser.lemon" + case 128: +// 667 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; - pp_destructor(33,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_zval_list(ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1832 "parser.c" +// 1853 "parser.c" + break; + case 24: +// 684 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_join_item(ppmsp[-3].minor.pp162, ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); +} +// 1860 "parser.c" + break; + case 25: +// 690 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); + pp_destructor(32,&ppmsp[-1].minor); +} +// 1868 "parser.c" break; - case 23: case 26: - case 124: -// 674 "parser.lemon" + case 46: + case 66: + case 160: +// 694 "parser.lemon" { - ppgotominor.pp244 = phql_ret_zval_list(ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); } -// 1841 "parser.c" +// 1878 "parser.c" break; case 28: - case 31: - case 51: - case 156: -// 700 "parser.lemon" +// 704 "parser.lemon" { - ppgotominor.pp244 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_INNERJOIN); + pp_destructor(33,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1851 "parser.c" +// 1887 "parser.c" break; case 29: -// 707 "parser.lemon" +// 708 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_item(ppmsp[-3].minor.pp244, ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_CROSSJOIN); + pp_destructor(35,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1858 "parser.c" +// 1896 "parser.c" break; case 30: -// 713 "parser.lemon" +// 712 "parser.lemon" { - ppgotominor.pp244 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); - pp_destructor(32,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_LEFTJOIN); + pp_destructor(36,&ppmsp[-2].minor); + pp_destructor(37,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1866 "parser.c" +// 1906 "parser.c" break; - case 33: -// 727 "parser.lemon" + case 31: +// 716 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_INNERJOIN); - pp_destructor(34,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_LEFTJOIN); + pp_destructor(36,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1875 "parser.c" +// 1915 "parser.c" break; - case 34: -// 731 "parser.lemon" + case 32: +// 720 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_CROSSJOIN); - pp_destructor(36,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_RIGHTJOIN); + pp_destructor(38,&ppmsp[-2].minor); + pp_destructor(37,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1884 "parser.c" +// 1925 "parser.c" break; - case 35: -// 735 "parser.lemon" + case 33: +// 724 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_LEFTJOIN); - pp_destructor(37,&ppmsp[-2].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_RIGHTJOIN); pp_destructor(38,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1894 "parser.c" +// 1934 "parser.c" break; - case 36: -// 739 "parser.lemon" + case 34: +// 728 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_LEFTJOIN); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_FULLJOIN); + pp_destructor(39,&ppmsp[-2].minor); pp_destructor(37,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1903 "parser.c" +// 1944 "parser.c" break; - case 37: -// 743 "parser.lemon" + case 35: +// 732 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_RIGHTJOIN); - pp_destructor(39,&ppmsp[-2].minor); - pp_destructor(38,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_FULLJOIN); + pp_destructor(39,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1913 "parser.c" +// 1953 "parser.c" break; - case 38: -// 747 "parser.lemon" + case 36: +// 736 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_RIGHTJOIN); - pp_destructor(39,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_INNERJOIN); + pp_destructor(34,&ppmsp[0].minor); } -// 1922 "parser.c" +// 1961 "parser.c" break; - case 39: -// 751 "parser.lemon" + case 37: +// 742 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_FULLJOIN); - pp_destructor(40,&ppmsp[-2].minor); - pp_destructor(38,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = ppmsp[0].minor.pp162; + pp_destructor(40,&ppmsp[-1].minor); } -// 1932 "parser.c" +// 1969 "parser.c" + break; + case 39: +// 753 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_insert_statement(ppmsp[-4].minor.pp162, NULL, ppmsp[-1].minor.pp162); + pp_destructor(41,&ppmsp[-6].minor); + pp_destructor(42,&ppmsp[-5].minor); + pp_destructor(43,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); +} +// 1981 "parser.c" break; case 40: -// 755 "parser.lemon" +// 757 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_FULLJOIN); - pp_destructor(40,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_insert_statement(ppmsp[-7].minor.pp162, ppmsp[-5].minor.pp162, ppmsp[-1].minor.pp162); + pp_destructor(41,&ppmsp[-9].minor); + pp_destructor(42,&ppmsp[-8].minor); + pp_destructor(44,&ppmsp[-6].minor); + pp_destructor(45,&ppmsp[-4].minor); + pp_destructor(43,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 1941 "parser.c" +// 1995 "parser.c" break; - case 41: -// 759 "parser.lemon" + case 47: +// 795 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_INNERJOIN); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_update_statement(ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1949 "parser.c" +// 2002 "parser.c" break; - case 42: -// 765 "parser.lemon" + case 48: +// 801 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; - pp_destructor(41,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_update_clause(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); + pp_destructor(46,&ppmsp[-3].minor); + pp_destructor(47,&ppmsp[-1].minor); } -// 1957 "parser.c" +// 2011 "parser.c" break; - case 44: -// 776 "parser.lemon" + case 51: +// 817 "parser.lemon" { - ppgotominor.pp244 = phql_ret_insert_statement(ppmsp[-4].minor.pp244, NULL, ppmsp[-1].minor.pp244); - pp_destructor(42,&ppmsp[-6].minor); - pp_destructor(43,&ppmsp[-5].minor); - pp_destructor(44,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_update_item(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); + pp_destructor(3,&ppmsp[-1].minor); } -// 1969 "parser.c" +// 2019 "parser.c" break; - case 45: -// 780 "parser.lemon" + case 53: +// 829 "parser.lemon" { - ppgotominor.pp244 = phql_ret_insert_statement(ppmsp[-7].minor.pp244, ppmsp[-5].minor.pp244, ppmsp[-1].minor.pp244); - pp_destructor(42,&ppmsp[-9].minor); - pp_destructor(43,&ppmsp[-8].minor); - pp_destructor(45,&ppmsp[-6].minor); - pp_destructor(46,&ppmsp[-4].minor); - pp_destructor(44,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_delete_statement(ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1983 "parser.c" +// 2026 "parser.c" break; - case 52: -// 818 "parser.lemon" + case 54: +// 835 "parser.lemon" { - ppgotominor.pp244 = phql_ret_update_statement(ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_delete_clause(ppmsp[0].minor.pp162); + pp_destructor(48,&ppmsp[-2].minor); + pp_destructor(27,&ppmsp[-1].minor); } -// 1990 "parser.c" +// 2035 "parser.c" break; - case 53: -// 824 "parser.lemon" + case 55: +// 841 "parser.lemon" { - ppgotominor.pp244 = phql_ret_update_clause(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); - pp_destructor(47,&ppmsp[-3].minor); - pp_destructor(48,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp0, NULL); + pp_destructor(32,&ppmsp[-1].minor); } -// 1999 "parser.c" +// 2043 "parser.c" break; case 56: -// 840 "parser.lemon" +// 845 "parser.lemon" { - ppgotominor.pp244 = phql_ret_update_item(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); - pp_destructor(3,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-1].minor.pp162, ppmsp[0].minor.pp0, NULL); +} +// 2050 "parser.c" + break; + case 57: +// 849 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[0].minor.pp162, NULL, NULL); } -// 2007 "parser.c" +// 2057 "parser.c" break; case 58: -// 852 "parser.lemon" +// 853 "parser.lemon" { - ppgotominor.pp244 = phql_ret_delete_statement(ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-4].minor.pp162, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp162); + pp_destructor(32,&ppmsp[-3].minor); + pp_destructor(49,&ppmsp[-1].minor); } -// 2014 "parser.c" +// 2066 "parser.c" break; case 59: -// 858 "parser.lemon" +// 857 "parser.lemon" { - ppgotominor.pp244 = phql_ret_delete_clause(ppmsp[0].minor.pp244); - pp_destructor(49,&ppmsp[-2].minor); - pp_destructor(27,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-6].minor.pp162, ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp162); + pp_destructor(32,&ppmsp[-5].minor); + pp_destructor(49,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2023 "parser.c" +// 2077 "parser.c" break; case 60: -// 864 "parser.lemon" +// 861 "parser.lemon" { - ppgotominor.pp244 = phql_ret_assoc_name(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp0); - pp_destructor(32,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-5].minor.pp162, ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp162); + pp_destructor(49,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2031 "parser.c" +// 2087 "parser.c" break; case 61: -// 868 "parser.lemon" +// 865 "parser.lemon" { - ppgotominor.pp244 = phql_ret_assoc_name(ppmsp[-1].minor.pp244, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-3].minor.pp162, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp162); + pp_destructor(49,&ppmsp[-1].minor); } -// 2038 "parser.c" +// 2095 "parser.c" break; case 62: -// 872 "parser.lemon" +// 869 "parser.lemon" { - ppgotominor.pp244 = phql_ret_assoc_name(ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-4].minor.pp162, NULL, ppmsp[-1].minor.pp162); + pp_destructor(49,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2045 "parser.c" +// 2105 "parser.c" break; - case 64: -// 884 "parser.lemon" + case 63: +// 873 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-2].minor.pp162, NULL, ppmsp[0].minor.pp162); + pp_destructor(49,&ppmsp[-1].minor); +} +// 2113 "parser.c" + break; + case 68: +// 901 "parser.lemon" +{ + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(50,&ppmsp[-1].minor); } -// 2053 "parser.c" +// 2121 "parser.c" break; - case 66: -// 894 "parser.lemon" + case 70: +// 911 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(51,&ppmsp[-2].minor); pp_destructor(52,&ppmsp[-1].minor); } -// 2062 "parser.c" +// 2130 "parser.c" break; - case 70: -// 914 "parser.lemon" + case 74: +// 931 "parser.lemon" { - ppgotominor.pp244 = phql_ret_order_item(ppmsp[0].minor.pp244, 0); + ppgotominor.pp162 = phql_ret_order_item(ppmsp[0].minor.pp162, 0); } -// 2069 "parser.c" +// 2137 "parser.c" break; - case 71: -// 918 "parser.lemon" + case 75: +// 935 "parser.lemon" { - ppgotominor.pp244 = phql_ret_order_item(ppmsp[-1].minor.pp244, PHQL_T_ASC); + ppgotominor.pp162 = phql_ret_order_item(ppmsp[-1].minor.pp162, PHQL_T_ASC); pp_destructor(53,&ppmsp[0].minor); } -// 2077 "parser.c" +// 2145 "parser.c" break; - case 72: -// 922 "parser.lemon" + case 76: +// 939 "parser.lemon" { - ppgotominor.pp244 = phql_ret_order_item(ppmsp[-1].minor.pp244, PHQL_T_DESC); + ppgotominor.pp162 = phql_ret_order_item(ppmsp[-1].minor.pp162, PHQL_T_DESC); pp_destructor(54,&ppmsp[0].minor); } -// 2085 "parser.c" +// 2153 "parser.c" break; - case 73: -// 928 "parser.lemon" + case 77: +// 945 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(55,&ppmsp[-2].minor); pp_destructor(52,&ppmsp[-1].minor); } -// 2094 "parser.c" +// 2162 "parser.c" break; - case 78: -// 954 "parser.lemon" + case 82: +// 971 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(56,&ppmsp[-1].minor); } -// 2102 "parser.c" +// 2170 "parser.c" break; - case 80: -// 964 "parser.lemon" + case 84: +// 981 "parser.lemon" { - ppgotominor.pp244 = phql_ret_for_update_clause(); + ppgotominor.pp162 = phql_ret_for_update_clause(); pp_destructor(57,&ppmsp[-1].minor); - pp_destructor(47,&ppmsp[0].minor); + pp_destructor(46,&ppmsp[0].minor); } -// 2111 "parser.c" +// 2179 "parser.c" break; - case 82: case 86: -// 974 "parser.lemon" + case 90: +// 991 "parser.lemon" { - ppgotominor.pp244 = phql_ret_limit_clause(ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_limit_clause(ppmsp[0].minor.pp162, NULL); pp_destructor(58,&ppmsp[-1].minor); } -// 2120 "parser.c" +// 2188 "parser.c" break; - case 83: -// 978 "parser.lemon" + case 87: +// 995 "parser.lemon" { - ppgotominor.pp244 = phql_ret_limit_clause(ppmsp[0].minor.pp244, ppmsp[-2].minor.pp244); + ppgotominor.pp162 = phql_ret_limit_clause(ppmsp[0].minor.pp162, ppmsp[-2].minor.pp162); pp_destructor(58,&ppmsp[-3].minor); pp_destructor(25,&ppmsp[-1].minor); } -// 2129 "parser.c" +// 2197 "parser.c" break; - case 84: -// 982 "parser.lemon" + case 88: +// 999 "parser.lemon" { - ppgotominor.pp244 = phql_ret_limit_clause(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_limit_clause(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(58,&ppmsp[-3].minor); pp_destructor(59,&ppmsp[-1].minor); } -// 2138 "parser.c" +// 2206 "parser.c" break; - case 88: - case 145: -// 1000 "parser.lemon" + case 92: + case 149: +// 1017 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_INTEGER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_INTEGER, ppmsp[0].minor.pp0); } -// 2146 "parser.c" +// 2214 "parser.c" break; - case 89: - case 146: -// 1004 "parser.lemon" + case 93: + case 150: +// 1021 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_HINTEGER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_HINTEGER, ppmsp[0].minor.pp0); } -// 2154 "parser.c" +// 2222 "parser.c" break; - case 90: - case 152: -// 1008 "parser.lemon" + case 94: + case 156: +// 1025 "parser.lemon" { - ppgotominor.pp244 = phql_ret_placeholder_zval(PHQL_T_NPLACEHOLDER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_placeholder_zval(PHQL_T_NPLACEHOLDER, ppmsp[0].minor.pp0); } -// 2162 "parser.c" +// 2230 "parser.c" break; - case 91: - case 153: -// 1012 "parser.lemon" + case 95: + case 157: +// 1029 "parser.lemon" { - ppgotominor.pp244 = phql_ret_placeholder_zval(PHQL_T_SPLACEHOLDER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_placeholder_zval(PHQL_T_SPLACEHOLDER, ppmsp[0].minor.pp0); } -// 2170 "parser.c" +// 2238 "parser.c" break; - case 92: - case 154: -// 1016 "parser.lemon" + case 96: + case 158: +// 1033 "parser.lemon" { - ppgotominor.pp244 = phql_ret_placeholder_zval(PHQL_T_BPLACEHOLDER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_placeholder_zval(PHQL_T_BPLACEHOLDER, ppmsp[0].minor.pp0); } -// 2178 "parser.c" +// 2246 "parser.c" break; - case 93: -// 1022 "parser.lemon" + case 97: +// 1039 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_MINUS, NULL, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_MINUS, NULL, ppmsp[0].minor.pp162); pp_destructor(20,&ppmsp[-1].minor); } -// 2186 "parser.c" +// 2254 "parser.c" break; - case 94: -// 1026 "parser.lemon" + case 98: +// 1043 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_SUB, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_SUB, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(20,&ppmsp[-1].minor); } -// 2194 "parser.c" +// 2262 "parser.c" break; - case 95: -// 1030 "parser.lemon" + case 99: +// 1047 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ADD, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ADD, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(19,&ppmsp[-1].minor); } -// 2202 "parser.c" +// 2270 "parser.c" break; - case 96: -// 1034 "parser.lemon" + case 100: +// 1051 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_MUL, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_MUL, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(17,&ppmsp[-1].minor); } -// 2210 "parser.c" +// 2278 "parser.c" break; - case 97: -// 1038 "parser.lemon" + case 101: +// 1055 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_DIV, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_DIV, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(16,&ppmsp[-1].minor); } -// 2218 "parser.c" +// 2286 "parser.c" break; - case 98: -// 1042 "parser.lemon" + case 102: +// 1059 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_MOD, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_MOD, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(18,&ppmsp[-1].minor); } -// 2226 "parser.c" +// 2294 "parser.c" break; - case 99: -// 1046 "parser.lemon" + case 103: +// 1063 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_AND, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_AND, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(9,&ppmsp[-1].minor); } -// 2234 "parser.c" +// 2302 "parser.c" break; - case 100: -// 1050 "parser.lemon" + case 104: +// 1067 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_OR, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_OR, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(10,&ppmsp[-1].minor); } -// 2242 "parser.c" +// 2310 "parser.c" break; - case 101: -// 1054 "parser.lemon" + case 105: +// 1071 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_AND, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_AND, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(13,&ppmsp[-1].minor); } -// 2250 "parser.c" +// 2318 "parser.c" break; - case 102: -// 1058 "parser.lemon" + case 106: +// 1075 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_OR, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_OR, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(14,&ppmsp[-1].minor); } -// 2258 "parser.c" +// 2326 "parser.c" break; - case 103: -// 1062 "parser.lemon" + case 107: +// 1079 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_XOR, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_XOR, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(15,&ppmsp[-1].minor); } -// 2266 "parser.c" +// 2334 "parser.c" break; - case 104: -// 1066 "parser.lemon" + case 108: +// 1083 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_EQUALS, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_EQUALS, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(3,&ppmsp[-1].minor); } -// 2274 "parser.c" +// 2342 "parser.c" break; - case 105: -// 1070 "parser.lemon" + case 109: +// 1087 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NOTEQUALS, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NOTEQUALS, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(4,&ppmsp[-1].minor); } -// 2282 "parser.c" +// 2350 "parser.c" break; - case 106: -// 1074 "parser.lemon" + case 110: +// 1091 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_LESS, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_LESS, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(5,&ppmsp[-1].minor); } -// 2290 "parser.c" +// 2358 "parser.c" break; - case 107: -// 1078 "parser.lemon" + case 111: +// 1095 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_GREATER, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_GREATER, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(6,&ppmsp[-1].minor); } -// 2298 "parser.c" +// 2366 "parser.c" break; - case 108: -// 1082 "parser.lemon" + case 112: +// 1099 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_GREATEREQUAL, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_GREATEREQUAL, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(7,&ppmsp[-1].minor); } -// 2306 "parser.c" +// 2374 "parser.c" break; - case 109: -// 1086 "parser.lemon" + case 113: +// 1103 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_LESSEQUAL, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_LESSEQUAL, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(8,&ppmsp[-1].minor); } -// 2314 "parser.c" +// 2382 "parser.c" break; - case 110: -// 1090 "parser.lemon" + case 114: +// 1107 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_LIKE, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_LIKE, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(11,&ppmsp[-1].minor); } -// 2322 "parser.c" +// 2390 "parser.c" break; - case 111: -// 1094 "parser.lemon" + case 115: +// 1111 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NLIKE, ppmsp[-3].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NLIKE, ppmsp[-3].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(23,&ppmsp[-2].minor); pp_destructor(11,&ppmsp[-1].minor); } -// 2331 "parser.c" +// 2399 "parser.c" break; - case 112: -// 1098 "parser.lemon" + case 116: +// 1115 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ILIKE, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ILIKE, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(12,&ppmsp[-1].minor); } -// 2339 "parser.c" +// 2407 "parser.c" break; - case 113: -// 1102 "parser.lemon" + case 117: +// 1119 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NILIKE, ppmsp[-3].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NILIKE, ppmsp[-3].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(23,&ppmsp[-2].minor); pp_destructor(12,&ppmsp[-1].minor); } -// 2348 "parser.c" +// 2416 "parser.c" break; - case 114: - case 117: -// 1106 "parser.lemon" + case 118: + case 121: +// 1123 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_IN, ppmsp[-4].minor.pp244, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_IN, ppmsp[-4].minor.pp162, ppmsp[-1].minor.pp162); pp_destructor(22,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2359 "parser.c" +// 2427 "parser.c" break; - case 115: - case 118: -// 1110 "parser.lemon" + case 119: + case 122: +// 1127 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NOTIN, ppmsp[-5].minor.pp244, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NOTIN, ppmsp[-5].minor.pp162, ppmsp[-1].minor.pp162); pp_destructor(23,&ppmsp[-4].minor); pp_destructor(22,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2371 "parser.c" +// 2439 "parser.c" break; - case 116: -// 1114 "parser.lemon" + case 120: +// 1131 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_SUBQUERY, ppmsp[-1].minor.pp244, NULL); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_SUBQUERY, ppmsp[-1].minor.pp162, NULL); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2380 "parser.c" +// 2448 "parser.c" break; - case 119: -// 1126 "parser.lemon" + case 123: +// 1143 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_EXISTS, NULL, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_EXISTS, NULL, ppmsp[-1].minor.pp162); pp_destructor(65,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2390 "parser.c" +// 2458 "parser.c" break; - case 120: -// 1130 "parser.lemon" + case 124: +// 1147 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_AGAINST, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_AGAINST, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(1,&ppmsp[-1].minor); } -// 2398 "parser.c" +// 2466 "parser.c" break; - case 121: -// 1134 "parser.lemon" + case 125: +// 1151 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_CAST, ppmsp[-3].minor.pp244, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_CAST, ppmsp[-3].minor.pp162, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); pp_destructor(66,&ppmsp[-5].minor); - pp_destructor(45,&ppmsp[-4].minor); + pp_destructor(44,&ppmsp[-4].minor); pp_destructor(32,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2409 "parser.c" +// 2477 "parser.c" break; - case 122: -// 1138 "parser.lemon" + case 126: +// 1155 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_CONVERT, ppmsp[-3].minor.pp244, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_CONVERT, ppmsp[-3].minor.pp162, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); pp_destructor(67,&ppmsp[-5].minor); - pp_destructor(45,&ppmsp[-4].minor); + pp_destructor(44,&ppmsp[-4].minor); pp_destructor(68,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2420 "parser.c" +// 2488 "parser.c" break; - case 123: -// 1142 "parser.lemon" + case 127: +// 1159 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_CASE, ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_CASE, ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162); pp_destructor(69,&ppmsp[-3].minor); pp_destructor(70,&ppmsp[0].minor); } -// 2429 "parser.c" +// 2497 "parser.c" break; - case 126: -// 1154 "parser.lemon" + case 130: +// 1171 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_WHEN, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_WHEN, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(71,&ppmsp[-3].minor); pp_destructor(72,&ppmsp[-1].minor); } -// 2438 "parser.c" +// 2506 "parser.c" break; - case 127: -// 1158 "parser.lemon" + case 131: +// 1175 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ELSE, ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ELSE, ppmsp[0].minor.pp162, NULL); pp_destructor(73,&ppmsp[-1].minor); } -// 2446 "parser.c" +// 2514 "parser.c" break; - case 129: -// 1168 "parser.lemon" + case 133: +// 1185 "parser.lemon" { - ppgotominor.pp244 = phql_ret_func_call(ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp244, ppmsp[-2].minor.pp244); - pp_destructor(45,&ppmsp[-3].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_func_call(ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp162, ppmsp[-2].minor.pp162); + pp_destructor(44,&ppmsp[-3].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2455 "parser.c" +// 2523 "parser.c" break; - case 130: -// 1174 "parser.lemon" + case 134: +// 1191 "parser.lemon" { - ppgotominor.pp244 = phql_ret_distinct(); + ppgotominor.pp162 = phql_ret_distinct(); pp_destructor(28,&ppmsp[0].minor); } -// 2463 "parser.c" +// 2531 "parser.c" break; - case 138: -// 1212 "parser.lemon" + case 142: +// 1229 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ISNULL, ppmsp[-2].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ISNULL, ppmsp[-2].minor.pp162, NULL); pp_destructor(21,&ppmsp[-1].minor); pp_destructor(74,&ppmsp[0].minor); } -// 2472 "parser.c" +// 2540 "parser.c" break; - case 139: -// 1216 "parser.lemon" + case 143: +// 1233 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ISNOTNULL, ppmsp[-3].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ISNOTNULL, ppmsp[-3].minor.pp162, NULL); pp_destructor(21,&ppmsp[-2].minor); pp_destructor(23,&ppmsp[-1].minor); pp_destructor(74,&ppmsp[0].minor); } -// 2482 "parser.c" +// 2550 "parser.c" break; - case 140: -// 1220 "parser.lemon" + case 144: +// 1237 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BETWEEN, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BETWEEN, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(2,&ppmsp[-1].minor); } -// 2490 "parser.c" +// 2558 "parser.c" break; - case 141: -// 1224 "parser.lemon" + case 145: +// 1241 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NOT, NULL, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NOT, NULL, ppmsp[0].minor.pp162); pp_destructor(23,&ppmsp[-1].minor); } -// 2498 "parser.c" +// 2566 "parser.c" break; - case 142: -// 1228 "parser.lemon" + case 146: +// 1245 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_NOT, NULL, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_NOT, NULL, ppmsp[0].minor.pp162); pp_destructor(24,&ppmsp[-1].minor); } -// 2506 "parser.c" +// 2574 "parser.c" break; - case 143: -// 1232 "parser.lemon" + case 147: +// 1249 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ENCLOSED, ppmsp[-1].minor.pp244, NULL); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ENCLOSED, ppmsp[-1].minor.pp162, NULL); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2515 "parser.c" +// 2583 "parser.c" break; - case 147: -// 1248 "parser.lemon" + case 151: +// 1265 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_STRING, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_STRING, ppmsp[0].minor.pp0); } -// 2522 "parser.c" +// 2590 "parser.c" break; - case 148: -// 1252 "parser.lemon" + case 152: +// 1269 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_DOUBLE, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_DOUBLE, ppmsp[0].minor.pp0); } -// 2529 "parser.c" +// 2597 "parser.c" break; - case 149: -// 1256 "parser.lemon" + case 153: +// 1273 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_NULL, NULL); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_NULL, NULL); pp_destructor(74,&ppmsp[0].minor); } -// 2537 "parser.c" +// 2605 "parser.c" break; - case 150: -// 1260 "parser.lemon" + case 154: +// 1277 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_TRUE, NULL); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_TRUE, NULL); pp_destructor(77,&ppmsp[0].minor); } -// 2545 "parser.c" +// 2613 "parser.c" break; - case 151: -// 1264 "parser.lemon" + case 155: +// 1281 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_FALSE, NULL); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_FALSE, NULL); pp_destructor(78,&ppmsp[0].minor); } -// 2553 "parser.c" +// 2621 "parser.c" break; - case 155: -// 1285 "parser.lemon" + case 159: +// 1302 "parser.lemon" { - ppgotominor.pp244 = phql_ret_qualified_name(NULL, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_qualified_name(NULL, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp0); pp_destructor(31,&ppmsp[-1].minor); } -// 2561 "parser.c" +// 2629 "parser.c" break; }; ppgoto = ppRuleInfo[ppruleno].lhs; @@ -103591,7 +104323,7 @@ static void pp_syntax_error( ){ phql_ARG_FETCH; #define PPTOKEN (ppminor.pp0) -// 490 "parser.lemon" +// 491 "parser.lemon" if (status->scanner_state->start_length) { { @@ -103658,7 +104390,7 @@ static void pp_syntax_error( status->status = PHQL_PARSING_FAILED; -// 2670 "parser.c" +// 2738 "parser.c" phql_ARG_STORE; /* Suppress warning about unused %extra_argument variable */ } @@ -104418,7 +105150,7 @@ static int phql_internal_parse_phql(zval **result, char *phql, unsigned int phql } -/* Generated by re2c 0.13.6 on Mon Jul 6 13:03:04 2015 */ +/* Generated by re2c 0.13.6 on Wed Aug 5 14:30:06 2015 */ // 1 "scanner.re" @@ -110837,7 +111569,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, __construct) { zephir_update_property_this(this_ptr, SL("_columnTypes"), columnTypes TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 357, result, cache); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 350, result, cache); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -110845,12 +111577,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, __construct) { static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { - zephir_fcall_cache_entry *_12 = NULL, *_14 = NULL; - zend_class_entry *_11; - HashTable *_2, *_5; - HashPosition _1, _4; + zephir_fcall_cache_entry *_13 = NULL, *_15 = NULL; + zend_class_entry *_12; + HashTable *_3, *_6; + HashPosition _2, _5; int dirtyState, ZEPHIR_LAST_CALL_STATUS; - zval *row, *hydrateMode, *alias = NULL, *activeRow = NULL, *type = NULL, *columnTypes, *column = NULL, *columnValue = NULL, *value = NULL, *attribute = NULL, *source = NULL, *attributes = NULL, *columnMap = NULL, *rowModel = NULL, *keepSnapshots = NULL, *sqlAlias = NULL, *modelName = NULL, *_0, **_3, **_6, *_7 = NULL, *_8 = NULL, *_9, *_10 = NULL, *_13, _15 = zval_used_for_init, _16 = zval_used_for_init; + zval *row, *hydrateMode, *eager, *alias = NULL, *activeRow = NULL, *type = NULL, *column = NULL, *columnValue = NULL, *value = NULL, *attribute = NULL, *source = NULL, *attributes = NULL, *columnMap = NULL, *rowModel = NULL, *keepSnapshots = NULL, *sqlAlias = NULL, *modelName = NULL, *_0, *_1, **_4, **_7, *_8 = NULL, *_9 = NULL, *_10, *_11 = NULL, *_14, _16 = zval_used_for_init, _17 = zval_used_for_init; ZEPHIR_MM_GROW(); @@ -110892,41 +111624,40 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { break; } while(0); - ZEPHIR_OBS_VAR(columnTypes); - zephir_read_property_this(&columnTypes, this_ptr, SL("_columnTypes"), PH_NOISY_CC); dirtyState = 0; - zephir_is_iterable(columnTypes, &_2, &_1, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 245); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_columnTypes"), PH_NOISY_CC); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 246); for ( - ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS - ; zephir_hash_move_forward_ex(_2, &_1) + ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS + ; zephir_hash_move_forward_ex(_3, &_2) ) { - ZEPHIR_GET_HMKEY(alias, _2, _1); - ZEPHIR_GET_HVALUE(column, _3); + ZEPHIR_GET_HMKEY(alias, _3, _2); + ZEPHIR_GET_HVALUE(column, _4); if (Z_TYPE_P(column) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Column type is corrupt", "phalcon/mvc/model/resultset/complex.zep", 135); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Column type is corrupt", "phalcon/mvc/model/resultset/complex.zep", 133); return; } ZEPHIR_OBS_NVAR(type); - zephir_array_fetch_string(&type, column, SL("type"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 138 TSRMLS_CC); + zephir_array_fetch_string(&type, column, SL("type"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 136 TSRMLS_CC); if (ZEPHIR_IS_STRING(type, "object")) { ZEPHIR_OBS_NVAR(source); - zephir_array_fetch_string(&source, column, SL("column"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 144 TSRMLS_CC); + zephir_array_fetch_string(&source, column, SL("column"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 142 TSRMLS_CC); ZEPHIR_OBS_NVAR(attributes); - zephir_array_fetch_string(&attributes, column, SL("attributes"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 145 TSRMLS_CC); + zephir_array_fetch_string(&attributes, column, SL("attributes"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 143 TSRMLS_CC); ZEPHIR_OBS_NVAR(columnMap); - zephir_array_fetch_string(&columnMap, column, SL("columnMap"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 146 TSRMLS_CC); + zephir_array_fetch_string(&columnMap, column, SL("columnMap"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 144 TSRMLS_CC); ZEPHIR_INIT_NVAR(rowModel); array_init(rowModel); - zephir_is_iterable(attributes, &_5, &_4, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 164); + zephir_is_iterable(attributes, &_6, &_5, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 162); for ( - ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS - ; zephir_hash_move_forward_ex(_5, &_4) + ; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS + ; zephir_hash_move_forward_ex(_6, &_5) ) { - ZEPHIR_GET_HVALUE(attribute, _6); + ZEPHIR_GET_HVALUE(attribute, _7); ZEPHIR_OBS_NVAR(columnValue); - ZEPHIR_INIT_LNVAR(_7); - ZEPHIR_CONCAT_SVSV(_7, "_", source, "_", attribute); - zephir_array_fetch(&columnValue, row, _7, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 157 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_8); + ZEPHIR_CONCAT_SVSV(_8, "_", source, "_", attribute); + zephir_array_fetch(&columnValue, row, _8, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 155 TSRMLS_CC); zephir_array_update_zval(&rowModel, attribute, &columnValue, PH_COPY | PH_SEPARATE); } do { @@ -110937,43 +111668,43 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { ZVAL_BOOL(keepSnapshots, 0); } if (ZEPHIR_GLOBAL(orm).late_state_binding) { - ZEPHIR_OBS_NVAR(_8); - zephir_array_fetch_string(&_8, column, SL("instance"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 175 TSRMLS_CC); - if (zephir_instance_of_ev(_8, phalcon_mvc_model_ce TSRMLS_CC)) { - zephir_array_fetch_string(&_9, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 176 TSRMLS_CC); + ZEPHIR_OBS_NVAR(_9); + zephir_array_fetch_string(&_9, column, SL("instance"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 173 TSRMLS_CC); + if (zephir_instance_of_ev(_9, phalcon_mvc_model_ce TSRMLS_CC)) { + zephir_array_fetch_string(&_10, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 174 TSRMLS_CC); ZEPHIR_INIT_NVAR(modelName); - zephir_get_class(modelName, _9, 0 TSRMLS_CC); + zephir_get_class(modelName, _10, 0 TSRMLS_CC); } else { ZEPHIR_INIT_NVAR(modelName); ZVAL_STRING(modelName, "Phalcon\\Mvc\\Model", 1); } - zephir_array_fetch_string(&_9, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 182 TSRMLS_CC); - ZEPHIR_INIT_NVAR(_10); - ZVAL_LONG(_10, dirtyState); - _11 = zephir_fetch_class(modelName TSRMLS_CC); - ZEPHIR_CALL_CE_STATIC(&value, _11, "cloneresultmap", NULL, 0, _9, rowModel, columnMap, _10, keepSnapshots); + zephir_array_fetch_string(&_10, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 180 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_11); + ZVAL_LONG(_11, dirtyState); + _12 = zephir_fetch_class(modelName TSRMLS_CC); + ZEPHIR_CALL_CE_STATIC(&value, _12, "cloneresultmap", NULL, 0, _10, rowModel, columnMap, _11, keepSnapshots); zephir_check_call_status(); } else { - zephir_array_fetch_string(&_13, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 190 TSRMLS_CC); - ZEPHIR_INIT_NVAR(_10); - ZVAL_LONG(_10, dirtyState); - ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmap", &_12, 0, _13, rowModel, columnMap, _10, keepSnapshots); + zephir_array_fetch_string(&_14, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 188 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_11); + ZVAL_LONG(_11, dirtyState); + ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmap", &_13, 0, _14, rowModel, columnMap, _11, keepSnapshots); zephir_check_call_status(); } break; } - ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_14, 0, rowModel, columnMap, hydrateMode); + ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_15, 0, rowModel, columnMap, hydrateMode); zephir_check_call_status(); break; } while(0); ZEPHIR_OBS_NVAR(attribute); - zephir_array_fetch_string(&attribute, column, SL("balias"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 204 TSRMLS_CC); + zephir_array_fetch_string(&attribute, column, SL("balias"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 202 TSRMLS_CC); } else { ZEPHIR_OBS_NVAR(sqlAlias); if (zephir_array_isset_string_fetch(&sqlAlias, column, SS("sqlAlias"), 0 TSRMLS_CC)) { ZEPHIR_OBS_NVAR(value); - zephir_array_fetch(&value, row, sqlAlias, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 212 TSRMLS_CC); + zephir_array_fetch(&value, row, sqlAlias, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 210 TSRMLS_CC); } else { ZEPHIR_OBS_NVAR(value); zephir_array_isset_fetch(&value, row, alias, 0 TSRMLS_CC); @@ -110981,23 +111712,25 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { if (zephir_array_isset_string(column, SS("balias"))) { ZEPHIR_CPY_WRT(attribute, alias); } else { - ZEPHIR_SINIT_NVAR(_15); - ZVAL_STRING(&_15, "_", 0); ZEPHIR_SINIT_NVAR(_16); - ZVAL_STRING(&_16, "", 0); + ZVAL_STRING(&_16, "_", 0); + ZEPHIR_SINIT_NVAR(_17); + ZVAL_STRING(&_17, "", 0); ZEPHIR_INIT_NVAR(attribute); - zephir_fast_str_replace(&attribute, &_15, &_16, alias TSRMLS_CC); + zephir_fast_str_replace(&attribute, &_16, &_17, alias TSRMLS_CC); } } - do { - if (ZEPHIR_IS_LONG(hydrateMode, 1)) { - zephir_array_update_zval(&activeRow, attribute, &value, PH_COPY | PH_SEPARATE); + if (!(zephir_array_isset_string_fetch(&eager, column, SS("eager"), 1 TSRMLS_CC))) { + do { + if (ZEPHIR_IS_LONG(hydrateMode, 1)) { + zephir_array_update_zval(&activeRow, attribute, &value, PH_COPY | PH_SEPARATE); + break; + } + zephir_update_property_zval_zval(activeRow, attribute, value TSRMLS_CC); break; - } - zephir_update_property_zval_zval(activeRow, attribute, value TSRMLS_CC); - break; - } while(0); + } while(0); + } } zephir_update_property_this(this_ptr, SL("_activeRow"), activeRow TSRMLS_CC); RETURN_CCTOR(activeRow); @@ -111021,7 +111754,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, toArray) { _0->funcs->get_current_data(_0, &ZEPHIR_TMP_ITERATOR_PTR TSRMLS_CC); ZEPHIR_CPY_WRT(current, (*ZEPHIR_TMP_ITERATOR_PTR)); } - zephir_array_append(&records, current, PH_SEPARATE, "phalcon/mvc/model/resultset/complex.zep", 258); + zephir_array_append(&records, current, PH_SEPARATE, "phalcon/mvc/model/resultset/complex.zep", 259); } _0->funcs->dtor(_0 TSRMLS_CC); RETURN_CCTOR(records); @@ -111050,7 +111783,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, serialize) { zephir_array_update_string(&_0, SL("rows"), &records, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_0, SL("columnTypes"), &columnTypes, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_0, SL("hydrateMode"), &hydrateMode, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 71, _0); + ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_CCTOR(serialized); @@ -111079,23 +111812,23 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, unserialize) { zephir_update_property_this(this_ptr, SL("_disableHydration"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(resultset) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/complex.zep", 303); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/complex.zep", 304); return; } - zephir_array_fetch_string(&_0, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 306 TSRMLS_CC); + zephir_array_fetch_string(&_0, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 307 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_rows"), _0 TSRMLS_CC); - zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 307 TSRMLS_CC); + zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 308 TSRMLS_CC); ZEPHIR_INIT_ZVAL_NREF(_2); ZVAL_LONG(_2, zephir_fast_count_int(_1 TSRMLS_CC)); zephir_update_property_this(this_ptr, SL("_count"), _2 TSRMLS_CC); - zephir_array_fetch_string(&_3, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 308 TSRMLS_CC); + zephir_array_fetch_string(&_3, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 309 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_cache"), _3 TSRMLS_CC); - zephir_array_fetch_string(&_4, resultset, SL("columnTypes"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 309 TSRMLS_CC); + zephir_array_fetch_string(&_4, resultset, SL("columnTypes"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 310 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_columnTypes"), _4 TSRMLS_CC); - zephir_array_fetch_string(&_5, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 310 TSRMLS_CC); + zephir_array_fetch_string(&_5, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 311 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_hydrateMode"), _5 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -111154,7 +111887,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, __construct) { zephir_update_property_this(this_ptr, SL("_model"), model TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_columnMap"), columnMap TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_keepSnapshots"), keepSnapshots TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 357, result, cache); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 350, result, cache); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -111209,12 +111942,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, current) { _6 = zephir_fetch_nproperty_this(this_ptr, SL("_keepSnapshots"), PH_NOISY_CC); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, 0); - ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 358, _2, row, columnMap, _3, _6); + ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 351, _2, row, columnMap, _3, _6); zephir_check_call_status(); } break; } - ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 359, row, columnMap, hydrateMode); + ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 352, row, columnMap, hydrateMode); zephir_check_call_status(); break; } while(0); @@ -111346,7 +112079,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, serialize) { ZEPHIR_OBS_NVAR(_1); zephir_read_property_this(&_1, this_ptr, SL("_hydrateMode"), PH_NOISY_CC); zephir_array_update_string(&_0, SL("hydrateMode"), &_1, PH_COPY | PH_SEPARATE); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -111374,7 +112107,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, unserialize) { } - ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(resultset) != IS_ARRAY) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/simple.zep", 252); @@ -111681,7 +112414,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, get) { ZEPHIR_INIT_VAR(_3); ZVAL_STRING(_3, "rollbackPendent", 1); zephir_array_fast_append(_2, _3); - ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 362, _2); + ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 355, _2); zephir_check_call_status(); } zephir_update_property_this(this_ptr, SL("_initialized"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); @@ -111740,9 +112473,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, getOrCreateTransaction) ZEPHIR_INIT_VAR(transaction); object_init_ex(transaction, phalcon_mvc_model_transaction_ce); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_service"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 363, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5); + ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 356, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 364, this_ptr); + ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 357, this_ptr); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_transactions"), transaction TSRMLS_CC); RETURN_ON_FAILURE(zephir_property_incr(this_ptr, SL("_number") TSRMLS_CC)); @@ -112030,7 +112763,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Email, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 274); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_0); @@ -112045,7 +112778,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Email, validate) { ZEPHIR_INIT_VAR(_5); zephir_create_array(_5, 1, 0 TSRMLS_CC); zephir_array_update_string(&_5, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, _5); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, _5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Email", ZEPHIR_TEMP_PARAM_COPY); @@ -112173,7 +112906,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Exclusionin, validate) { ZEPHIR_INIT_NVAR(_0); zephir_fast_join_str(_0, SL(", "), domain TSRMLS_CC); zephir_array_update_string(&_4, SL(":domain"), &_0, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Exclusion", ZEPHIR_TEMP_PARAM_COPY); @@ -112303,7 +113036,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Inclusionin, validate) { zephir_check_temp_parameter(_0); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 365, value, domain, strict); + ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 358, value, domain, strict); zephir_check_call_status(); if (!(zephir_is_true(_5))) { ZEPHIR_INIT_NVAR(_0); @@ -112321,7 +113054,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Inclusionin, validate) { ZEPHIR_INIT_NVAR(_0); zephir_fast_join_str(_0, SL(", "), domain TSRMLS_CC); zephir_array_update_string(&_6, SL(":domain"), &_0, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 53, message, _6); + ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 54, message, _6); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Inclusion", ZEPHIR_TEMP_PARAM_COPY); @@ -112449,7 +113182,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Ip, validate) { zephir_array_update_string(&options, SL("flags"), &_6, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, 275); - ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 191, value, &_5, options); + ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 192, value, &_5, options); zephir_check_call_status(); if (!(zephir_is_true(_7))) { ZEPHIR_INIT_NVAR(_0); @@ -112463,7 +113196,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Ip, validate) { ZEPHIR_INIT_NVAR(_4); zephir_create_array(_4, 1, 0 TSRMLS_CC); zephir_array_update_string(&_4, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "IP", ZEPHIR_TEMP_PARAM_COPY); @@ -112570,7 +113303,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Numericality, validate) { ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 1, 0 TSRMLS_CC); zephir_array_update_string(&_3, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, _3); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Numericality", ZEPHIR_TEMP_PARAM_COPY); @@ -112673,7 +113406,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_PresenceOf, validate) { ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 1, 0 TSRMLS_CC); zephir_array_update_string(&_3, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, _3); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "PresenceOf", ZEPHIR_TEMP_PARAM_COPY); @@ -112805,7 +113538,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Regex, validate) { ZEPHIR_INIT_VAR(_6); zephir_create_array(_6, 1, 0 TSRMLS_CC); zephir_array_update_string(&_6, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 53, message, _6); + ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 54, message, _6); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_5); ZVAL_STRING(_5, "Regex", ZEPHIR_TEMP_PARAM_COPY); @@ -112919,7 +113652,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) { RETURN_MM_BOOL(1); } if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value); + ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 359, value); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(length); @@ -112945,7 +113678,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) { zephir_create_array(_4, 2, 0 TSRMLS_CC); zephir_array_update_string(&_4, SL(":field"), &field, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL(":max"), &maximum, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "TooLong", ZEPHIR_TEMP_PARAM_COPY); @@ -112975,7 +113708,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) { zephir_create_array(_4, 2, 0 TSRMLS_CC); zephir_array_update_string(&_4, SL(":field"), &field, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL(":min"), &minimum, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "TooShort", ZEPHIR_TEMP_PARAM_COPY); @@ -113256,7 +113989,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) { ZVAL_STRING(message, "Value of field: ':field' is already present in another record", 1); } } - ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_18); ZVAL_STRING(_18, "Unique", ZEPHIR_TEMP_PARAM_COPY); @@ -113352,7 +114085,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Url, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 273); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_0); @@ -113367,7 +114100,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Url, validate) { ZEPHIR_INIT_VAR(_5); zephir_create_array(_5, 1, 0 TSRMLS_CC); zephir_array_update_string(&_5, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, _5); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, _5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Url", ZEPHIR_TEMP_PARAM_COPY); @@ -113687,7 +114420,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Annotations, handle) { } zephir_update_property_this(this_ptr, SL("_processed"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 367, realUri); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 360, realUri); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -113902,7 +114635,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Annotations, processActionAnnotation) { zephir_check_temp_parameter(_3); zephir_check_call_status(); if (Z_TYPE_P(converts) == IS_ARRAY) { - zephir_is_iterable(converts, &_5, &_4, 0, 0, "phalcon/mvc/router/annotations.zep", 360); + zephir_is_iterable(converts, &_5, &_4, 0, 0, "phalcon/mvc/router/annotations.zep", 354); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -113919,7 +114652,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Annotations, processActionAnnotation) { zephir_check_temp_parameter(_3); zephir_check_call_status(); if (Z_TYPE_P(converts) == IS_ARRAY) { - zephir_is_iterable(converts, &_9, &_8, 0, 0, "phalcon/mvc/router/annotations.zep", 370); + zephir_is_iterable(converts, &_9, &_8, 0, 0, "phalcon/mvc/router/annotations.zep", 364); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) @@ -114519,7 +115252,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Group, _addRoute) { zephir_read_property_this(&defaultPaths, this_ptr, SL("_paths"), PH_NOISY_CC); if (Z_TYPE_P(defaultPaths) == IS_ARRAY) { if (Z_TYPE_P(paths) == IS_STRING) { - ZEPHIR_CALL_CE_STATIC(&processedPaths, phalcon_mvc_router_route_ce, "getroutepaths", &_0, 75, paths); + ZEPHIR_CALL_CE_STATIC(&processedPaths, phalcon_mvc_router_route_ce, "getroutepaths", &_0, 77, paths); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(processedPaths, paths); @@ -114538,10 +115271,10 @@ static PHP_METHOD(Phalcon_Mvc_Router_Group, _addRoute) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_prefix"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_2); ZEPHIR_CONCAT_VV(_2, _1, pattern); - ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 74, _2, mergedPaths, httpMethods); + ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 76, _2, mergedPaths, httpMethods); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_routes"), route TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 368, this_ptr); + ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 361, this_ptr); zephir_check_call_status(); RETURN_CCTOR(route); @@ -116050,7 +116783,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, _loadTemplateEngines) { if (Z_TYPE_P(registeredEngines) != IS_ARRAY) { ZEPHIR_INIT_VAR(_0); object_init_ex(_0, phalcon_mvc_view_engine_php_ce); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 370, this_ptr, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 363, this_ptr, dependencyInjector); zephir_check_call_status(); zephir_array_update_string(&engines, SL(".phtml"), &_0, PH_COPY | PH_SEPARATE); } else { @@ -116289,7 +117022,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, render) { ZEPHIR_INIT_VAR(_1); zephir_create_symbol_table(TSRMLS_C); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_OBS_VAR(viewParams); zephir_read_property_this(&viewParams, this_ptr, SL("_viewParams"), PH_NOISY_CC); @@ -116303,7 +117036,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, render) { } else { ZEPHIR_CPY_WRT(mergedParams, viewParams); } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 389, path, mergedParams); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 382, path, mergedParams); zephir_check_call_status(); if (Z_TYPE_P(cache) == IS_OBJECT) { ZEPHIR_CALL_METHOD(&_0, cache, "isstarted", NULL, 0); @@ -116323,7 +117056,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, render) { zephir_check_call_status(); } } - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); RETURN_MM_MEMBER(this_ptr, "_content"); @@ -116354,7 +117087,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, partial) { } - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); if (Z_TYPE_P(params) == IS_ARRAY) { ZEPHIR_OBS_VAR(viewParams); @@ -116371,12 +117104,12 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, partial) { } else { ZEPHIR_CPY_WRT(mergedParams, params); } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 389, partialPath, mergedParams); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 382, partialPath, mergedParams); zephir_check_call_status(); if (Z_TYPE_P(params) == IS_ARRAY) { zephir_update_property_this(this_ptr, SL("_viewParams"), viewParams TSRMLS_CC); } - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_content"), PH_NOISY_CC); zend_print_zval(_1, 0); @@ -116755,7 +117488,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Php, render) { if (mustClean == 1) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371); + ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 364); zephir_check_call_status(); } if (Z_TYPE_P(params) == IS_ARRAY) { @@ -116777,7 +117510,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Php, render) { } if (mustClean == 1) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 117); + ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 119); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _4, "setcontent", NULL, 0, _5); zephir_check_call_status(); @@ -116850,18 +117583,18 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, getCompiler) { ZEPHIR_INIT_NVAR(compiler); object_init_ex(compiler, phalcon_mvc_view_engine_volt_compiler_ce); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 372, _0); + ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 365, _0); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _1); if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) { - ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 373, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 366, dependencyInjector); zephir_check_call_status(); } ZEPHIR_OBS_VAR(options); zephir_read_property_this(&options, this_ptr, SL("_options"), PH_NOISY_CC); if (Z_TYPE_P(options) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 374, options); + ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 367, options); zephir_check_call_status(); } zephir_update_property_this(this_ptr, SL("_compiler"), compiler TSRMLS_CC); @@ -116901,7 +117634,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) { if (mustClean) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371); + ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 364); zephir_check_call_status(); } ZEPHIR_CALL_METHOD(&compiler, this_ptr, "getcompiler", NULL, 0); @@ -116929,7 +117662,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) { } if (mustClean) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 117); + ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 119); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _4, "setcontent", NULL, 0, _5); zephir_check_call_status(); @@ -116960,7 +117693,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, length) { ZVAL_LONG(length, zephir_fast_count_int(item TSRMLS_CC)); } else { if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, item); + ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 359, item); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(length); @@ -116986,7 +117719,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, isIncluded) { } if (Z_TYPE_P(haystack) == IS_STRING) { if ((zephir_function_exists_ex(SS("mb_strpos") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 375, haystack, needle); + ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 368, haystack, needle); zephir_check_call_status(); RETURN_MM_BOOL(!ZEPHIR_IS_FALSE_IDENTICAL(_0)); } @@ -117039,7 +117772,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) { _0 = ZEPHIR_IS_STRING(to, "utf8"); } if (_0) { - ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 376, text); + ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 369, text); zephir_check_call_status(); RETURN_MM(); } @@ -117048,17 +117781,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) { _1 = ZEPHIR_IS_STRING(from, "utf8"); } if (_1) { - ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 377, text); + ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 370, text); zephir_check_call_status(); RETURN_MM(); } if ((zephir_function_exists_ex(SS("mb_convert_encoding") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, text, from, to); + ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 181, text, from, to); zephir_check_call_status(); RETURN_MM(); } if ((zephir_function_exists_ex(SS("iconv") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 378, from, to, text); + ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 371, from, to, text); zephir_check_call_status(); RETURN_MM(); } @@ -117129,7 +117862,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) { if (Z_TYPE_P(value) == IS_ARRAY) { ZEPHIR_SINIT_VAR(_5); ZVAL_LONG(&_5, start); - ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 379, value, &_5, length); + ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 372, value, &_5, length); zephir_check_call_status(); RETURN_MM(); } @@ -117137,13 +117870,13 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) { if (Z_TYPE_P(length) != IS_NULL) { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, start); - ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5, length); + ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 373, value, &_5, length); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, start); - ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5); + ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 373, value, &_5); zephir_check_call_status(); RETURN_MM(); } @@ -117173,7 +117906,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, sort) { Z_SET_ISREF_P(value); - ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 381, value); + ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 374, value); Z_UNSET_ISREF_P(value); zephir_check_call_status(); RETURN_CTOR(value); @@ -117217,7 +117950,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, callMacro) { ZEPHIR_MM_RESTORE(); return; } - ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 382, macro, arguments); + ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 375, macro, arguments); zephir_check_call_status(); RETURN_MM(); @@ -117479,7 +118212,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, addExtension) { if (Z_TYPE_P(extension) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The extension is not valid", "phalcon/mvc/view/engine/volt/compiler.zep", 198); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "The extension is not valid", "phalcon/mvc/view/engine/volt/compiler.zep", 198); return; } if ((zephir_method_exists_ex(extension, SS("initialize") TSRMLS_CC) == SUCCESS)) { @@ -117619,7 +118352,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, getUniquePrefix) { } } if (Z_TYPE_P(prefix) != IS_STRING) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The unique compilation prefix is invalid", "phalcon/mvc/view/engine/volt/compiler.zep", 292); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "The unique compilation prefix is invalid", "phalcon/mvc/view/engine/volt/compiler.zep", 292); return; } RETURN_CCTOR(prefix); @@ -117680,7 +118413,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) { } } } else { - ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 383, left); + ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 376, left); zephir_check_call_status(); ZEPHIR_OBS_VAR(leftType); zephir_array_fetch_string(&leftType, left, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 339 TSRMLS_CC); @@ -117702,7 +118435,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) { zephir_array_fetch_string(&_7, right, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 352 TSRMLS_CC); zephir_concat_self(&exprCode, _7 TSRMLS_CC); } else { - ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 383, right); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 376, right); zephir_check_call_status(); zephir_concat_self(&exprCode, _1 TSRMLS_CC); } @@ -117712,10 +118445,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) { static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { - zend_bool _7; + zend_bool _6; zephir_fcall_cache_entry *_0 = NULL; int ZEPHIR_LAST_CALL_STATUS; - zval *expr_param = NULL, *code = NULL, *funcArguments = NULL, *arguments = NULL, *nameExpr, *nameType, *name, *extensions, *functions, *definition, *extendedBlocks, *block, *currentBlock, *exprLevel, *escapedCode = NULL, *method = NULL, *arrayHelpers = NULL, *className, *_2 = NULL, *_3, *_4, *_5 = NULL, *_6, *_8 = NULL; + zval *expr_param = NULL, *code = NULL, *funcArguments = NULL, *arguments = NULL, *nameExpr, *nameType, *name, *extensions, *functions, *definition, *extendedBlocks, *block, *currentBlock, *exprLevel, *escapedCode = NULL, *method = NULL, *arrayHelpers = NULL, *className, *_2 = NULL, *_3, *_4, *_5, *_7 = NULL; zval *expr = NULL, *_1 = NULL; ZEPHIR_MM_GROW(); @@ -117731,7 +118464,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { ZVAL_NULL(funcArguments); ZEPHIR_OBS_NVAR(funcArguments); if (zephir_array_isset_string_fetch(&funcArguments, expr, SS("arguments"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 383, funcArguments); + ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 376, funcArguments); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(arguments); @@ -117754,7 +118487,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { zephir_array_fast_append(_1, funcArguments); ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "compileFunction", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _2, _1); + ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 377, _2, _1); zephir_check_temp_parameter(_2); zephir_check_call_status(); if (Z_TYPE_P(code) == IS_STRING) { @@ -117782,7 +118515,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { } } ZEPHIR_INIT_NVAR(_2); - object_init_ex(_2, phalcon_mvc_view_exception_ce); + object_init_ex(_2, phalcon_mvc_view_engine_volt_exception_ce); zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 427 TSRMLS_CC); zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 427 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); @@ -117794,16 +118527,11 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { return; } } - _6 = zephir_fetch_nproperty_this(this_ptr, SL("_macros"), PH_NOISY_CC); - if (zephir_array_isset(_6, name)) { - ZEPHIR_CONCAT_SVSVS(return_value, "$this->callMacro('", name, "', array(", arguments, "))"); - RETURN_MM(); - } - _7 = ZEPHIR_IS_STRING(name, "get_content"); - if (!(_7)) { - _7 = ZEPHIR_IS_STRING(name, "content"); + _6 = ZEPHIR_IS_STRING(name, "get_content"); + if (!(_6)) { + _6 = ZEPHIR_IS_STRING(name, "content"); } - if (_7) { + if (_6) { RETURN_MM_STRING("$this->getContent()", 1); } if (ZEPHIR_IS_STRING(name, "partial")) { @@ -117821,7 +118549,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { ZEPHIR_OBS_VAR(exprLevel); zephir_read_property_this(&exprLevel, this_ptr, SL("_exprLevel"), PH_NOISY_CC); if (Z_TYPE_P(block) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 385, block); + ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 378, block); zephir_check_call_status(); if (ZEPHIR_IS_LONG(exprLevel, 1)) { ZEPHIR_CPY_WRT(escapedCode, code); @@ -117848,7 +118576,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { } ZEPHIR_INIT_NVAR(_2); zephir_camelize(_2, name); - ZEPHIR_CALL_FUNCTION(&method, "lcfirst", NULL, 65, _2); + ZEPHIR_CALL_FUNCTION(&method, "lcfirst", NULL, 67, _2); zephir_check_call_status(); ZEPHIR_INIT_VAR(className); ZVAL_STRING(className, "Phalcon\\Tag", 1); @@ -117914,21 +118642,12 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { ZEPHIR_CONCAT_SVS(return_value, "constant(", arguments, ")"); RETURN_MM(); } - ZEPHIR_INIT_NVAR(_2); - object_init_ex(_2, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC); - zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_5); - ZEPHIR_CONCAT_SVSVSV(_5, "Undefined function '", name, "' in ", _3, " on line ", _4); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _5); - zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC); - ZEPHIR_MM_RESTORE(); - return; + ZEPHIR_CONCAT_SVSVS(return_value, "$this->callMacro('", name, "', array(", arguments, "))"); + RETURN_MM(); } - ZEPHIR_CALL_METHOD(&_8, this_ptr, "expression", &_0, 383, nameExpr); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "expression", &_0, 376, nameExpr); zephir_check_call_status(); - ZEPHIR_CONCAT_VSVS(return_value, _8, "(", arguments, ")"); + ZEPHIR_CONCAT_VSVS(return_value, _7, "(", arguments, ")"); RETURN_MM(); } @@ -117950,10 +118669,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) { ZEPHIR_OBS_VAR(type); - zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 586 TSRMLS_CC); + zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 579 TSRMLS_CC); if (ZEPHIR_IS_LONG(type, 265)) { ZEPHIR_OBS_VAR(name); - zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 593 TSRMLS_CC); + zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 586 TSRMLS_CC); if (ZEPHIR_IS_STRING(name, "empty")) { ZEPHIR_CONCAT_SVS(return_value, "empty(", left, ")"); RETURN_MM(); @@ -117981,33 +118700,33 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) { } if (ZEPHIR_IS_LONG(type, 350)) { ZEPHIR_OBS_VAR(testName); - zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 644 TSRMLS_CC); + zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 637 TSRMLS_CC); ZEPHIR_OBS_NVAR(name); if (zephir_array_isset_string_fetch(&name, testName, SS("value"), 0 TSRMLS_CC)) { if (ZEPHIR_IS_STRING(name, "divisibleby")) { - zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 648 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1); + zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 641 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, _1); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "(((", left, ") % (", _0, ")) == 0)"); RETURN_MM(); } if (ZEPHIR_IS_STRING(name, "sameas")) { - zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 655 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1); + zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 648 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, _1); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "(", left, ") === (", _0, ")"); RETURN_MM(); } if (ZEPHIR_IS_STRING(name, "type")) { - zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 662 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1); + zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 655 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, _1); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "gettype(", left, ") === (", _0, ")"); RETURN_MM(); } } } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, test); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, test); zephir_check_call_status(); ZEPHIR_CONCAT_VSV(return_value, left, " == ", _0); RETURN_MM(); @@ -118033,28 +118752,28 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { ZEPHIR_INIT_VAR(code); ZVAL_NULL(code); ZEPHIR_OBS_VAR(type); - zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 681 TSRMLS_CC); + zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 674 TSRMLS_CC); if (ZEPHIR_IS_LONG(type, 265)) { ZEPHIR_OBS_VAR(name); - zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 687 TSRMLS_CC); + zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 680 TSRMLS_CC); } else { if (!ZEPHIR_IS_LONG(type, 350)) { ZEPHIR_INIT_VAR(_0); - object_init_ex(_0, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC); - zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC); + object_init_ex(_0, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 688 TSRMLS_CC); + zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 688 TSRMLS_CC); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SVSV(_3, "Unknown filter type in ", _1, " on line ", _2); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 688 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_VAR(functionName); - zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 698 TSRMLS_CC); + zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 691 TSRMLS_CC); ZEPHIR_OBS_NVAR(name); - zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 699 TSRMLS_CC); + zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 692 TSRMLS_CC); } ZEPHIR_INIT_VAR(funcArguments); ZVAL_NULL(funcArguments); @@ -118064,9 +118783,9 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { if (zephir_array_isset_string_fetch(&funcArguments, filter, SS("arguments"), 0 TSRMLS_CC)) { if (!ZEPHIR_IS_STRING(name, "default")) { ZEPHIR_OBS_VAR(file); - zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC); + zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 707 TSRMLS_CC); ZEPHIR_OBS_VAR(line); - zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC); + zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 707 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); zephir_create_array(_4, 3, 0 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); @@ -118079,11 +118798,11 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { zephir_array_update_string(&_4, SL("file"), &file, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("line"), &line, PH_COPY | PH_SEPARATE); Z_SET_ISREF_P(funcArguments); - ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 386, funcArguments, _4); + ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 379, funcArguments, _4); Z_UNSET_ISREF_P(funcArguments); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 383, funcArguments); + ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 376, funcArguments); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(arguments, left); @@ -118098,7 +118817,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { zephir_array_fast_append(_4, funcArguments); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "compileFilter", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _0, _4); + ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 377, _0, _4); zephir_check_temp_parameter(_0); zephir_check_call_status(); if (Z_TYPE_P(code) == IS_STRING) { @@ -118126,14 +118845,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { } } ZEPHIR_INIT_NVAR(_0); - object_init_ex(_0, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC); - zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC); + object_init_ex(_0, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 770 TSRMLS_CC); + zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 770 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVSVSV(_3, "Invalid definition for user filter '", name, "' in ", _1, " on line ", _2); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 770 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -118255,14 +118974,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { RETURN_MM(); } ZEPHIR_INIT_NVAR(_0); - object_init_ex(_0, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC); - zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC); + object_init_ex(_0, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 959 TSRMLS_CC); + zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 959 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVSVSV(_3, "Unknown filter \"", name, "\" in ", _1, " on line ", _2); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 959 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -118296,7 +119015,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { zephir_array_fast_append(_0, expr); ZEPHIR_INIT_NVAR(_1); ZVAL_STRING(_1, "resolveExpression", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 384, _1, _0); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 377, _1, _0); zephir_check_temp_parameter(_1); zephir_check_call_status(); if (Z_TYPE_P(exprCode) == IS_STRING) { @@ -118307,22 +119026,22 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { if (!(zephir_array_isset_string_fetch(&type, expr, SS("type"), 0 TSRMLS_CC))) { ZEPHIR_INIT_NVAR(items); array_init(items); - zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1007); + zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1000); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) ) { ZEPHIR_GET_HVALUE(singleExpr, _5); - zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1000 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 383, _6); + zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 993 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 376, _6); zephir_check_call_status(); ZEPHIR_OBS_NVAR(name); if (zephir_array_isset_string_fetch(&name, singleExpr, SS("name"), 0 TSRMLS_CC)) { ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSV(_8, "'", name, "' => ", singleExprCode); - zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1002); + zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 995); } else { - zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1004); + zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 997); } } ZEPHIR_INIT_NVAR(exprCode); @@ -118336,24 +119055,24 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } ZEPHIR_OBS_NVAR(left); if (zephir_array_isset_string_fetch(&left, expr, SS("left"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 383, left); + ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 376, left); zephir_check_call_status(); } if (ZEPHIR_IS_LONG(type, 311)) { - zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1030 TSRMLS_CC); + zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1023 TSRMLS_CC); ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvetest", &_10, 0, _6, leftCode); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 124)) { - zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1038 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 387, _11, leftCode); + zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1031 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 380, _11, leftCode); zephir_check_call_status(); break; } ZEPHIR_OBS_NVAR(right); if (zephir_array_isset_string_fetch(&right, expr, SS("right"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 383, right); + ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 376, right); zephir_check_call_status(); } ZEPHIR_INIT_NVAR(exprCode); @@ -118425,17 +119144,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } if (ZEPHIR_IS_LONG(type, 258)) { ZEPHIR_OBS_NVAR(exprCode); - zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1105 TSRMLS_CC); + zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1098 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(type, 259)) { ZEPHIR_OBS_NVAR(exprCode); - zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1109 TSRMLS_CC); + zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1102 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(type, 260)) { ZEPHIR_INIT_NVAR(_1); - zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1113 TSRMLS_CC); + zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1106 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_13); ZVAL_STRING(&_13, "'", 0); ZEPHIR_SINIT_NVAR(_14); @@ -118461,7 +119180,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { break; } if (ZEPHIR_IS_LONG(type, 265)) { - zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1129 TSRMLS_CC); + zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1122 TSRMLS_CC); ZEPHIR_INIT_NVAR(exprCode); ZEPHIR_CONCAT_SV(exprCode, "$", _11); break; @@ -118529,7 +119248,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { if (ZEPHIR_IS_LONG(type, 365)) { ZEPHIR_OBS_NVAR(start); if (zephir_array_isset_string_fetch(&start, expr, SS("start"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 383, start); + ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 376, start); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(startCode); @@ -118537,7 +119256,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } ZEPHIR_OBS_NVAR(end); if (zephir_array_isset_string_fetch(&end, expr, SS("end"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 383, end); + ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 376, end); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(endCode); @@ -118628,8 +119347,8 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { break; } if (ZEPHIR_IS_LONG(type, 366)) { - zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1268 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 383, _6); + zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1261 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 376, _6); zephir_check_call_status(); ZEPHIR_INIT_NVAR(exprCode); ZEPHIR_CONCAT_SVSVSVS(exprCode, "(", _16, " ? ", leftCode, " : ", rightCode, ")"); @@ -118647,18 +119366,18 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } if (ZEPHIR_IS_LONG(type, 364)) { ZEPHIR_OBS_NVAR(exprCode); - zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1280 TSRMLS_CC); + zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1273 TSRMLS_CC); break; } ZEPHIR_INIT_NVAR(_1); - object_init_ex(_1, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC); - zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC); + object_init_ex(_1, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1277 TSRMLS_CC); + zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1277 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSVSV(_8, "Unknown expression ", type, " in ", _11, " on line ", _17); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_18, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1277 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -118689,7 +119408,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends } isStatementList = 1; if (!(zephir_array_isset_string(statements, SS("type")))) { - zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1324); + zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1317); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -118702,7 +119421,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends } } if (isStatementList == 1) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 388, statements); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 381, statements); zephir_check_call_status(); RETURN_MM(); } @@ -118734,7 +119453,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { if (!(zephir_array_isset_string(statement, SS("expr")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1352); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1345); return; } ZEPHIR_INIT_VAR(compilation); @@ -118749,15 +119468,15 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { ZEPHIR_INIT_VAR(prefixLevel); ZEPHIR_CONCAT_VV(prefixLevel, prefix, level); ZEPHIR_OBS_VAR(expr); - zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1370 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr); + zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1363 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 376, expr); zephir_check_call_status(); ZEPHIR_OBS_VAR(blockStatements); - zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1376 TSRMLS_CC); + zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1369 TSRMLS_CC); ZEPHIR_INIT_NVAR(forElse); ZVAL_BOOL(forElse, 0); if (Z_TYPE_P(blockStatements) == IS_ARRAY) { - zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1402); + zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1395); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -118780,7 +119499,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { } } } - ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 381, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_OBS_VAR(loopContext); zephir_read_property_this(&loopContext, this_ptr, SL("_loopPointers"), PH_NOISY_CC); @@ -118815,7 +119534,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { ZEPHIR_CPY_WRT(iterator, exprCode); } ZEPHIR_OBS_VAR(variable); - zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1431 TSRMLS_CC); + zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1424 TSRMLS_CC); ZEPHIR_OBS_VAR(key); if (zephir_array_isset_string_fetch(&key, statement, SS("key"), 0 TSRMLS_CC)) { ZEPHIR_INIT_LNVAR(_5); @@ -118828,7 +119547,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { } ZEPHIR_OBS_VAR(ifExpr); if (zephir_array_isset_string_fetch(&ifExpr, statement, SS("if_expr"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 383, ifExpr); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 376, ifExpr); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVS(_5, "if (", _12, ") { ?>"); @@ -118923,19 +119642,19 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileIf) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1522); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1515); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); - zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1528 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 388, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1521 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 381, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_INIT_VAR(compilation); ZEPHIR_CONCAT_SVSV(compilation, "", _1); ZEPHIR_OBS_VAR(blockStatements); if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("false_statements"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 381, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SV(_5, "", _4); @@ -118961,10 +119680,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileElseIf) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1557); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1550); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, ""); RETURN_MM(); @@ -118993,12 +119712,12 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1577); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1570); return; } - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 376, expr); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 383, expr); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 376, expr); zephir_check_call_status(); ZEPHIR_INIT_VAR(compilation); ZEPHIR_CONCAT_SVS(compilation, "di->get('viewCache'); "); @@ -119007,14 +119726,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) { ZEPHIR_INIT_VAR(_2); ZEPHIR_CONCAT_SVS(_2, "$_cacheKey[", exprCode, "]"); zephir_concat_self(&compilation, _2 TSRMLS_CC); - zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1587 TSRMLS_CC); + zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1580 TSRMLS_CC); if (ZEPHIR_IS_LONG(_3, 265)) { - zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1588 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1581 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", $", _4, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); } else { - zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1590 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1583 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", ", _4, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); @@ -119027,20 +119746,20 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) { ZEPHIR_INIT_LNVAR(_2); ZEPHIR_CONCAT_SVS(_2, "if ($_cacheKey[", exprCode, "] === null) { ?>"); zephir_concat_self(&compilation, _2 TSRMLS_CC); - zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1600 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 388, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1593 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 381, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_concat_self(&compilation, _6 TSRMLS_CC); ZEPHIR_OBS_NVAR(lifetime); if (zephir_array_isset_string_fetch(&lifetime, statement, SS("lifetime"), 0 TSRMLS_CC)) { - zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1606 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1599 TSRMLS_CC); if (ZEPHIR_IS_LONG(_4, 265)) { - zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1607 TSRMLS_CC); + zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1600 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, $", _7, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); } else { - zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1609 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1602 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, ", _4, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); @@ -119075,24 +119794,24 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileSet) { ZEPHIR_OBS_VAR(assignments); if (!(zephir_array_isset_string_fetch(&assignments, statement, SS("assignments"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1630); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1623); return; } ZEPHIR_INIT_VAR(compilation); ZVAL_STRING(compilation, ""); RETURN_MM(); @@ -119170,10 +119889,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileReturn) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1711); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1704); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, ""); RETURN_MM(); @@ -119197,14 +119916,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileAutoEscape) { ZEPHIR_OBS_VAR(autoescape); if (!(zephir_array_isset_string_fetch(&autoescape, statement, SS("enable"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1731); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1724); return; } ZEPHIR_OBS_VAR(oldAutoescape); zephir_read_property_this(&oldAutoescape, this_ptr, SL("_autoescape"), PH_NOISY_CC); zephir_update_property_this(this_ptr, SL("_autoescape"), autoescape TSRMLS_CC); - zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1740 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 388, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1733 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 381, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_autoescape"), oldAutoescape TSRMLS_CC); RETURN_CCTOR(compilation); @@ -119226,17 +119945,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileEcho) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1761); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1754); return; } - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); - zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1769 TSRMLS_CC); + zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1762 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 350)) { - zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1771 TSRMLS_CC); - zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1773 TSRMLS_CC); + zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1764 TSRMLS_CC); + zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1766 TSRMLS_CC); if (ZEPHIR_IS_LONG(_1, 265)) { - zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1778 TSRMLS_CC); + zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1771 TSRMLS_CC); if (ZEPHIR_IS_STRING(_2, "super")) { RETURN_CCTOR(exprCode); } @@ -119268,14 +119987,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) { ZEPHIR_OBS_VAR(pathExpr); if (!(zephir_array_isset_string_fetch(&pathExpr, statement, SS("path"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1806); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1799); return; } - zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1813 TSRMLS_CC); + zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1806 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 260)) { if (!(zephir_array_isset_string(statement, SS("params")))) { ZEPHIR_OBS_VAR(path); - zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1823 TSRMLS_CC); + zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1816 TSRMLS_CC); ZEPHIR_OBS_VAR(view); zephir_read_property_this(&view, this_ptr, SL("_view"), PH_NOISY_CC); if (Z_TYPE_P(view) == IS_OBJECT) { @@ -119303,14 +120022,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) { RETURN_CCTOR(compilation); } } - ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 383, pathExpr); + ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 376, pathExpr); zephir_check_call_status(); ZEPHIR_OBS_VAR(params); if (!(zephir_array_isset_string_fetch(¶ms, statement, SS("params"), 0 TSRMLS_CC))) { ZEPHIR_CONCAT_SVS(return_value, "partial(", path, "); ?>"); RETURN_MM(); } - ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 383, params); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 376, params); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "partial(", path, ", ", _1, "); ?>"); RETURN_MM(); @@ -119337,18 +120056,18 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { ZEPHIR_OBS_VAR(name); if (!(zephir_array_isset_string_fetch(&name, statement, SS("name"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1878); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1871); return; } _0 = zephir_fetch_nproperty_this(this_ptr, SL("_macros"), PH_NOISY_CC); if (zephir_array_isset(_0, name)) { ZEPHIR_INIT_VAR(_1); - object_init_ex(_1, phalcon_mvc_view_exception_ce); + object_init_ex(_1, phalcon_mvc_view_engine_volt_exception_ce); ZEPHIR_INIT_VAR(_2); ZEPHIR_CONCAT_SVS(_2, "Macro '", name, "' is already defined"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1885 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1878 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -119366,7 +120085,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { ZEPHIR_INIT_LNVAR(_2); ZEPHIR_CONCAT_VS(_2, macroName, " = function($__p = null) { "); zephir_concat_self(&code, _2 TSRMLS_CC); - zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1923); + zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1916); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -119374,7 +120093,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { ZEPHIR_GET_HMKEY(position, _4, _3); ZEPHIR_GET_HVALUE(parameter, _5); ZEPHIR_OBS_NVAR(variableName); - zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1907 TSRMLS_CC); + zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1900 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_6); ZEPHIR_CONCAT_SVS(_6, "if (isset($__p[", position, "])) { "); zephir_concat_self(&code, _6 TSRMLS_CC); @@ -119391,7 +120110,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { zephir_concat_self_str(&code, SL(" } else { ") TSRMLS_CC); ZEPHIR_OBS_NVAR(defaultValue); if (zephir_array_isset_string_fetch(&defaultValue, parameter, SS("default"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 383, defaultValue); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 376, defaultValue); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SVSVS(_12, "$", variableName, " = ", _10, ";"); @@ -119407,7 +120126,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { } ZEPHIR_OBS_VAR(blockStatements); if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("block_statements"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 381, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_2); ZEPHIR_CONCAT_VS(_2, _10, " + +#include +#include +#include + + + +ZEPHIR_INIT_CLASS(Phalcon_Mvc_View_Engine_Volt_Exception) { + + ZEPHIR_REGISTER_CLASS_EX(Phalcon\\Mvc\\View\\Engine\\Volt, Exception, phalcon, mvc_view_engine_volt_exception, phalcon_mvc_view_exception_ce, NULL, 0); + + return SUCCESS; + +} + + + /* Driver template for the LEMON parser generator. ** The author disclaims copyright to this source code. */ @@ -130015,7 +130756,7 @@ static PHP_METHOD(Phalcon_Paginator_Adapter_NativeArray, getPaginate) { number = zephir_fast_count_int(items TSRMLS_CC); ZEPHIR_SINIT_VAR(_2); ZVAL_LONG(&_2, show); - ZEPHIR_CALL_FUNCTION(&_3, "floatval", NULL, 311, &_2); + ZEPHIR_CALL_FUNCTION(&_3, "floatval", NULL, 304, &_2); zephir_check_call_status(); roundedTotal = zephir_safe_div_long_zval(number, _3 TSRMLS_CC); totalPages = (int) (roundedTotal); @@ -130026,7 +130767,7 @@ static PHP_METHOD(Phalcon_Paginator_Adapter_NativeArray, getPaginate) { ZVAL_LONG(&_2, (show * ((pageNumber - 1)))); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, show); - ZEPHIR_CALL_FUNCTION(&_5, "array_slice", NULL, 379, items, &_2, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "array_slice", NULL, 372, items, &_2, &_4); zephir_check_call_status(); ZEPHIR_CPY_WRT(items, _5); if (pageNumber < totalPages) { @@ -130336,7 +131077,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, connect) { ZEPHIR_INIT_VAR(_3); ZVAL_NULL(_3); Z_SET_ISREF_P(_2); - ZEPHIR_CALL_FUNCTION(&connection, "fsockopen", NULL, 390, _0, _1, _2, _3); + ZEPHIR_CALL_FUNCTION(&connection, "fsockopen", NULL, 383, _0, _1, _2, _3); Z_UNSET_ISREF_P(_2); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_RESOURCE) { @@ -130345,7 +131086,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, connect) { } ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, -1); - ZEPHIR_CALL_FUNCTION(NULL, "stream_set_timeout", NULL, 391, connection, &_4, ZEPHIR_GLOBAL(global_null)); + ZEPHIR_CALL_FUNCTION(NULL, "stream_set_timeout", NULL, 384, connection, &_4, ZEPHIR_GLOBAL(global_null)); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_connection"), connection TSRMLS_CC); RETURN_CCTOR(connection); @@ -130382,7 +131123,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, put) { ZEPHIR_INIT_NVAR(ttr); ZVAL_LONG(ttr, 86400); } - ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 71, data); + ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 73, data); zephir_check_call_status(); ZEPHIR_INIT_VAR(length); ZVAL_LONG(length, zephir_fast_strlen_ev(serialized)); @@ -130392,7 +131133,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, put) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", &_1, 0, serialized); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&status, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 128 TSRMLS_CC); _2 = !ZEPHIR_IS_STRING(status, "INSERTED"); @@ -130428,7 +131169,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, reserve) { } ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, command); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&_0, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 153 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_0, "RESERVED")) { @@ -130439,9 +131180,9 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, reserve) { zephir_array_fetch_long(&_3, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 163 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_2, this_ptr, "read", NULL, 0, _3); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "unserialize", NULL, 72, _2); + ZEPHIR_CALL_FUNCTION(&_4, "unserialize", NULL, 74, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 393, this_ptr, _1, _4); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 386, this_ptr, _1, _4); zephir_check_call_status(); RETURN_MM(); @@ -130473,7 +131214,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, choose) { ZEPHIR_CONCAT_SV(_0, "use ", tube); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 176 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "USING")) { @@ -130510,7 +131251,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, watch) { ZEPHIR_CONCAT_SV(_0, "watch ", tube); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 193 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "WATCHING")) { @@ -130533,7 +131274,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, stats) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_temp_parameter(_0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 394); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 387); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 210 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "OK")) { @@ -130570,7 +131311,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, statsTube) { ZEPHIR_CONCAT_SV(_0, "stats-tube ", tube); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 394); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 387); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 227 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "OK")) { @@ -130581,6 +131322,29 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, statsTube) { } +static PHP_METHOD(Phalcon_Queue_Beanstalk, listTubes) { + + int ZEPHIR_LAST_CALL_STATUS; + zval *response = NULL, *_0, *_1, *_2; + + ZEPHIR_MM_GROW(); + + ZEPHIR_INIT_VAR(_0); + ZVAL_STRING(_0, "list-tubes", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); + zephir_check_temp_parameter(_0); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 387); + zephir_check_call_status(); + zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 244 TSRMLS_CC); + if (!ZEPHIR_IS_STRING(_1, "OK")) { + RETURN_MM_BOOL(0); + } + zephir_array_fetch_long(&_2, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 248 TSRMLS_CC); + RETURN_CTOR(_2); + +} + static PHP_METHOD(Phalcon_Queue_Beanstalk, peekReady) { int ZEPHIR_LAST_CALL_STATUS; @@ -130593,20 +131357,20 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, peekReady) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_temp_parameter(_0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); - zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 244 TSRMLS_CC); + zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 261 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "FOUND")) { RETURN_MM_BOOL(0); } object_init_ex(return_value, phalcon_queue_beanstalk_job_ce); - zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 248 TSRMLS_CC); - zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 248 TSRMLS_CC); + zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); + zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, this_ptr, "read", NULL, 0, _4); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 72, _3); + ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 74, _3); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 393, this_ptr, _2, _5); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 386, this_ptr, _2, _5); zephir_check_call_status(); RETURN_MM(); @@ -130624,20 +131388,20 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, peekBuried) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_temp_parameter(_0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); - zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 261 TSRMLS_CC); + zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 278 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "FOUND")) { RETURN_MM_BOOL(0); } object_init_ex(return_value, phalcon_queue_beanstalk_job_ce); - zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); - zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); + zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 282 TSRMLS_CC); + zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 282 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, this_ptr, "read", NULL, 0, _4); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 72, _3); + ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 74, _3); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 393, this_ptr, _2, _5); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 386, this_ptr, _2, _5); zephir_check_call_status(); RETURN_MM(); @@ -130668,13 +131432,13 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, readYaml) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); ZEPHIR_OBS_VAR(status); - zephir_array_fetch_long(&status, response, 0, PH_NOISY, "phalcon/queue/beanstalk.zep", 290 TSRMLS_CC); + zephir_array_fetch_long(&status, response, 0, PH_NOISY, "phalcon/queue/beanstalk.zep", 307 TSRMLS_CC); if (zephir_fast_count_int(response TSRMLS_CC) > 1) { ZEPHIR_OBS_VAR(numberOfBytes); - zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 293 TSRMLS_CC); + zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 310 TSRMLS_CC); ZEPHIR_CALL_METHOD(&response, this_ptr, "read", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_FUNCTION(&data, "yaml_parse", NULL, 0, response); @@ -130723,13 +131487,13 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, read) { } ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, (length + 2)); - ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 395, connection, &_0); + ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 388, connection, &_0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 396, connection); + ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 389, connection); zephir_check_call_status(); - zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 337 TSRMLS_CC); + zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 354 TSRMLS_CC); if (zephir_is_true(_2)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 338); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 355); return; } ZEPHIR_SINIT_NVAR(_0); @@ -130741,7 +131505,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, read) { ZVAL_LONG(&_0, 16384); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "\r\n", 0); - ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 397, connection, &_0, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 390, connection, &_0, &_3); zephir_check_call_status(); RETURN_MM(); @@ -130773,7 +131537,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, write) { ZEPHIR_CPY_WRT(packet, _0); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, zephir_fast_strlen_ev(packet)); - ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 398, connection, packet, &_1); + ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 391, connection, packet, &_1); zephir_check_call_status(); RETURN_MM(); @@ -131065,6 +131829,315 @@ ZEPHIR_INIT_CLASS(Phalcon_Security_Exception) { +#ifdef HAVE_CONFIG_H +#endif + +#include + +#include +#include +#include + + + +ZEPHIR_INIT_CLASS(Phalcon_Security_Random) { + + ZEPHIR_REGISTER_CLASS(Phalcon\\Security, Random, phalcon, security_random, phalcon_security_random_method_entry, 0); + + return SUCCESS; + +} + +static PHP_METHOD(Phalcon_Security_Random, bytes) { + + zval *len_param = NULL, *handle = NULL, *ret = NULL, *_0 = NULL, _1, _2 = zval_used_for_init, _3; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &len_param); + + if (!len_param) { + len = 16; + } else { + len = zephir_get_intval(len_param); + } + + + if (len <= 0) { + len = 16; + } + if ((zephir_function_exists_ex(SS("\\sodium\\randombytes_buf") TSRMLS_CC) == SUCCESS)) { + ZEPHIR_INIT_VAR(_0); + ZVAL_LONG(_0, len); + ZEPHIR_RETURN_CALL_FUNCTION("\\sodium\\randombytes_buf", NULL, 0, _0); + zephir_check_call_status(); + RETURN_MM(); + } + if ((zephir_function_exists_ex(SS("openssl_random_pseudo_bytes") TSRMLS_CC) == SUCCESS)) { + ZEPHIR_INIT_NVAR(_0); + ZVAL_LONG(_0, len); + ZEPHIR_RETURN_CALL_FUNCTION("openssl_random_pseudo_bytes", NULL, 400, _0); + zephir_check_call_status(); + RETURN_MM(); + } + ZEPHIR_SINIT_VAR(_1); + ZVAL_STRING(&_1, "/dev/urandom", 0); + if ((zephir_file_exists(&_1 TSRMLS_CC) == SUCCESS)) { + ZEPHIR_SINIT_VAR(_2); + ZVAL_STRING(&_2, "/dev/urandom", 0); + ZEPHIR_SINIT_VAR(_3); + ZVAL_STRING(&_3, "rb", 0); + ZEPHIR_CALL_FUNCTION(&handle, "fopen", NULL, 285, &_2, &_3); + zephir_check_call_status(); + if (!ZEPHIR_IS_FALSE_IDENTICAL(handle)) { + ZEPHIR_SINIT_NVAR(_2); + ZVAL_LONG(&_2, 0); + ZEPHIR_CALL_FUNCTION(NULL, "stream_set_read_buffer", NULL, 403, handle, &_2); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_2); + ZVAL_LONG(&_2, len); + ZEPHIR_CALL_FUNCTION(&ret, "fread", NULL, 388, handle, &_2); + zephir_check_call_status(); + zephir_fclose(handle TSRMLS_CC); + if (zephir_fast_strlen_ev(ret) != len) { + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_security_exception_ce, "Unexpected partial read from random device", "phalcon/security/random.zep", 117); + return; + } + RETURN_CCTOR(ret); + } + } + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_security_exception_ce, "No random device", "phalcon/security/random.zep", 124); + return; + +} + +static PHP_METHOD(Phalcon_Security_Random, hex) { + + zval *len_param = NULL, *_0 = NULL, *_1, _2, *_3 = NULL; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &len_param); + + if (!len_param) { + len = 0; + } else { + len = zephir_get_intval(len_param); + } + + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, len); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "bytes", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_SINIT_VAR(_2); + ZVAL_STRING(&_2, "H*", 0); + ZEPHIR_CALL_FUNCTION(&_3, "unpack", NULL, 404, &_2, _0); + zephir_check_call_status(); + Z_SET_ISREF_P(_3); + ZEPHIR_RETURN_CALL_FUNCTION("array_shift", NULL, 121, _3); + Z_UNSET_ISREF_P(_3); + zephir_check_call_status(); + RETURN_MM(); + +} + +static PHP_METHOD(Phalcon_Security_Random, base64) { + + zval *len_param = NULL, *_0 = NULL, *_1; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &len_param); + + if (!len_param) { + len = 0; + } else { + len = zephir_get_intval(len_param); + } + + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, len); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "bytes", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", NULL, 114, _0); + zephir_check_call_status(); + RETURN_MM(); + +} + +static PHP_METHOD(Phalcon_Security_Random, base64Safe) { + + zend_bool padding; + zval *len_param = NULL, *padding_param = NULL, *s = NULL, *_0 = NULL, *_1 = NULL, *_2, _3; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 2, &len_param, &padding_param); + + if (!len_param) { + len = 0; + } else { + len = zephir_get_intval(len_param); + } + if (!padding_param) { + padding = 0; + } else { + padding = zephir_get_boolval(padding_param); + } + + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, len); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "base64", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_INIT_NVAR(_1); + ZVAL_STRING(_1, "#[^a-z0-9_=-]+#i", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_INIT_VAR(_2); + ZVAL_STRING(_2, "", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_FUNCTION(&s, "preg_replace", NULL, 29, _1, _2, _0); + zephir_check_temp_parameter(_1); + zephir_check_temp_parameter(_2); + zephir_check_call_status(); + if (!(padding)) { + ZEPHIR_SINIT_VAR(_3); + ZVAL_STRING(&_3, "=", 0); + zephir_fast_trim(return_value, s, &_3, ZEPHIR_TRIM_BOTH TSRMLS_CC); + RETURN_MM(); + } + RETURN_CCTOR(s); + +} + +static PHP_METHOD(Phalcon_Security_Random, uuid) { + + int ZEPHIR_LAST_CALL_STATUS; + zval *ary = NULL, *_0 = NULL, *_1 = NULL, _2 = zval_used_for_init, *_3 = NULL, *_4, *_5, *_6, *_7; + + ZEPHIR_MM_GROW(); + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, 16); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "bytes", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_SINIT_VAR(_2); + ZVAL_STRING(&_2, "N1a/n1b/n1c/n1d/n1e/N1f", 0); + ZEPHIR_CALL_FUNCTION(&_3, "unpack", NULL, 404, &_2, _0); + zephir_check_call_status(); + ZEPHIR_CALL_FUNCTION(&ary, "array_values", NULL, 215, _3); + zephir_check_call_status(); + zephir_array_fetch_long(&_4, ary, 2, PH_NOISY | PH_READONLY, "phalcon/security/random.zep", 222 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_1); + ZVAL_LONG(_1, ((((int) (zephir_get_numberval(_4)) & 0x0fff)) | 0x4000)); + zephir_array_update_long(&ary, 2, &_1, PH_COPY | PH_SEPARATE, "phalcon/security/random.zep", 222); + zephir_array_fetch_long(&_5, ary, 3, PH_NOISY | PH_READONLY, "phalcon/security/random.zep", 223 TSRMLS_CC); + ZEPHIR_INIT_VAR(_6); + ZVAL_LONG(_6, ((((int) (zephir_get_numberval(_5)) & 0x3fff)) | 0x8000)); + zephir_array_update_long(&ary, 3, &_6, PH_COPY | PH_SEPARATE, "phalcon/security/random.zep", 223); + ZEPHIR_INIT_VAR(_7); + ZVAL_STRING(_7, "%08x-%04x-%04x-%04x-%04x%08x", ZEPHIR_TEMP_PARAM_COPY); + Z_SET_ISREF_P(ary); + ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 379, ary, _7); + zephir_check_temp_parameter(_7); + Z_UNSET_ISREF_P(ary); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_2); + ZVAL_STRING(&_2, "sprintf", 0); + ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, &_2, ary); + zephir_check_call_status(); + RETURN_MM(); + +} + +static PHP_METHOD(Phalcon_Security_Random, number) { + + zephir_fcall_cache_entry *_4 = NULL, *_9 = NULL, *_14 = NULL, *_18 = NULL; + zval *len_param = NULL, *hex = NULL, *bin = NULL, *mask = NULL, *rnd = NULL, *ret = NULL, *first = NULL, _0 = zval_used_for_init, *_1, _2, *_3, *_8 = NULL, _10 = zval_used_for_init, _11 = zval_used_for_init, _12 = zval_used_for_init, *_13 = NULL, _15 = zval_used_for_init, _16 = zval_used_for_init, *_17 = NULL; + int len, ZEPHIR_LAST_CALL_STATUS, _5, _6, _7; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &len_param); + + len = zephir_get_intval(len_param); + + + if (len > 0) { + ZEPHIR_SINIT_VAR(_0); + ZVAL_LONG(&_0, len); + ZEPHIR_CALL_FUNCTION(&hex, "dechex", NULL, 405, &_0); + zephir_check_call_status(); + if (((zephir_fast_strlen_ev(hex) & 1)) == 1) { + ZEPHIR_INIT_VAR(_1); + ZEPHIR_CONCAT_SV(_1, "0", hex); + ZEPHIR_CPY_WRT(hex, _1); + } + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "H*", 0); + ZEPHIR_CALL_FUNCTION(&bin, "pack", NULL, 406, &_0, hex); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_LONG(&_0, 0); + ZEPHIR_SINIT_VAR(_2); + ZVAL_LONG(&_2, 1); + ZEPHIR_INIT_VAR(_3); + zephir_substr(_3, bin, 0 , 1 , 0); + ZEPHIR_CALL_FUNCTION(&mask, "ord", &_4, 132, _3); + zephir_check_call_status(); + _5 = ((int) (zephir_get_numberval(mask)) | (((int) (zephir_get_numberval(mask)) >> 1))); + ZEPHIR_INIT_NVAR(mask); + ZVAL_LONG(mask, _5); + _6 = ((int) (zephir_get_numberval(mask)) | (((int) (zephir_get_numberval(mask)) >> 2))); + ZEPHIR_INIT_NVAR(mask); + ZVAL_LONG(mask, _6); + _7 = ((int) (zephir_get_numberval(mask)) | (((int) (zephir_get_numberval(mask)) >> 4))); + ZEPHIR_INIT_NVAR(mask); + ZVAL_LONG(mask, _7); + do { + ZEPHIR_INIT_NVAR(_8); + ZVAL_LONG(_8, zephir_fast_strlen_ev(bin)); + ZEPHIR_CALL_METHOD(&rnd, this_ptr, "bytes", &_9, 0, _8); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_10); + ZVAL_LONG(&_10, 0); + ZEPHIR_SINIT_NVAR(_11); + ZVAL_LONG(&_11, 1); + ZEPHIR_INIT_NVAR(_8); + zephir_substr(_8, rnd, 0 , 1 , 0); + ZEPHIR_CALL_FUNCTION(&first, "ord", &_4, 132, _8); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_12); + zephir_bitwise_and_function(&_12, first, mask TSRMLS_CC); + ZEPHIR_CALL_FUNCTION(&_13, "chr", &_14, 130, &_12); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_15); + ZVAL_LONG(&_15, 0); + ZEPHIR_SINIT_NVAR(_16); + ZVAL_LONG(&_16, 1); + ZEPHIR_CALL_FUNCTION(&_17, "substr_replace", &_18, 407, rnd, _13, &_15, &_16); + zephir_check_call_status(); + ZEPHIR_CPY_WRT(rnd, _17); + } while (ZEPHIR_LT(bin, rnd)); + ZEPHIR_SINIT_NVAR(_10); + ZVAL_STRING(&_10, "H*", 0); + ZEPHIR_CALL_FUNCTION(&ret, "unpack", NULL, 404, &_10, rnd); + zephir_check_call_status(); + Z_SET_ISREF_P(ret); + ZEPHIR_CALL_FUNCTION(&_13, "array_shift", NULL, 121, ret); + Z_UNSET_ISREF_P(ret); + zephir_check_call_status(); + ZEPHIR_RETURN_CALL_FUNCTION("hexdec", NULL, 408, _13); + zephir_check_call_status(); + RETURN_MM(); + } + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_security_exception_ce, "Require a positive integer > 0", "phalcon/security/random.zep", 269); + return; + +} + + + + #ifdef HAVE_CONFIG_H #endif @@ -131125,7 +132198,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, start) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 54); + ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 55); zephir_check_call_status(); if (!(zephir_is_true(_0))) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_started"), PH_NOISY_CC); @@ -131136,7 +132209,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, start) { _2 = !ZEPHIR_IS_LONG_IDENTICAL(_3, 2); } if (_2) { - ZEPHIR_CALL_FUNCTION(NULL, "session_start", NULL, 55); + ZEPHIR_CALL_FUNCTION(NULL, "session_start", NULL, 56); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_started"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); RETURN_MM_BOOL(1); @@ -131183,7 +132256,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, setName) { zephir_get_strval(name, name_param); - ZEPHIR_CALL_FUNCTION(NULL, "session_name", NULL, 56, name); + ZEPHIR_CALL_FUNCTION(NULL, "session_name", NULL, 57, name); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -131195,16 +132268,38 @@ static PHP_METHOD(Phalcon_Session_Adapter, getName) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("session_name", NULL, 56); + ZEPHIR_RETURN_CALL_FUNCTION("session_name", NULL, 57); zephir_check_call_status(); RETURN_MM(); } +static PHP_METHOD(Phalcon_Session_Adapter, regenerateId) { + + int ZEPHIR_LAST_CALL_STATUS; + zval *deleteOldSession_param = NULL; + zend_bool deleteOldSession; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &deleteOldSession_param); + + if (!deleteOldSession_param) { + deleteOldSession = 1; + } else { + deleteOldSession = zephir_get_boolval(deleteOldSession_param); + } + + + ZEPHIR_CALL_FUNCTION(NULL, "session_regenerate_id", NULL, 58, (deleteOldSession ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_check_call_status(); + RETURN_THIS(); + +} + static PHP_METHOD(Phalcon_Session_Adapter, get) { zend_bool remove; - zval *index_param = NULL, *defaultValue = NULL, *remove_param = NULL, *value, *key, *_0, *_SESSION; + zval *index_param = NULL, *defaultValue = NULL, *remove_param = NULL, *value, *key = NULL, *uniqueId, *_SESSION; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -131222,9 +132317,13 @@ static PHP_METHOD(Phalcon_Session_Adapter, get) { } - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(key); - ZEPHIR_CONCAT_VV(key, _0, index); + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(key); + ZEPHIR_CONCAT_VSV(key, uniqueId, "#", index); + } else { + ZEPHIR_CPY_WRT(key, index); + } ZEPHIR_OBS_VAR(value); if (zephir_array_isset_fetch(&value, _SESSION, key, 0 TSRMLS_CC)) { if (remove) { @@ -131239,8 +132338,8 @@ static PHP_METHOD(Phalcon_Session_Adapter, get) { static PHP_METHOD(Phalcon_Session_Adapter, set) { - int _2; - zval *index_param = NULL, *value, *_SESSION, *_0, *_1; + int _1; + zval *index_param = NULL, *value, *uniqueId, *_SESSION, *_0; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -131250,12 +132349,20 @@ static PHP_METHOD(Phalcon_Session_Adapter, set) { zephir_get_strval(index, index_param); - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_1); - ZEPHIR_CONCAT_VV(_1, _0, index); - _2 = zephir_maybe_separate_zval(&_SESSION); - zephir_array_update_zval(&_SESSION, _1, &value, PH_COPY | PH_SEPARATE); - if (_2) { + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + ZEPHIR_CONCAT_VSV(_0, uniqueId, "#", index); + _1 = zephir_maybe_separate_zval(&_SESSION); + zephir_array_update_zval(&_SESSION, _0, &value, PH_COPY | PH_SEPARATE); + if (_1) { + ZEND_SET_SYMBOL(&EG(symbol_table), "_SESSION", _SESSION); + } + RETURN_MM_NULL(); + } + _1 = zephir_maybe_separate_zval(&_SESSION); + zephir_array_update_zval(&_SESSION, index, &value, PH_COPY | PH_SEPARATE); + if (_1) { ZEND_SET_SYMBOL(&EG(symbol_table), "_SESSION", _SESSION); } ZEPHIR_MM_RESTORE(); @@ -131264,7 +132371,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, set) { static PHP_METHOD(Phalcon_Session_Adapter, has) { - zval *index_param = NULL, *_SESSION, *_0, *_1; + zval *index_param = NULL, *uniqueId, *_SESSION, *_0; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -131274,16 +132381,19 @@ static PHP_METHOD(Phalcon_Session_Adapter, has) { zephir_get_strval(index, index_param); - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_1); - ZEPHIR_CONCAT_VV(_1, _0, index); - RETURN_MM_BOOL(zephir_array_isset(_SESSION, _1)); + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + ZEPHIR_CONCAT_VSV(_0, uniqueId, "#", index); + RETURN_MM_BOOL(zephir_array_isset(_SESSION, _0)); + } + RETURN_MM_BOOL(zephir_array_isset(_SESSION, index)); } static PHP_METHOD(Phalcon_Session_Adapter, remove) { - zval *index_param = NULL, *_0, *_1, *_SESSION; + zval *index_param = NULL, *uniqueId, *_0, *_SESSION; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -131293,10 +132403,14 @@ static PHP_METHOD(Phalcon_Session_Adapter, remove) { zephir_get_strval(index, index_param); - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_1); - ZEPHIR_CONCAT_VV(_1, _0, index); - zephir_array_unset(&_SESSION, _1, PH_SEPARATE); + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + ZEPHIR_CONCAT_VSV(_0, uniqueId, "#", index); + zephir_array_unset(&_SESSION, _0, PH_SEPARATE); + RETURN_MM_NULL(); + } + zephir_array_unset(&_SESSION, index, PH_SEPARATE); ZEPHIR_MM_RESTORE(); } @@ -131307,7 +132421,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, getId) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("session_id", NULL, 57); + ZEPHIR_RETURN_CALL_FUNCTION("session_id", NULL, 59); zephir_check_call_status(); RETURN_MM(); @@ -131325,7 +132439,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, setId) { zephir_get_strval(id, id_param); - ZEPHIR_CALL_FUNCTION(NULL, "session_id", NULL, 57, id); + ZEPHIR_CALL_FUNCTION(NULL, "session_id", NULL, 59, id); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -131341,11 +132455,47 @@ static PHP_METHOD(Phalcon_Session_Adapter, isStarted) { static PHP_METHOD(Phalcon_Session_Adapter, destroy) { int ZEPHIR_LAST_CALL_STATUS; + HashTable *_2; + HashPosition _1; + zval *removeData_param = NULL, *uniqueId, *key = NULL, *_SESSION = NULL, *_0 = NULL, **_3, *_4 = NULL; + zend_bool removeData; ZEPHIR_MM_GROW(); + zephir_get_global(&_SESSION, SS("_SESSION") TSRMLS_CC); + zephir_fetch_params(1, 0, 1, &removeData_param); + if (!removeData_param) { + removeData = 0; + } else { + removeData = zephir_get_boolval(removeData_param); + } + + + if (removeData) { + ZEPHIR_OBS_VAR(uniqueId); + zephir_read_property_this(&uniqueId, this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + zephir_is_iterable(_SESSION, &_2, &_1, 1, 0, "phalcon/session/adapter.zep", 265); + for ( + ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS + ; zephir_hash_move_forward_ex(_2, &_1) + ) { + ZEPHIR_GET_HMKEY(key, _2, _1); + ZEPHIR_GET_HVALUE(_0, _3); + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_VS(_4, uniqueId, "#"); + if (zephir_start_with(key, _4, NULL)) { + zephir_array_unset(&_SESSION, key, PH_SEPARATE); + } + } + } else { + ZEPHIR_INIT_NVAR(_SESSION); + array_init(_SESSION); + } + } zephir_update_property_this(this_ptr, SL("_started"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); - ZEPHIR_RETURN_CALL_FUNCTION("session_destroy", NULL, 58); + ZEPHIR_RETURN_CALL_FUNCTION("session_destroy", NULL, 60); zephir_check_call_status(); RETURN_MM(); @@ -131359,7 +132509,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, status) { ZEPHIR_MM_GROW(); if (!(zephir_is_php_version(50300))) { - ZEPHIR_CALL_FUNCTION(&status, "session_status", NULL, 59); + ZEPHIR_CALL_FUNCTION(&status, "session_status", NULL, 61); zephir_check_call_status(); do { if (ZEPHIR_IS_LONG(status, 0)) { @@ -131487,6 +132637,8 @@ ZEPHIR_DOC_METHOD(Phalcon_Session_AdapterInterface, isStarted); ZEPHIR_DOC_METHOD(Phalcon_Session_AdapterInterface, destroy); +ZEPHIR_DOC_METHOD(Phalcon_Session_AdapterInterface, regenerateId); + @@ -131613,7 +132765,7 @@ static PHP_METHOD(Phalcon_Session_Bag, initialize) { static PHP_METHOD(Phalcon_Session_Bag, destroy) { int ZEPHIR_LAST_CALL_STATUS; - zval *_0, *_1, *_2; + zval *_0, *_1, *_2, *_3; ZEPHIR_MM_GROW(); @@ -131622,9 +132774,12 @@ static PHP_METHOD(Phalcon_Session_Bag, destroy) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "initialize", NULL, 0); zephir_check_call_status(); } - _1 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _1, "remove", NULL, 0, _2); + ZEPHIR_INIT_VAR(_1); + array_init(_1); + zephir_update_property_this(this_ptr, SL("_data"), _1 TSRMLS_CC); + _2 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); + _3 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(NULL, _2, "remove", NULL, 0, _3); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -131825,7 +132980,7 @@ static PHP_METHOD(Phalcon_Session_Bag, __isset) { static PHP_METHOD(Phalcon_Session_Bag, remove) { int ZEPHIR_LAST_CALL_STATUS; - zval *property_param = NULL, *_0, *_1, *_2, *_3, *_4; + zval *property_param = NULL, *data, *_0, *_1; zval *property = NULL; ZEPHIR_MM_GROW(); @@ -131844,15 +132999,15 @@ static PHP_METHOD(Phalcon_Session_Bag, remove) { } - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - if (zephir_array_isset(_0, property)) { - _1 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - zephir_array_unset(&_1, property, PH_SEPARATE); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); - _3 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _2, "set", NULL, 0, _3, _4); + ZEPHIR_OBS_VAR(data); + zephir_read_property_this(&data, this_ptr, SL("_data"), PH_NOISY_CC); + if (zephir_array_isset(data, property)) { + zephir_array_unset(&data, property, PH_SEPARATE); + _0 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(NULL, _0, "set", NULL, 0, _1, data); zephir_check_call_status(); + zephir_update_property_this(this_ptr, SL("_data"), data TSRMLS_CC); RETURN_MM_BOOL(1); } RETURN_MM_BOOL(0); @@ -131918,7 +133073,7 @@ static PHP_METHOD(Phalcon_Session_Bag, getIterator) { } object_init_ex(return_value, zephir_get_internal_ce(SS("arrayiterator") TSRMLS_CC)); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 412, _1); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 411, _1); zephir_check_call_status(); RETURN_MM(); @@ -132206,7 +133361,7 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); ZEPHIR_INIT_VAR(_4); zephir_create_array(_4, 4, 0 TSRMLS_CC); @@ -132214,7 +133369,7 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) { zephir_array_update_string(&_4, SL("client"), &client, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("prefix"), &prefix, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("statsKey"), &statsKey, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, _4); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 312, _1, _4); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_libmemcached"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); @@ -132253,9 +133408,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) { ZEPHIR_INIT_NVAR(_6); ZVAL_STRING(_6, "gc", 1); zephir_array_fast_append(_11, _6); - ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _5, _7, _8, _9, _10, _11); + ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 409, _5, _7, _8, _9, _10, _11); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 411, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 410, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -132431,9 +133586,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 314, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -132472,9 +133627,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) { ZEPHIR_INIT_NVAR(_5); ZVAL_STRING(_5, "gc", 1); zephir_array_fast_append(_10, _5); - ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10); + ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 409, _4, _6, _7, _8, _9, _10); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 411, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 410, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -132648,9 +133803,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 315, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -132689,9 +133844,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct) { ZEPHIR_INIT_NVAR(_5); ZVAL_STRING(_5, "gc", 1); zephir_array_fast_append(_10, _5); - ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10); + ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 409, _4, _6, _7, _8, _9, _10); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_redis_ce, this_ptr, "__construct", &_11, 411, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_redis_ce, this_ptr, "__construct", &_11, 410, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -132932,7 +134087,7 @@ static PHP_METHOD(Phalcon_Tag_Select, selectField) { ZEPHIR_GET_CONSTANT(_6, "PHP_EOL"); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, "", _6); - ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 416, options, using, value, _7); + ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 415, options, using, value, _7); zephir_check_call_status(); zephir_concat_self(&code, _8 TSRMLS_CC); } else { @@ -132941,7 +134096,7 @@ static PHP_METHOD(Phalcon_Tag_Select, selectField) { ZEPHIR_GET_CONSTANT(_6, "PHP_EOL"); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, "", _6); - ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 417, options, value, _7); + ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 416, options, value, _7); zephir_check_call_status(); zephir_concat_self(&code, _8 TSRMLS_CC); } else { @@ -133079,12 +134234,12 @@ static PHP_METHOD(Phalcon_Tag_Select, _optionsFromArray) { ) { ZEPHIR_GET_HMKEY(optionValue, _1, _0); ZEPHIR_GET_HVALUE(optionText, _2); - ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 181, optionValue); + ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 182, optionValue); zephir_check_call_status(); if (Z_TYPE_P(optionText) == IS_ARRAY) { ZEPHIR_INIT_NVAR(_4); ZEPHIR_GET_CONSTANT(_4, "PHP_EOL"); - ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 417, optionText, value, closeOption); + ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 416, optionText, value, closeOption); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_7); ZEPHIR_GET_CONSTANT(_7, "PHP_EOL"); @@ -133478,7 +134633,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct) { - ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_csv_ce, this_ptr, "__construct", &_0, 426, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_csv_ce, this_ptr, "__construct", &_0, 425, options); zephir_check_call_status(); if (!(zephir_array_isset_string(options, SS("content")))) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter 'content' is required", "phalcon/translate/adapter/csv.zep", 43); @@ -133491,7 +134646,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct) { ZVAL_STRING(_3, ";", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_4); ZVAL_STRING(_4, "\"", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_load", NULL, 427, _1, _2, _3, _4); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_load", NULL, 426, _1, _2, _3, _4); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -133513,7 +134668,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Csv, _load) { ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "rb", 0); - ZEPHIR_CALL_FUNCTION(&fileHandler, "fopen", NULL, 292, file, &_0); + ZEPHIR_CALL_FUNCTION(&fileHandler, "fopen", NULL, 285, file, &_0); zephir_check_call_status(); if (Z_TYPE_P(fileHandler) != IS_RESOURCE) { ZEPHIR_INIT_VAR(_1); @@ -133527,7 +134682,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Csv, _load) { return; } while (1) { - ZEPHIR_CALL_FUNCTION(&data, "fgetcsv", &_3, 428, fileHandler, length, delimiter, enclosure); + ZEPHIR_CALL_FUNCTION(&data, "fgetcsv", &_3, 427, fileHandler, length, delimiter, enclosure); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(data)) { break; @@ -133685,7 +134840,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, __construct) { - ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_gettext_ce, this_ptr, "__construct", &_0, 426, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_gettext_ce, this_ptr, "__construct", &_0, 425, options); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, this_ptr, "prepareoptions", NULL, 0, options); zephir_check_call_status(); @@ -133718,22 +134873,22 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, query) { } - ZEPHIR_CALL_FUNCTION(&_0, "func_num_args", NULL, 421); + ZEPHIR_CALL_FUNCTION(&_0, "func_num_args", NULL, 420); zephir_check_call_status(); if (ZEPHIR_GT_LONG(_0, 2)) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 2); - ZEPHIR_CALL_FUNCTION(&domain, "func_get_arg", NULL, 420, &_1); + ZEPHIR_CALL_FUNCTION(&domain, "func_get_arg", NULL, 419, &_1); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(domain); ZVAL_NULL(domain); } if (!(zephir_is_true(domain))) { - ZEPHIR_CALL_FUNCTION(&translation, "gettext", NULL, 429, index); + ZEPHIR_CALL_FUNCTION(&translation, "gettext", NULL, 428, index); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&translation, "dgettext", NULL, 430, domain, index); + ZEPHIR_CALL_FUNCTION(&translation, "dgettext", NULL, 429, domain, index); zephir_check_call_status(); } ZEPHIR_RETURN_CALL_METHOD(this_ptr, "replaceplaceholders", NULL, 0, translation, placeholders); @@ -133831,12 +134986,12 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, nquery) { if (!(domain && Z_STRLEN_P(domain))) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, count); - ZEPHIR_CALL_FUNCTION(&translation, "ngettext", NULL, 431, msgid1, msgid2, &_0); + ZEPHIR_CALL_FUNCTION(&translation, "ngettext", NULL, 430, msgid1, msgid2, &_0); zephir_check_call_status(); } else { ZEPHIR_SINIT_NVAR(_0); ZVAL_LONG(&_0, count); - ZEPHIR_CALL_FUNCTION(&translation, "dngettext", NULL, 432, domain, msgid1, msgid2, &_0); + ZEPHIR_CALL_FUNCTION(&translation, "dngettext", NULL, 431, domain, msgid1, msgid2, &_0); zephir_check_call_status(); } ZEPHIR_RETURN_CALL_METHOD(this_ptr, "replaceplaceholders", NULL, 0, translation, placeholders); @@ -133867,7 +135022,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setDomain) { } - ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 433, domain); + ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 432, domain); zephir_check_call_status(); RETURN_MM(); @@ -133882,7 +135037,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, resetDomain) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getdefaultdomain", NULL, 0); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 433, _0); + ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 432, _0); zephir_check_call_status(); RETURN_MM(); @@ -133944,14 +135099,14 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setDirectory) { ) { ZEPHIR_GET_HMKEY(key, _1, _0); ZEPHIR_GET_HVALUE(value, _2); - ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 434, key, value); + ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 433, key, value); zephir_check_call_status(); } } } else { ZEPHIR_CALL_METHOD(&_4, this_ptr, "getdefaultdomain", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 434, _4, directory); + ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 433, _4, directory); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -133994,7 +135149,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setLocale) { ZEPHIR_INIT_VAR(_0); - ZEPHIR_CALL_FUNCTION(&_1, "func_get_args", NULL, 166); + ZEPHIR_CALL_FUNCTION(&_1, "func_get_args", NULL, 167); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_2); ZVAL_STRING(&_2, "setlocale", 0); @@ -134007,12 +135162,12 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setLocale) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_locale"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_4); ZEPHIR_CONCAT_SV(_4, "LC_ALL=", _3); - ZEPHIR_CALL_FUNCTION(NULL, "putenv", NULL, 435, _4); + ZEPHIR_CALL_FUNCTION(NULL, "putenv", NULL, 434, _4); zephir_check_call_status(); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_locale"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_6); ZVAL_LONG(&_6, 0); - ZEPHIR_CALL_FUNCTION(NULL, "setlocale", NULL, 415, &_6, _5); + ZEPHIR_CALL_FUNCTION(NULL, "setlocale", NULL, 414, &_6, _5); zephir_check_call_status(); RETURN_MM_MEMBER(this_ptr, "_locale"); @@ -134125,7 +135280,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_NativeArray, __construct) { - ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_nativearray_ce, this_ptr, "__construct", &_0, 426, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_nativearray_ce, this_ptr, "__construct", &_0, 425, options); zephir_check_call_status(); ZEPHIR_OBS_VAR(data); if (!(zephir_array_isset_string_fetch(&data, options, SS("content"), 0 TSRMLS_CC))) { @@ -134331,7 +135486,7 @@ static PHP_METHOD(Phalcon_Translate_Interpolator_IndexedArray, replacePlaceholde } if (_0) { Z_SET_ISREF_P(placeholders); - ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 386, placeholders, translation); + ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 379, placeholders, translation); Z_UNSET_ISREF_P(placeholders); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_1); @@ -134552,7 +135707,7 @@ static PHP_METHOD(Phalcon_Validation_Message, __set_state) { zephir_array_fetch_string(&_0, message, SL("_message"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC); zephir_array_fetch_string(&_1, message, SL("_field"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC); zephir_array_fetch_string(&_2, message, SL("_type"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 436, _0, _1, _2); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 435, _0, _1, _2); zephir_check_call_status(); RETURN_MM(); @@ -135166,7 +136321,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) { if (_2) { RETURN_MM_BOOL(1); } - ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 437, value); + ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 436, value); zephir_check_call_status(); if (!(zephir_is_true(_3))) { ZEPHIR_INIT_NVAR(_1); @@ -135195,11 +136350,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Alnum", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -135269,7 +136424,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) { if (_2) { RETURN_MM_BOOL(1); } - ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 438, value); + ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 437, value); zephir_check_call_status(); if (!(zephir_is_true(_3))) { ZEPHIR_INIT_NVAR(_1); @@ -135298,11 +136453,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Alpha", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -135415,11 +136570,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Between, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Between", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -135483,7 +136638,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&valueWith, validation, "getvalue", NULL, 0, fieldWith); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 439, value, valueWith); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 438, value, valueWith); zephir_check_call_status(); if (!(zephir_is_true(_1))) { ZEPHIR_INIT_NVAR(_0); @@ -135522,11 +136677,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZVAL_STRING(_3, "Confirmation", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _2, field, _3); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 435, _2, field, _3); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -135565,12 +136720,12 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, compare) { } ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "utf-8", 0); - ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 194, a, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 195, a, &_3); zephir_check_call_status(); zephir_get_strval(a, _4); ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "utf-8", 0); - ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 194, b, &_3); + ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 195, b, &_3); zephir_check_call_status(); zephir_get_strval(b, _6); } @@ -135637,7 +136792,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) { if (_2) { RETURN_MM_BOOL(1); } - ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 440, value); + ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 439, value); zephir_check_call_status(); if (!(zephir_is_true(_3))) { ZEPHIR_INIT_NVAR(_1); @@ -135666,11 +136821,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Digit", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -135742,7 +136897,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Email, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 274); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_1); @@ -135771,11 +136926,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Email, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "Email", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _5, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -135884,11 +137039,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_ExclusionIn, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_3, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_3, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_4); ZVAL_STRING(_4, "ExclusionIn", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _3, field, _4); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _3, field, _4); zephir_check_temp_parameter(_4); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -136000,11 +137155,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_11); ZVAL_STRING(_11, "FileIniSize", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 436, _9, field, _11); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 435, _9, field, _11); zephir_check_temp_parameter(_11); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -136044,7 +137199,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { _20 = _18; if (!(_20)) { zephir_array_fetch_string(&_21, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 79 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 232, _21); + ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 233, _21); zephir_check_call_status(); _20 = !zephir_is_true(_9); } @@ -136066,11 +137221,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_23); ZVAL_STRING(_23, "FileEmpty", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _22, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -136103,11 +137258,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_23); ZVAL_STRING(_23, "FileValid", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _9, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _9, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -136153,7 +137308,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { zephir_array_fetch_long(&unit, matches, 2, PH_NOISY, "phalcon/validation/validator/file.zep", 115 TSRMLS_CC); } zephir_array_fetch_long(&_28, matches, 1, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _28); + ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 304, _28); zephir_check_call_status(); ZEPHIR_INIT_VAR(_30); zephir_array_fetch(&_31, byteUnits, unit, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC); @@ -136163,9 +137318,9 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { ZEPHIR_INIT_VAR(bytes); mul_function(bytes, _22, _30 TSRMLS_CC); zephir_array_fetch_string(&_33, value, SL("size"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 120 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _33); + ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 304, _33); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 311, bytes); + ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 304, bytes); zephir_check_call_status(); if (ZEPHIR_GT(_22, _34)) { ZEPHIR_INIT_NVAR(_30); @@ -136186,11 +137341,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_30); object_init_ex(_30, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_36); ZVAL_STRING(_36, "FileSize", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 436, _35, field, _36); + ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 435, _35, field, _36); zephir_check_temp_parameter(_36); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _30); @@ -136216,12 +137371,12 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { if ((zephir_function_exists_ex(SS("finfo_open") TSRMLS_CC) == SUCCESS)) { ZEPHIR_SINIT_NVAR(_32); ZVAL_LONG(&_32, 16); - ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 229, &_32); + ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 230, &_32); zephir_check_call_status(); zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 143 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, tmp, _28); + ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 231, tmp, _28); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, tmp); + ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 232, tmp); zephir_check_call_status(); } else { ZEPHIR_OBS_NVAR(mime); @@ -136248,11 +137403,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_23); ZVAL_STRING(_23, "FileType", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _22, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -136276,7 +137431,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } if (_37) { zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 164 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 249, _28); + ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 241, _28); zephir_check_call_status(); ZEPHIR_OBS_VAR(width); zephir_array_fetch_long(&width, tmp, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 165 TSRMLS_CC); @@ -136333,11 +137488,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_23); ZVAL_STRING(_23, "FileMinResolution", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _35, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _35, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -136389,11 +137544,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_23); object_init_ex(_23, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_41, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_41, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_26); ZVAL_STRING(_26, "FileMaxResolution", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 436, _41, field, _26); + ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 435, _41, field, _26); zephir_check_temp_parameter(_26); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _23); @@ -136507,11 +137662,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Identical, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_4); ZVAL_STRING(_4, "Identical", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _4); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _2, field, _4); zephir_check_temp_parameter(_4); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -136608,7 +137763,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) { zephir_check_temp_parameter(_1); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 365, value, domain, strict); + ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 358, value, domain, strict); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_1); @@ -136640,11 +137795,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "InclusionIn", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _5, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -136746,11 +137901,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Numericality, validate) { } ZEPHIR_INIT_NVAR(_5); object_init_ex(_5, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "Numericality", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 436, _6, field, _7); + ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 435, _6, field, _7); zephir_check_temp_parameter(_7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _5); @@ -136839,11 +137994,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_PresenceOf, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZVAL_STRING(_3, "PresenceOf", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _3); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _2, field, _3); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -136955,11 +138110,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Regex, validate) { } ZEPHIR_INIT_NVAR(_4); object_init_ex(_4, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "Regex", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 436, _6, field, _7); + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 435, _6, field, _7); zephir_check_temp_parameter(_7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _4); @@ -137058,7 +138213,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) { zephir_check_call_status(); } if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value); + ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 359, value); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(length); @@ -137089,11 +138244,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "TooLong", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 436, _4, field, _6); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 435, _4, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -137126,11 +138281,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) { } ZEPHIR_INIT_NVAR(_6); object_init_ex(_6, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_8); ZVAL_STRING(_8, "TooShort", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 436, _4, field, _8); + ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 435, _4, field, _8); zephir_check_temp_parameter(_8); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _6); @@ -137267,11 +138422,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "Uniqueness", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _6, field, _7); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 435, _6, field, _7); zephir_check_temp_parameter(_7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -137343,7 +138498,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Url, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 273); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_1); @@ -137372,11 +138527,11 @@ static PHP_METHOD(Phalcon_Validation_Validator_Url, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "Url", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _5, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); @@ -137453,6 +138608,7 @@ zend_class_entry *phalcon_di_serviceinterface_ce; zend_class_entry *phalcon_escaperinterface_ce; zend_class_entry *phalcon_events_managerinterface_ce; zend_class_entry *phalcon_filterinterface_ce; +zend_class_entry *phalcon_http_cookieinterface_ce; zend_class_entry *phalcon_http_request_fileinterface_ce; zend_class_entry *phalcon_http_requestinterface_ce; zend_class_entry *phalcon_http_response_cookiesinterface_ce; @@ -137516,6 +138672,7 @@ zend_class_entry *phalcon_cache_frontend_data_ce; zend_class_entry *phalcon_di_factorydefault_ce; zend_class_entry *phalcon_mvc_model_transaction_exception_ce; zend_class_entry *phalcon_mvc_router_ce; +zend_class_entry *phalcon_mvc_view_exception_ce; zend_class_entry *phalcon_0__closure_ce; zend_class_entry *phalcon_acl_adapter_memory_ce; zend_class_entry *phalcon_acl_ce; @@ -137714,7 +138871,7 @@ zend_class_entry *phalcon_mvc_view_ce; zend_class_entry *phalcon_mvc_view_engine_php_ce; zend_class_entry *phalcon_mvc_view_engine_volt_ce; zend_class_entry *phalcon_mvc_view_engine_volt_compiler_ce; -zend_class_entry *phalcon_mvc_view_exception_ce; +zend_class_entry *phalcon_mvc_view_engine_volt_exception_ce; zend_class_entry *phalcon_mvc_view_simple_ce; zend_class_entry *phalcon_paginator_adapter_model_ce; zend_class_entry *phalcon_paginator_adapter_nativearray_ce; @@ -137725,6 +138882,7 @@ zend_class_entry *phalcon_queue_beanstalk_job_ce; zend_class_entry *phalcon_registry_ce; zend_class_entry *phalcon_security_ce; zend_class_entry *phalcon_security_exception_ce; +zend_class_entry *phalcon_security_random_ce; zend_class_entry *phalcon_session_adapter_files_ce; zend_class_entry *phalcon_session_adapter_libmemcached_ce; zend_class_entry *phalcon_session_adapter_memcache_ce; @@ -137781,6 +138939,7 @@ PHP_INI_BEGIN() STD_PHP_INI_BOOLEAN("phalcon.orm.exception_on_failed_save", "0", PHP_INI_ALL, OnUpdateBool, orm.exception_on_failed_save, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.enable_literals", "1", PHP_INI_ALL, OnUpdateBool, orm.enable_literals, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.late_state_binding", "0", PHP_INI_ALL, OnUpdateBool, orm.late_state_binding, zend_phalcon_globals, phalcon_globals) + STD_PHP_INI_BOOLEAN("phalcon.orm.enable_implicit_joins", "1", PHP_INI_ALL, OnUpdateBool, orm.enable_implicit_joins, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.cast_on_hydrate", "0", PHP_INI_ALL, OnUpdateBool, orm.cast_on_hydrate, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.ignore_unknown_columns", "0", PHP_INI_ALL, OnUpdateBool, orm.ignore_unknown_columns, zend_phalcon_globals, phalcon_globals) PHP_INI_END() @@ -137846,6 +139005,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_EscaperInterface); ZEPHIR_INIT(Phalcon_Events_ManagerInterface); ZEPHIR_INIT(Phalcon_FilterInterface); + ZEPHIR_INIT(Phalcon_Http_CookieInterface); ZEPHIR_INIT(Phalcon_Http_RequestInterface); ZEPHIR_INIT(Phalcon_Http_Request_FileInterface); ZEPHIR_INIT(Phalcon_Http_ResponseInterface); @@ -137909,6 +139069,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_Di_FactoryDefault); ZEPHIR_INIT(Phalcon_Mvc_Model_Transaction_Exception); ZEPHIR_INIT(Phalcon_Mvc_Router); + ZEPHIR_INIT(Phalcon_Mvc_View_Exception); ZEPHIR_INIT(Phalcon_Acl); ZEPHIR_INIT(Phalcon_Acl_Adapter_Memory); ZEPHIR_INIT(Phalcon_Acl_Exception); @@ -138106,7 +139267,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Php); ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Volt); ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Volt_Compiler); - ZEPHIR_INIT(Phalcon_Mvc_View_Exception); + ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Volt_Exception); ZEPHIR_INIT(Phalcon_Mvc_View_Simple); ZEPHIR_INIT(Phalcon_Paginator_Adapter_Model); ZEPHIR_INIT(Phalcon_Paginator_Adapter_NativeArray); @@ -138117,6 +139278,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_Registry); ZEPHIR_INIT(Phalcon_Security); ZEPHIR_INIT(Phalcon_Security_Exception); + ZEPHIR_INIT(Phalcon_Security_Random); ZEPHIR_INIT(Phalcon_Session); ZEPHIR_INIT(Phalcon_Session_Adapter_Files); ZEPHIR_INIT(Phalcon_Session_Adapter_Libmemcached); @@ -138210,6 +139372,7 @@ static void php_zephir_init_globals(zend_phalcon_globals *phalcon_globals TSRMLS + } static PHP_RINIT_FUNCTION(phalcon) diff --git a/build/safe/phalcon.zep.h b/build/safe/phalcon.zep.h index 877bafc5931..c72569af8a9 100644 --- a/build/safe/phalcon.zep.h +++ b/build/safe/phalcon.zep.h @@ -2627,6 +2627,7 @@ static PHP_METHOD(Phalcon_Session_Adapter, setOptions); static PHP_METHOD(Phalcon_Session_Adapter, getOptions); static PHP_METHOD(Phalcon_Session_Adapter, setName); static PHP_METHOD(Phalcon_Session_Adapter, getName); +static PHP_METHOD(Phalcon_Session_Adapter, regenerateId); static PHP_METHOD(Phalcon_Session_Adapter, get); static PHP_METHOD(Phalcon_Session_Adapter, set); static PHP_METHOD(Phalcon_Session_Adapter, has); @@ -2653,6 +2654,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setname, 0, 0, 1) ZEND_ARG_INFO(0, name) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_regenerateid, 0, 0, 0) + ZEND_ARG_INFO(0, deleteOldSession) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_get, 0, 0, 1) ZEND_ARG_INFO(0, index) ZEND_ARG_INFO(0, defaultValue) @@ -2676,6 +2681,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setid, 0, 0, 1) ZEND_ARG_INFO(0, id) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_destroy, 0, 0, 0) + ZEND_ARG_INFO(0, removeData) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___get, 0, 0, 1) ZEND_ARG_INFO(0, index) ZEND_END_ARG_INFO() @@ -2700,6 +2709,7 @@ ZEPHIR_INIT_FUNCS(phalcon_session_adapter_method_entry) { PHP_ME(Phalcon_Session_Adapter, getOptions, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, setName, arginfo_phalcon_session_adapter_setname, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, getName, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Session_Adapter, regenerateId, arginfo_phalcon_session_adapter_regenerateid, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, get, arginfo_phalcon_session_adapter_get, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, set, arginfo_phalcon_session_adapter_set, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, has, arginfo_phalcon_session_adapter_has, ZEND_ACC_PUBLIC) @@ -2707,7 +2717,7 @@ ZEPHIR_INIT_FUNCS(phalcon_session_adapter_method_entry) { PHP_ME(Phalcon_Session_Adapter, getId, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, setId, arginfo_phalcon_session_adapter_setid, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, isStarted, NULL, ZEND_ACC_PUBLIC) - PHP_ME(Phalcon_Session_Adapter, destroy, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Session_Adapter, destroy, arginfo_phalcon_session_adapter_destroy, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, status, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, __get, arginfo_phalcon_session_adapter___get, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, __set, arginfo_phalcon_session_adapter___set, ZEND_ACC_PUBLIC) @@ -2742,6 +2752,14 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_remove, 0, 0, 1) ZEND_ARG_INFO(0, index) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_destroy, 0, 0, 0) + ZEND_ARG_INFO(0, removeData) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_regenerateid, 0, 0, 0) + ZEND_ARG_INFO(0, deleteOldSession) +ZEND_END_ARG_INFO() + ZEPHIR_INIT_FUNCS(phalcon_session_adapterinterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, start, NULL) PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, setOptions, arginfo_phalcon_session_adapterinterface_setoptions) @@ -2752,7 +2770,8 @@ ZEPHIR_INIT_FUNCS(phalcon_session_adapterinterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, remove, arginfo_phalcon_session_adapterinterface_remove) PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getId, NULL) PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, isStarted, NULL) - PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, destroy, NULL) + PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, destroy, arginfo_phalcon_session_adapterinterface_destroy) + PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, regenerateId, arginfo_phalcon_session_adapterinterface_regenerateid) PHP_FE_END }; @@ -4594,6 +4613,11 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_di_serviceinterface_resolve, 0, 0, 0) ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 1) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_di_serviceinterface_setparameter, 0, 0, 2) + ZEND_ARG_INFO(0, position) + ZEND_ARG_ARRAY_INFO(0, parameter, 0) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_di_serviceinterface___set_state, 0, 0, 1) ZEND_ARG_ARRAY_INFO(0, attributes, 0) ZEND_END_ARG_INFO() @@ -4606,6 +4630,7 @@ ZEPHIR_INIT_FUNCS(phalcon_di_serviceinterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, setDefinition, arginfo_phalcon_di_serviceinterface_setdefinition) PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, getDefinition, NULL) PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, resolve, arginfo_phalcon_di_serviceinterface_resolve) + PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, setParameter, arginfo_phalcon_di_serviceinterface_setparameter) ZEND_FENTRY(__set_state, NULL, arginfo_phalcon_di_serviceinterface___set_state, ZEND_ACC_STATIC|ZEND_ACC_ABSTRACT|ZEND_ACC_PUBLIC) PHP_FE_END }; @@ -4712,6 +4737,64 @@ ZEPHIR_INIT_FUNCS(phalcon_filterinterface_method_entry) { PHP_FE_END }; +zend_class_entry *phalcon_http_cookieinterface_ce; + +ZEPHIR_INIT_CLASS(Phalcon_Http_CookieInterface); + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setvalue, 0, 0, 1) + ZEND_ARG_INFO(0, value) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_getvalue, 0, 0, 0) + ZEND_ARG_INFO(0, filters) + ZEND_ARG_INFO(0, defaultValue) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_useencryption, 0, 0, 1) + ZEND_ARG_INFO(0, useEncryption) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setexpiration, 0, 0, 1) + ZEND_ARG_INFO(0, expire) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setpath, 0, 0, 1) + ZEND_ARG_INFO(0, path) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setdomain, 0, 0, 1) + ZEND_ARG_INFO(0, domain) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setsecure, 0, 0, 1) + ZEND_ARG_INFO(0, secure) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_sethttponly, 0, 0, 1) + ZEND_ARG_INFO(0, httpOnly) +ZEND_END_ARG_INFO() + +ZEPHIR_INIT_FUNCS(phalcon_http_cookieinterface_method_entry) { + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setValue, arginfo_phalcon_http_cookieinterface_setvalue) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getValue, arginfo_phalcon_http_cookieinterface_getvalue) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, send, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, delete, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, useEncryption, arginfo_phalcon_http_cookieinterface_useencryption) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, isUsingEncryption, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setExpiration, arginfo_phalcon_http_cookieinterface_setexpiration) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getExpiration, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setPath, arginfo_phalcon_http_cookieinterface_setpath) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getName, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getPath, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setDomain, arginfo_phalcon_http_cookieinterface_setdomain) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getDomain, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setSecure, arginfo_phalcon_http_cookieinterface_setsecure) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getSecure, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setHttpOnly, arginfo_phalcon_http_cookieinterface_sethttponly) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getHttpOnly, NULL) + PHP_FE_END +}; + zend_class_entry *phalcon_http_request_fileinterface_ce; ZEPHIR_INIT_CLASS(Phalcon_Http_Request_FileInterface); @@ -5247,12 +5330,6 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_criteriainterface_notinwhere, 0 ZEND_ARG_ARRAY_INFO(0, values, 0) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_criteriainterface_frominput, 0, 0, 3) - ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 0) - ZEND_ARG_INFO(0, modelName) - ZEND_ARG_ARRAY_INFO(0, data, 0) -ZEND_END_ARG_INFO() - ZEPHIR_INIT_FUNCS(phalcon_mvc_model_criteriainterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, setModelName, arginfo_phalcon_mvc_model_criteriainterface_setmodelname) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getModelName, NULL) @@ -5275,7 +5352,6 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_criteriainterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getLimit, NULL) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getOrder, NULL) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getParams, NULL) - ZEND_FENTRY(fromInput, NULL, arginfo_phalcon_mvc_model_criteriainterface_frominput, ZEND_ACC_STATIC|ZEND_ACC_ABSTRACT|ZEND_ACC_PUBLIC) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, execute, NULL) PHP_FE_END }; @@ -6369,6 +6445,11 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_urlinterface_method_entry) { PHP_FE_END }; +zend_class_entry *phalcon_mvc_view_exception_ce; + +ZEPHIR_INIT_CLASS(Phalcon_Mvc_View_Exception); + + zend_class_entry *phalcon_mvc_viewinterface_ce; ZEPHIR_INIT_CLASS(Phalcon_Mvc_ViewInterface); @@ -8134,6 +8215,7 @@ static PHP_METHOD(Phalcon_Cache_Multiple, start); static PHP_METHOD(Phalcon_Cache_Multiple, save); static PHP_METHOD(Phalcon_Cache_Multiple, delete); static PHP_METHOD(Phalcon_Cache_Multiple, exists); +static PHP_METHOD(Phalcon_Cache_Multiple, flush); ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_multiple___construct, 0, 0, 0) ZEND_ARG_INFO(0, backends) @@ -8177,6 +8259,7 @@ ZEPHIR_INIT_FUNCS(phalcon_cache_multiple_method_entry) { PHP_ME(Phalcon_Cache_Multiple, save, arginfo_phalcon_cache_multiple_save, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Cache_Multiple, delete, arginfo_phalcon_cache_multiple_delete, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Cache_Multiple, exists, arginfo_phalcon_cache_multiple_exists, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Cache_Multiple, flush, NULL, ZEND_ACC_PUBLIC) PHP_FE_END }; @@ -9682,11 +9765,11 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setsqlstatement, 0, 0, 1 ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setsqlvariables, 0, 0, 1) - ZEND_ARG_INFO(0, sqlVariables) + ZEND_ARG_ARRAY_INFO(0, sqlVariables, 0) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setsqlbindtypes, 0, 0, 1) - ZEND_ARG_INFO(0, sqlBindTypes) + ZEND_ARG_ARRAY_INFO(0, sqlBindTypes, 0) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setinitialtime, 0, 0, 1) @@ -13544,7 +13627,7 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model___call, 0, 0, 2) ZEND_ARG_INFO(0, arguments) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model___callstatic, 0, 0, 1) +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model___callstatic, 0, 0, 2) ZEND_ARG_INFO(0, method) ZEND_ARG_INFO(0, arguments) ZEND_END_ARG_INFO() @@ -13879,6 +13962,7 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_criteria_frominput, 0, 0, 3) ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 0) ZEND_ARG_INFO(0, modelName) ZEND_ARG_ARRAY_INFO(0, data, 0) + ZEND_ARG_INFO(0, operator) ZEND_END_ARG_INFO() ZEPHIR_INIT_FUNCS(phalcon_mvc_model_criteria_method_entry) { @@ -14723,6 +14807,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, getSql); ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query___construct, 0, 0, 0) ZEND_ARG_INFO(0, phql) ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 1) + ZEND_ARG_INFO(0, options) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query_setdi, 0, 0, 1) @@ -14985,6 +15070,7 @@ ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query_builder_addfrom, 0, 0, 1) ZEND_ARG_INFO(0, model) ZEND_ARG_INFO(0, alias) + ZEND_ARG_INFO(0, with) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query_builder_join, 0, 0, 1) @@ -15164,6 +15250,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Relation, getReferencedModel); static PHP_METHOD(Phalcon_Mvc_Model_Relation, getFields); static PHP_METHOD(Phalcon_Mvc_Model_Relation, getReferencedFields); static PHP_METHOD(Phalcon_Mvc_Model_Relation, getOptions); +static PHP_METHOD(Phalcon_Mvc_Model_Relation, getOption); static PHP_METHOD(Phalcon_Mvc_Model_Relation, isForeignKey); static PHP_METHOD(Phalcon_Mvc_Model_Relation, getForeignKey); static PHP_METHOD(Phalcon_Mvc_Model_Relation, getParams); @@ -15187,6 +15274,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_relation_setintermediaterelatio ZEND_ARG_INFO(0, intermediateReferencedFields) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_relation_getoption, 0, 0, 1) + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO() + ZEPHIR_INIT_FUNCS(phalcon_mvc_model_relation_method_entry) { PHP_ME(Phalcon_Mvc_Model_Relation, __construct, arginfo_phalcon_mvc_model_relation___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR) PHP_ME(Phalcon_Mvc_Model_Relation, setIntermediateRelation, arginfo_phalcon_mvc_model_relation_setintermediaterelation, ZEND_ACC_PUBLIC) @@ -15195,6 +15286,7 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_relation_method_entry) { PHP_ME(Phalcon_Mvc_Model_Relation, getFields, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getReferencedFields, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getOptions, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Mvc_Model_Relation, getOption, arginfo_phalcon_mvc_model_relation_getoption, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, isForeignKey, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getForeignKey, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getParams, NULL, ZEND_ACC_PUBLIC) @@ -16640,9 +16732,9 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_view_engine_volt_compiler_method_entry) { PHP_FE_END }; -zend_class_entry *phalcon_mvc_view_exception_ce; +zend_class_entry *phalcon_mvc_view_engine_volt_exception_ce; -ZEPHIR_INIT_CLASS(Phalcon_Mvc_View_Exception); +ZEPHIR_INIT_CLASS(Phalcon_Mvc_View_Engine_Volt_Exception); zend_class_entry *phalcon_mvc_view_simple_ce; @@ -16847,6 +16939,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, choose); static PHP_METHOD(Phalcon_Queue_Beanstalk, watch); static PHP_METHOD(Phalcon_Queue_Beanstalk, stats); static PHP_METHOD(Phalcon_Queue_Beanstalk, statsTube); +static PHP_METHOD(Phalcon_Queue_Beanstalk, listTubes); static PHP_METHOD(Phalcon_Queue_Beanstalk, peekReady); static PHP_METHOD(Phalcon_Queue_Beanstalk, peekBuried); static PHP_METHOD(Phalcon_Queue_Beanstalk, readStatus); @@ -16897,6 +16990,7 @@ ZEPHIR_INIT_FUNCS(phalcon_queue_beanstalk_method_entry) { PHP_ME(Phalcon_Queue_Beanstalk, watch, arginfo_phalcon_queue_beanstalk_watch, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, stats, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, statsTube, arginfo_phalcon_queue_beanstalk_statstube, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Queue_Beanstalk, listTubes, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, peekReady, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, peekBuried, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, readStatus, NULL, ZEND_ACC_FINAL|ZEND_ACC_PUBLIC) @@ -17130,6 +17224,48 @@ zend_class_entry *phalcon_security_exception_ce; ZEPHIR_INIT_CLASS(Phalcon_Security_Exception); +zend_class_entry *phalcon_security_random_ce; + +ZEPHIR_INIT_CLASS(Phalcon_Security_Random); + +static PHP_METHOD(Phalcon_Security_Random, bytes); +static PHP_METHOD(Phalcon_Security_Random, hex); +static PHP_METHOD(Phalcon_Security_Random, base64); +static PHP_METHOD(Phalcon_Security_Random, base64Safe); +static PHP_METHOD(Phalcon_Security_Random, uuid); +static PHP_METHOD(Phalcon_Security_Random, number); + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_bytes, 0, 0, 0) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_hex, 0, 0, 0) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_base64, 0, 0, 0) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_base64safe, 0, 0, 0) + ZEND_ARG_INFO(0, len) + ZEND_ARG_INFO(0, padding) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_number, 0, 0, 1) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEPHIR_INIT_FUNCS(phalcon_security_random_method_entry) { + PHP_ME(Phalcon_Security_Random, bytes, arginfo_phalcon_security_random_bytes, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, hex, arginfo_phalcon_security_random_hex, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, base64, arginfo_phalcon_security_random_base64, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, base64Safe, arginfo_phalcon_security_random_base64safe, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, uuid, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, number, arginfo_phalcon_security_random_number, ZEND_ACC_PUBLIC) + PHP_FE_END +}; + zend_class_entry *phalcon_session_ce; ZEPHIR_INIT_CLASS(Phalcon_Session); diff --git a/build/safe/php_phalcon.h b/build/safe/php_phalcon.h index aed59e8482d..34511ce576f 100644 --- a/build/safe/php_phalcon.h +++ b/build/safe/php_phalcon.h @@ -196,7 +196,7 @@ typedef zend_function zephir_fcall_cache_entry; #define PHP_PHALCON_NAME "phalcon" -#define PHP_PHALCON_VERSION "2.0.6" +#define PHP_PHALCON_VERSION "2.0.7" #define PHP_PHALCON_EXTNAME "phalcon" #define PHP_PHALCON_AUTHOR "Phalcon Team and contributors" #define PHP_PHALCON_ZEPVERSION "0.7.1b" @@ -219,6 +219,7 @@ typedef struct _zephir_struct_orm { zend_bool exception_on_failed_save; zend_bool enable_literals; zend_bool late_state_binding; + zend_bool enable_implicit_joins; zend_bool cast_on_hydrate; zend_bool ignore_unknown_columns; } zephir_struct_orm; diff --git a/config.json b/config.json index 8bf29fc525d..02a75c9af74 100644 --- a/config.json +++ b/config.json @@ -10,7 +10,7 @@ "name": "phalcon", "description": "Web framework delivered as a C-extension for PHP", "author": "Phalcon Team and contributors", - "version": "2.0.6", + "version": "2.0.7", "verbose": false, "optimizer-dirs": [ "optimizers" @@ -85,6 +85,10 @@ "type": "bool", "default": false }, + "orm.enable_implicit_joins": { + "type": "bool", + "default": true + }, "orm.cast_on_hydrate": { "type": "bool", "default": false diff --git a/ext/config.m4 b/ext/config.m4 index df0249c878b..77b49595d3b 100644 --- a/ext/config.m4 +++ b/ext/config.m4 @@ -83,6 +83,7 @@ if test "$PHP_PHALCON" = "yes"; then phalcon/escaperinterface.zep.c phalcon/events/managerinterface.zep.c phalcon/filterinterface.zep.c + phalcon/http/cookieinterface.zep.c phalcon/http/request/fileinterface.zep.c phalcon/http/requestinterface.zep.c phalcon/http/response/cookiesinterface.zep.c @@ -107,6 +108,7 @@ if test "$PHP_PHALCON" = "yes"; then phalcon/mvc/router/groupinterface.zep.c phalcon/mvc/router/routeinterface.zep.c phalcon/mvc/urlinterface.zep.c + phalcon/mvc/view/exception.zep.c phalcon/mvc/viewinterface.zep.c phalcon/session/baginterface.zep.c phalcon/validation/messageinterface.zep.c @@ -312,7 +314,7 @@ if test "$PHP_PHALCON" = "yes"; then phalcon/mvc/view/engine/php.zep.c phalcon/mvc/view/engine/volt.zep.c phalcon/mvc/view/engine/volt/compiler.zep.c - phalcon/mvc/view/exception.zep.c + phalcon/mvc/view/engine/volt/exception.zep.c phalcon/mvc/view/simple.zep.c phalcon/paginator/adapter/model.zep.c phalcon/paginator/adapter/nativearray.zep.c @@ -323,6 +325,7 @@ if test "$PHP_PHALCON" = "yes"; then phalcon/registry.zep.c phalcon/security.zep.c phalcon/security/exception.zep.c + phalcon/security/random.zep.c phalcon/session.zep.c phalcon/session/adapter/files.zep.c phalcon/session/adapter/libmemcached.zep.c diff --git a/ext/config.w32 b/ext/config.w32 index 95c18f1229b..e6d5fb0a221 100644 --- a/ext/config.w32 +++ b/ext/config.w32 @@ -38,8 +38,8 @@ if (PHP_PHALCON != "no") { ADD_SOURCES(configure_module_dirname + "/phalcon/mvc/model/metadata", "strategyinterface.zep.c apc.zep.c files.zep.c libmemcached.zep.c memcache.zep.c memory.zep.c redis.zep.c session.zep.c xcache.zep.c", "phalcon"); ADD_SOURCES(configure_module_dirname + "/phalcon/mvc/view", "engine.zep.c engineinterface.zep.c exception.zep.c simple.zep.c", "phalcon"); ADD_SOURCES(configure_module_dirname + "/phalcon/cache/frontend", "data.zep.c base64.zep.c igbinary.zep.c json.zep.c none.zep.c output.zep.c", "phalcon"); + ADD_SOURCES(configure_module_dirname + "/phalcon/http", "cookieinterface.zep.c requestinterface.zep.c responseinterface.zep.c cookie.zep.c request.zep.c response.zep.c", "phalcon"); ADD_SOURCES(configure_module_dirname + "/phalcon/http/request", "fileinterface.zep.c exception.zep.c file.zep.c", "phalcon"); - ADD_SOURCES(configure_module_dirname + "/phalcon/http", "requestinterface.zep.c responseinterface.zep.c cookie.zep.c request.zep.c response.zep.c", "phalcon"); ADD_SOURCES(configure_module_dirname + "/phalcon/http/response", "cookiesinterface.zep.c headersinterface.zep.c cookies.zep.c exception.zep.c headers.zep.c", "phalcon"); ADD_SOURCES(configure_module_dirname + "/phalcon/mvc/micro", "collectioninterface.zep.c collection.zep.c exception.zep.c lazyloader.zep.c middlewareinterface.zep.c", "phalcon"); ADD_SOURCES(configure_module_dirname + "/phalcon/mvc/model/query", "builderinterface.zep.c statusinterface.zep.c builder.zep.c lang.zep.c status.zep.c", "phalcon"); @@ -84,11 +84,11 @@ if (PHP_PHALCON != "no") { ADD_SOURCES(configure_module_dirname + "/phalcon/mvc/url", "exception.zep.c", "phalcon"); ADD_SOURCES(configure_module_dirname + "/phalcon/mvc/user", "component.zep.c module.zep.c plugin.zep.c", "phalcon"); ADD_SOURCES(configure_module_dirname + "/phalcon/mvc/view/engine", "php.zep.c volt.zep.c", "phalcon"); - ADD_SOURCES(configure_module_dirname + "/phalcon/mvc/view/engine/volt", "compiler.zep.c", "phalcon"); + ADD_SOURCES(configure_module_dirname + "/phalcon/mvc/view/engine/volt", "compiler.zep.c exception.zep.c", "phalcon"); ADD_SOURCES(configure_module_dirname + "/phalcon/paginator/adapter", "model.zep.c nativearray.zep.c querybuilder.zep.c", "phalcon"); ADD_SOURCES(configure_module_dirname + "/phalcon/queue", "beanstalk.zep.c", "phalcon"); ADD_SOURCES(configure_module_dirname + "/phalcon/queue/beanstalk", "job.zep.c", "phalcon"); - ADD_SOURCES(configure_module_dirname + "/phalcon/security", "exception.zep.c", "phalcon"); + ADD_SOURCES(configure_module_dirname + "/phalcon/security", "exception.zep.c random.zep.c", "phalcon"); ADD_SOURCES(configure_module_dirname + "/phalcon/session/adapter", "files.zep.c libmemcached.zep.c memcache.zep.c redis.zep.c", "phalcon"); ADD_SOURCES(configure_module_dirname + "/phalcon/tag", "exception.zep.c select.zep.c", "phalcon"); ADD_SOURCES(configure_module_dirname + "/phalcon/translate/adapter", "csv.zep.c gettext.zep.c nativearray.zep.c", "phalcon"); diff --git a/ext/kernel/math.c b/ext/kernel/math.c index 1d813b77201..022e6f9e588 100644 --- a/ext/kernel/math.c +++ b/ext/kernel/math.c @@ -48,6 +48,96 @@ double zephir_floor(zval *op1 TSRMLS_DC) return floor(zephir_get_numberval(op1)); } +double zephir_sin(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return sin(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return sin(zephir_get_numberval(op1)); +} + +double zephir_asin(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return asin(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return asin(zephir_get_numberval(op1)); +} + +double zephir_cos(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return cos(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return cos(zephir_get_numberval(op1)); +} + +double zephir_acos(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return acos(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return acos(zephir_get_numberval(op1)); +} + +double zephir_sqrt(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return sqrt(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return sqrt(zephir_get_numberval(op1)); +} + +double zephir_tan(zval *op1 TSRMLS_DC) +{ + switch (Z_TYPE_P(op1)) { + case IS_LONG: + return tan(Z_LVAL_P(op1)); + case IS_ARRAY: + case IS_OBJECT: + case IS_RESOURCE: + zend_error(E_WARNING, "Unsupported operand types"); + break; + } + + return tan(zephir_get_numberval(op1)); +} + double zephir_ceil(zval *op1 TSRMLS_DC) { @@ -144,6 +234,8 @@ void zephir_pow_function_ex(zval *return_value, zval *zbase, zval *zexp TSRMLS_D } #endif + + long zephir_mt_rand(long min, long max TSRMLS_DC) { long number; diff --git a/ext/kernel/math.h b/ext/kernel/math.h index 8baf524cee9..f323bf383ad 100644 --- a/ext/kernel/math.h +++ b/ext/kernel/math.h @@ -23,10 +23,19 @@ #include #include +double zephir_sin(zval *op1 TSRMLS_DC); +double zephir_asin(zval *op1 TSRMLS_DC); +double zephir_tan(zval *op1 TSRMLS_DC); +double zephir_cos(zval *op1 TSRMLS_DC); +double zephir_acos(zval *op1 TSRMLS_DC); +double zephir_sqrt(zval *op1 TSRMLS_DC); + double zephir_floor(zval *op1 TSRMLS_DC); double zephir_ceil(zval *op1 TSRMLS_DC); + void zephir_round(zval *return_value, zval *op1, zval *op2, zval *op3 TSRMLS_DC); void zephir_pow(zval *return_value, zval *op1, zval *op2 TSRMLS_DC); + long zephir_mt_rand(long min, long max TSRMLS_DC); #endif diff --git a/ext/phalcon.c b/ext/phalcon.c index 7dfc4d1679d..5184434f847 100644 --- a/ext/phalcon.c +++ b/ext/phalcon.c @@ -70,6 +70,7 @@ zend_class_entry *phalcon_di_serviceinterface_ce; zend_class_entry *phalcon_escaperinterface_ce; zend_class_entry *phalcon_events_managerinterface_ce; zend_class_entry *phalcon_filterinterface_ce; +zend_class_entry *phalcon_http_cookieinterface_ce; zend_class_entry *phalcon_http_request_fileinterface_ce; zend_class_entry *phalcon_http_requestinterface_ce; zend_class_entry *phalcon_http_response_cookiesinterface_ce; @@ -133,6 +134,7 @@ zend_class_entry *phalcon_cache_frontend_data_ce; zend_class_entry *phalcon_di_factorydefault_ce; zend_class_entry *phalcon_mvc_model_transaction_exception_ce; zend_class_entry *phalcon_mvc_router_ce; +zend_class_entry *phalcon_mvc_view_exception_ce; zend_class_entry *phalcon_0__closure_ce; zend_class_entry *phalcon_acl_adapter_memory_ce; zend_class_entry *phalcon_acl_ce; @@ -331,7 +333,7 @@ zend_class_entry *phalcon_mvc_view_ce; zend_class_entry *phalcon_mvc_view_engine_php_ce; zend_class_entry *phalcon_mvc_view_engine_volt_ce; zend_class_entry *phalcon_mvc_view_engine_volt_compiler_ce; -zend_class_entry *phalcon_mvc_view_exception_ce; +zend_class_entry *phalcon_mvc_view_engine_volt_exception_ce; zend_class_entry *phalcon_mvc_view_simple_ce; zend_class_entry *phalcon_paginator_adapter_model_ce; zend_class_entry *phalcon_paginator_adapter_nativearray_ce; @@ -342,6 +344,7 @@ zend_class_entry *phalcon_queue_beanstalk_job_ce; zend_class_entry *phalcon_registry_ce; zend_class_entry *phalcon_security_ce; zend_class_entry *phalcon_security_exception_ce; +zend_class_entry *phalcon_security_random_ce; zend_class_entry *phalcon_session_adapter_files_ce; zend_class_entry *phalcon_session_adapter_libmemcached_ce; zend_class_entry *phalcon_session_adapter_memcache_ce; @@ -398,6 +401,7 @@ PHP_INI_BEGIN() STD_PHP_INI_BOOLEAN("phalcon.orm.exception_on_failed_save", "0", PHP_INI_ALL, OnUpdateBool, orm.exception_on_failed_save, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.enable_literals", "1", PHP_INI_ALL, OnUpdateBool, orm.enable_literals, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.late_state_binding", "0", PHP_INI_ALL, OnUpdateBool, orm.late_state_binding, zend_phalcon_globals, phalcon_globals) + STD_PHP_INI_BOOLEAN("phalcon.orm.enable_implicit_joins", "1", PHP_INI_ALL, OnUpdateBool, orm.enable_implicit_joins, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.cast_on_hydrate", "0", PHP_INI_ALL, OnUpdateBool, orm.cast_on_hydrate, zend_phalcon_globals, phalcon_globals) STD_PHP_INI_BOOLEAN("phalcon.orm.ignore_unknown_columns", "0", PHP_INI_ALL, OnUpdateBool, orm.ignore_unknown_columns, zend_phalcon_globals, phalcon_globals) PHP_INI_END() @@ -463,6 +467,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_EscaperInterface); ZEPHIR_INIT(Phalcon_Events_ManagerInterface); ZEPHIR_INIT(Phalcon_FilterInterface); + ZEPHIR_INIT(Phalcon_Http_CookieInterface); ZEPHIR_INIT(Phalcon_Http_RequestInterface); ZEPHIR_INIT(Phalcon_Http_Request_FileInterface); ZEPHIR_INIT(Phalcon_Http_ResponseInterface); @@ -526,6 +531,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_Di_FactoryDefault); ZEPHIR_INIT(Phalcon_Mvc_Model_Transaction_Exception); ZEPHIR_INIT(Phalcon_Mvc_Router); + ZEPHIR_INIT(Phalcon_Mvc_View_Exception); ZEPHIR_INIT(Phalcon_Acl); ZEPHIR_INIT(Phalcon_Acl_Adapter_Memory); ZEPHIR_INIT(Phalcon_Acl_Exception); @@ -723,7 +729,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Php); ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Volt); ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Volt_Compiler); - ZEPHIR_INIT(Phalcon_Mvc_View_Exception); + ZEPHIR_INIT(Phalcon_Mvc_View_Engine_Volt_Exception); ZEPHIR_INIT(Phalcon_Mvc_View_Simple); ZEPHIR_INIT(Phalcon_Paginator_Adapter_Model); ZEPHIR_INIT(Phalcon_Paginator_Adapter_NativeArray); @@ -734,6 +740,7 @@ static PHP_MINIT_FUNCTION(phalcon) ZEPHIR_INIT(Phalcon_Registry); ZEPHIR_INIT(Phalcon_Security); ZEPHIR_INIT(Phalcon_Security_Exception); + ZEPHIR_INIT(Phalcon_Security_Random); ZEPHIR_INIT(Phalcon_Session); ZEPHIR_INIT(Phalcon_Session_Adapter_Files); ZEPHIR_INIT(Phalcon_Session_Adapter_Libmemcached); @@ -830,6 +837,7 @@ static void php_zephir_init_globals(zend_phalcon_globals *phalcon_globals TSRMLS + } static PHP_RINIT_FUNCTION(phalcon) diff --git a/ext/phalcon.h b/ext/phalcon.h index e5d4f6eaf90..3b459f3cda9 100644 --- a/ext/phalcon.h +++ b/ext/phalcon.h @@ -78,6 +78,7 @@ #include "phalcon/escaperinterface.zep.h" #include "phalcon/events/managerinterface.zep.h" #include "phalcon/filterinterface.zep.h" +#include "phalcon/http/cookieinterface.zep.h" #include "phalcon/http/request/fileinterface.zep.h" #include "phalcon/http/requestinterface.zep.h" #include "phalcon/http/response/cookiesinterface.zep.h" @@ -102,6 +103,7 @@ #include "phalcon/mvc/router/groupinterface.zep.h" #include "phalcon/mvc/router/routeinterface.zep.h" #include "phalcon/mvc/urlinterface.zep.h" +#include "phalcon/mvc/view/exception.zep.h" #include "phalcon/mvc/viewinterface.zep.h" #include "phalcon/session/baginterface.zep.h" #include "phalcon/validation/messageinterface.zep.h" @@ -307,7 +309,7 @@ #include "phalcon/mvc/view/engine/php.zep.h" #include "phalcon/mvc/view/engine/volt.zep.h" #include "phalcon/mvc/view/engine/volt/compiler.zep.h" -#include "phalcon/mvc/view/exception.zep.h" +#include "phalcon/mvc/view/engine/volt/exception.zep.h" #include "phalcon/mvc/view/simple.zep.h" #include "phalcon/paginator/adapter/model.zep.h" #include "phalcon/paginator/adapter/nativearray.zep.h" @@ -318,6 +320,7 @@ #include "phalcon/registry.zep.h" #include "phalcon/security.zep.h" #include "phalcon/security/exception.zep.h" +#include "phalcon/security/random.zep.h" #include "phalcon/session.zep.h" #include "phalcon/session/adapter/files.zep.h" #include "phalcon/session/adapter/libmemcached.zep.h" diff --git a/ext/phalcon/0__closure.zep.c b/ext/phalcon/0__closure.zep.c index 19f92a3bb7c..6534e0e4a7a 100644 --- a/ext/phalcon/0__closure.zep.c +++ b/ext/phalcon/0__closure.zep.c @@ -39,7 +39,7 @@ PHP_METHOD(phalcon_0__closure, __invoke) { zephir_array_fetch_long(&_0, matches, 1, PH_NOISY | PH_READONLY, "phalcon/text.zep", 272 TSRMLS_CC); ZEPHIR_INIT_VAR(words); zephir_fast_explode_str(words, SL("|"), _0, LONG_MAX TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 442, words); + ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 441, words); zephir_check_call_status(); zephir_array_fetch(&_1, words, _2, PH_NOISY | PH_READONLY, "phalcon/text.zep", 273 TSRMLS_CC); RETURN_CTOR(_1); diff --git a/ext/phalcon/acl/adapter.zep.c b/ext/phalcon/acl/adapter.zep.c index 8ba37a8b253..fcf885ac71a 100644 --- a/ext/phalcon/acl/adapter.zep.c +++ b/ext/phalcon/acl/adapter.zep.c @@ -70,7 +70,6 @@ ZEPHIR_INIT_CLASS(Phalcon_Acl_Adapter) { /** * Role which the list is checking if it's allowed to certain resource/access - * @var mixed */ PHP_METHOD(Phalcon_Acl_Adapter, getActiveRole) { @@ -81,7 +80,6 @@ PHP_METHOD(Phalcon_Acl_Adapter, getActiveRole) { /** * Resource which the list is checking if some role can access it - * @var mixed */ PHP_METHOD(Phalcon_Acl_Adapter, getActiveResource) { @@ -92,7 +90,6 @@ PHP_METHOD(Phalcon_Acl_Adapter, getActiveResource) { /** * Active access which the list is checking if some role can access it - * @var mixed */ PHP_METHOD(Phalcon_Acl_Adapter, getActiveAccess) { diff --git a/ext/phalcon/acl/adapter/memory.zep.c b/ext/phalcon/acl/adapter/memory.zep.c index faf80849386..c3720e808d5 100644 --- a/ext/phalcon/acl/adapter/memory.zep.c +++ b/ext/phalcon/acl/adapter/memory.zep.c @@ -189,7 +189,7 @@ PHP_METHOD(Phalcon_Acl_Adapter_Memory, addRole) { ZEPHIR_CPY_WRT(roleName, role); ZEPHIR_INIT_NVAR(roleObject); object_init_ex(roleObject, phalcon_acl_role_ce); - ZEPHIR_CALL_METHOD(NULL, roleObject, "__construct", NULL, 76, role); + ZEPHIR_CALL_METHOD(NULL, roleObject, "__construct", NULL, 78, role); zephir_check_call_status(); } _0 = zephir_fetch_nproperty_this(this_ptr, SL("_rolesNames"), PH_NOISY_CC); @@ -258,7 +258,7 @@ PHP_METHOD(Phalcon_Acl_Adapter_Memory, addInherit) { ; zephir_hash_move_forward_ex(_6, &_5) ) { ZEPHIR_GET_HVALUE(deepInheritName, _7); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "addinherit", &_8, 77, roleName, deepInheritName); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "addinherit", &_8, 79, roleName, deepInheritName); zephir_check_call_status(); } } @@ -361,7 +361,7 @@ PHP_METHOD(Phalcon_Acl_Adapter_Memory, addResource) { ZEPHIR_CPY_WRT(resourceName, resourceValue); ZEPHIR_INIT_NVAR(resourceObject); object_init_ex(resourceObject, phalcon_acl_resource_ce); - ZEPHIR_CALL_METHOD(NULL, resourceObject, "__construct", NULL, 78, resourceName); + ZEPHIR_CALL_METHOD(NULL, resourceObject, "__construct", NULL, 80, resourceName); zephir_check_call_status(); } _0 = zephir_fetch_nproperty_this(this_ptr, SL("_resourcesNames"), PH_NOISY_CC); diff --git a/ext/phalcon/acl/resource.zep.c b/ext/phalcon/acl/resource.zep.c index 4ade7a6f0b6..6b8ddb9144d 100644 --- a/ext/phalcon/acl/resource.zep.c +++ b/ext/phalcon/acl/resource.zep.c @@ -46,7 +46,6 @@ ZEPHIR_INIT_CLASS(Phalcon_Acl_Resource) { /** * Resource name - * @var string */ PHP_METHOD(Phalcon_Acl_Resource, getName) { @@ -57,7 +56,6 @@ PHP_METHOD(Phalcon_Acl_Resource, getName) { /** * Resource name - * @var string */ PHP_METHOD(Phalcon_Acl_Resource, __toString) { @@ -68,7 +66,6 @@ PHP_METHOD(Phalcon_Acl_Resource, __toString) { /** * Resource description - * @var string */ PHP_METHOD(Phalcon_Acl_Resource, getDescription) { diff --git a/ext/phalcon/acl/role.zep.c b/ext/phalcon/acl/role.zep.c index 916a2ce2da5..cf40e13220e 100644 --- a/ext/phalcon/acl/role.zep.c +++ b/ext/phalcon/acl/role.zep.c @@ -47,7 +47,6 @@ ZEPHIR_INIT_CLASS(Phalcon_Acl_Role) { /** * Role name - * @var string */ PHP_METHOD(Phalcon_Acl_Role, getName) { @@ -58,7 +57,6 @@ PHP_METHOD(Phalcon_Acl_Role, getName) { /** * Role name - * @var string */ PHP_METHOD(Phalcon_Acl_Role, __toString) { @@ -69,7 +67,6 @@ PHP_METHOD(Phalcon_Acl_Role, __toString) { /** * Role description - * @var string */ PHP_METHOD(Phalcon_Acl_Role, getDescription) { diff --git a/ext/phalcon/annotations/adapter.zep.c b/ext/phalcon/annotations/adapter.zep.c index 8c83d081937..d751ca4a8b3 100644 --- a/ext/phalcon/annotations/adapter.zep.c +++ b/ext/phalcon/annotations/adapter.zep.c @@ -17,6 +17,7 @@ #include "kernel/fcall.h" #include "kernel/array.h" #include "kernel/operators.h" +#include "kernel/hash.h" /** @@ -163,8 +164,11 @@ PHP_METHOD(Phalcon_Annotations_Adapter, getMethods) { */ PHP_METHOD(Phalcon_Annotations_Adapter, getMethod) { + zephir_fcall_cache_entry *_4 = NULL; + HashTable *_1; + HashPosition _0; int ZEPHIR_LAST_CALL_STATUS; - zval *className_param = NULL, *methodName_param = NULL, *classAnnotations = NULL, *methods = NULL, *method; + zval *className_param = NULL, *methodName_param = NULL, *classAnnotations = NULL, *methods = NULL, *method = NULL, *methodKey = NULL, **_2, *_3 = NULL; zval *className = NULL, *methodName = NULL; ZEPHIR_MM_GROW(); @@ -180,13 +184,23 @@ PHP_METHOD(Phalcon_Annotations_Adapter, getMethod) { ZEPHIR_CALL_METHOD(&methods, classAnnotations, "getmethodsannotations", NULL, 0); zephir_check_call_status(); if (Z_TYPE_P(methods) == IS_ARRAY) { - if (zephir_array_isset_fetch(&method, methods, methodName, 1 TSRMLS_CC)) { - RETURN_CTOR(method); + zephir_is_iterable(methods, &_1, &_0, 0, 0, "phalcon/annotations/adapter.zep", 154); + for ( + ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS + ; zephir_hash_move_forward_ex(_1, &_0) + ) { + ZEPHIR_GET_HMKEY(methodKey, _1, _0); + ZEPHIR_GET_HVALUE(method, _2); + ZEPHIR_CALL_FUNCTION(&_3, "strcasecmp", &_4, 19, methodKey, methodName); + zephir_check_call_status(); + if (!(zephir_is_true(_3))) { + RETURN_CCTOR(method); + } } } } object_init_ex(return_value, phalcon_annotations_collection_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 19); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 20); zephir_check_call_status(); RETURN_MM(); @@ -247,7 +261,7 @@ PHP_METHOD(Phalcon_Annotations_Adapter, getProperty) { } } object_init_ex(return_value, phalcon_annotations_collection_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 19); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 20); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/annotations/adapter/apc.zep.c b/ext/phalcon/annotations/adapter/apc.zep.c index eb218b35472..dcbcfff5b6f 100644 --- a/ext/phalcon/annotations/adapter/apc.zep.c +++ b/ext/phalcon/annotations/adapter/apc.zep.c @@ -76,7 +76,7 @@ PHP_METHOD(Phalcon_Annotations_Adapter_Apc, __construct) { * Reads parsed annotations from APC * * @param string key - * @return Phalcon\Annotations\Reflection + * @return \Phalcon\Annotations\Reflection */ PHP_METHOD(Phalcon_Annotations_Adapter_Apc, read) { @@ -105,7 +105,7 @@ PHP_METHOD(Phalcon_Annotations_Adapter_Apc, read) { ZEPHIR_INIT_VAR(_2); ZEPHIR_CONCAT_SVV(_2, "_PHAN", _1, key); zephir_fast_strtolower(_0, _2); - ZEPHIR_RETURN_CALL_FUNCTION("apc_fetch", NULL, 79, _0); + ZEPHIR_RETURN_CALL_FUNCTION("apc_fetch", NULL, 81, _0); zephir_check_call_status(); RETURN_MM(); @@ -142,7 +142,7 @@ PHP_METHOD(Phalcon_Annotations_Adapter_Apc, write) { ZEPHIR_CONCAT_SVV(_2, "_PHAN", _1, key); zephir_fast_strtolower(_0, _2); _3 = zephir_fetch_nproperty_this(this_ptr, SL("_ttl"), PH_NOISY_CC); - ZEPHIR_RETURN_CALL_FUNCTION("apc_store", NULL, 80, _0, data, _3); + ZEPHIR_RETURN_CALL_FUNCTION("apc_store", NULL, 82, _0, data, _3); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/annotations/adapter/files.zep.c b/ext/phalcon/annotations/adapter/files.zep.c index 68cec9bcb07..aaab445fd80 100644 --- a/ext/phalcon/annotations/adapter/files.zep.c +++ b/ext/phalcon/annotations/adapter/files.zep.c @@ -74,7 +74,7 @@ PHP_METHOD(Phalcon_Annotations_Adapter_Files, __construct) { * Reads parsed annotations from files * * @param string key - * @return Phalcon\Annotations\Reflection + * @return \Phalcon\Annotations\Reflection */ PHP_METHOD(Phalcon_Annotations_Adapter_Files, read) { diff --git a/ext/phalcon/annotations/adapter/memory.zep.c b/ext/phalcon/annotations/adapter/memory.zep.c index 16f2105e0b9..71415165689 100644 --- a/ext/phalcon/annotations/adapter/memory.zep.c +++ b/ext/phalcon/annotations/adapter/memory.zep.c @@ -45,7 +45,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Annotations_Adapter_Memory) { * Reads parsed annotations from memory * * @param string key - * @return Phalcon\Annotations\Reflection + * @return \Phalcon\Annotations\Reflection */ PHP_METHOD(Phalcon_Annotations_Adapter_Memory, read) { diff --git a/ext/phalcon/annotations/adapter/xcache.zep.c b/ext/phalcon/annotations/adapter/xcache.zep.c index 851e1d52359..84df494c286 100644 --- a/ext/phalcon/annotations/adapter/xcache.zep.c +++ b/ext/phalcon/annotations/adapter/xcache.zep.c @@ -43,7 +43,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Annotations_Adapter_Xcache) { * Reads parsed annotations from XCache * * @param string key - * @return Phalcon\Annotations\Reflection + * @return \Phalcon\Annotations\Reflection */ PHP_METHOD(Phalcon_Annotations_Adapter_Xcache, read) { @@ -71,10 +71,10 @@ PHP_METHOD(Phalcon_Annotations_Adapter_Xcache, read) { ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SV(_1, "_PHAN", key); zephir_fast_strtolower(_0, _1); - ZEPHIR_CALL_FUNCTION(&serialized, "xcache_get", NULL, 81, _0); + ZEPHIR_CALL_FUNCTION(&serialized, "xcache_get", NULL, 83, _0); zephir_check_call_status(); if (Z_TYPE_P(serialized) == IS_STRING) { - ZEPHIR_CALL_FUNCTION(&data, "unserialize", NULL, 72, serialized); + ZEPHIR_CALL_FUNCTION(&data, "unserialize", NULL, 74, serialized); zephir_check_call_status(); if (Z_TYPE_P(data) == IS_OBJECT) { RETURN_CCTOR(data); @@ -113,9 +113,9 @@ PHP_METHOD(Phalcon_Annotations_Adapter_Xcache, write) { ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SV(_1, "_PHAN", key); zephir_fast_strtolower(_0, _1); - ZEPHIR_CALL_FUNCTION(&_2, "serialize", NULL, 71, data); + ZEPHIR_CALL_FUNCTION(&_2, "serialize", NULL, 73, data); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, _0, _2); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, _0, _2); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/annotations/adapterinterface.zep.c b/ext/phalcon/annotations/adapterinterface.zep.c index 5b1b6de777a..be92a16a161 100644 --- a/ext/phalcon/annotations/adapterinterface.zep.c +++ b/ext/phalcon/annotations/adapterinterface.zep.c @@ -39,7 +39,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Annotations_AdapterInterface, getReader); * Parses or retrieves all the annotations found in a class * * @param string|object className - * @return Phalcon\Annotations\Reflection + * @return \Phalcon\Annotations\Reflection */ ZEPHIR_DOC_METHOD(Phalcon_Annotations_AdapterInterface, get); @@ -56,7 +56,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Annotations_AdapterInterface, getMethods); * * @param string className * @param string methodName - * @return Phalcon\Annotations\Collection + * @return \Phalcon\Annotations\Collection */ ZEPHIR_DOC_METHOD(Phalcon_Annotations_AdapterInterface, getMethod); @@ -73,7 +73,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Annotations_AdapterInterface, getProperties); * * @param string className * @param string propertyName - * @return Phalcon\Annotations\Collection + * @return \Phalcon\Annotations\Collection */ ZEPHIR_DOC_METHOD(Phalcon_Annotations_AdapterInterface, getProperty); diff --git a/ext/phalcon/annotations/annotation.zep.c b/ext/phalcon/annotations/annotation.zep.c index 3e796b5460c..06bb61eff47 100644 --- a/ext/phalcon/annotations/annotation.zep.c +++ b/ext/phalcon/annotations/annotation.zep.c @@ -167,7 +167,7 @@ PHP_METHOD(Phalcon_Annotations_Annotation, getExpression) { ) { ZEPHIR_GET_HVALUE(item, _3); zephir_array_fetch_string(&_4, item, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/annotations/annotation.zep", 121 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&resolvedItem, this_ptr, "getexpression", &_5, 83, _4); + ZEPHIR_CALL_METHOD(&resolvedItem, this_ptr, "getexpression", &_5, 85, _4); zephir_check_call_status(); ZEPHIR_OBS_NVAR(name); if (zephir_array_isset_string_fetch(&name, item, SS("name"), 0 TSRMLS_CC)) { @@ -180,7 +180,7 @@ PHP_METHOD(Phalcon_Annotations_Annotation, getExpression) { } if (ZEPHIR_IS_LONG(type, 300)) { object_init_ex(return_value, phalcon_annotations_annotation_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 84, expr); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 86, expr); zephir_check_call_status(); RETURN_MM(); } @@ -279,7 +279,6 @@ PHP_METHOD(Phalcon_Annotations_Annotation, hasArgument) { /** * Returns a named argument * - * @param string name * @return mixed */ PHP_METHOD(Phalcon_Annotations_Annotation, getNamedArgument) { @@ -314,7 +313,6 @@ PHP_METHOD(Phalcon_Annotations_Annotation, getNamedArgument) { /** * Returns a named parameter * - * @param string name * @return mixed */ PHP_METHOD(Phalcon_Annotations_Annotation, getNamedParameter) { diff --git a/ext/phalcon/annotations/collection.zep.c b/ext/phalcon/annotations/collection.zep.c index a3eef95b20a..32665cce373 100644 --- a/ext/phalcon/annotations/collection.zep.c +++ b/ext/phalcon/annotations/collection.zep.c @@ -96,7 +96,7 @@ PHP_METHOD(Phalcon_Annotations_Collection, __construct) { ZEPHIR_GET_HVALUE(annotationData, _3); ZEPHIR_INIT_NVAR(_4); object_init_ex(_4, phalcon_annotations_annotation_ce); - ZEPHIR_CALL_METHOD(NULL, _4, "__construct", &_5, 84, annotationData); + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", &_5, 86, annotationData); zephir_check_call_status(); zephir_array_append(&annotations, _4, PH_SEPARATE, "phalcon/annotations/collection.zep", 66); } @@ -136,7 +136,7 @@ PHP_METHOD(Phalcon_Annotations_Collection, rewind) { /** * Returns the current annotation in the iterator * - * @return Phalcon\Annotations\Annotation + * @return \Phalcon\Annotations\Annotation */ PHP_METHOD(Phalcon_Annotations_Collection, current) { diff --git a/ext/phalcon/annotations/reader.zep.c b/ext/phalcon/annotations/reader.zep.c index 3c59f4cb2e1..2e6389a63e6 100644 --- a/ext/phalcon/annotations/reader.zep.c +++ b/ext/phalcon/annotations/reader.zep.c @@ -57,15 +57,15 @@ PHP_METHOD(Phalcon_Annotations_Reader, parse) { array_init(annotations); ZEPHIR_INIT_VAR(reflection); object_init_ex(reflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 62, className); + ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 64, className); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&comment, reflection, "getdoccomment", NULL, 85); + ZEPHIR_CALL_METHOD(&comment, reflection, "getdoccomment", NULL, 87); zephir_check_call_status(); if (Z_TYPE_P(comment) == IS_STRING) { ZEPHIR_INIT_VAR(classAnnotations); - ZEPHIR_CALL_METHOD(&_0, reflection, "getfilename", NULL, 86); + ZEPHIR_CALL_METHOD(&_0, reflection, "getfilename", NULL, 88); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, reflection, "getstartline", NULL, 87); + ZEPHIR_CALL_METHOD(&_1, reflection, "getstartline", NULL, 89); zephir_check_call_status(); ZEPHIR_LAST_CALL_STATUS = phannot_parse_annotations(classAnnotations, comment, _0, _1 TSRMLS_CC); zephir_check_call_status(); @@ -73,7 +73,7 @@ PHP_METHOD(Phalcon_Annotations_Reader, parse) { zephir_array_update_string(&annotations, SL("class"), &classAnnotations, PH_COPY | PH_SEPARATE); } } - ZEPHIR_CALL_METHOD(&properties, reflection, "getproperties", NULL, 88); + ZEPHIR_CALL_METHOD(&properties, reflection, "getproperties", NULL, 90); zephir_check_call_status(); if (zephir_fast_count_int(properties TSRMLS_CC)) { line = 1; @@ -89,7 +89,7 @@ PHP_METHOD(Phalcon_Annotations_Reader, parse) { zephir_check_call_status(); if (Z_TYPE_P(comment) == IS_STRING) { ZEPHIR_INIT_NVAR(propertyAnnotations); - ZEPHIR_CALL_METHOD(&_0, reflection, "getfilename", NULL, 86); + ZEPHIR_CALL_METHOD(&_0, reflection, "getfilename", NULL, 88); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_5); ZVAL_LONG(_5, line); @@ -106,7 +106,7 @@ PHP_METHOD(Phalcon_Annotations_Reader, parse) { zephir_array_update_string(&annotations, SL("properties"), &annotationsProperties, PH_COPY | PH_SEPARATE); } } - ZEPHIR_CALL_METHOD(&methods, reflection, "getmethods", NULL, 89); + ZEPHIR_CALL_METHOD(&methods, reflection, "getmethods", NULL, 91); zephir_check_call_status(); if (zephir_fast_count_int(methods TSRMLS_CC)) { ZEPHIR_INIT_VAR(annotationsMethods); diff --git a/ext/phalcon/annotations/reflection.zep.c b/ext/phalcon/annotations/reflection.zep.c index a6f3ef6f5d7..594c964df39 100644 --- a/ext/phalcon/annotations/reflection.zep.c +++ b/ext/phalcon/annotations/reflection.zep.c @@ -93,7 +93,7 @@ PHP_METHOD(Phalcon_Annotations_Reflection, getClassAnnotations) { if (zephir_array_isset_string_fetch(&reflectionClass, _0, SS("class"), 1 TSRMLS_CC)) { ZEPHIR_INIT_VAR(collection); object_init_ex(collection, phalcon_annotations_collection_ce); - ZEPHIR_CALL_METHOD(NULL, collection, "__construct", NULL, 19, reflectionClass); + ZEPHIR_CALL_METHOD(NULL, collection, "__construct", NULL, 20, reflectionClass); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_classAnnotations"), collection TSRMLS_CC); RETURN_CCTOR(collection); @@ -136,7 +136,7 @@ PHP_METHOD(Phalcon_Annotations_Reflection, getMethodsAnnotations) { ZEPHIR_GET_HVALUE(reflectionMethod, _3); ZEPHIR_INIT_NVAR(_4); object_init_ex(_4, phalcon_annotations_collection_ce); - ZEPHIR_CALL_METHOD(NULL, _4, "__construct", &_5, 19, reflectionMethod); + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", &_5, 20, reflectionMethod); zephir_check_call_status(); zephir_array_update_zval(&collections, methodName, &_4, PH_COPY | PH_SEPARATE); } @@ -152,7 +152,7 @@ PHP_METHOD(Phalcon_Annotations_Reflection, getMethodsAnnotations) { } /** - * Returns the annotations found in the properties' docblocks + * Returns the annotations found in the properties' docblocks */ PHP_METHOD(Phalcon_Annotations_Reflection, getPropertiesAnnotations) { @@ -182,7 +182,7 @@ PHP_METHOD(Phalcon_Annotations_Reflection, getPropertiesAnnotations) { ZEPHIR_GET_HVALUE(reflectionProperty, _3); ZEPHIR_INIT_NVAR(_4); object_init_ex(_4, phalcon_annotations_collection_ce); - ZEPHIR_CALL_METHOD(NULL, _4, "__construct", &_5, 19, reflectionProperty); + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", &_5, 20, reflectionProperty); zephir_check_call_status(); zephir_array_update_zval(&collections, property, &_4, PH_COPY | PH_SEPARATE); } diff --git a/ext/phalcon/assets/collection.zep.c b/ext/phalcon/assets/collection.zep.c index 8ce063cc056..dd17459b630 100644 --- a/ext/phalcon/assets/collection.zep.c +++ b/ext/phalcon/assets/collection.zep.c @@ -209,7 +209,7 @@ PHP_METHOD(Phalcon_Assets_Collection, addCss) { local = ZEPHIR_GLOBAL(global_null); } if (!filter_param) { - filter = 0; + filter = 1; } else { filter = zephir_get_boolval(filter_param); } @@ -218,9 +218,6 @@ PHP_METHOD(Phalcon_Assets_Collection, addCss) { } - if (!(filter)) { - filter = 1; - } if (Z_TYPE_P(local) == IS_BOOL) { ZEPHIR_CPY_WRT(collectionLocal, local); } else { @@ -235,7 +232,7 @@ PHP_METHOD(Phalcon_Assets_Collection, addCss) { } ZEPHIR_INIT_VAR(_0); object_init_ex(_0, phalcon_assets_resource_css_ce); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 90, path, collectionLocal, (filter ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), collectionAttributes); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 92, path, collectionLocal, (filter ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), collectionAttributes); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_resources"), _0 TSRMLS_CC); RETURN_THIS(); @@ -257,7 +254,7 @@ PHP_METHOD(Phalcon_Assets_Collection, addInlineCss) { zephir_get_strval(content, content_param); if (!filter_param) { - filter = 0; + filter = 1; } else { filter = zephir_get_boolval(filter_param); } @@ -266,9 +263,6 @@ PHP_METHOD(Phalcon_Assets_Collection, addInlineCss) { } - if (!(filter)) { - filter = 1; - } if (Z_TYPE_P(attributes) == IS_ARRAY) { ZEPHIR_CPY_WRT(collectionAttributes, attributes); } else { @@ -277,7 +271,7 @@ PHP_METHOD(Phalcon_Assets_Collection, addInlineCss) { } ZEPHIR_INIT_VAR(_0); object_init_ex(_0, phalcon_assets_inline_css_ce); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 91, content, (filter ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), collectionAttributes); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 93, content, (filter ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), collectionAttributes); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_codes"), _0 TSRMLS_CC); RETURN_THIS(); @@ -291,7 +285,7 @@ PHP_METHOD(Phalcon_Assets_Collection, addInlineCss) { * @param boolean local * @param boolean filter * @param array attributes - * @return Phalcon\Assets\Collection + * @return \Phalcon\Assets\Collection */ PHP_METHOD(Phalcon_Assets_Collection, addJs) { @@ -318,7 +312,7 @@ PHP_METHOD(Phalcon_Assets_Collection, addJs) { local = ZEPHIR_GLOBAL(global_null); } if (!filter_param) { - filter = 0; + filter = 1; } else { filter = zephir_get_boolval(filter_param); } @@ -327,9 +321,6 @@ PHP_METHOD(Phalcon_Assets_Collection, addJs) { } - if (!(filter)) { - filter = 1; - } if (Z_TYPE_P(local) == IS_BOOL) { ZEPHIR_CPY_WRT(collectionLocal, local); } else { @@ -344,7 +335,7 @@ PHP_METHOD(Phalcon_Assets_Collection, addJs) { } ZEPHIR_INIT_VAR(_0); object_init_ex(_0, phalcon_assets_resource_js_ce); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 92, path, collectionLocal, (filter ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), collectionAttributes); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 94, path, collectionLocal, (filter ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), collectionAttributes); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_resources"), _0 TSRMLS_CC); RETURN_THIS(); @@ -366,7 +357,7 @@ PHP_METHOD(Phalcon_Assets_Collection, addInlineJs) { zephir_get_strval(content, content_param); if (!filter_param) { - filter = 0; + filter = 1; } else { filter = zephir_get_boolval(filter_param); } @@ -375,9 +366,6 @@ PHP_METHOD(Phalcon_Assets_Collection, addInlineJs) { } - if (!(filter)) { - filter = 1; - } if (Z_TYPE_P(attributes) == IS_ARRAY) { ZEPHIR_CPY_WRT(collectionAttributes, attributes); } else { @@ -386,7 +374,7 @@ PHP_METHOD(Phalcon_Assets_Collection, addInlineJs) { } ZEPHIR_INIT_VAR(_0); object_init_ex(_0, phalcon_assets_inline_js_ce); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 93, content, (filter ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), collectionAttributes); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 95, content, (filter ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), collectionAttributes); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_codes"), _0 TSRMLS_CC); RETURN_THIS(); @@ -719,7 +707,7 @@ PHP_METHOD(Phalcon_Assets_Collection, getRealTargetPath) { ZEPHIR_INIT_VAR(completePath); ZEPHIR_CONCAT_VV(completePath, basePath, targetPath); if ((zephir_file_exists(completePath TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("realpath", NULL, 60, completePath); + ZEPHIR_RETURN_CALL_FUNCTION("realpath", NULL, 62, completePath); zephir_check_call_status(); RETURN_MM(); } diff --git a/ext/phalcon/assets/inline/css.zep.c b/ext/phalcon/assets/inline/css.zep.c index fa612d51f09..38fe02ee588 100644 --- a/ext/phalcon/assets/inline/css.zep.c +++ b/ext/phalcon/assets/inline/css.zep.c @@ -69,7 +69,7 @@ PHP_METHOD(Phalcon_Assets_Inline_Css, __construct) { } ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "css", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_PARENT(NULL, phalcon_assets_inline_css_ce, this_ptr, "__construct", &_0, 94, _1, content, (filter ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), attributes); + ZEPHIR_CALL_PARENT(NULL, phalcon_assets_inline_css_ce, this_ptr, "__construct", &_0, 96, _1, content, (filter ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), attributes); zephir_check_temp_parameter(_1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/assets/inline/js.zep.c b/ext/phalcon/assets/inline/js.zep.c index 0dd8ecc73dd..b8c5a295263 100644 --- a/ext/phalcon/assets/inline/js.zep.c +++ b/ext/phalcon/assets/inline/js.zep.c @@ -69,7 +69,7 @@ PHP_METHOD(Phalcon_Assets_Inline_Js, __construct) { } ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "js", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_PARENT(NULL, phalcon_assets_inline_js_ce, this_ptr, "__construct", &_0, 94, _1, content, (filter ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), attributes); + ZEPHIR_CALL_PARENT(NULL, phalcon_assets_inline_js_ce, this_ptr, "__construct", &_0, 96, _1, content, (filter ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), attributes); zephir_check_temp_parameter(_1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/assets/manager.zep.c b/ext/phalcon/assets/manager.zep.c index bac3229993b..2752f94c91b 100644 --- a/ext/phalcon/assets/manager.zep.c +++ b/ext/phalcon/assets/manager.zep.c @@ -157,7 +157,7 @@ PHP_METHOD(Phalcon_Assets_Manager, addCss) { ZEPHIR_INIT_VAR(_0); object_init_ex(_0, phalcon_assets_resource_css_ce); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 90, path, local, filter, attributes); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 92, path, local, filter, attributes); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "css", ZEPHIR_TEMP_PARAM_COPY); @@ -191,7 +191,7 @@ PHP_METHOD(Phalcon_Assets_Manager, addInlineCss) { ZEPHIR_INIT_VAR(_0); object_init_ex(_0, phalcon_assets_inline_css_ce); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 91, content, filter, attributes); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 93, content, filter, attributes); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "css", ZEPHIR_TEMP_PARAM_COPY); @@ -243,7 +243,7 @@ PHP_METHOD(Phalcon_Assets_Manager, addJs) { ZEPHIR_INIT_VAR(_0); object_init_ex(_0, phalcon_assets_resource_js_ce); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 92, path, local, filter, attributes); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 94, path, local, filter, attributes); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "js", ZEPHIR_TEMP_PARAM_COPY); @@ -277,7 +277,7 @@ PHP_METHOD(Phalcon_Assets_Manager, addInlineJs) { ZEPHIR_INIT_VAR(_0); object_init_ex(_0, phalcon_assets_inline_js_ce); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 93, content, filter, attributes); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 95, content, filter, attributes); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "js", ZEPHIR_TEMP_PARAM_COPY); @@ -328,7 +328,7 @@ PHP_METHOD(Phalcon_Assets_Manager, addResourceByType) { } zephir_update_property_array(this_ptr, SL("_collections"), type, collection TSRMLS_CC); } - ZEPHIR_CALL_METHOD(NULL, collection, "add", NULL, 95, resource); + ZEPHIR_CALL_METHOD(NULL, collection, "add", NULL, 97, resource); zephir_check_call_status(); RETURN_THIS(); @@ -370,7 +370,7 @@ PHP_METHOD(Phalcon_Assets_Manager, addInlineCodeByType) { } zephir_update_property_array(this_ptr, SL("_collections"), type, collection TSRMLS_CC); } - ZEPHIR_CALL_METHOD(NULL, collection, "addinline", NULL, 96, code); + ZEPHIR_CALL_METHOD(NULL, collection, "addinline", NULL, 98, code); zephir_check_call_status(); RETURN_THIS(); @@ -572,7 +572,7 @@ PHP_METHOD(Phalcon_Assets_Manager, collection) { /** * Traverses a collection calling the callback to generate its HTML * - * @param Phalcon\Assets\Collection collection + * @param \Phalcon\Assets\Collection collection * @param callback callback * @param string type */ @@ -647,7 +647,7 @@ PHP_METHOD(Phalcon_Assets_Manager, output) { ZEPHIR_MM_RESTORE(); return; } - ZEPHIR_CALL_FUNCTION(&_2, "is_dir", NULL, 97, completeTargetPath); + ZEPHIR_CALL_FUNCTION(&_2, "is_dir", NULL, 99, completeTargetPath); zephir_check_call_status(); if (zephir_is_true(_2)) { ZEPHIR_INIT_NVAR(_0); @@ -872,7 +872,7 @@ PHP_METHOD(Phalcon_Assets_Manager, output) { /** * Traverses a collection and generate its HTML * - * @param Phalcon\Assets\Collection collection + * @param \Phalcon\Assets\Collection collection * @param string type */ PHP_METHOD(Phalcon_Assets_Manager, outputInline) { diff --git a/ext/phalcon/assets/resource.zep.c b/ext/phalcon/assets/resource.zep.c index 342f0b363e9..40aa21660af 100644 --- a/ext/phalcon/assets/resource.zep.c +++ b/ext/phalcon/assets/resource.zep.c @@ -415,7 +415,7 @@ PHP_METHOD(Phalcon_Assets_Resource, getRealSourcePath) { if (zephir_is_true(_0)) { ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_VV(_1, basePath, sourcePath); - ZEPHIR_RETURN_CALL_FUNCTION("realpath", NULL, 60, _1); + ZEPHIR_RETURN_CALL_FUNCTION("realpath", NULL, 62, _1); zephir_check_call_status(); RETURN_MM(); } @@ -454,7 +454,7 @@ PHP_METHOD(Phalcon_Assets_Resource, getRealTargetPath) { ZEPHIR_INIT_VAR(completePath); ZEPHIR_CONCAT_VV(completePath, basePath, targetPath); if ((zephir_file_exists(completePath TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("realpath", NULL, 60, completePath); + ZEPHIR_RETURN_CALL_FUNCTION("realpath", NULL, 62, completePath); zephir_check_call_status(); RETURN_MM(); } diff --git a/ext/phalcon/assets/resource/css.zep.c b/ext/phalcon/assets/resource/css.zep.c index c25928c6a74..af6ec104f6b 100644 --- a/ext/phalcon/assets/resource/css.zep.c +++ b/ext/phalcon/assets/resource/css.zep.c @@ -79,7 +79,7 @@ PHP_METHOD(Phalcon_Assets_Resource_Css, __construct) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "css", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_PARENT(NULL, phalcon_assets_resource_css_ce, this_ptr, "__construct", &_0, 98, _1, path, (local ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (filter ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), attributes); + ZEPHIR_CALL_PARENT(NULL, phalcon_assets_resource_css_ce, this_ptr, "__construct", &_0, 100, _1, path, (local ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (filter ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), attributes); zephir_check_temp_parameter(_1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/assets/resource/js.zep.c b/ext/phalcon/assets/resource/js.zep.c index ed09a4caa5d..faf64825919 100644 --- a/ext/phalcon/assets/resource/js.zep.c +++ b/ext/phalcon/assets/resource/js.zep.c @@ -59,7 +59,7 @@ PHP_METHOD(Phalcon_Assets_Resource_Js, __construct) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "js", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_PARENT(NULL, phalcon_assets_resource_js_ce, this_ptr, "__construct", &_0, 98, _1, path, local, filter, attributes); + ZEPHIR_CALL_PARENT(NULL, phalcon_assets_resource_js_ce, this_ptr, "__construct", &_0, 100, _1, path, local, filter, attributes); zephir_check_temp_parameter(_1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/cache/backend.zep.c b/ext/phalcon/cache/backend.zep.c index a7ae6177de8..6f22d14b0ee 100644 --- a/ext/phalcon/cache/backend.zep.c +++ b/ext/phalcon/cache/backend.zep.c @@ -106,8 +106,8 @@ PHP_METHOD(Phalcon_Cache_Backend, setLastKey) { /** * Phalcon\Cache\Backend constructor * - * @param Phalcon\Cache\FrontendInterface frontend - * @param array options + * @param \Phalcon\Cache\FrontendInterface frontend + * @param array options */ PHP_METHOD(Phalcon_Cache_Backend, __construct) { diff --git a/ext/phalcon/cache/backend/apc.zep.c b/ext/phalcon/cache/backend/apc.zep.c index 36aa1e04236..22886953735 100644 --- a/ext/phalcon/cache/backend/apc.zep.c +++ b/ext/phalcon/cache/backend/apc.zep.c @@ -92,7 +92,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Apc, get) { ZEPHIR_INIT_VAR(prefixedKey); ZEPHIR_CONCAT_SVV(prefixedKey, "_PHCA", _0, keyName); zephir_update_property_this(this_ptr, SL("_lastKey"), prefixedKey TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&cachedContent, "apc_fetch", NULL, 79, prefixedKey); + ZEPHIR_CALL_FUNCTION(&cachedContent, "apc_fetch", NULL, 81, prefixedKey); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(cachedContent)) { RETURN_MM_NULL(); @@ -173,7 +173,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Apc, save) { } else { ZEPHIR_CPY_WRT(ttl, lifetime); } - ZEPHIR_CALL_FUNCTION(NULL, "apc_store", NULL, 80, lastKey, preparedContent, ttl); + ZEPHIR_CALL_FUNCTION(NULL, "apc_store", NULL, 82, lastKey, preparedContent, ttl); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&isBuffering, frontend, "isbuffering", NULL, 0); zephir_check_call_status(); @@ -221,11 +221,11 @@ PHP_METHOD(Phalcon_Cache_Backend_Apc, increment) { if ((zephir_function_exists_ex(SS("apc_inc") TSRMLS_CC) == SUCCESS)) { ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, value); - ZEPHIR_CALL_FUNCTION(&result, "apc_inc", NULL, 99, prefixedKey, _1); + ZEPHIR_CALL_FUNCTION(&result, "apc_inc", NULL, 101, prefixedKey, _1); zephir_check_call_status(); RETURN_CCTOR(result); } else { - ZEPHIR_CALL_FUNCTION(&cachedContent, "apc_fetch", NULL, 79, prefixedKey); + ZEPHIR_CALL_FUNCTION(&cachedContent, "apc_fetch", NULL, 81, prefixedKey); zephir_check_call_status(); if (zephir_is_numeric(cachedContent)) { ZEPHIR_INIT_NVAR(result); @@ -273,11 +273,11 @@ PHP_METHOD(Phalcon_Cache_Backend_Apc, decrement) { if ((zephir_function_exists_ex(SS("apc_dec") TSRMLS_CC) == SUCCESS)) { ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, value); - ZEPHIR_RETURN_CALL_FUNCTION("apc_dec", NULL, 100, lastKey, _1); + ZEPHIR_RETURN_CALL_FUNCTION("apc_dec", NULL, 102, lastKey, _1); zephir_check_call_status(); RETURN_MM(); } else { - ZEPHIR_CALL_FUNCTION(&cachedContent, "apc_fetch", NULL, 79, lastKey); + ZEPHIR_CALL_FUNCTION(&cachedContent, "apc_fetch", NULL, 81, lastKey); zephir_check_call_status(); if (zephir_is_numeric(cachedContent)) { ZEPHIR_INIT_VAR(result); @@ -321,7 +321,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Apc, delete) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_prefix"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "_PHCA", _0, keyName); - ZEPHIR_RETURN_CALL_FUNCTION("apc_delete", NULL, 101, _1); + ZEPHIR_RETURN_CALL_FUNCTION("apc_delete", NULL, 103, _1); zephir_check_call_status(); RETURN_MM(); @@ -427,7 +427,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Apc, exists) { ZEPHIR_CONCAT_SVV(lastKey, "_PHCA", _0, keyName); } if (zephir_is_true(lastKey)) { - ZEPHIR_CALL_FUNCTION(&_1, "apc_exists", NULL, 102, lastKey); + ZEPHIR_CALL_FUNCTION(&_1, "apc_exists", NULL, 104, lastKey); zephir_check_call_status(); if (!ZEPHIR_IS_FALSE_IDENTICAL(_1)) { RETURN_MM_BOOL(1); @@ -471,7 +471,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Apc, flush) { ZEPHIR_CPY_WRT(item, (*ZEPHIR_TMP_ITERATOR_PTR)); } zephir_array_fetch_string(&_4, item, SL("key"), PH_NOISY | PH_READONLY, "phalcon/cache/backend/apc.zep", 264 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(NULL, "apc_delete", &_5, 101, _4); + ZEPHIR_CALL_FUNCTION(NULL, "apc_delete", &_5, 103, _4); zephir_check_call_status(); } _0->funcs->dtor(_0 TSRMLS_CC); diff --git a/ext/phalcon/cache/backend/file.zep.c b/ext/phalcon/cache/backend/file.zep.c index e077af14dd1..72965fa510c 100644 --- a/ext/phalcon/cache/backend/file.zep.c +++ b/ext/phalcon/cache/backend/file.zep.c @@ -123,7 +123,7 @@ PHP_METHOD(Phalcon_Cache_Backend_File, __construct) { return; } } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_file_ce, this_ptr, "__construct", &_5, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_file_ce, this_ptr, "__construct", &_5, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -336,7 +336,7 @@ PHP_METHOD(Phalcon_Cache_Backend_File, delete) { ZEPHIR_INIT_VAR(cacheFile); ZEPHIR_CONCAT_VVV(cacheFile, cacheDir, _1, _2); if ((zephir_file_exists(cacheFile TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("unlink", NULL, 104, cacheFile); + ZEPHIR_RETURN_CALL_FUNCTION("unlink", NULL, 106, cacheFile); zephir_check_call_status(); RETURN_MM(); } @@ -375,7 +375,7 @@ PHP_METHOD(Phalcon_Cache_Backend_File, queryKeys) { } ZEPHIR_INIT_VAR(_2); object_init_ex(_2, spl_ce_DirectoryIterator); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 105, cacheDir); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 107, cacheDir); zephir_check_call_status(); _1 = zephir_get_iterator(_2 TSRMLS_CC); _1->funcs->rewind(_1 TSRMLS_CC); @@ -655,7 +655,7 @@ PHP_METHOD(Phalcon_Cache_Backend_File, flush) { } ZEPHIR_INIT_VAR(_2); object_init_ex(_2, spl_ce_DirectoryIterator); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 105, cacheDir); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 107, cacheDir); zephir_check_call_status(); _1 = zephir_get_iterator(_2 TSRMLS_CC); _1->funcs->rewind(_1 TSRMLS_CC); @@ -677,7 +677,7 @@ PHP_METHOD(Phalcon_Cache_Backend_File, flush) { _4 = zephir_start_with(key, prefix, NULL); } if (_4) { - ZEPHIR_CALL_FUNCTION(&_5, "unlink", &_6, 104, cacheFile); + ZEPHIR_CALL_FUNCTION(&_5, "unlink", &_6, 106, cacheFile); zephir_check_call_status(); if (!(zephir_is_true(_5))) { RETURN_MM_BOOL(0); diff --git a/ext/phalcon/cache/backend/libmemcached.zep.c b/ext/phalcon/cache/backend/libmemcached.zep.c index e071b67cdfe..a8b1485dcf6 100644 --- a/ext/phalcon/cache/backend/libmemcached.zep.c +++ b/ext/phalcon/cache/backend/libmemcached.zep.c @@ -112,7 +112,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Libmemcached, __construct) { ZVAL_STRING(_1, "_PHCM", 1); zephir_array_update_string(&options, SL("statsKey"), &_1, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_libmemcached_ce, this_ptr, "__construct", &_2, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_libmemcached_ce, this_ptr, "__construct", &_2, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/cache/backend/memcache.zep.c b/ext/phalcon/cache/backend/memcache.zep.c index 61dba70c760..946b6f82fb7 100644 --- a/ext/phalcon/cache/backend/memcache.zep.c +++ b/ext/phalcon/cache/backend/memcache.zep.c @@ -107,7 +107,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Memcache, __construct) { ZVAL_STRING(_0, "_PHCM", 1); zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_memcache_ce, this_ptr, "__construct", &_1, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_memcache_ce, this_ptr, "__construct", &_1, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/cache/backend/memory.zep.c b/ext/phalcon/cache/backend/memory.zep.c index 80dbb3490e2..208f1cc551f 100644 --- a/ext/phalcon/cache/backend/memory.zep.c +++ b/ext/phalcon/cache/backend/memory.zep.c @@ -412,7 +412,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Memory, serialize) { ZEPHIR_OBS_VAR(_1); zephir_read_property_this(&_1, this_ptr, SL("_frontend"), PH_NOISY_CC); zephir_array_update_string(&_0, SL("frontend"), &_1, PH_COPY | PH_SEPARATE); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -431,7 +431,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Memory, unserialize) { - ZEPHIR_CALL_FUNCTION(&unserialized, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&unserialized, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(unserialized) != IS_ARRAY) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(zend_exception_get_default(TSRMLS_C), "Unserialized data must be an array", "phalcon/cache/backend/memory.zep", 295); diff --git a/ext/phalcon/cache/backend/mongo.zep.c b/ext/phalcon/cache/backend/mongo.zep.c index ab9c45aa943..78e457f13fd 100644 --- a/ext/phalcon/cache/backend/mongo.zep.c +++ b/ext/phalcon/cache/backend/mongo.zep.c @@ -65,7 +65,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Cache_Backend_Mongo) { /** * Phalcon\Cache\Backend\Mongo constructor * - * @param Phalcon\Cache\FrontendInterface frontend + * @param \Phalcon\Cache\FrontendInterface frontend * @param array options */ PHP_METHOD(Phalcon_Cache_Backend_Mongo, __construct) { @@ -96,7 +96,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Mongo, __construct) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "The parameter 'collection' is required", "phalcon/cache/backend/mongo.zep", 79); return; } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_mongo_ce, this_ptr, "__construct", &_0, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_mongo_ce, this_ptr, "__construct", &_0, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -208,7 +208,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Mongo, get) { zephir_time(_2); zephir_array_update_string(&_1, SL("$gt"), &_2, PH_COPY | PH_SEPARATE); zephir_array_update_string(&conditions, SL("time"), &_1, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&document, _3, "findone", NULL, 0, conditions); zephir_check_call_status(); @@ -305,7 +305,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Mongo, save) { } else { ZEPHIR_CPY_WRT(ttl, lifetime); } - ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_0); zephir_time(_0); @@ -370,7 +370,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Mongo, delete) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 1, 0 TSRMLS_CC); @@ -380,7 +380,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Mongo, delete) { zephir_array_update_string(&_1, SL("key"), &_3, PH_COPY | PH_SEPARATE); ZEPHIR_CALL_METHOD(NULL, _0, "remove", NULL, 0, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "rand", NULL, 107); + ZEPHIR_CALL_FUNCTION(&_4, "rand", NULL, 109); zephir_check_call_status(); if (zephir_safe_mod_long_long(zephir_get_intval(_4), 100 TSRMLS_CC) == 0) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "gc", NULL, 0); @@ -432,7 +432,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Mongo, queryKeys) { zephir_time(_0); zephir_array_update_string(&_2, SL("$gt"), &_0, PH_COPY | PH_SEPARATE); zephir_array_update_string(&conditions, SL("time"), &_2, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&collection, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 1, 0 TSRMLS_CC); @@ -497,7 +497,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Mongo, exists) { ZEPHIR_CONCAT_VV(lastKey, _0, keyName); } if (zephir_is_true(lastKey)) { - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 2, 0 TSRMLS_CC); @@ -528,7 +528,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Mongo, gc) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 1, 0 TSRMLS_CC); @@ -570,7 +570,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Mongo, increment) { ZEPHIR_INIT_VAR(prefixedKey); ZEPHIR_CONCAT_VV(prefixedKey, _0, keyName); zephir_update_property_this(this_ptr, SL("_lastKey"), prefixedKey TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_2); zephir_create_array(_2, 1, 0 TSRMLS_CC); @@ -628,7 +628,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Mongo, decrement) { ZEPHIR_INIT_VAR(prefixedKey); ZEPHIR_CONCAT_VV(prefixedKey, _0, keyName); zephir_update_property_this(this_ptr, SL("_lastKey"), prefixedKey TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_INIT_VAR(_2); zephir_create_array(_2, 1, 0 TSRMLS_CC); @@ -670,11 +670,11 @@ PHP_METHOD(Phalcon_Cache_Backend_Mongo, flush) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 106); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getcollection", NULL, 108); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _0, "remove", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "rand", NULL, 107); + ZEPHIR_CALL_FUNCTION(&_1, "rand", NULL, 109); zephir_check_call_status(); if (zephir_safe_mod_long_long(zephir_get_intval(_1), 100 TSRMLS_CC) == 0) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "gc", NULL, 0); diff --git a/ext/phalcon/cache/backend/redis.zep.c b/ext/phalcon/cache/backend/redis.zep.c index 3526291484a..45099dbe098 100644 --- a/ext/phalcon/cache/backend/redis.zep.c +++ b/ext/phalcon/cache/backend/redis.zep.c @@ -119,7 +119,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Redis, __construct) { ZVAL_STRING(_0, "_PHCR", 1); zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_redis_ce, this_ptr, "__construct", &_3, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_redis_ce, this_ptr, "__construct", &_3, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -140,8 +140,10 @@ PHP_METHOD(Phalcon_Cache_Backend_Redis, _connect) { zephir_read_property_this(&options, this_ptr, SL("_options"), PH_NOISY_CC); ZEPHIR_INIT_VAR(redis); object_init_ex(redis, zephir_get_internal_ce(SS("redis") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, redis, "__construct", NULL, 0); - zephir_check_call_status(); + if (zephir_has_constructor(redis TSRMLS_CC)) { + ZEPHIR_CALL_METHOD(NULL, redis, "__construct", NULL, 0); + zephir_check_call_status(); + } ZEPHIR_OBS_VAR(host); _0 = !(zephir_array_isset_string_fetch(&host, options, SS("host"), 0 TSRMLS_CC)); if (!(_0)) { diff --git a/ext/phalcon/cache/backend/xcache.zep.c b/ext/phalcon/cache/backend/xcache.zep.c index ef12d59c133..c163fd24cb0 100644 --- a/ext/phalcon/cache/backend/xcache.zep.c +++ b/ext/phalcon/cache/backend/xcache.zep.c @@ -58,7 +58,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Cache_Backend_Xcache) { /** * Phalcon\Cache\Backend\Xcache constructor * - * @param Phalcon\Cache\FrontendInterface frontend + * @param \Phalcon\Cache\FrontendInterface frontend * @param array options */ PHP_METHOD(Phalcon_Cache_Backend_Xcache, __construct) { @@ -86,7 +86,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Xcache, __construct) { ZVAL_STRING(_0, "_PHCX", 1); zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_xcache_ce, this_ptr, "__construct", &_1, 103, frontend, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_cache_backend_xcache_ce, this_ptr, "__construct", &_1, 105, frontend, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -118,7 +118,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Xcache, get) { ZEPHIR_INIT_VAR(prefixedKey); ZEPHIR_CONCAT_SVV(prefixedKey, "_PHCX", _0, keyName); zephir_update_property_this(this_ptr, SL("_lastKey"), prefixedKey TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&cachedContent, "xcache_get", NULL, 81, prefixedKey); + ZEPHIR_CALL_FUNCTION(&cachedContent, "xcache_get", NULL, 83, prefixedKey); zephir_check_call_status(); if (!(zephir_is_true(cachedContent))) { RETURN_MM_NULL(); @@ -204,10 +204,10 @@ PHP_METHOD(Phalcon_Cache_Backend_Xcache, save) { ZEPHIR_CPY_WRT(tt1, lifetime); } if (zephir_is_numeric(cachedContent)) { - ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 82, lastKey, cachedContent, tt1); + ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 84, lastKey, cachedContent, tt1); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 82, lastKey, preparedContent, tt1); + ZEPHIR_CALL_FUNCTION(&success, "xcache_set", &_1, 84, lastKey, preparedContent, tt1); zephir_check_call_status(); } ZEPHIR_CALL_METHOD(&isBuffering, frontend, "isbuffering", NULL, 0); @@ -229,14 +229,14 @@ PHP_METHOD(Phalcon_Cache_Backend_Xcache, save) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Unexpected inconsistency in options", "phalcon/cache/backend/xcache.zep", 169); return; } - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) != IS_ARRAY) { ZEPHIR_INIT_NVAR(keys); array_init(keys); } zephir_array_update_zval(&keys, lastKey, &tt1, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", &_1, 82, specialKey, keys); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", &_1, 84, specialKey, keys); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -268,14 +268,14 @@ PHP_METHOD(Phalcon_Cache_Backend_Xcache, delete) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Unexpected inconsistency in options", "phalcon/cache/backend/xcache.zep", 199); return; } - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) != IS_ARRAY) { ZEPHIR_INIT_NVAR(keys); array_init(keys); } zephir_array_unset(&keys, prefixedKey, PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, specialKey, keys); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, specialKey, keys); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -318,7 +318,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Xcache, queryKeys) { } ZEPHIR_INIT_VAR(retval); array_init(retval); - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) == IS_ARRAY) { ZEPHIR_INIT_VAR(_1); @@ -374,7 +374,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Xcache, exists) { ZEPHIR_CONCAT_SVV(lastKey, "_PHCX", _0, keyName); } if (zephir_is_true(lastKey)) { - ZEPHIR_RETURN_CALL_FUNCTION("xcache_isset", NULL, 108, lastKey); + ZEPHIR_RETURN_CALL_FUNCTION("xcache_isset", NULL, 110, lastKey); zephir_check_call_status(); RETURN_MM(); } @@ -420,14 +420,14 @@ PHP_METHOD(Phalcon_Cache_Backend_Xcache, increment) { if ((zephir_function_exists_ex(SS("xcache_inc") TSRMLS_CC) == SUCCESS)) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, value); - ZEPHIR_CALL_FUNCTION(&newVal, "xcache_inc", NULL, 109, lastKey, &_1); + ZEPHIR_CALL_FUNCTION(&newVal, "xcache_inc", NULL, 111, lastKey, &_1); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 81, lastKey); + ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 83, lastKey); zephir_check_call_status(); ZEPHIR_INIT_NVAR(newVal); ZVAL_LONG(newVal, (zephir_get_numberval(origVal) - value)); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, lastKey, newVal); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, lastKey, newVal); zephir_check_call_status(); } RETURN_CCTOR(newVal); @@ -472,14 +472,14 @@ PHP_METHOD(Phalcon_Cache_Backend_Xcache, decrement) { if ((zephir_function_exists_ex(SS("xcache_dec") TSRMLS_CC) == SUCCESS)) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, value); - ZEPHIR_CALL_FUNCTION(&newVal, "xcache_dec", NULL, 110, lastKey, &_1); + ZEPHIR_CALL_FUNCTION(&newVal, "xcache_dec", NULL, 112, lastKey, &_1); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 81, lastKey); + ZEPHIR_CALL_FUNCTION(&origVal, "xcache_get", NULL, 83, lastKey); zephir_check_call_status(); ZEPHIR_INIT_NVAR(newVal); ZVAL_LONG(newVal, (zephir_get_numberval(origVal) - value)); - ZEPHIR_CALL_FUNCTION(&success, "xcache_set", NULL, 82, lastKey, newVal); + ZEPHIR_CALL_FUNCTION(&success, "xcache_set", NULL, 84, lastKey, newVal); zephir_check_call_status(); } RETURN_CCTOR(newVal); @@ -507,7 +507,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Xcache, flush) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Unexpected inconsistency in options", "phalcon/cache/backend/xcache.zep", 350); return; } - ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 81, specialKey); + ZEPHIR_CALL_FUNCTION(&keys, "xcache_get", NULL, 83, specialKey); zephir_check_call_status(); if (Z_TYPE_P(keys) == IS_ARRAY) { ZEPHIR_INIT_VAR(_1); @@ -519,10 +519,10 @@ PHP_METHOD(Phalcon_Cache_Backend_Xcache, flush) { ZEPHIR_GET_HMKEY(key, _3, _2); ZEPHIR_GET_HVALUE(_1, _4); zephir_array_unset(&keys, key, PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_unset", &_5, 111, key); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_unset", &_5, 113, key); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, specialKey, keys); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, specialKey, keys); zephir_check_call_status(); } RETURN_MM_BOOL(1); diff --git a/ext/phalcon/cache/frontend/base64.zep.c b/ext/phalcon/cache/frontend/base64.zep.c index bd203f67325..38bb2681582 100644 --- a/ext/phalcon/cache/frontend/base64.zep.c +++ b/ext/phalcon/cache/frontend/base64.zep.c @@ -158,7 +158,7 @@ PHP_METHOD(Phalcon_Cache_Frontend_Base64, beforeStore) { - ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", NULL, 112, data); + ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", NULL, 114, data); zephir_check_call_status(); RETURN_MM(); @@ -180,7 +180,7 @@ PHP_METHOD(Phalcon_Cache_Frontend_Base64, afterRetrieve) { - ZEPHIR_RETURN_CALL_FUNCTION("base64_decode", NULL, 113, data); + ZEPHIR_RETURN_CALL_FUNCTION("base64_decode", NULL, 115, data); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/cache/frontend/data.zep.c b/ext/phalcon/cache/frontend/data.zep.c index 44a0dc5bf0b..e9d4df4202f 100644 --- a/ext/phalcon/cache/frontend/data.zep.c +++ b/ext/phalcon/cache/frontend/data.zep.c @@ -159,14 +159,14 @@ PHP_METHOD(Phalcon_Cache_Frontend_Data, beforeStore) { - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, data); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, data); zephir_check_call_status(); RETURN_MM(); } /** - * Unserializes data after retrieval + * Unserializes data after retrieval */ PHP_METHOD(Phalcon_Cache_Frontend_Data, afterRetrieve) { @@ -178,7 +178,7 @@ PHP_METHOD(Phalcon_Cache_Frontend_Data, afterRetrieve) { - ZEPHIR_RETURN_CALL_FUNCTION("unserialize", NULL, 72, data); + ZEPHIR_RETURN_CALL_FUNCTION("unserialize", NULL, 74, data); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/cache/frontend/igbinary.zep.c b/ext/phalcon/cache/frontend/igbinary.zep.c index c3764bd4274..16f1349c07f 100644 --- a/ext/phalcon/cache/frontend/igbinary.zep.c +++ b/ext/phalcon/cache/frontend/igbinary.zep.c @@ -159,7 +159,7 @@ PHP_METHOD(Phalcon_Cache_Frontend_Igbinary, beforeStore) { - ZEPHIR_RETURN_CALL_FUNCTION("igbinary_serialize", NULL, 114, data); + ZEPHIR_RETURN_CALL_FUNCTION("igbinary_serialize", NULL, 116, data); zephir_check_call_status(); RETURN_MM(); @@ -181,7 +181,7 @@ PHP_METHOD(Phalcon_Cache_Frontend_Igbinary, afterRetrieve) { - ZEPHIR_RETURN_CALL_FUNCTION("igbinary_unserialize", NULL, 115, data); + ZEPHIR_RETURN_CALL_FUNCTION("igbinary_unserialize", NULL, 117, data); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/cache/frontend/output.zep.c b/ext/phalcon/cache/frontend/output.zep.c index e1e6426cc13..2510a771ecd 100644 --- a/ext/phalcon/cache/frontend/output.zep.c +++ b/ext/phalcon/cache/frontend/output.zep.c @@ -138,7 +138,7 @@ PHP_METHOD(Phalcon_Cache_Frontend_Output, start) { ZEPHIR_MM_GROW(); zephir_update_property_this(this_ptr, SL("_buffering"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -158,7 +158,7 @@ PHP_METHOD(Phalcon_Cache_Frontend_Output, getContent) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_buffering"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_contents", NULL, 117); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_contents", NULL, 119); zephir_check_call_status(); RETURN_MM(); } @@ -178,7 +178,7 @@ PHP_METHOD(Phalcon_Cache_Frontend_Output, stop) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_buffering"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); } zephir_update_property_this(this_ptr, SL("_buffering"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); diff --git a/ext/phalcon/cache/multiple.zep.c b/ext/phalcon/cache/multiple.zep.c index ac9c8f24905..492bb9c5449 100644 --- a/ext/phalcon/cache/multiple.zep.c +++ b/ext/phalcon/cache/multiple.zep.c @@ -310,3 +310,29 @@ PHP_METHOD(Phalcon_Cache_Multiple, exists) { } +/** + * Flush all backend(s) + */ +PHP_METHOD(Phalcon_Cache_Multiple, flush) { + + int ZEPHIR_LAST_CALL_STATUS; + HashTable *_2; + HashPosition _1; + zval *backend = NULL, *_0, **_3; + + ZEPHIR_MM_GROW(); + + _0 = zephir_fetch_nproperty_this(this_ptr, SL("_backends"), PH_NOISY_CC); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/cache/multiple.zep", 199); + for ( + ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS + ; zephir_hash_move_forward_ex(_2, &_1) + ) { + ZEPHIR_GET_HVALUE(backend, _3); + ZEPHIR_CALL_METHOD(NULL, backend, "flush", NULL, 0); + zephir_check_call_status(); + } + RETURN_MM_BOOL(1); + +} + diff --git a/ext/phalcon/cache/multiple.zep.h b/ext/phalcon/cache/multiple.zep.h index f224ffcc49e..9bc901ba9be 100644 --- a/ext/phalcon/cache/multiple.zep.h +++ b/ext/phalcon/cache/multiple.zep.h @@ -10,6 +10,7 @@ PHP_METHOD(Phalcon_Cache_Multiple, start); PHP_METHOD(Phalcon_Cache_Multiple, save); PHP_METHOD(Phalcon_Cache_Multiple, delete); PHP_METHOD(Phalcon_Cache_Multiple, exists); +PHP_METHOD(Phalcon_Cache_Multiple, flush); ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_multiple___construct, 0, 0, 0) ZEND_ARG_INFO(0, backends) @@ -53,5 +54,6 @@ ZEPHIR_INIT_FUNCS(phalcon_cache_multiple_method_entry) { PHP_ME(Phalcon_Cache_Multiple, save, arginfo_phalcon_cache_multiple_save, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Cache_Multiple, delete, arginfo_phalcon_cache_multiple_delete, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Cache_Multiple, exists, arginfo_phalcon_cache_multiple_exists, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Cache_Multiple, flush, NULL, ZEND_ACC_PUBLIC) PHP_FE_END }; diff --git a/ext/phalcon/cli/console.zep.c b/ext/phalcon/cli/console.zep.c index 48b34b93ef9..22a2db0ae42 100644 --- a/ext/phalcon/cli/console.zep.c +++ b/ext/phalcon/cli/console.zep.c @@ -425,7 +425,7 @@ PHP_METHOD(Phalcon_Cli_Console, setArgument) { } if (_0) { Z_SET_ISREF_P(arguments); - ZEPHIR_CALL_FUNCTION(NULL, "array_shift", &_1, 119, arguments); + ZEPHIR_CALL_FUNCTION(NULL, "array_shift", &_1, 121, arguments); Z_UNSET_ISREF_P(arguments); zephir_check_call_status(); } @@ -440,7 +440,7 @@ PHP_METHOD(Phalcon_Cli_Console, setArgument) { ZVAL_STRING(&_5, "--", 0); ZEPHIR_SINIT_NVAR(_6); ZVAL_LONG(&_6, 2); - ZEPHIR_CALL_FUNCTION(&_7, "strncmp", &_8, 120, arg, &_5, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "strncmp", &_8, 122, arg, &_5, &_6); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_7, 0)) { ZEPHIR_SINIT_NVAR(_5); @@ -477,7 +477,7 @@ PHP_METHOD(Phalcon_Cli_Console, setArgument) { ZVAL_STRING(&_12, "-", 0); ZEPHIR_SINIT_NVAR(_13); ZVAL_LONG(&_13, 1); - ZEPHIR_CALL_FUNCTION(&_15, "strncmp", &_8, 120, arg, &_12, &_13); + ZEPHIR_CALL_FUNCTION(&_15, "strncmp", &_8, 122, arg, &_12, &_13); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_15, 0)) { ZEPHIR_SINIT_NVAR(_12); @@ -495,21 +495,21 @@ PHP_METHOD(Phalcon_Cli_Console, setArgument) { } if (str) { ZEPHIR_INIT_NVAR(_9); - ZEPHIR_CALL_CE_STATIC(&_7, phalcon_cli_router_route_ce, "getdelimiter", &_16, 121); + ZEPHIR_CALL_CE_STATIC(&_7, phalcon_cli_router_route_ce, "getdelimiter", &_16, 123); zephir_check_call_status(); zephir_fast_join(_9, _7, args TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_arguments"), _9 TSRMLS_CC); } else { if (zephir_fast_count_int(args TSRMLS_CC)) { Z_SET_ISREF_P(args); - ZEPHIR_CALL_FUNCTION(&_15, "array_shift", &_1, 119, args); + ZEPHIR_CALL_FUNCTION(&_15, "array_shift", &_1, 121, args); Z_UNSET_ISREF_P(args); zephir_check_call_status(); zephir_array_update_string(&handleArgs, SL("task"), &_15, PH_COPY | PH_SEPARATE); } if (zephir_fast_count_int(args TSRMLS_CC)) { Z_SET_ISREF_P(args); - ZEPHIR_CALL_FUNCTION(&_7, "array_shift", &_1, 119, args); + ZEPHIR_CALL_FUNCTION(&_7, "array_shift", &_1, 121, args); Z_UNSET_ISREF_P(args); zephir_check_call_status(); zephir_array_update_string(&handleArgs, SL("action"), &_7, PH_COPY | PH_SEPARATE); diff --git a/ext/phalcon/cli/dispatcher.zep.c b/ext/phalcon/cli/dispatcher.zep.c index 57449e74c08..650cd2c57fe 100644 --- a/ext/phalcon/cli/dispatcher.zep.c +++ b/ext/phalcon/cli/dispatcher.zep.c @@ -72,7 +72,7 @@ PHP_METHOD(Phalcon_Cli_Dispatcher, __construct) { ZEPHIR_INIT_VAR(_0); array_init(_0); zephir_update_property_this(this_ptr, SL("_options"), _0 TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_cli_dispatcher_ce, this_ptr, "__construct", &_1, 122); + ZEPHIR_CALL_PARENT(NULL, phalcon_cli_dispatcher_ce, this_ptr, "__construct", &_1, 124); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/cli/router.zep.c b/ext/phalcon/cli/router.zep.c index 920bcf15bcc..dcdb0456033 100644 --- a/ext/phalcon/cli/router.zep.c +++ b/ext/phalcon/cli/router.zep.c @@ -108,7 +108,7 @@ PHP_METHOD(Phalcon_Cli_Router, __construct) { add_assoc_long_ex(_1, SS("task"), 1); ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "#^(?::delimiter)?([a-zA-Z0-9\\_\\-]+)[:delimiter]{0,1}$#", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 123, _2, _1); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 125, _2, _1); zephir_check_temp_parameter(_2); zephir_check_call_status(); zephir_array_append(&routes, _0, PH_SEPARATE, "phalcon/cli/router.zep", 90); @@ -121,7 +121,7 @@ PHP_METHOD(Phalcon_Cli_Router, __construct) { add_assoc_long_ex(_4, SS("params"), 3); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "#^(?::delimiter)?([a-zA-Z0-9\\_\\-]+):delimiter([a-zA-Z0-9\\.\\_]+)(:delimiter.*)*$#", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 123, _5, _4); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 125, _5, _4); zephir_check_temp_parameter(_5); zephir_check_call_status(); zephir_array_append(&routes, _2, PH_SEPARATE, "phalcon/cli/router.zep", 96); @@ -439,7 +439,7 @@ PHP_METHOD(Phalcon_Cli_Router, handle) { ZEPHIR_INIT_VAR(strParams); zephir_substr(strParams, _15, 1 , 0, ZEPHIR_SUBSTR_NO_LENGTH); if (zephir_is_true(strParams)) { - ZEPHIR_CALL_CE_STATIC(&_17, phalcon_cli_router_route_ce, "getdelimiter", &_18, 121); + ZEPHIR_CALL_CE_STATIC(&_17, phalcon_cli_router_route_ce, "getdelimiter", &_18, 123); zephir_check_call_status(); ZEPHIR_INIT_NVAR(params); zephir_fast_explode(params, _17, strParams, LONG_MAX TSRMLS_CC); @@ -477,7 +477,7 @@ PHP_METHOD(Phalcon_Cli_Router, handle) { * * @param string pattern * @param string/array paths - * @return Phalcon\Cli\Router\Route + * @return \Phalcon\Cli\Router\Route */ PHP_METHOD(Phalcon_Cli_Router, add) { @@ -506,7 +506,7 @@ PHP_METHOD(Phalcon_Cli_Router, add) { ZEPHIR_INIT_VAR(route); object_init_ex(route, phalcon_cli_router_route_ce); - ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 123, pattern, paths); + ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 125, pattern, paths); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_routes"), route TSRMLS_CC); RETURN_CCTOR(route); @@ -601,7 +601,7 @@ PHP_METHOD(Phalcon_Cli_Router, getRoutes) { * Returns a route object by its id * * @param int id - * @return Phalcon\Cli\Router\Route + * @return \Phalcon\Cli\Router\Route */ PHP_METHOD(Phalcon_Cli_Router, getRouteById) { diff --git a/ext/phalcon/cli/router/route.zep.c b/ext/phalcon/cli/router/route.zep.c index 61aa40d03a6..626fa6763ae 100644 --- a/ext/phalcon/cli/router/route.zep.c +++ b/ext/phalcon/cli/router/route.zep.c @@ -630,7 +630,7 @@ PHP_METHOD(Phalcon_Cli_Router_Route, setName) { * If the callback returns false the route is treated as not matched * * @param callback callback - * @return Phalcon\Cli\Router\Route + * @return \Phalcon\Cli\Router\Route */ PHP_METHOD(Phalcon_Cli_Router_Route, beforeMatch) { @@ -729,7 +729,7 @@ PHP_METHOD(Phalcon_Cli_Router_Route, getReversedPaths) { * * @param string name * @param callable converter - * @return Phalcon\Cli\Router\Route + * @return \Phalcon\Cli\Router\Route */ PHP_METHOD(Phalcon_Cli_Router_Route, convert) { diff --git a/ext/phalcon/config.zep.c b/ext/phalcon/config.zep.c index 5789896c933..ea1cf278e2a 100644 --- a/ext/phalcon/config.zep.c +++ b/ext/phalcon/config.zep.c @@ -114,7 +114,7 @@ PHP_METHOD(Phalcon_Config, offsetExists) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); RETURN_MM_BOOL(zephir_isset_property_zval(this_ptr, index TSRMLS_CC)); @@ -143,7 +143,7 @@ PHP_METHOD(Phalcon_Config, get) { } - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); if (zephir_isset_property_zval(this_ptr, index TSRMLS_CC)) { @@ -174,7 +174,7 @@ PHP_METHOD(Phalcon_Config, offsetGet) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); ZEPHIR_OBS_VAR(_1); @@ -201,13 +201,13 @@ PHP_METHOD(Phalcon_Config, offsetSet) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); if (Z_TYPE_P(value) == IS_ARRAY) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_config_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 21, value); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 22, value); zephir_check_call_status(); zephir_update_property_zval_zval(this_ptr, index, _1 TSRMLS_CC); } else { @@ -235,7 +235,7 @@ PHP_METHOD(Phalcon_Config, offsetUnset) { ZEPHIR_SEPARATE_PARAM(index); - ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 20, index); + ZEPHIR_CALL_FUNCTION(&_0, "strval", NULL, 21, index); zephir_check_call_status(); ZEPHIR_CPY_WRT(index, _0); zephir_update_property_zval_zval(this_ptr, index, ZEPHIR_GLOBAL(global_null) TSRMLS_CC); @@ -261,7 +261,7 @@ PHP_METHOD(Phalcon_Config, merge) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_merge", NULL, 22, config); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_merge", NULL, 23, config); zephir_check_call_status(); RETURN_MM(); @@ -285,7 +285,7 @@ PHP_METHOD(Phalcon_Config, toArray) { ZEPHIR_INIT_VAR(arrayConfig); array_init(arrayConfig); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, this_ptr); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/config.zep", 180); for ( @@ -330,7 +330,7 @@ PHP_METHOD(Phalcon_Config, count) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, this_ptr); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM_LONG(zephir_fast_count_int(_0 TSRMLS_CC)); @@ -353,7 +353,7 @@ PHP_METHOD(Phalcon_Config, __set_state) { object_init_ex(return_value, phalcon_config_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 21, data); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 22, data); zephir_check_call_status(); RETURN_MM(); @@ -369,12 +369,12 @@ PHP_METHOD(Phalcon_Config, __set_state) { */ PHP_METHOD(Phalcon_Config, _merge) { - zephir_fcall_cache_entry *_8 = NULL, *_9 = NULL; + zephir_fcall_cache_entry *_6 = NULL, *_7 = NULL; zend_bool _4, _5; HashTable *_2; HashPosition _1; int ZEPHIR_LAST_CALL_STATUS; - zval *config, *instance = NULL, *key = NULL, *value = NULL, *number = NULL, *_0 = NULL, **_3, *_6 = NULL, *_7 = NULL; + zval *config, *instance = NULL, *key = NULL, *value = NULL, *number = NULL, *localObject = NULL, *_0 = NULL, **_3; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 1, 1, &config, &instance); @@ -391,39 +391,40 @@ PHP_METHOD(Phalcon_Config, _merge) { } ZEPHIR_CALL_METHOD(&number, instance, "count", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, config); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, config); zephir_check_call_status(); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/config.zep", 239); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/config.zep", 245); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) ) { ZEPHIR_GET_HMKEY(key, _2, _1); ZEPHIR_GET_HVALUE(value, _3); - _4 = zephir_isset_property_zval(instance, key TSRMLS_CC); - if (_4) { - _4 = Z_TYPE_P(value) == IS_OBJECT; - } - _5 = _4; - if (_5) { - ZEPHIR_OBS_NVAR(_6); - zephir_read_property_zval(&_6, instance, key, PH_NOISY_CC); - _5 = Z_TYPE_P(_6) == IS_OBJECT; + ZEPHIR_OBS_NVAR(localObject); + if (zephir_fetch_property_zval(&localObject, instance, key, PH_SILENT_CC)) { + _4 = Z_TYPE_P(localObject) == IS_OBJECT; + if (_4) { + _4 = Z_TYPE_P(value) == IS_OBJECT; + } + if (_4) { + _5 = zephir_instance_of_ev(localObject, phalcon_config_ce TSRMLS_CC); + if (_5) { + _5 = zephir_instance_of_ev(value, phalcon_config_ce TSRMLS_CC); + } + if (_5) { + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_merge", &_6, 23, value, localObject); + zephir_check_call_status(); + continue; + } + } } - if (_5) { - ZEPHIR_OBS_NVAR(_7); - zephir_read_property_zval(&_7, instance, key, PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_merge", &_8, 22, value, _7); + if (Z_TYPE_P(key) == IS_LONG) { + ZEPHIR_CALL_FUNCTION(&key, "strval", &_7, 21, number); zephir_check_call_status(); - } else { - if (Z_TYPE_P(key) == IS_LONG) { - ZEPHIR_CALL_FUNCTION(&key, "strval", &_9, 20, number); - zephir_check_call_status(); - ZEPHIR_SEPARATE(number); - zephir_increment(number); - } - zephir_update_property_zval_zval(instance, key, value TSRMLS_CC); + ZEPHIR_SEPARATE(number); + zephir_increment(number); } + zephir_update_property_zval_zval(instance, key, value TSRMLS_CC); } RETVAL_ZVAL(instance, 1, 0); RETURN_MM(); diff --git a/ext/phalcon/config/adapter/ini.zep.c b/ext/phalcon/config/adapter/ini.zep.c index 1d8ec21de83..29e9e518666 100644 --- a/ext/phalcon/config/adapter/ini.zep.c +++ b/ext/phalcon/config/adapter/ini.zep.c @@ -89,7 +89,7 @@ PHP_METHOD(Phalcon_Config_Adapter_Ini, __construct) { } - ZEPHIR_CALL_FUNCTION(&iniConfig, "parse_ini_file", NULL, 124, filePath, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&iniConfig, "parse_ini_file", NULL, 126, filePath, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(iniConfig)) { ZEPHIR_INIT_VAR(_0); @@ -139,7 +139,7 @@ PHP_METHOD(Phalcon_Config_Adapter_Ini, __construct) { zephir_array_update_zval(&config, section, &directives, PH_COPY | PH_SEPARATE); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_ini_ce, this_ptr, "__construct", &_12, 21, config); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_ini_ce, this_ptr, "__construct", &_12, 22, config); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -202,7 +202,7 @@ PHP_METHOD(Phalcon_Config_Adapter_Ini, _parseIniString) { zephir_substr(_3, path, zephir_get_intval(&_2), 0, ZEPHIR_SUBSTR_NO_LENGTH); zephir_get_strval(path, _3); zephir_create_array(return_value, 1, 0 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "_parseinistring", NULL, 125, path, value); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "_parseinistring", NULL, 127, path, value); zephir_check_call_status(); zephir_array_update_zval(&return_value, key, &_4, PH_COPY); RETURN_MM(); diff --git a/ext/phalcon/config/adapter/json.zep.c b/ext/phalcon/config/adapter/json.zep.c index cf8949d2a4b..8e9c94c0b53 100644 --- a/ext/phalcon/config/adapter/json.zep.c +++ b/ext/phalcon/config/adapter/json.zep.c @@ -78,7 +78,7 @@ PHP_METHOD(Phalcon_Config_Adapter_Json, __construct) { ZEPHIR_INIT_VAR(_2); zephir_file_get_contents(_2, filePath TSRMLS_CC); zephir_json_decode(_1, &(_1), _2, zephir_get_intval(ZEPHIR_GLOBAL(global_true)) TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_json_ce, this_ptr, "__construct", &_0, 21, _1); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_json_ce, this_ptr, "__construct", &_0, 22, _1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/config/adapter/php.zep.c b/ext/phalcon/config/adapter/php.zep.c index 4c233fa4dfa..3884809bbbb 100644 --- a/ext/phalcon/config/adapter/php.zep.c +++ b/ext/phalcon/config/adapter/php.zep.c @@ -91,7 +91,7 @@ PHP_METHOD(Phalcon_Config_Adapter_Php, __construct) { if (zephir_require_zval_ret(&_1, filePath TSRMLS_CC) == FAILURE) { RETURN_MM_NULL(); } - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_php_ce, this_ptr, "__construct", &_0, 21, _1); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_php_ce, this_ptr, "__construct", &_0, 22, _1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/config/adapter/yaml.zep.c b/ext/phalcon/config/adapter/yaml.zep.c index 54e99a27643..f8027dd58da 100644 --- a/ext/phalcon/config/adapter/yaml.zep.c +++ b/ext/phalcon/config/adapter/yaml.zep.c @@ -90,7 +90,7 @@ PHP_METHOD(Phalcon_Config_Adapter_Yaml, __construct) { ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "yaml", 0); - ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", NULL, 126, &_0); + ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", NULL, 128, &_0); zephir_check_call_status(); if (!(zephir_is_true(_1))) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_config_exception_ce, "Yaml extension not loaded", "phalcon/config/adapter/yaml.zep", 62); @@ -102,11 +102,11 @@ PHP_METHOD(Phalcon_Config_Adapter_Yaml, __construct) { ZEPHIR_INIT_VAR(_3); ZVAL_LONG(_3, ndocs); Z_SET_ISREF_P(_3); - ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 127, filePath, _2, _3, callbacks); + ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 129, filePath, _2, _3, callbacks); Z_UNSET_ISREF_P(_3); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 127, filePath); + ZEPHIR_CALL_FUNCTION(&yamlConfig, "yaml_parse_file", &_4, 129, filePath); zephir_check_call_status(); } if (ZEPHIR_IS_FALSE_IDENTICAL(yamlConfig)) { @@ -122,7 +122,7 @@ PHP_METHOD(Phalcon_Config_Adapter_Yaml, __construct) { ZEPHIR_MM_RESTORE(); return; } - ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_yaml_ce, this_ptr, "__construct", &_6, 21, yamlConfig); + ZEPHIR_CALL_PARENT(NULL, phalcon_config_adapter_yaml_ce, this_ptr, "__construct", &_6, 22, yamlConfig); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/crypt.zep.c b/ext/phalcon/crypt.zep.c index ca0716ee4bc..d14cb461966 100644 --- a/ext/phalcon/crypt.zep.c +++ b/ext/phalcon/crypt.zep.c @@ -271,15 +271,15 @@ PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 1) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (paddingSize - 1)); - ZEPHIR_CALL_FUNCTION(&_4, "str_repeat", &_5, 129, _2, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "str_repeat", &_5, 131, _2, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(padding); ZEPHIR_CONCAT_VV(padding, _4, _6); @@ -288,11 +288,11 @@ PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 2) { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 129, _2, &_1); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 131, _2, &_1); zephir_check_call_status(); break; } @@ -313,16 +313,16 @@ PHP_METHOD(Phalcon_Crypt, _cryptPadText) { _7 = 1; } i = _8; - ZEPHIR_CALL_FUNCTION(&_2, "rand", &_10, 107); + ZEPHIR_CALL_FUNCTION(&_2, "rand", &_10, 109); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 128, _2); + ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 130, _2); zephir_check_call_status(); zephir_concat_self(&padding, _4 TSRMLS_CC); } } ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "chr", &_3, 130, &_1); zephir_check_call_status(); zephir_concat_self(&padding, _6 TSRMLS_CC); break; @@ -330,15 +330,15 @@ PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 4) { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 0x80); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (paddingSize - 1)); - ZEPHIR_CALL_FUNCTION(&_6, "str_repeat", &_5, 129, _4, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "str_repeat", &_5, 131, _4, &_1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(padding); ZEPHIR_CONCAT_VV(padding, _2, _6); @@ -347,11 +347,11 @@ PHP_METHOD(Phalcon_Crypt, _cryptPadText) { if (paddingType == 5) { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 128, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "chr", &_3, 130, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 129, _2, &_1); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 131, _2, &_1); zephir_check_call_status(); break; } @@ -360,7 +360,7 @@ PHP_METHOD(Phalcon_Crypt, _cryptPadText) { ZVAL_STRING(&_1, " ", 0); ZEPHIR_SINIT_VAR(_11); ZVAL_LONG(&_11, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 129, &_1, &_11); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_5, 131, &_1, &_11); zephir_check_call_status(); break; } @@ -458,18 +458,18 @@ PHP_METHOD(Phalcon_Crypt, _cryptUnpadText) { ZVAL_LONG(&_4, 1); ZEPHIR_INIT_VAR(last); zephir_substr(last, text, zephir_get_intval(&_3), 1 , 0); - ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 130, last); + ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 132, last); zephir_check_call_status(); ord = zephir_get_intval(_5); if (ord <= blockSize) { paddingSize = ord; ZEPHIR_SINIT_VAR(_7); ZVAL_LONG(&_7, 0); - ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 128, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 130, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, (paddingSize - 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, _8, &_7); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, _8, &_7); zephir_check_call_status(); ZEPHIR_INIT_VAR(padding); ZEPHIR_CONCAT_VV(padding, _10, last); @@ -490,18 +490,18 @@ PHP_METHOD(Phalcon_Crypt, _cryptUnpadText) { ZVAL_LONG(&_4, 1); ZEPHIR_INIT_NVAR(last); zephir_substr(last, text, zephir_get_intval(&_3), 1 , 0); - ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 130, last); + ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 132, last); zephir_check_call_status(); ord = zephir_get_intval(_5); if (ord <= blockSize) { paddingSize = ord; ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, paddingSize); - ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 128, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "chr", &_9, 130, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, paddingSize); - ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_11, 129, _8, &_7); + ZEPHIR_CALL_FUNCTION(&padding, "str_repeat", &_11, 131, _8, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, (length - paddingSize)); @@ -520,7 +520,7 @@ PHP_METHOD(Phalcon_Crypt, _cryptUnpadText) { ZVAL_LONG(&_4, 1); ZEPHIR_INIT_NVAR(last); zephir_substr(last, text, zephir_get_intval(&_3), 1 , 0); - ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 130, last); + ZEPHIR_CALL_FUNCTION(&_5, "ord", &_6, 132, last); zephir_check_call_status(); paddingSize = zephir_get_intval(_5); break; @@ -683,7 +683,7 @@ PHP_METHOD(Phalcon_Crypt, encrypt) { zephir_read_property_this(&cipher, this_ptr, SL("_cipher"), PH_NOISY_CC); ZEPHIR_OBS_VAR(mode); zephir_read_property_this(&mode, this_ptr, SL("_mode"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 131, cipher, mode); + ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 133, cipher, mode); zephir_check_call_status(); if (ZEPHIR_LT_LONG(ivSize, zephir_fast_strlen_ev(encryptKey))) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 320); @@ -691,14 +691,14 @@ PHP_METHOD(Phalcon_Crypt, encrypt) { } ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 2); - ZEPHIR_CALL_FUNCTION(&iv, "mcrypt_create_iv", NULL, 132, ivSize, &_0); + ZEPHIR_CALL_FUNCTION(&iv, "mcrypt_create_iv", NULL, 134, ivSize, &_0); zephir_check_call_status(); if (Z_TYPE_P(iv) != IS_STRING) { - ZEPHIR_CALL_FUNCTION(&_1, "strval", NULL, 20, iv); + ZEPHIR_CALL_FUNCTION(&_1, "strval", NULL, 21, iv); zephir_check_call_status(); ZEPHIR_CPY_WRT(iv, _1); } - ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 133, cipher, mode); + ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 135, cipher, mode); zephir_check_call_status(); if (Z_TYPE_P(blockSize) != IS_LONG) { _2 = zephir_get_intval(blockSize); @@ -721,7 +721,7 @@ PHP_METHOD(Phalcon_Crypt, encrypt) { } else { ZEPHIR_CPY_WRT(padded, text); } - ZEPHIR_CALL_FUNCTION(&_1, "mcrypt_encrypt", NULL, 134, cipher, encryptKey, padded, mode, iv); + ZEPHIR_CALL_FUNCTION(&_1, "mcrypt_encrypt", NULL, 136, cipher, encryptKey, padded, mode, iv); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, iv, _1); RETURN_MM(); @@ -779,7 +779,7 @@ PHP_METHOD(Phalcon_Crypt, decrypt) { zephir_read_property_this(&cipher, this_ptr, SL("_cipher"), PH_NOISY_CC); ZEPHIR_OBS_VAR(mode); zephir_read_property_this(&mode, this_ptr, SL("_mode"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 131, cipher, mode); + ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 133, cipher, mode); zephir_check_call_status(); ZEPHIR_INIT_VAR(keySize); ZVAL_LONG(keySize, zephir_fast_strlen_ev(decryptKey)); @@ -799,9 +799,9 @@ PHP_METHOD(Phalcon_Crypt, decrypt) { ZVAL_LONG(&_1, 0); ZEPHIR_INIT_VAR(_2); zephir_substr(_2, text, 0 , zephir_get_intval(ivSize), 0); - ZEPHIR_CALL_FUNCTION(&decrypted, "mcrypt_decrypt", NULL, 135, cipher, decryptKey, _0, mode, _2); + ZEPHIR_CALL_FUNCTION(&decrypted, "mcrypt_decrypt", NULL, 137, cipher, decryptKey, _0, mode, _2); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 133, cipher, mode); + ZEPHIR_CALL_FUNCTION(&blockSize, "mcrypt_get_block_size", NULL, 135, cipher, mode); zephir_check_call_status(); ZEPHIR_OBS_VAR(paddingType); zephir_read_property_this(&paddingType, this_ptr, SL("_padding"), PH_NOISY_CC); @@ -861,19 +861,19 @@ PHP_METHOD(Phalcon_Crypt, encryptBase64) { if (safe == 1) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "encrypt", &_1, 0, text, key); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_2, "base64_encode", &_3, 112, _0); + ZEPHIR_CALL_FUNCTION(&_2, "base64_encode", &_3, 114, _0); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "+/", 0); ZEPHIR_SINIT_VAR(_5); ZVAL_STRING(&_5, "-_", 0); - ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 53, _2, &_4, &_5); + ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 54, _2, &_4, &_5); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_CALL_METHOD(&_0, this_ptr, "encrypt", &_1, 0, text, key); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", &_3, 112, _0); + ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", &_3, 114, _0); zephir_check_call_status(); RETURN_MM(); @@ -924,15 +924,15 @@ PHP_METHOD(Phalcon_Crypt, decryptBase64) { ZVAL_STRING(&_0, "-_", 0); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "+/", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, text, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, text, &_0, &_1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_3, "base64_decode", &_4, 113, _2); + ZEPHIR_CALL_FUNCTION(&_3, "base64_decode", &_4, 115, _2); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "decrypt", &_5, 0, _3, key); zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_CALL_FUNCTION(&_2, "base64_decode", &_4, 113, text); + ZEPHIR_CALL_FUNCTION(&_2, "base64_decode", &_4, 115, text); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "decrypt", &_5, 0, _2, key); zephir_check_call_status(); @@ -949,7 +949,7 @@ PHP_METHOD(Phalcon_Crypt, getAvailableCiphers) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_algorithms", NULL, 136); + ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_algorithms", NULL, 138); zephir_check_call_status(); RETURN_MM(); @@ -964,7 +964,7 @@ PHP_METHOD(Phalcon_Crypt, getAvailableModes) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_modes", NULL, 137); + ZEPHIR_RETURN_CALL_FUNCTION("mcrypt_list_modes", NULL, 139); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/db.zep.c b/ext/phalcon/db.zep.c index 1d8c39fbafd..424dec4efff 100644 --- a/ext/phalcon/db.zep.c +++ b/ext/phalcon/db.zep.c @@ -30,11 +30,14 @@ * * Phalcon\Db is an abstract class. You only can use it with a database adapter like Phalcon\Db\Adapter\Pdo * - * + * + *use Phalcon\Db; + *use Phalcon\Db\Exception; + *use Phalcon\Db\Adapter\Pdo\Mysql as MysqlConnection; * *try { * - * $connection = new \Phalcon\Db\Adapter\Pdo\Mysql(array( + * $connection = new MysqlConnection(array( * 'host' => '192.168.0.11', * 'username' => 'sigma', * 'password' => 'secret', @@ -43,15 +46,14 @@ * )); * * $result = $connection->query("SELECT * FROM robots LIMIT 5"); - * $result->setFetchMode(Phalcon\Db::FETCH_NUM); + * $result->setFetchMode(Db::FETCH_NUM); * while ($robot = $result->fetch()) { * print_r($robot); * } * - *} catch (Phalcon\Db\Exception $e) { + *} catch (Exception $e) { * echo $e->getMessage(), PHP_EOL; - *} - * + *} * */ ZEPHIR_INIT_CLASS(Phalcon_Db) { diff --git a/ext/phalcon/db/adapter.zep.c b/ext/phalcon/db/adapter.zep.c index f97c1d71a5a..11cbe016ca3 100644 --- a/ext/phalcon/db/adapter.zep.c +++ b/ext/phalcon/db/adapter.zep.c @@ -132,8 +132,6 @@ PHP_METHOD(Phalcon_Db_Adapter, getType) { /** * Active SQL bound parameter variables - * - * @var string */ PHP_METHOD(Phalcon_Db_Adapter, getSqlVariables) { @@ -1257,7 +1255,7 @@ PHP_METHOD(Phalcon_Db_Adapter, dropTable) { } /** - * Creates a view + * Creates a view */ PHP_METHOD(Phalcon_Db_Adapter, createView) { diff --git a/ext/phalcon/db/adapter/pdo.zep.c b/ext/phalcon/db/adapter/pdo.zep.c index 0dedaa02975..8f778510c4d 100644 --- a/ext/phalcon/db/adapter/pdo.zep.c +++ b/ext/phalcon/db/adapter/pdo.zep.c @@ -77,7 +77,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo, __construct) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "connect", NULL, 0, descriptor); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_ce, this_ptr, "__construct", &_0, 24, descriptor); + ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_ce, this_ptr, "__construct", &_0, 25, descriptor); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -292,7 +292,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo, executePrepared) { if (ZEPHIR_IS_LONG(type, 1)) { ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 10); - ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_5, 25, value, &_4); + ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_5, 26, value, &_4); zephir_check_call_status(); break; } @@ -454,7 +454,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo, query) { zephir_check_call_status(); } object_init_ex(return_value, phalcon_db_result_pdo_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 26, this_ptr, statement, sqlStatement, bindParams, bindTypes); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 27, this_ptr, statement, sqlStatement, bindParams, bindTypes); zephir_check_call_status(); RETURN_MM(); } @@ -682,7 +682,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo, convertBoundParams) { ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, setOrder); Z_SET_ISREF_P(matches); - ZEPHIR_CALL_FUNCTION(&_1, "preg_match_all", NULL, 27, bindPattern, sql, matches, _0); + ZEPHIR_CALL_FUNCTION(&_1, "preg_match_all", NULL, 28, bindPattern, sql, matches, _0); Z_UNSET_ISREF_P(matches); zephir_check_call_status(); if (zephir_is_true(_1)) { @@ -711,7 +711,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo, convertBoundParams) { } ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "?", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&boundSql, "preg_replace", NULL, 28, bindPattern, _0, sql); + ZEPHIR_CALL_FUNCTION(&boundSql, "preg_replace", NULL, 29, bindPattern, _0, sql); zephir_check_temp_parameter(_0); zephir_check_call_status(); } else { diff --git a/ext/phalcon/db/adapter/pdo/mysql.zep.c b/ext/phalcon/db/adapter/pdo/mysql.zep.c index 769e32ce54c..5ab98df2d53 100644 --- a/ext/phalcon/db/adapter/pdo/mysql.zep.c +++ b/ext/phalcon/db/adapter/pdo/mysql.zep.c @@ -318,7 +318,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo_Mysql, describeColumns) { zephir_array_fetch_long(&columnName, field, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/mysql.zep", 324 TSRMLS_CC); ZEPHIR_INIT_NVAR(_7); object_init_ex(_7, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_15, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_15, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter/pdo/mysql.zep", 325); ZEPHIR_CPY_WRT(oldColumn, columnName); diff --git a/ext/phalcon/db/adapter/pdo/oracle.zep.c b/ext/phalcon/db/adapter/pdo/oracle.zep.c index 5797f6df5a5..5303de6c76e 100644 --- a/ext/phalcon/db/adapter/pdo/oracle.zep.c +++ b/ext/phalcon/db/adapter/pdo/oracle.zep.c @@ -82,7 +82,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo_Oracle, connect) { ZEPHIR_OBS_NVAR(descriptor); zephir_read_property_this(&descriptor, this_ptr, SL("_descriptor"), PH_NOISY_CC); } - ZEPHIR_CALL_PARENT(&status, phalcon_db_adapter_pdo_oracle_ce, this_ptr, "connect", &_0, 139, descriptor); + ZEPHIR_CALL_PARENT(&status, phalcon_db_adapter_pdo_oracle_ce, this_ptr, "connect", &_0, 141, descriptor); zephir_check_call_status(); ZEPHIR_OBS_VAR(startup); if (zephir_array_isset_string_fetch(&startup, descriptor, SS("startup"), 0 TSRMLS_CC)) { @@ -261,7 +261,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo_Oracle, describeColumns) { zephir_array_fetch_long(&columnName, field, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/oracle.zep", 194 TSRMLS_CC); ZEPHIR_INIT_NVAR(_8); object_init_ex(_8, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _8, "__construct", &_11, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _8, "__construct", &_11, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _8, PH_SEPARATE, "phalcon/db/adapter/pdo/oracle.zep", 199); ZEPHIR_CPY_WRT(oldColumn, columnName); diff --git a/ext/phalcon/db/adapter/pdo/postgresql.zep.c b/ext/phalcon/db/adapter/pdo/postgresql.zep.c index 5a6293f7385..ac0554100c7 100644 --- a/ext/phalcon/db/adapter/pdo/postgresql.zep.c +++ b/ext/phalcon/db/adapter/pdo/postgresql.zep.c @@ -101,7 +101,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, connect) { zephir_array_update_string(&descriptor, SL("password"), &ZEPHIR_GLOBAL(global_null), PH_COPY | PH_SEPARATE); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_postgresql_ce, this_ptr, "connect", &_3, 139, descriptor); + ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_postgresql_ce, this_ptr, "connect", &_3, 141, descriptor); zephir_check_call_status(); if (!(ZEPHIR_IS_EMPTY(schema))) { ZEPHIR_INIT_VAR(sql); @@ -328,7 +328,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, describeColumns) { ZVAL_STRING(_8, "/^'|'?::[[:alnum:][:space:]]+$/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_9); ZVAL_STRING(_9, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_15, "preg_replace", &_16, 28, _8, _9, _14); + ZEPHIR_CALL_FUNCTION(&_15, "preg_replace", &_16, 29, _8, _9, _14); zephir_check_temp_parameter(_8); zephir_check_temp_parameter(_9); zephir_check_call_status(); @@ -336,7 +336,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, describeColumns) { zephir_array_fetch_string(&_17, definition, SL("default"), PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/postgresql.zep", 305 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_18); ZVAL_STRING(&_18, "null", 0); - ZEPHIR_CALL_FUNCTION(&_19, "strcasecmp", &_20, 140, _17, &_18); + ZEPHIR_CALL_FUNCTION(&_19, "strcasecmp", &_20, 19, _17, &_18); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_19, 0)) { zephir_array_update_string(&definition, SL("default"), &ZEPHIR_GLOBAL(global_null), PH_COPY | PH_SEPARATE); @@ -345,7 +345,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo_Postgresql, describeColumns) { zephir_array_fetch_long(&columnName, field, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/postgresql.zep", 313 TSRMLS_CC); ZEPHIR_INIT_NVAR(_7); object_init_ex(_7, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter/pdo/postgresql.zep", 314); ZEPHIR_CPY_WRT(oldColumn, columnName); diff --git a/ext/phalcon/db/adapter/pdo/sqlite.zep.c b/ext/phalcon/db/adapter/pdo/sqlite.zep.c index 7e0ed40428f..3d4066032ee 100644 --- a/ext/phalcon/db/adapter/pdo/sqlite.zep.c +++ b/ext/phalcon/db/adapter/pdo/sqlite.zep.c @@ -82,7 +82,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, connect) { return; } zephir_array_update_string(&descriptor, SL("dsn"), &dbname, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_sqlite_ce, this_ptr, "connect", &_0, 139, descriptor); + ZEPHIR_CALL_PARENT(NULL, phalcon_db_adapter_pdo_sqlite_ce, this_ptr, "connect", &_0, 141, descriptor); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -287,7 +287,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, describeColumns) { zephir_array_fetch_long(&_13, field, 4, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/sqlite.zep", 279 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "null", 0); - ZEPHIR_CALL_FUNCTION(&_15, "strcasecmp", &_16, 140, _13, &_14); + ZEPHIR_CALL_FUNCTION(&_15, "strcasecmp", &_16, 19, _13, &_14); zephir_check_call_status(); _9 = !ZEPHIR_IS_LONG(_15, 0); if (_9) { @@ -300,7 +300,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, describeColumns) { ZVAL_STRING(_7, "/^'|'$/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_8); ZVAL_STRING(_8, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_19, "preg_replace", &_20, 28, _7, _8, _18); + ZEPHIR_CALL_FUNCTION(&_19, "preg_replace", &_20, 29, _7, _8, _18); zephir_check_temp_parameter(_7); zephir_check_temp_parameter(_8); zephir_check_call_status(); @@ -309,7 +309,7 @@ PHP_METHOD(Phalcon_Db_Adapter_Pdo_Sqlite, describeColumns) { zephir_array_fetch_long(&columnName, field, 1, PH_NOISY | PH_READONLY, "phalcon/db/adapter/pdo/sqlite.zep", 286 TSRMLS_CC); ZEPHIR_INIT_NVAR(_7); object_init_ex(_7, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_21, 140, columnName, definition); zephir_check_call_status(); zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter/pdo/sqlite.zep", 287); ZEPHIR_CPY_WRT(oldColumn, columnName); diff --git a/ext/phalcon/db/adapterinterface.zep.c b/ext/phalcon/db/adapterinterface.zep.c index 836864f1527..454605bb75b 100644 --- a/ext/phalcon/db/adapterinterface.zep.c +++ b/ext/phalcon/db/adapterinterface.zep.c @@ -275,7 +275,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Db_AdapterInterface, query); /** * Sends SQL statements to the database server returning the success state. - * Use this method only when the SQL statement sent to the server doesn't return any rows + * Use this method only when the SQL statement sent to the server doesn't return any rows */ ZEPHIR_DOC_METHOD(Phalcon_Db_AdapterInterface, execute); diff --git a/ext/phalcon/db/column.zep.c b/ext/phalcon/db/column.zep.c index 4071b4f15ba..073ec1fe32c 100644 --- a/ext/phalcon/db/column.zep.c +++ b/ext/phalcon/db/column.zep.c @@ -279,8 +279,6 @@ ZEPHIR_INIT_CLASS(Phalcon_Db_Column) { /** * Column's name - * - * @var string */ PHP_METHOD(Phalcon_Db_Column, getName) { @@ -291,8 +289,6 @@ PHP_METHOD(Phalcon_Db_Column, getName) { /** * Schema which table related is - * - * @var string */ PHP_METHOD(Phalcon_Db_Column, getSchemaName) { @@ -303,8 +299,6 @@ PHP_METHOD(Phalcon_Db_Column, getSchemaName) { /** * Column data type - * - * @var int|string */ PHP_METHOD(Phalcon_Db_Column, getType) { @@ -315,8 +309,6 @@ PHP_METHOD(Phalcon_Db_Column, getType) { /** * Column data type reference - * - * @var int */ PHP_METHOD(Phalcon_Db_Column, getTypeReference) { @@ -327,8 +319,6 @@ PHP_METHOD(Phalcon_Db_Column, getTypeReference) { /** * Column data type values - * - * @var array|string */ PHP_METHOD(Phalcon_Db_Column, getTypeValues) { @@ -339,8 +329,6 @@ PHP_METHOD(Phalcon_Db_Column, getTypeValues) { /** * Integer column size - * - * @var int */ PHP_METHOD(Phalcon_Db_Column, getSize) { @@ -351,8 +339,6 @@ PHP_METHOD(Phalcon_Db_Column, getSize) { /** * Integer column number scale - * - * @var int */ PHP_METHOD(Phalcon_Db_Column, getScale) { @@ -645,7 +631,7 @@ PHP_METHOD(Phalcon_Db_Column, __set_state) { zephir_array_update_string(&definition, SL("bindType"), &bindType, PH_COPY | PH_SEPARATE); } object_init_ex(return_value, phalcon_db_column_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 138, columnName, definition); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 140, columnName, definition); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/db/dialect.zep.c b/ext/phalcon/db/dialect.zep.c index 82f70df8fee..d42cc2235ac 100644 --- a/ext/phalcon/db/dialect.zep.c +++ b/ext/phalcon/db/dialect.zep.c @@ -325,7 +325,7 @@ PHP_METHOD(Phalcon_Db_Dialect, getColumnList) { ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(column, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlcolumn", &_4, 29, column, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlcolumn", &_4, 30, column, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_append(&columns, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 158); } @@ -459,17 +459,17 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlExpression) { } do { if (ZEPHIR_IS_STRING(type, "scalar")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionscalar", NULL, 30, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionscalar", NULL, 31, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "object")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionobject", NULL, 31, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionobject", NULL, 32, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "qualified")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionqualified", NULL, 32, expression, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionqualified", NULL, 33, expression, escapeChar); zephir_check_call_status(); RETURN_MM(); } @@ -518,34 +518,34 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlExpression) { RETURN_CTOR(_0); } if (ZEPHIR_IS_STRING(type, "binary-op")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionbinaryoperations", NULL, 33, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionbinaryoperations", NULL, 34, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "unary-op")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionunaryoperations", NULL, 34, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionunaryoperations", NULL, 35, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "parentheses")) { zephir_array_fetch_string(&_0, expression, SL("left"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 305 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_6, this_ptr, "getsqlexpression", NULL, 35, _0, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_6, this_ptr, "getsqlexpression", NULL, 36, _0, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "(", _6, ")"); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "functionCall")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionfunctioncall", NULL, 36, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionfunctioncall", NULL, 37, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "list")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionlist", NULL, 37, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionlist", NULL, 38, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "all")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionall", NULL, 38, expression, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionall", NULL, 39, expression, escapeChar); zephir_check_call_status(); RETURN_MM(); } @@ -557,17 +557,17 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlExpression) { RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "cast")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncastvalue", NULL, 39, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncastvalue", NULL, 40, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "convert")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionconvertvalue", NULL, 40, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressionconvertvalue", NULL, 41, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(type, "case")) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncase", NULL, 41, expression, escapeChar, bindCounts); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlexpressioncase", NULL, 42, expression, escapeChar, bindCounts); zephir_check_call_status(); RETURN_MM(); } @@ -616,7 +616,7 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlTable) { zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", NULL, 42, table, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", NULL, 43, table, escapeChar); zephir_check_call_status(); RETURN_MM(); @@ -665,12 +665,12 @@ PHP_METHOD(Phalcon_Db_Dialect, select) { zephir_array_isset_string_fetch(&bindCounts, definition, SS("bindCounts"), 0 TSRMLS_CC); ZEPHIR_OBS_VAR(escapeChar); zephir_read_property_this(&escapeChar, this_ptr, SL("_escapeChar"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 43, columns, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 44, columns, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SV(_1, " ", _0); zephir_concat_self(&sql, _1 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "getsqlexpressionfrom", NULL, 44, tables, escapeChar); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "getsqlexpressionfrom", NULL, 45, tables, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SV(_3, " ", _2); @@ -682,7 +682,7 @@ PHP_METHOD(Phalcon_Db_Dialect, select) { } if (_4) { zephir_array_fetch_string(&_6, definition, SL("joins"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 429 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionjoins", NULL, 45, _6, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionjoins", NULL, 46, _6, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -694,7 +694,7 @@ PHP_METHOD(Phalcon_Db_Dialect, select) { _8 = zephir_is_true(where); } if (_8) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionwhere", NULL, 46, where, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionwhere", NULL, 47, where, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -706,7 +706,7 @@ PHP_METHOD(Phalcon_Db_Dialect, select) { _9 = zephir_is_true(groupBy); } if (_9) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressiongroupby", NULL, 47, groupBy, escapeChar); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressiongroupby", NULL, 48, groupBy, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -718,7 +718,7 @@ PHP_METHOD(Phalcon_Db_Dialect, select) { _10 = zephir_is_true(having); } if (_10) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionhaving", NULL, 48, having, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionhaving", NULL, 49, having, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -730,7 +730,7 @@ PHP_METHOD(Phalcon_Db_Dialect, select) { _11 = zephir_is_true(orderBy); } if (_11) { - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionorderby", NULL, 49, orderBy, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getsqlexpressionorderby", NULL, 50, orderBy, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, " ", _5); @@ -746,7 +746,7 @@ PHP_METHOD(Phalcon_Db_Dialect, select) { zephir_create_array(_13, 2, 0 TSRMLS_CC); zephir_array_update_string(&_13, SL("sql"), &sql, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_13, SL("value"), &limit, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&sql, this_ptr, "getsqlexpressionlimit", NULL, 50, _13, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&sql, this_ptr, "getsqlexpressionlimit", NULL, 51, _13, escapeChar, bindCounts); zephir_check_call_status(); } _14 = zephir_array_isset_string_fetch(&forUpdate, definition, SS("forUpdate"), 1 TSRMLS_CC); @@ -900,7 +900,7 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionScalar) { if (zephir_array_isset_string(expression, SS("column"))) { zephir_array_fetch_string(&_0, expression, SL("column"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 525 TSRMLS_CC); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlcolumn", NULL, 29, _0); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getsqlcolumn", NULL, 30, _0); zephir_check_call_status(); RETURN_MM(); } @@ -1036,7 +1036,7 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionBinaryOperations) { ZEPHIR_CALL_METHOD(&left, this_ptr, "getsqlexpression", &_1, 0, _0, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_2, expression, SL("right"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 583 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 35, _2, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 36, _2, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_3, expression, SL("op"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 585 TSRMLS_CC); ZEPHIR_CONCAT_VSVSV(return_value, left, " ", _3, " ", right); @@ -1082,7 +1082,7 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionUnaryOperations) { ZEPHIR_OBS_VAR(right); if (zephir_array_isset_string_fetch(&right, expression, SS("right"), 0 TSRMLS_CC)) { zephir_array_fetch_string(&_2, expression, SL("op"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 606 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getsqlexpression", &_1, 35, right, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getsqlexpression", &_1, 36, right, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_VSV(return_value, _2, " ", _0); RETURN_MM(); @@ -1298,7 +1298,7 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionCastValue) { ZEPHIR_CALL_METHOD(&left, this_ptr, "getsqlexpression", &_1, 0, _0, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_2, expression, SL("right"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 693 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 35, _2, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 36, _2, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "CAST(", left, " AS ", right, ")"); RETURN_MM(); @@ -1336,7 +1336,7 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionConvertValue) { ZEPHIR_CALL_METHOD(&left, this_ptr, "getsqlexpression", &_1, 0, _0, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_2, expression, SL("right"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 706 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 35, _2, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&right, this_ptr, "getsqlexpression", &_1, 36, _2, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "CONVERT(", left, " USING ", right, ")"); RETURN_MM(); @@ -1387,17 +1387,17 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionCase) { zephir_array_fetch_string(&_7, whenClause, SL("type"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 721 TSRMLS_CC); if (ZEPHIR_IS_STRING(_7, "when")) { zephir_array_fetch_string(&_9, whenClause, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 723 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 35, _9, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 36, _9, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_fetch_string(&_11, whenClause, SL("then"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 725 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_10, this_ptr, "getsqlexpression", &_2, 35, _11, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "getsqlexpression", &_2, 36, _11, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SVSV(_12, " WHEN ", _8, " THEN ", _10); zephir_concat_self(&sql, _12 TSRMLS_CC); } else { zephir_array_fetch_string(&_9, whenClause, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 727 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 35, _9, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_2, 36, _9, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SV(_12, " ELSE ", _8); @@ -1441,7 +1441,7 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionFrom) { ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(table, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqltable", &_4, 51, table, escapeChar); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqltable", &_4, 52, table, escapeChar); zephir_check_call_status(); zephir_array_append(&tables, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 746); } @@ -1511,7 +1511,7 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionJoins) { ; zephir_hash_move_forward_ex(_6, &_5) ) { ZEPHIR_GET_HVALUE(condition, _7); - ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_4, 35, condition, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_8, this_ptr, "getsqlexpression", &_4, 36, condition, escapeChar, bindCounts); zephir_check_call_status(); zephir_array_append(&joinCondition, _8, PH_SEPARATE, "phalcon/db/dialect.zep", 779); } @@ -1532,7 +1532,7 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionJoins) { zephir_concat_self_str(&joinType, SL(" ") TSRMLS_CC); } zephir_array_fetch_string(&_11, join, SL("source"), PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 792 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&joinTable, this_ptr, "getsqltable", &_12, 51, _11, escapeChar); + ZEPHIR_CALL_METHOD(&joinTable, this_ptr, "getsqltable", &_12, 52, _11, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_13); ZEPHIR_CONCAT_SVSVSV(_13, " ", joinType, "JOIN ", joinTable, " ON ", joinCondition); @@ -1785,7 +1785,7 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionLimit) { _3 = Z_TYPE_P(offset) == IS_ARRAY; } if (_3) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getsqlexpression", &_2, 35, offset, escapeChar, bindCounts); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getsqlexpression", &_2, 36, offset, escapeChar, bindCounts); zephir_check_call_status(); ZEPHIR_CPY_WRT(offset, _4); } @@ -1840,7 +1840,7 @@ PHP_METHOD(Phalcon_Db_Dialect, prepareColumnAlias) { if (!ZEPHIR_IS_STRING(alias, "")) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", NULL, 42, alias, escapeChar); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", NULL, 43, alias, escapeChar); zephir_check_call_status(); ZEPHIR_CONCAT_VSV(return_value, qualified, " AS ", _0); RETURN_MM(); @@ -1893,18 +1893,18 @@ PHP_METHOD(Phalcon_Db_Dialect, prepareTable) { } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", &_1, 42, table, escapeChar); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", &_1, 43, table, escapeChar); zephir_check_call_status(); zephir_get_strval(table, _0); if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 42, schema, escapeChar); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 43, schema, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_VSV(_3, _2, ".", table); zephir_get_strval(table, _3); } if (!ZEPHIR_IS_STRING(alias, "")) { - ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 42, alias, escapeChar); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "escape", &_1, 43, alias, escapeChar); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_VSV(_3, table, " AS ", _2); @@ -1955,11 +1955,11 @@ PHP_METHOD(Phalcon_Db_Dialect, prepareQualified) { if (!ZEPHIR_IS_STRING(domain, "")) { ZEPHIR_INIT_VAR(_0); ZEPHIR_CONCAT_VSV(_0, domain, ".", column); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 42, _0, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 43, _0, escapeChar); zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 42, column, escapeChar); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "escape", &_1, 43, column, escapeChar); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/db/dialect/mysql.zep.c b/ext/phalcon/db/dialect/mysql.zep.c index f4928ac3dd0..26ac6e8dffb 100644 --- a/ext/phalcon/db/dialect/mysql.zep.c +++ b/ext/phalcon/db/dialect/mysql.zep.c @@ -259,7 +259,7 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) { ZEPHIR_GET_HVALUE(value, _7); ZEPHIR_SINIT_NVAR(_8); ZVAL_STRING(&_8, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_9, 141, value, &_8); + ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_9, 142, value, &_8); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "\"", _0, "\", "); @@ -277,7 +277,7 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) { } else { ZEPHIR_SINIT_NVAR(_10); ZVAL_STRING(&_10, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_9, 141, typeValues, &_10); + ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_9, 142, typeValues, &_10); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, "(\"", _2, "\")"); @@ -339,7 +339,7 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 142, defaultValue, &_3); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\""); @@ -419,7 +419,7 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 142, defaultValue, &_3); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\""); @@ -541,7 +541,7 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 43, _4); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 44, _4); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSVS(_1, "`", _2, "` (", _3, ")"); @@ -644,7 +644,7 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, addPrimaryKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 44, _2); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD PRIMARY KEY (", _1, ")"); RETURN_MM(); @@ -736,7 +736,7 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 43, _3); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 44, _3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_5, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); @@ -746,7 +746,7 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_8, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 43, _8); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 44, _8); zephir_check_call_status(); ZEPHIR_INIT_VAR(sql); ZEPHIR_CONCAT_SVSVSVSVSVS(sql, "ALTER TABLE ", _0, " ADD FOREIGN KEY `", _1, "`(", _2, ") REFERENCES ", _4, "(", _7, ")"); @@ -903,7 +903,7 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_NVAR(_6); ZVAL_STRING(&_6, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 142, defaultValue, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\""); @@ -941,7 +941,7 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) { ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_13, 43, _4); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_13, 44, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(indexSql); ZEPHIR_CONCAT_SVS(indexSql, "PRIMARY KEY (", _3, ")"); @@ -950,13 +950,13 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { if (!(ZEPHIR_IS_EMPTY(indexType))) { ZEPHIR_CALL_METHOD(&_14, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_13, 43, _14); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_13, 44, _14); zephir_check_call_status(); ZEPHIR_CONCAT_VSVSVS(indexSql, indexType, " KEY `", indexName, "` (", _7, ")"); } else { ZEPHIR_CALL_METHOD(&_15, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_14, this_ptr, "getcolumnlist", &_13, 43, _15); + ZEPHIR_CALL_METHOD(&_14, this_ptr, "getcolumnlist", &_13, 44, _15); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(indexSql, "KEY `", indexName, "` (", _14, ")"); } @@ -976,13 +976,13 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_13, 43, _7); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_13, 44, _7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_14, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_13, 43, _19); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_13, 44, _19); zephir_check_call_status(); ZEPHIR_INIT_NVAR(referenceSql); ZEPHIR_CONCAT_SVSVSSVSVS(referenceSql, "CONSTRAINT `", _3, "` FOREIGN KEY (", _4, ")", " REFERENCES `", _14, "`(", _15, ")"); diff --git a/ext/phalcon/db/dialect/oracle.zep.c b/ext/phalcon/db/dialect/oracle.zep.c index 684ad8d82c4..03d43eafaf0 100644 --- a/ext/phalcon/db/dialect/oracle.zep.c +++ b/ext/phalcon/db/dialect/oracle.zep.c @@ -775,14 +775,14 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, viewExists) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, viewName); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_VIEWS WHERE VIEW_NAME='", _0, "' AND OWNER='", _2, "'"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, viewName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_VIEWS WHERE VIEW_NAME='", _0, "'"); RETURN_MM(); @@ -811,7 +811,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, listViews) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT VIEW_NAME FROM ALL_VIEWS WHERE OWNER='", _0, "' ORDER BY VIEW_NAME"); RETURN_MM(); @@ -858,14 +858,14 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, tableExists) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, tableName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, tableName); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_TABLES WHERE TABLE_NAME='", _0, "' AND OWNER = '", _2, "'"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, tableName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, tableName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT CASE WHEN COUNT(*) > 0 THEN 1 ELSE 0 END RET FROM ALL_TABLES WHERE TABLE_NAME='", _0, "'"); RETURN_MM(); @@ -909,14 +909,14 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeColumns) { if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schema); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT TC.COLUMN_NAME, TC.DATA_TYPE, TC.DATA_LENGTH, TC.DATA_PRECISION, TC.DATA_SCALE, TC.NULLABLE, C.CONSTRAINT_TYPE, TC.DATA_DEFAULT, CC.POSITION FROM ALL_TAB_COLUMNS TC LEFT JOIN (ALL_CONS_COLUMNS CC JOIN ALL_CONSTRAINTS C ON (CC.CONSTRAINT_NAME = C.CONSTRAINT_NAME AND CC.TABLE_NAME = C.TABLE_NAME AND CC.OWNER = C.OWNER AND C.CONSTRAINT_TYPE = 'P')) ON TC.TABLE_NAME = CC.TABLE_NAME AND TC.COLUMN_NAME = CC.COLUMN_NAME WHERE TC.TABLE_NAME = '", _0, "' AND TC.OWNER = '", _2, "' ORDER BY TC.COLUMN_ID"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT TC.COLUMN_NAME, TC.DATA_TYPE, TC.DATA_LENGTH, TC.DATA_PRECISION, TC.DATA_SCALE, TC.NULLABLE, C.CONSTRAINT_TYPE, TC.DATA_DEFAULT, CC.POSITION FROM ALL_TAB_COLUMNS TC LEFT JOIN (ALL_CONS_COLUMNS CC JOIN ALL_CONSTRAINTS C ON (CC.CONSTRAINT_NAME = C.CONSTRAINT_NAME AND CC.TABLE_NAME = C.TABLE_NAME AND CC.OWNER = C.OWNER AND C.CONSTRAINT_TYPE = 'P')) ON TC.TABLE_NAME = CC.TABLE_NAME AND TC.COLUMN_NAME = CC.COLUMN_NAME WHERE TC.TABLE_NAME = '", _0, "' ORDER BY TC.COLUMN_ID"); RETURN_MM(); @@ -949,7 +949,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, listTables) { if (!ZEPHIR_IS_STRING(schemaName, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, schemaName); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT TABLE_NAME, OWNER FROM ALL_TABLES WHERE OWNER='", _0, "' ORDER BY OWNER, TABLE_NAME"); RETURN_MM(); @@ -991,14 +991,14 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeIndexes) { if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, schema); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "SELECT I.TABLE_NAME, 0 AS C0, I.INDEX_NAME, IC.COLUMN_POSITION, IC.COLUMN_NAME FROM ALL_INDEXES I JOIN ALL_IND_COLUMNS IC ON I.INDEX_NAME = IC.INDEX_NAME WHERE I.TABLE_NAME = '", _0, "' AND IC.INDEX_OWNER = '", _2, "'"); RETURN_MM(); } - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "SELECT I.TABLE_NAME, 0 AS C0, I.INDEX_NAME, IC.COLUMN_POSITION, IC.COLUMN_NAME FROM ALL_INDEXES I JOIN ALL_IND_COLUMNS IC ON I.INDEX_NAME = IC.INDEX_NAME WHERE I.TABLE_NAME = '", _0, "'"); RETURN_MM(); @@ -1040,15 +1040,15 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeReferences) { ZEPHIR_INIT_VAR(sql); ZVAL_STRING(sql, "SELECT AC.TABLE_NAME, CC.COLUMN_NAME, AC.CONSTRAINT_NAME, AC.R_OWNER, RCC.TABLE_NAME R_TABLE_NAME, RCC.COLUMN_NAME R_COLUMN_NAME FROM ALL_CONSTRAINTS AC JOIN ALL_CONS_COLUMNS CC ON AC.CONSTRAINT_NAME = CC.CONSTRAINT_NAME JOIN ALL_CONS_COLUMNS RCC ON AC.R_OWNER = RCC.OWNER AND AC.R_CONSTRAINT_NAME = RCC.CONSTRAINT_NAME WHERE AC.CONSTRAINT_TYPE='R' ", 1); if (!ZEPHIR_IS_STRING(schema, "")) { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, schema); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SVSVS(_3, "AND AC.OWNER='", _0, "' AND AC.TABLE_NAME = '", _2, "'"); zephir_concat_self(&sql, _3 TSRMLS_CC); } else { - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, table); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 143, table); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVS(_3, "AND AC.TABLE_NAME = '", _0, "'"); @@ -1156,11 +1156,11 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, prepareTable) { } - ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 142, table); + ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 143, table); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_3, phalcon_text_ce, "upper", &_2, 142, schema); + ZEPHIR_CALL_CE_STATIC(&_3, phalcon_text_ce, "upper", &_2, 143, schema); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_PARENT(phalcon_db_dialect_oracle_ce, this_ptr, "preparetable", &_0, 143, _1, _3, alias, escapeChar); + ZEPHIR_RETURN_CALL_PARENT(phalcon_db_dialect_oracle_ce, this_ptr, "preparetable", &_0, 144, _1, _3, alias, escapeChar); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/db/dialect/postgresql.zep.c b/ext/phalcon/db/dialect/postgresql.zep.c index fcb5a52d650..abe67b996b3 100644 --- a/ext/phalcon/db/dialect/postgresql.zep.c +++ b/ext/phalcon/db/dialect/postgresql.zep.c @@ -180,7 +180,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, getColumnDefinition) { ZEPHIR_GET_HVALUE(value, _4); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_6, 141, value, &_5); + ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_6, 142, value, &_5); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "\"", _0, "\", "); @@ -198,7 +198,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, getColumnDefinition) { } else { ZEPHIR_SINIT_NVAR(_7); ZVAL_STRING(&_7, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_10, "addcslashes", &_6, 141, typeValues, &_7); + ZEPHIR_CALL_FUNCTION(&_10, "addcslashes", &_6, 142, typeValues, &_7); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, "(\"", _10, "\")"); @@ -263,7 +263,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 142, defaultValue, &_4); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\""); @@ -398,7 +398,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) { zephir_check_call_status(); ZEPHIR_SINIT_VAR(_11); ZVAL_STRING(&_11, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_12, "addcslashes", NULL, 141, defaultValue, &_11); + ZEPHIR_CALL_FUNCTION(&_12, "addcslashes", NULL, 142, defaultValue, &_11); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_VSVSVS(_9, sqlAlterTable, " ALTER COLUMN \"", _8, "\" SET DEFAULT \"", _12, "\""); @@ -524,7 +524,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addIndex) { zephir_concat_self(&sql, _1 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 43, _5); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 44, _5); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZEPHIR_CONCAT_SVS(_6, " (", _4, ")"); @@ -624,7 +624,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 44, _2); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _1, ")"); RETURN_MM(); @@ -716,13 +716,13 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 43, _3); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 44, _3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_4, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_6, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", NULL, 43, _6); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", NULL, 44, _6); zephir_check_call_status(); ZEPHIR_INIT_VAR(sql); ZEPHIR_CONCAT_SVSVSVSSVSVS(sql, "ALTER TABLE ", _0, " ADD CONSTRAINT \"", _1, "\" FOREIGN KEY (", _2, ")", " REFERENCES \"", _4, "\" (", _5, ")"); @@ -803,12 +803,12 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropForeignKey) { */ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { - zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_16 = NULL; - HashTable *_1, *_14, *_23; - HashPosition _0, _13, _22; + zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL; + HashTable *_1, *_13, *_21; + HashPosition _0, _12, _20; int ZEPHIR_LAST_CALL_STATUS; zval *definition = NULL; - zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, *_10 = NULL, *_11 = NULL, *_12 = NULL, **_15, *_17 = NULL, *_18 = NULL, *_19 = NULL, *_20 = NULL, *_21 = NULL, **_24, *_25 = NULL; + zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, *_10 = NULL, *_11 = NULL, **_14, *_15 = NULL, *_16 = NULL, *_17 = NULL, *_18 = NULL, *_19 = NULL, **_22, *_23, *_24 = NULL; zval *tableName = NULL, *schemaName = NULL; ZEPHIR_MM_GROW(); @@ -881,7 +881,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_NVAR(_6); ZVAL_STRING(&_6, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 142, defaultValue, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\""); @@ -906,22 +906,22 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 381); } if (!(ZEPHIR_IS_EMPTY(primaryColumns))) { - ZEPHIR_INIT_VAR(_12); - zephir_fast_join_str(_12, SL(","), primaryColumns TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 44, primaryColumns); + zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); - ZEPHIR_CONCAT_SVS(_9, "PRIMARY KEY (", _12, ")"); + ZEPHIR_CONCAT_SVS(_9, "PRIMARY KEY (", _3, ")"); zephir_array_append(&createLines, _9, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 384); } ZEPHIR_INIT_VAR(indexSqlAfterCreate); ZVAL_STRING(indexSqlAfterCreate, "", 1); ZEPHIR_OBS_VAR(indexes); if (zephir_array_isset_string_fetch(&indexes, definition, SS("indexes"), 0 TSRMLS_CC)) { - zephir_is_iterable(indexes, &_14, &_13, 0, 0, "phalcon/db/dialect/postgresql.zep", 418); + zephir_is_iterable(indexes, &_13, &_12, 0, 0, "phalcon/db/dialect/postgresql.zep", 418); for ( - ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS - ; zephir_hash_move_forward_ex(_14, &_13) + ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS + ; zephir_hash_move_forward_ex(_13, &_12) ) { - ZEPHIR_GET_HVALUE(index, _15); + ZEPHIR_GET_HVALUE(index, _14); ZEPHIR_CALL_METHOD(&indexName, index, "getname", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0); @@ -931,7 +931,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) { ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_16, 43, _4); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", NULL, 44, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(indexSql); ZEPHIR_CONCAT_SVS(indexSql, "CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _3, ")"); @@ -939,25 +939,25 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { if (!(ZEPHIR_IS_EMPTY(indexType))) { ZEPHIR_CALL_METHOD(&_10, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_16, 43, _10); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 44, _10); zephir_check_call_status(); ZEPHIR_INIT_NVAR(indexSql); ZEPHIR_CONCAT_SVSVSVS(indexSql, "CONSTRAINT \"", indexName, "\" ", indexType, " (", _7, ")"); } else { ZEPHIR_CALL_METHOD(&_11, index, "getname", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_17, this_ptr, "preparetable", NULL, 143, tableName, schemaName); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "preparetable", NULL, 144, tableName, schemaName); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_18); - ZEPHIR_CONCAT_SVSV(_18, "CREATE INDEX \"", _11, "\" ON ", _17); - zephir_concat_self(&indexSqlAfterCreate, _18 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_20, index, "getcolumns", NULL, 0); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SVSV(_16, "CREATE INDEX \"", _11, "\" ON ", _15); + zephir_concat_self(&indexSqlAfterCreate, _16 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_18, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_19, this_ptr, "getcolumnlist", &_16, 43, _20); + ZEPHIR_CALL_METHOD(&_17, this_ptr, "getcolumnlist", NULL, 44, _18); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_21); - ZEPHIR_CONCAT_SVS(_21, " (", _19, ");"); - zephir_concat_self(&indexSqlAfterCreate, _21 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_19); + ZEPHIR_CONCAT_SVS(_19, " (", _17, ");"); + zephir_concat_self(&indexSqlAfterCreate, _19 TSRMLS_CC); } } if (!(ZEPHIR_IS_EMPTY(indexSql))) { @@ -967,64 +967,64 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) { } ZEPHIR_OBS_VAR(references); if (zephir_array_isset_string_fetch(&references, definition, SS("references"), 0 TSRMLS_CC)) { - zephir_is_iterable(references, &_23, &_22, 0, 0, "phalcon/db/dialect/postgresql.zep", 443); + zephir_is_iterable(references, &_21, &_20, 0, 0, "phalcon/db/dialect/postgresql.zep", 443); for ( - ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS - ; zephir_hash_move_forward_ex(_23, &_22) + ; zephir_hash_get_current_data_ex(_21, (void**) &_22, &_20) == SUCCESS + ; zephir_hash_move_forward_ex(_21, &_20) ) { - ZEPHIR_GET_HVALUE(reference, _24); + ZEPHIR_GET_HVALUE(reference, _22); ZEPHIR_CALL_METHOD(&_3, reference, "getname", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_16, 43, _7); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 44, _7); zephir_check_call_status(); ZEPHIR_INIT_NVAR(referenceSql); ZEPHIR_CONCAT_SVSVS(referenceSql, "CONSTRAINT \"", _3, "\" FOREIGN KEY (", _4, ") REFERENCES "); ZEPHIR_CALL_METHOD(&_11, reference, "getreferencedtable", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_10, this_ptr, "preparetable", NULL, 143, _11, schemaName); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "preparetable", NULL, 144, _11, schemaName); zephir_check_call_status(); zephir_concat_self(&referenceSql, _10 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0); + ZEPHIR_CALL_METHOD(&_17, reference, "getreferencedcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_17, this_ptr, "getcolumnlist", &_16, 43, _19); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", NULL, 44, _17); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_9); - ZEPHIR_CONCAT_SVS(_9, " (", _17, ")"); + ZEPHIR_CONCAT_SVS(_9, " (", _15, ")"); zephir_concat_self(&referenceSql, _9 TSRMLS_CC); ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0); zephir_check_call_status(); if (!(ZEPHIR_IS_EMPTY(onDelete))) { - ZEPHIR_INIT_LNVAR(_18); - ZEPHIR_CONCAT_SV(_18, " ON DELETE ", onDelete); - zephir_concat_self(&referenceSql, _18 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SV(_16, " ON DELETE ", onDelete); + zephir_concat_self(&referenceSql, _16 TSRMLS_CC); } ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0); zephir_check_call_status(); if (!(ZEPHIR_IS_EMPTY(onUpdate))) { - ZEPHIR_INIT_LNVAR(_21); - ZEPHIR_CONCAT_SV(_21, " ON UPDATE ", onUpdate); - zephir_concat_self(&referenceSql, _21 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_19); + ZEPHIR_CONCAT_SV(_19, " ON UPDATE ", onUpdate); + zephir_concat_self(&referenceSql, _19 TSRMLS_CC); } zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 441); } } - ZEPHIR_INIT_NVAR(_12); - zephir_fast_join_str(_12, SL(",\n\t"), createLines TSRMLS_CC); + ZEPHIR_INIT_VAR(_23); + zephir_fast_join_str(_23, SL(",\n\t"), createLines TSRMLS_CC); ZEPHIR_INIT_LNVAR(_9); - ZEPHIR_CONCAT_VS(_9, _12, "\n)"); + ZEPHIR_CONCAT_VS(_9, _23, "\n)"); zephir_concat_self(&sql, _9 TSRMLS_CC); if (zephir_array_isset_string(definition, SS("options"))) { ZEPHIR_CALL_METHOD(&_3, this_ptr, "_gettableoptions", NULL, 0, definition); zephir_check_call_status(); - ZEPHIR_INIT_VAR(_25); - ZEPHIR_CONCAT_SV(_25, " ", _3); - zephir_concat_self(&sql, _25 TSRMLS_CC); + ZEPHIR_INIT_VAR(_24); + ZEPHIR_CONCAT_SV(_24, " ", _3); + zephir_concat_self(&sql, _24 TSRMLS_CC); } - ZEPHIR_INIT_LNVAR(_25); - ZEPHIR_CONCAT_SV(_25, ";", indexSqlAfterCreate); - zephir_concat_self(&sql, _25 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_24); + ZEPHIR_CONCAT_SV(_24, ";", indexSqlAfterCreate); + zephir_concat_self(&sql, _24 TSRMLS_CC); RETURN_CCTOR(sql); } diff --git a/ext/phalcon/db/dialect/sqlite.zep.c b/ext/phalcon/db/dialect/sqlite.zep.c index ed05aa1ae66..ceceb44fd10 100644 --- a/ext/phalcon/db/dialect/sqlite.zep.c +++ b/ext/phalcon/db/dialect/sqlite.zep.c @@ -147,7 +147,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, getColumnDefinition) { ZEPHIR_GET_HVALUE(value, _5); ZEPHIR_SINIT_NVAR(_6); ZVAL_STRING(&_6, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_7, 141, value, &_6); + ZEPHIR_CALL_FUNCTION(&_0, "addcslashes", &_7, 142, value, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "\"", _0, "\", "); @@ -165,7 +165,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, getColumnDefinition) { } else { ZEPHIR_SINIT_NVAR(_8); ZVAL_STRING(&_8, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_7, 141, typeValues, &_8); + ZEPHIR_CALL_FUNCTION(&_2, "addcslashes", &_7, 142, typeValues, &_8); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVS(_10, "(\"", _2, "\")"); @@ -230,7 +230,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addColumn) { if (!(ZEPHIR_IS_EMPTY(defaultValue))) { ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "\"", 0); - ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 142, defaultValue, &_4); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\""); @@ -403,7 +403,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addIndex) { } ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 43, _2); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getcolumnlist", NULL, 44, _2); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_VS(_1, _0, ")"); diff --git a/ext/phalcon/db/index.zep.c b/ext/phalcon/db/index.zep.c index 1e155418faa..c5f4648876d 100644 --- a/ext/phalcon/db/index.zep.c +++ b/ext/phalcon/db/index.zep.c @@ -60,8 +60,6 @@ ZEPHIR_INIT_CLASS(Phalcon_Db_Index) { /** * Index name - * - * @var string */ PHP_METHOD(Phalcon_Db_Index, getName) { @@ -72,8 +70,6 @@ PHP_METHOD(Phalcon_Db_Index, getName) { /** * Index columns - * - * @var array */ PHP_METHOD(Phalcon_Db_Index, getColumns) { @@ -84,8 +80,6 @@ PHP_METHOD(Phalcon_Db_Index, getColumns) { /** * Index type - * - * @var string */ PHP_METHOD(Phalcon_Db_Index, getType) { diff --git a/ext/phalcon/db/profiler.zep.c b/ext/phalcon/db/profiler.zep.c index 3250aaa92a1..f5b7e272992 100644 --- a/ext/phalcon/db/profiler.zep.c +++ b/ext/phalcon/db/profiler.zep.c @@ -85,7 +85,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Db_Profiler) { * Starts the profile of a SQL sentence * * @param string sqlStatement - * @return Phalcon\Db\Profiler + * @return \Phalcon\Db\Profiler */ PHP_METHOD(Phalcon_Db_Profiler, startProfile) { @@ -109,19 +109,19 @@ PHP_METHOD(Phalcon_Db_Profiler, startProfile) { ZEPHIR_CALL_METHOD(NULL, activeProfile, "__construct", NULL, 0); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 144, sqlStatement); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 145, sqlStatement); zephir_check_call_status(); if (Z_TYPE_P(sqlVariables) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 145, sqlVariables); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 146, sqlVariables); zephir_check_call_status(); } if (Z_TYPE_P(sqlBindTypes) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 146, sqlBindTypes); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 147, sqlBindTypes); zephir_check_call_status(); } ZEPHIR_INIT_VAR(_0); zephir_microtime(_0, ZEPHIR_GLOBAL(global_true) TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 147, _0); + ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 148, _0); zephir_check_call_status(); if ((zephir_method_exists_ex(this_ptr, SS("beforestartprofile") TSRMLS_CC) == SUCCESS)) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "beforestartprofile", NULL, 0, activeProfile); diff --git a/ext/phalcon/db/profiler/item.zep.c b/ext/phalcon/db/profiler/item.zep.c index af0142a85f5..0145f4b87ea 100644 --- a/ext/phalcon/db/profiler/item.zep.c +++ b/ext/phalcon/db/profiler/item.zep.c @@ -13,8 +13,8 @@ #include "kernel/main.h" #include "kernel/object.h" -#include "kernel/memory.h" #include "kernel/operators.h" +#include "kernel/memory.h" /** @@ -68,25 +68,25 @@ ZEPHIR_INIT_CLASS(Phalcon_Db_Profiler_Item) { /** * SQL statement related to the profile - * - * @var string */ PHP_METHOD(Phalcon_Db_Profiler_Item, setSqlStatement) { - zval *sqlStatement; + zval *sqlStatement_param = NULL; + zval *sqlStatement = NULL; - zephir_fetch_params(0, 1, 0, &sqlStatement); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &sqlStatement_param); + zephir_get_strval(sqlStatement, sqlStatement_param); zephir_update_property_this(this_ptr, SL("_sqlStatement"), sqlStatement TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } /** * SQL statement related to the profile - * - * @var string */ PHP_METHOD(Phalcon_Db_Profiler_Item, getSqlStatement) { @@ -97,25 +97,25 @@ PHP_METHOD(Phalcon_Db_Profiler_Item, getSqlStatement) { /** * SQL variables related to the profile - * - * @var array */ PHP_METHOD(Phalcon_Db_Profiler_Item, setSqlVariables) { - zval *sqlVariables; + zval *sqlVariables_param = NULL; + zval *sqlVariables = NULL; - zephir_fetch_params(0, 1, 0, &sqlVariables); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &sqlVariables_param); + zephir_get_arrval(sqlVariables, sqlVariables_param); zephir_update_property_this(this_ptr, SL("_sqlVariables"), sqlVariables TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } /** * SQL variables related to the profile - * - * @var array */ PHP_METHOD(Phalcon_Db_Profiler_Item, getSqlVariables) { @@ -126,25 +126,25 @@ PHP_METHOD(Phalcon_Db_Profiler_Item, getSqlVariables) { /** * SQL bind types related to the profile - * - * @var array */ PHP_METHOD(Phalcon_Db_Profiler_Item, setSqlBindTypes) { - zval *sqlBindTypes; + zval *sqlBindTypes_param = NULL; + zval *sqlBindTypes = NULL; - zephir_fetch_params(0, 1, 0, &sqlBindTypes); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &sqlBindTypes_param); + zephir_get_arrval(sqlBindTypes, sqlBindTypes_param); zephir_update_property_this(this_ptr, SL("_sqlBindTypes"), sqlBindTypes TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } /** * SQL bind types related to the profile - * - * @var array */ PHP_METHOD(Phalcon_Db_Profiler_Item, getSqlBindTypes) { @@ -155,25 +155,25 @@ PHP_METHOD(Phalcon_Db_Profiler_Item, getSqlBindTypes) { /** * Timestamp when the profile started - * - * @var double */ PHP_METHOD(Phalcon_Db_Profiler_Item, setInitialTime) { - zval *initialTime; + zval *initialTime_param = NULL, *_0; + double initialTime; - zephir_fetch_params(0, 1, 0, &initialTime); + zephir_fetch_params(0, 1, 0, &initialTime_param); + initialTime = zephir_get_doubleval(initialTime_param); - zephir_update_property_this(this_ptr, SL("_initialTime"), initialTime TSRMLS_CC); + ZEPHIR_INIT_ZVAL_NREF(_0); + ZVAL_DOUBLE(_0, initialTime); + zephir_update_property_this(this_ptr, SL("_initialTime"), _0 TSRMLS_CC); } /** * Timestamp when the profile started - * - * @var double */ PHP_METHOD(Phalcon_Db_Profiler_Item, getInitialTime) { @@ -184,25 +184,25 @@ PHP_METHOD(Phalcon_Db_Profiler_Item, getInitialTime) { /** * Timestamp when the profile ended - * - * @var double */ PHP_METHOD(Phalcon_Db_Profiler_Item, setFinalTime) { - zval *finalTime; + zval *finalTime_param = NULL, *_0; + double finalTime; - zephir_fetch_params(0, 1, 0, &finalTime); + zephir_fetch_params(0, 1, 0, &finalTime_param); + finalTime = zephir_get_doubleval(finalTime_param); - zephir_update_property_this(this_ptr, SL("_finalTime"), finalTime TSRMLS_CC); + ZEPHIR_INIT_ZVAL_NREF(_0); + ZVAL_DOUBLE(_0, finalTime); + zephir_update_property_this(this_ptr, SL("_finalTime"), _0 TSRMLS_CC); } /** * Timestamp when the profile ended - * - * @var double */ PHP_METHOD(Phalcon_Db_Profiler_Item, getFinalTime) { diff --git a/ext/phalcon/db/profiler/item.zep.h b/ext/phalcon/db/profiler/item.zep.h index dccba4e6d5b..8e21ab80b61 100644 --- a/ext/phalcon/db/profiler/item.zep.h +++ b/ext/phalcon/db/profiler/item.zep.h @@ -20,11 +20,11 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setsqlstatement, 0, 0, 1 ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setsqlvariables, 0, 0, 1) - ZEND_ARG_INFO(0, sqlVariables) + ZEND_ARG_ARRAY_INFO(0, sqlVariables, 0) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setsqlbindtypes, 0, 0, 1) - ZEND_ARG_INFO(0, sqlBindTypes) + ZEND_ARG_ARRAY_INFO(0, sqlBindTypes, 0) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_profiler_item_setinitialtime, 0, 0, 1) diff --git a/ext/phalcon/db/rawvalue.zep.c b/ext/phalcon/db/rawvalue.zep.c index 2e769732a97..3225b55035c 100644 --- a/ext/phalcon/db/rawvalue.zep.c +++ b/ext/phalcon/db/rawvalue.zep.c @@ -48,8 +48,6 @@ ZEPHIR_INIT_CLASS(Phalcon_Db_RawValue) { /** * Raw value without quoting or formating - * - * @var string */ PHP_METHOD(Phalcon_Db_RawValue, getValue) { @@ -60,8 +58,6 @@ PHP_METHOD(Phalcon_Db_RawValue, getValue) { /** * Raw value without quoting or formating - * - * @var string */ PHP_METHOD(Phalcon_Db_RawValue, __toString) { diff --git a/ext/phalcon/db/reference.zep.c b/ext/phalcon/db/reference.zep.c index 06fe9973532..d285b1d87e6 100644 --- a/ext/phalcon/db/reference.zep.c +++ b/ext/phalcon/db/reference.zep.c @@ -92,8 +92,6 @@ ZEPHIR_INIT_CLASS(Phalcon_Db_Reference) { /** * Constraint name - * - * @var string */ PHP_METHOD(Phalcon_Db_Reference, getName) { @@ -118,8 +116,6 @@ PHP_METHOD(Phalcon_Db_Reference, getReferencedSchema) { /** * Referenced Table - * - * @var string */ PHP_METHOD(Phalcon_Db_Reference, getReferencedTable) { @@ -130,8 +126,6 @@ PHP_METHOD(Phalcon_Db_Reference, getReferencedTable) { /** * Local reference columns - * - * @var array */ PHP_METHOD(Phalcon_Db_Reference, getColumns) { @@ -142,8 +136,6 @@ PHP_METHOD(Phalcon_Db_Reference, getColumns) { /** * Referenced Columns - * - * @var array */ PHP_METHOD(Phalcon_Db_Reference, getReferencedColumns) { @@ -154,8 +146,6 @@ PHP_METHOD(Phalcon_Db_Reference, getReferencedColumns) { /** * ON DELETE - * - * @var array */ PHP_METHOD(Phalcon_Db_Reference, getOnDelete) { @@ -166,8 +156,6 @@ PHP_METHOD(Phalcon_Db_Reference, getOnDelete) { /** * ON UPDATE - * - * @var array */ PHP_METHOD(Phalcon_Db_Reference, getOnUpdate) { diff --git a/ext/phalcon/db/result/pdo.zep.c b/ext/phalcon/db/result/pdo.zep.c index 498d3579f3c..658a68c093f 100644 --- a/ext/phalcon/db/result/pdo.zep.c +++ b/ext/phalcon/db/result/pdo.zep.c @@ -73,7 +73,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Db_Result_Pdo) { /** * Phalcon\Db\Result\Pdo constructor * - * @param Phalcon\Db\AdapterInterface connection + * @param \Phalcon\Db\AdapterInterface connection * @param \PDOStatement result * @param string sqlStatement * @param array bindParams diff --git a/ext/phalcon/db/resultinterface.zep.c b/ext/phalcon/db/resultinterface.zep.c index cbc6c1816d2..6c582e2097f 100644 --- a/ext/phalcon/db/resultinterface.zep.c +++ b/ext/phalcon/db/resultinterface.zep.c @@ -28,7 +28,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Db_ResultInterface) { /** * Phalcon\Db\Result\Pdo constructor * - * @param Phalcon\Db\AdapterInterface connection + * @param \Phalcon\Db\AdapterInterface connection * @param \PDOStatement result * @param string sqlStatement * @param array bindParams diff --git a/ext/phalcon/debug.zep.c b/ext/phalcon/debug.zep.c index ce744f9b56a..3f475877987 100644 --- a/ext/phalcon/debug.zep.c +++ b/ext/phalcon/debug.zep.c @@ -191,7 +191,7 @@ PHP_METHOD(Phalcon_Debug, listenExceptions) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "onUncaughtException", 1); zephir_array_fast_append(_0, _1); - ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _0); + ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 149, _0); zephir_check_call_status(); RETURN_THIS(); @@ -214,7 +214,7 @@ PHP_METHOD(Phalcon_Debug, listenLowSeverity) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "onUncaughtLowSeverity", 1); zephir_array_fast_append(_0, _1); - ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 149, _0); + ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 150, _0); zephir_check_call_status(); ZEPHIR_INIT_VAR(_2); zephir_create_array(_2, 2, 0 TSRMLS_CC); @@ -222,7 +222,7 @@ PHP_METHOD(Phalcon_Debug, listenLowSeverity) { ZEPHIR_INIT_NVAR(_1); ZVAL_STRING(_1, "onUncaughtException", 1); zephir_array_fast_append(_2, _1); - ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _2); + ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 149, _2); zephir_check_call_status(); RETURN_THIS(); @@ -263,7 +263,7 @@ PHP_METHOD(Phalcon_Debug, debugVar) { ZEPHIR_INIT_VAR(_0); zephir_create_array(_0, 3, 0 TSRMLS_CC); zephir_array_fast_append(_0, varz); - ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 150); + ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 151); zephir_check_call_status(); zephir_array_fast_append(_0, _1); ZEPHIR_INIT_VAR(_2); @@ -309,7 +309,7 @@ PHP_METHOD(Phalcon_Debug, _escapeString) { ZVAL_LONG(&_3, 2); ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "utf-8", 0); - ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 151, _0, &_3, &_4); + ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 152, _0, &_3, &_4); zephir_check_call_status(); RETURN_MM(); } @@ -363,7 +363,7 @@ PHP_METHOD(Phalcon_Debug, _getArrayDump) { ) { ZEPHIR_GET_HMKEY(k, _2, _1); ZEPHIR_GET_HVALUE(v, _3); - ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 152, v); + ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 153, v); zephir_check_call_status(); if (zephir_is_true(_4)) { ZEPHIR_INIT_NVAR(varDump); @@ -380,7 +380,7 @@ PHP_METHOD(Phalcon_Debug, _getArrayDump) { if (Z_TYPE_P(v) == IS_ARRAY) { ZEPHIR_INIT_NVAR(_8); ZVAL_LONG(_8, (zephir_get_numberval(n) + 1)); - ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 153, v, _8); + ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 154, v, _8); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVSVS(_10, "[", k, "] => Array(", _6, ")"); @@ -424,7 +424,7 @@ PHP_METHOD(Phalcon_Debug, _getVarDump) { - ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 152, variable); + ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 153, variable); zephir_check_call_status(); if (zephir_is_true(_0)) { if (Z_TYPE_P(variable) == IS_BOOL) { @@ -458,7 +458,7 @@ PHP_METHOD(Phalcon_Debug, _getVarDump) { } } if (Z_TYPE_P(variable) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 153, variable); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 154, variable); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, "Array(", _1, ")"); RETURN_MM(); @@ -482,7 +482,7 @@ PHP_METHOD(Phalcon_Debug, getMajorVersion) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 154); + ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 155); zephir_check_call_status(); ZEPHIR_INIT_VAR(parts); zephir_fast_explode_str(parts, SL(" "), _0, LONG_MAX TSRMLS_CC); @@ -504,7 +504,7 @@ PHP_METHOD(Phalcon_Debug, getVersion) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmajorversion", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 154); + ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 155); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "
Phalcon Framework ", _1, "
"); RETURN_MM(); @@ -605,9 +605,9 @@ PHP_METHOD(Phalcon_Debug, showTraceItem) { } else { ZEPHIR_INIT_VAR(classReflection); object_init_ex(classReflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, classReflection, "__construct", NULL, 62, className); + ZEPHIR_CALL_METHOD(NULL, classReflection, "__construct", NULL, 64, className); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 155); + ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 156); zephir_check_call_status(); if (zephir_is_true(_8)) { ZEPHIR_INIT_VAR(_9); @@ -640,9 +640,9 @@ PHP_METHOD(Phalcon_Debug, showTraceItem) { if ((zephir_function_exists(functionName TSRMLS_CC) == SUCCESS)) { ZEPHIR_INIT_VAR(functionReflection); object_init_ex(functionReflection, zephir_get_internal_ce(SS("reflectionfunction") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 156, functionName); + ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 157, functionName); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 157); + ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 158); zephir_check_call_status(); if (zephir_is_true(_8)) { ZEPHIR_SINIT_NVAR(_4); @@ -703,7 +703,7 @@ PHP_METHOD(Phalcon_Debug, showTraceItem) { ZEPHIR_OBS_VAR(showFiles); zephir_read_property_this(&showFiles, this_ptr, SL("_showFiles"), PH_NOISY_CC); if (zephir_is_true(showFiles)) { - ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 158, filez); + ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 159, filez); zephir_check_call_status(); ZEPHIR_INIT_VAR(numberLines); ZVAL_LONG(numberLines, zephir_fast_count_int(lines TSRMLS_CC)); @@ -786,7 +786,7 @@ PHP_METHOD(Phalcon_Debug, showTraceItem) { ZVAL_LONG(&_23, 2); ZEPHIR_SINIT_NVAR(_25); ZVAL_STRING(&_25, "UTF-8", 0); - ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_26, 151, _21, &_23, &_25); + ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_26, 152, _21, &_23, &_25); zephir_check_call_status(); zephir_concat_self(&html, _8 TSRMLS_CC); } @@ -813,7 +813,7 @@ PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) { - ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 159); + ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 160); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_1); zephir_bitwise_and_function(&_1, _0, severity TSRMLS_CC); @@ -822,7 +822,7 @@ PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) { object_init_ex(_2, zephir_get_internal_ce(SS("errorexception") TSRMLS_CC)); ZEPHIR_INIT_VAR(_3); ZVAL_LONG(_3, 0); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 160, message, _3, severity, file, line); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 161, message, _3, severity, file, line); zephir_check_call_status(); zephir_throw_exception_debug(_2, "phalcon/debug.zep", 566 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -850,10 +850,10 @@ PHP_METHOD(Phalcon_Debug, onUncaughtException) { - ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 161); + ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 162); zephir_check_call_status(); if (ZEPHIR_GT_LONG(obLevel, 0)) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); } _0 = zephir_fetch_static_property_ce(phalcon_debug_ce, SL("_isActive") TSRMLS_CC); @@ -917,7 +917,7 @@ PHP_METHOD(Phalcon_Debug, onUncaughtException) { ) { ZEPHIR_GET_HMKEY(n, _11, _10); ZEPHIR_GET_HVALUE(traceItem, _12); - ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 162, n, traceItem); + ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 163, n, traceItem); zephir_check_call_status(); zephir_concat_self(&html, _13 TSRMLS_CC); } @@ -936,7 +936,7 @@ PHP_METHOD(Phalcon_Debug, onUncaughtException) { ZEPHIR_CONCAT_SVSVS(_18, "
"); zephir_concat_self(&html, _18 TSRMLS_CC); } else { - ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 163, value, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 164, value, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_18); ZEPHIR_CONCAT_SVSVS(_18, ""); @@ -962,7 +962,7 @@ PHP_METHOD(Phalcon_Debug, onUncaughtException) { zephir_concat_self_str(&html, SL("
Memory
Usage", _13, "
", keyRequest, "", value, "
", keyRequest, "", _13, "
") TSRMLS_CC); zephir_concat_self_str(&html, SL("
") TSRMLS_CC); zephir_concat_self_str(&html, SL("") TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 164); + ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 165); zephir_check_call_status(); zephir_is_iterable(_13, &_25, &_24, 0, 0, "phalcon/debug.zep", 694); for ( @@ -977,7 +977,7 @@ PHP_METHOD(Phalcon_Debug, onUncaughtException) { } zephir_concat_self_str(&html, SL("
#Path
") TSRMLS_CC); zephir_concat_self_str(&html, SL("
") TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 165, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 166, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_27); ZEPHIR_CONCAT_SVS(_27, ""); diff --git a/ext/phalcon/debug/dump.zep.c b/ext/phalcon/debug/dump.zep.c index a5d81c14def..fb98e32b398 100644 --- a/ext/phalcon/debug/dump.zep.c +++ b/ext/phalcon/debug/dump.zep.c @@ -140,7 +140,7 @@ PHP_METHOD(Phalcon_Debug_Dump, all) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "variables", 1); zephir_array_fast_append(_0, _1); - ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 166); + ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 167); zephir_check_call_status(); ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, _0, _2); zephir_check_call_status(); @@ -303,7 +303,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { add_assoc_long_ex(_1, SS(":count"), zephir_fast_count_int(variable TSRMLS_CC)); ZEPHIR_SINIT_VAR(_5); ZVAL_STRING(&_5, "Array (:count) (\n", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); zephir_concat_self(&output, _2 TSRMLS_CC); zephir_is_iterable(variable, &_8, &_7, 0, 0, "phalcon/debug/dump.zep", 154); @@ -315,7 +315,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { ZEPHIR_GET_HVALUE(value, _9); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -328,7 +328,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_12, SL(":key"), &key, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "[:key] => ", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _10, _13); @@ -352,7 +352,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 167, value, _3, &_5); + ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 168, value, _3, &_5); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); @@ -362,7 +362,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab - 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_CONCAT_VVS(return_value, output, _10, ")"); RETURN_MM(); @@ -381,10 +381,10 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":class"), &_3, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Object :class", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); zephir_concat_self(&output, _2 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 168, variable); + ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 169, variable); zephir_check_call_status(); if (zephir_is_true(_13)) { ZEPHIR_INIT_NVAR(_12); @@ -395,19 +395,19 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_check_temp_parameter(_3); zephir_check_call_status(); zephir_array_update_string(&_12, SL(":style"), &_18, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 168, variable); + ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 169, variable); zephir_check_call_status(); zephir_array_update_string(&_12, SL(":parent"), &_18, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, " extends :parent", 0); - ZEPHIR_CALL_FUNCTION(&_18, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_18, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); zephir_concat_self(&output, _18 TSRMLS_CC); } zephir_concat_self_str(&output, SL(" (\n") TSRMLS_CC); _22 = zephir_fetch_nproperty_this(this_ptr, SL("_detailed"), PH_NOISY_CC); if (!(zephir_is_true(_22))) { - ZEPHIR_CALL_FUNCTION(&_10, "get_object_vars", NULL, 23, variable); + ZEPHIR_CALL_FUNCTION(&_10, "get_object_vars", NULL, 24, variable); zephir_check_call_status(); zephir_is_iterable(_10, &_24, &_23, 0, 0, "phalcon/debug/dump.zep", 171); for ( @@ -418,7 +418,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { ZEPHIR_GET_HVALUE(value, _25); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_13, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_13, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 3, 0 TSRMLS_CC); @@ -432,7 +432,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { add_assoc_stringl_ex(_12, SS(":type"), SL("public"), 1); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:key (:type) = ", 0); - ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _13, _26); @@ -441,7 +441,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5); + ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 168, value, _3, &_5); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); @@ -451,7 +451,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { } else { do { Z_SET_ISREF_P(variable); - ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 169, variable); + ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 170, variable); Z_UNSET_ISREF_P(variable); zephir_check_call_status(); if (!(zephir_is_true(attr))) { @@ -467,9 +467,9 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { ZEPHIR_INIT_NVAR(_3); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "\\x00", 0); - ZEPHIR_CALL_FUNCTION(&_10, "ord", &_29, 130, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "ord", &_29, 132, &_5); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_13, "chr", &_30, 128, _10); + ZEPHIR_CALL_FUNCTION(&_13, "chr", &_30, 130, _10); zephir_check_call_status(); zephir_fast_explode(_3, _13, key, LONG_MAX TSRMLS_CC); ZEPHIR_CPY_WRT(key, _3); @@ -486,7 +486,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 3, 0 TSRMLS_CC); @@ -497,14 +497,14 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_check_call_status(); zephir_array_update_string(&_12, SL(":style"), &_26, PH_COPY | PH_SEPARATE); Z_SET_ISREF_P(key); - ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 170, key); + ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 171, key); Z_UNSET_ISREF_P(key); zephir_check_call_status(); zephir_array_update_string(&_12, SL(":key"), &_26, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_12, SL(":type"), &type, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:key (:type) = ", 0); - ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _18, _26); @@ -513,7 +513,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5); + ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 168, value, _3, &_5); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); @@ -521,11 +521,11 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_concat_self(&output, _20 TSRMLS_CC); } while (zephir_is_true(attr)); } - ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 171, variable); + ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 172, variable); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 3, 0 TSRMLS_CC); @@ -541,7 +541,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { add_assoc_long_ex(_12, SS(":count"), zephir_fast_count_int(attr TSRMLS_CC)); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, ":class methods: (:count) (\n", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _10, _13); @@ -552,7 +552,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { if (zephir_fast_in_array(_3, _33 TSRMLS_CC)) { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); ZEPHIR_CONCAT_VS(_20, _18, "[already listed]\n"); @@ -570,7 +570,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { if (ZEPHIR_IS_STRING(value, "__construct")) { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -583,7 +583,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_12, SL(":method"), &value, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:method(); [constructor]\n", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _12); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _12); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); ZEPHIR_CONCAT_VV(_14, _10, _13); @@ -591,7 +591,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { } else { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab + 1)); - ZEPHIR_CALL_FUNCTION(&_26, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_26, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_38); zephir_create_array(_38, 2, 0 TSRMLS_CC); @@ -604,7 +604,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_38, SL(":method"), &value, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "->:method();\n", 0); - ZEPHIR_CALL_FUNCTION(&_27, "strtr", &_6, 53, &_5, _38); + ZEPHIR_CALL_FUNCTION(&_27, "strtr", &_6, 54, &_5, _38); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_39); ZEPHIR_CONCAT_VV(_39, _26, _27); @@ -613,7 +613,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, tab); - ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_18, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_20); ZEPHIR_CONCAT_VS(_20, _18, ")\n"); @@ -621,7 +621,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, (tab - 1)); - ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 129, space, &_5); + ZEPHIR_CALL_FUNCTION(&_10, "str_repeat", &_11, 131, space, &_5); zephir_check_call_status(); ZEPHIR_CONCAT_VVS(return_value, output, _10, ")"); RETURN_MM(); @@ -638,12 +638,12 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Integer (:var)", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); } - ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 172, variable); + ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 173, variable); zephir_check_call_status(); if (zephir_is_true(_2)) { ZEPHIR_INIT_NVAR(_1); @@ -657,7 +657,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Float (:var)", 0); - ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _13); RETURN_MM(); @@ -675,7 +675,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Numeric string (:length) \":var\"", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -694,14 +694,14 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { ZVAL_LONG(&_5, 4); ZEPHIR_SINIT_VAR(_40); ZVAL_STRING(&_40, "utf-8", 0); - ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 151, variable, &_5, &_40); + ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 152, variable, &_5, &_40); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_26, "nl2br", NULL, 173, _2); + ZEPHIR_CALL_FUNCTION(&_26, "nl2br", NULL, 174, _2); zephir_check_call_status(); zephir_array_update_string(&_1, SL(":var"), &_26, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "String (:length) \":var\"", 0); - ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _26); RETURN_MM(); @@ -726,7 +726,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &_14, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Boolean (:var)", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -742,7 +742,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":style"), &_2, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "NULL", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -758,7 +758,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) { zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "(:var)", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 54, &_5, _1); zephir_check_call_status(); ZEPHIR_CONCAT_VV(return_value, output, _2); RETURN_MM(); @@ -803,7 +803,7 @@ PHP_METHOD(Phalcon_Debug_Dump, variable) { zephir_array_update_string(&_0, SL(":output"), &_1, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "
:output
", 0); - ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 53, &_3, _0); + ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 54, &_3, _0); zephir_check_call_status(); RETURN_MM(); @@ -835,7 +835,7 @@ PHP_METHOD(Phalcon_Debug_Dump, variables) { ZEPHIR_INIT_VAR(output); ZVAL_STRING(output, "", 1); - ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 166); + ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 167); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/debug/dump.zep", 290); for ( diff --git a/ext/phalcon/di.zep.c b/ext/phalcon/di.zep.c index d498dd96427..428638c27b8 100644 --- a/ext/phalcon/di.zep.c +++ b/ext/phalcon/di.zep.c @@ -27,7 +27,7 @@ * Phalcon\Di * * Phalcon\Di is a component that implements Dependency Injection/Service Location - * of services and it"s itself a container for them. + * of services and it's itself a container for them. * * Since Phalcon is highly decoupled, Phalcon\Di is essential to integrate the different * components of the framework. The developer can also use this component to inject dependencies @@ -166,7 +166,7 @@ PHP_METHOD(Phalcon_Di, set) { ZEPHIR_INIT_VAR(service); object_init_ex(service, phalcon_di_service_ce); - ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 61, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 63, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_services"), name, service TSRMLS_CC); RETURN_CCTOR(service); @@ -202,7 +202,7 @@ PHP_METHOD(Phalcon_Di, setShared) { object_init_ex(service, phalcon_di_service_ce); ZEPHIR_SINIT_VAR(_0); ZVAL_BOOL(&_0, 1); - ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 61, name, definition, &_0); + ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 63, name, definition, &_0); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_services"), name, service TSRMLS_CC); RETURN_CCTOR(service); @@ -244,7 +244,7 @@ PHP_METHOD(Phalcon_Di, remove) { /** * Attempts to register a service in the services container - * Only is successful if a service hasn"t been registered previously + * Only is successful if a service hasn't been registered previously * with the same name */ PHP_METHOD(Phalcon_Di, attempt) { @@ -279,7 +279,7 @@ PHP_METHOD(Phalcon_Di, attempt) { if (!(zephir_array_isset(_0, name))) { ZEPHIR_INIT_VAR(service); object_init_ex(service, phalcon_di_service_ce); - ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 61, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, service, "__construct", NULL, 63, name, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_services"), name, service TSRMLS_CC); RETURN_CCTOR(service); @@ -406,6 +406,7 @@ PHP_METHOD(Phalcon_Di, getService) { /** * Resolves the service based on its configuration + * @returm mixed */ PHP_METHOD(Phalcon_Di, get) { @@ -459,7 +460,7 @@ PHP_METHOD(Phalcon_Di, get) { ZEPHIR_CONCAT_SVS(_3, "Service '", name, "' wasn't found in the dependency injection container"); ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/di.zep", 229 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/di.zep", 230 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -468,9 +469,9 @@ PHP_METHOD(Phalcon_Di, get) { if (zephir_is_php_version(50600)) { ZEPHIR_INIT_VAR(reflection); object_init_ex(reflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 62, name); + ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 64, name); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&instance, reflection, "newinstanceargs", NULL, 63, parameters); + ZEPHIR_CALL_METHOD(&instance, reflection, "newinstanceargs", NULL, 65, parameters); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(instance); @@ -481,9 +482,9 @@ PHP_METHOD(Phalcon_Di, get) { if (zephir_is_php_version(50600)) { ZEPHIR_INIT_NVAR(reflection); object_init_ex(reflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 62, name); + ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 64, name); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 64); + ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 66); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(instance); @@ -495,9 +496,9 @@ PHP_METHOD(Phalcon_Di, get) { if (zephir_is_php_version(50600)) { ZEPHIR_INIT_NVAR(reflection); object_init_ex(reflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC)); - ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 62, name); + ZEPHIR_CALL_METHOD(NULL, reflection, "__construct", NULL, 64, name); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 64); + ZEPHIR_CALL_METHOD(&instance, reflection, "newinstance", NULL, 66); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(instance); @@ -799,7 +800,7 @@ PHP_METHOD(Phalcon_Di, __call) { ZVAL_LONG(&_0, 3); ZEPHIR_INIT_VAR(_1); zephir_substr(_1, method, 3 , 0, ZEPHIR_SUBSTR_NO_LENGTH); - ZEPHIR_CALL_FUNCTION(&possibleService, "lcfirst", &_2, 65, _1); + ZEPHIR_CALL_FUNCTION(&possibleService, "lcfirst", &_2, 67, _1); zephir_check_call_status(); if (zephir_array_isset(services, possibleService)) { if (zephir_fast_count_int(arguments TSRMLS_CC)) { @@ -819,7 +820,7 @@ PHP_METHOD(Phalcon_Di, __call) { ZVAL_LONG(&_0, 3); ZEPHIR_INIT_NVAR(_1); zephir_substr(_1, method, 3 , 0, ZEPHIR_SUBSTR_NO_LENGTH); - ZEPHIR_CALL_FUNCTION(&_4, "lcfirst", &_2, 65, _1); + ZEPHIR_CALL_FUNCTION(&_4, "lcfirst", &_2, 67, _1); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, this_ptr, "set", NULL, 0, _4, definition); zephir_check_call_status(); @@ -832,7 +833,7 @@ PHP_METHOD(Phalcon_Di, __call) { ZEPHIR_CONCAT_SVS(_5, "Call to undefined method or service '", method, "'"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _5); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/di.zep", 427 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/di.zep", 428 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; diff --git a/ext/phalcon/di/factorydefault.zep.c b/ext/phalcon/di/factorydefault.zep.c index 70d46c62b58..afe70674999 100644 --- a/ext/phalcon/di/factorydefault.zep.c +++ b/ext/phalcon/di/factorydefault.zep.c @@ -45,7 +45,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_ce, this_ptr, "__construct", &_0, 73); + ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_ce, this_ptr, "__construct", &_0, 75); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 21, 0 TSRMLS_CC); @@ -57,7 +57,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Router", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_VAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -70,7 +70,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Dispatcher", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -83,7 +83,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Url", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -96,7 +96,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -109,7 +109,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\MetaData\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -122,7 +122,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Http\\Response", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -135,7 +135,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Http\\Response\\Cookies", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -148,7 +148,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Http\\Request", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -161,7 +161,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Filter", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -174,7 +174,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Escaper", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -187,7 +187,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Security", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -200,7 +200,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Crypt", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -213,7 +213,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Annotations\\Adapter\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -226,7 +226,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Flash\\Direct", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -239,7 +239,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Flash\\Session", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -252,7 +252,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Tag", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -265,7 +265,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Session\\Adapter\\Files", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -276,7 +276,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_3, "sessionBag", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_4); ZVAL_STRING(_4, "Phalcon\\Session\\Bag", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -289,7 +289,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Events\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -297,12 +297,12 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZEPHIR_INIT_NVAR(_2); object_init_ex(_2, phalcon_di_service_ce); ZEPHIR_INIT_NVAR(_3); - ZVAL_STRING(_3, "transactions", ZEPHIR_TEMP_PARAM_COPY); + ZVAL_STRING(_3, "transactionManager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_NVAR(_4); ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Transaction\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -315,7 +315,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault, __construct) { ZVAL_STRING(_4, "Phalcon\\Assets\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); diff --git a/ext/phalcon/di/factorydefault/cli.zep.c b/ext/phalcon/di/factorydefault/cli.zep.c index eff6410c256..2ee5dccbe89 100644 --- a/ext/phalcon/di/factorydefault/cli.zep.c +++ b/ext/phalcon/di/factorydefault/cli.zep.c @@ -46,7 +46,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 174); + ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 175); zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); zephir_create_array(_1, 10, 0 TSRMLS_CC); @@ -58,7 +58,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\CLI\\Router", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_VAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -71,7 +71,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\CLI\\Dispatcher", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -84,7 +84,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -97,7 +97,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\MetaData\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -110,7 +110,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Filter", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -123,7 +123,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Escaper", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -136,7 +136,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Annotations\\Adapter\\Memory", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -149,7 +149,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Security", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -162,7 +162,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Events\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); @@ -175,7 +175,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) { ZVAL_STRING(_4, "Phalcon\\Mvc\\Model\\Transaction\\Manager", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_SINIT_NVAR(_5); ZVAL_BOOL(&_5, 1); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 61, _3, _4, &_5); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_6, 63, _3, _4, &_5); zephir_check_temp_parameter(_3); zephir_check_temp_parameter(_4); zephir_check_call_status(); diff --git a/ext/phalcon/di/injectable.zep.c b/ext/phalcon/di/injectable.zep.c index 72966165ea9..90439b23cd0 100644 --- a/ext/phalcon/di/injectable.zep.c +++ b/ext/phalcon/di/injectable.zep.c @@ -49,7 +49,7 @@ * @property \Phalcon\Mvc\Model\MetaData\Memory|\Phalcon\Mvc\Model\MetadataInterface $modelsMetadata * @property \Phalcon\Mvc\Model\Transaction\Manager $transactionManager * @property \Phalcon\Assets\Manager $assets - * @property \Phalcon\DI|\Phalcon\DiInterface $di + * @property \Phalcon\Di|\Phalcon\DiInterface $di * @property \Phalcon\Session\Bag $persistent * @property \Phalcon\Mvc\View|\Phalcon\Mvc\ViewInterface $view */ diff --git a/ext/phalcon/di/service.zep.c b/ext/phalcon/di/service.zep.c index 4867d262366..210c9be500d 100644 --- a/ext/phalcon/di/service.zep.c +++ b/ext/phalcon/di/service.zep.c @@ -181,7 +181,7 @@ PHP_METHOD(Phalcon_Di_Service, getDefinition) { * Resolves the service * * @param array parameters - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\DiInterface dependencyInjector * @return mixed */ PHP_METHOD(Phalcon_Di_Service, resolve) { @@ -258,7 +258,7 @@ PHP_METHOD(Phalcon_Di_Service, resolve) { ZEPHIR_CALL_METHOD(NULL, builder, "__construct", NULL, 0); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 175, dependencyInjector, definition, parameters); + ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 176, dependencyInjector, definition, parameters); zephir_check_call_status(); } else { found = 0; @@ -396,7 +396,7 @@ PHP_METHOD(Phalcon_Di_Service, __set_state) { return; } object_init_ex(return_value, phalcon_di_service_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 61, name, definition, shared); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 63, name, definition, shared); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/di/service/builder.zep.c b/ext/phalcon/di/service/builder.zep.c index d6c44ad9c90..29e46600ea6 100644 --- a/ext/phalcon/di/service/builder.zep.c +++ b/ext/phalcon/di/service/builder.zep.c @@ -39,7 +39,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Di_Service_Builder) { /** * Resolves a constructor/call parameter * - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\DiInterface dependencyInjector * @param int position * @param array argument * @return mixed @@ -188,7 +188,7 @@ PHP_METHOD(Phalcon_Di_Service_Builder, _buildParameters) { ) { ZEPHIR_GET_HMKEY(position, _1, _0); ZEPHIR_GET_HVALUE(argument, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 176, dependencyInjector, position, argument); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 177, dependencyInjector, position, argument); zephir_check_call_status(); zephir_array_append(&buildArguments, _3, PH_SEPARATE, "phalcon/di/service/builder.zep", 117); } @@ -199,7 +199,7 @@ PHP_METHOD(Phalcon_Di_Service_Builder, _buildParameters) { /** * Builds a service using a complex service definition * - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\DiInterface dependencyInjector * @param array definition * @param array parameters * @return mixed @@ -241,7 +241,7 @@ PHP_METHOD(Phalcon_Di_Service_Builder, build) { } else { ZEPHIR_OBS_VAR(arguments); if (zephir_array_isset_string_fetch(&arguments, definition, SS("arguments"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 178, dependencyInjector, arguments); zephir_check_call_status(); ZEPHIR_INIT_NVAR(instance); ZEPHIR_LAST_CALL_STATUS = zephir_create_instance_params(instance, className, _0 TSRMLS_CC); @@ -262,7 +262,7 @@ PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "Setter injection parameters must be an array", "phalcon/di/service/builder.zep", 181); return; } - zephir_is_iterable(paramCalls, &_3, &_2, 0, 0, "phalcon/di/service/builder.zep", 235); + zephir_is_iterable(paramCalls, &_3, &_2, 0, 0, "phalcon/di/service/builder.zep", 233); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -311,7 +311,7 @@ PHP_METHOD(Phalcon_Di_Service_Builder, build) { } if (zephir_fast_count_int(arguments TSRMLS_CC)) { ZEPHIR_INIT_NVAR(_5); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 178, dependencyInjector, arguments); zephir_check_call_status(); ZEPHIR_CALL_USER_FUNC_ARRAY(_5, methodCall, _0); zephir_check_call_status(); @@ -326,14 +326,14 @@ PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_OBS_NVAR(paramCalls); if (zephir_array_isset_string_fetch(¶mCalls, definition, SS("properties"), 0 TSRMLS_CC)) { if (Z_TYPE_P(instance) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "The definition has properties injection parameters but the constructor didn't return an instance", "phalcon/di/service/builder.zep", 243); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "The definition has properties injection parameters but the constructor didn't return an instance", "phalcon/di/service/builder.zep", 241); return; } if (Z_TYPE_P(paramCalls) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "Setter injection parameters must be an array", "phalcon/di/service/builder.zep", 247); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_di_exception_ce, "Setter injection parameters must be an array", "phalcon/di/service/builder.zep", 245); return; } - zephir_is_iterable(paramCalls, &_9, &_8, 0, 0, "phalcon/di/service/builder.zep", 282); + zephir_is_iterable(paramCalls, &_9, &_8, 0, 0, "phalcon/di/service/builder.zep", 279); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) @@ -347,7 +347,7 @@ PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_CONCAT_SV(_6, "Property must be an array on position ", propertyPosition); ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_11, "phalcon/di/service/builder.zep", 259 TSRMLS_CC); + zephir_throw_exception_debug(_11, "phalcon/di/service/builder.zep", 257 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -359,7 +359,7 @@ PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_CONCAT_SV(_6, "The property name is required on position ", propertyPosition); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 266 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 264 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -371,11 +371,11 @@ PHP_METHOD(Phalcon_Di_Service_Builder, build) { ZEPHIR_CONCAT_SV(_6, "The property value is required on position ", propertyPosition); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 273 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/di/service/builder.zep", 271 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 176, dependencyInjector, propertyPosition, propertyValue); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 177, dependencyInjector, propertyPosition, propertyValue); zephir_check_call_status(); zephir_update_property_zval_zval(instance, propertyName, _0 TSRMLS_CC); } diff --git a/ext/phalcon/di/serviceinterface.zep.c b/ext/phalcon/di/serviceinterface.zep.c index a5d891cc254..0e99b9f6d2e 100644 --- a/ext/phalcon/di/serviceinterface.zep.c +++ b/ext/phalcon/di/serviceinterface.zep.c @@ -69,11 +69,16 @@ ZEPHIR_DOC_METHOD(Phalcon_Di_ServiceInterface, getDefinition); * Resolves the service * * @param array parameters - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\DiInterface dependencyInjector * @return mixed */ ZEPHIR_DOC_METHOD(Phalcon_Di_ServiceInterface, resolve); +/** + * Changes a parameter in the definition without resolve the service + */ +ZEPHIR_DOC_METHOD(Phalcon_Di_ServiceInterface, setParameter); + /** * Restore the interal state of a service */ diff --git a/ext/phalcon/di/serviceinterface.zep.h b/ext/phalcon/di/serviceinterface.zep.h index 0abce67b933..98bbe33d61e 100644 --- a/ext/phalcon/di/serviceinterface.zep.h +++ b/ext/phalcon/di/serviceinterface.zep.h @@ -22,6 +22,11 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_di_serviceinterface_resolve, 0, 0, 0) ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 1) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_di_serviceinterface_setparameter, 0, 0, 2) + ZEND_ARG_INFO(0, position) + ZEND_ARG_ARRAY_INFO(0, parameter, 0) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_di_serviceinterface___set_state, 0, 0, 1) ZEND_ARG_ARRAY_INFO(0, attributes, 0) ZEND_END_ARG_INFO() @@ -34,6 +39,7 @@ ZEPHIR_INIT_FUNCS(phalcon_di_serviceinterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, setDefinition, arginfo_phalcon_di_serviceinterface_setdefinition) PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, getDefinition, NULL) PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, resolve, arginfo_phalcon_di_serviceinterface_resolve) + PHP_ABSTRACT_ME(Phalcon_Di_ServiceInterface, setParameter, arginfo_phalcon_di_serviceinterface_setparameter) ZEND_FENTRY(__set_state, NULL, arginfo_phalcon_di_serviceinterface___set_state, ZEND_ACC_STATIC|ZEND_ACC_ABSTRACT|ZEND_ACC_PUBLIC) PHP_FE_END }; diff --git a/ext/phalcon/diinterface.zep.c b/ext/phalcon/diinterface.zep.c index 3148f1ffac6..944e6e262db 100644 --- a/ext/phalcon/diinterface.zep.c +++ b/ext/phalcon/diinterface.zep.c @@ -32,7 +32,7 @@ ZEPHIR_INIT_CLASS(Phalcon_DiInterface) { * @param string name * @param mixed definition * @param boolean shared - * @return Phalcon\Di\ServiceInterface + * @return \Phalcon\Di\ServiceInterface */ ZEPHIR_DOC_METHOD(Phalcon_DiInterface, set); @@ -41,7 +41,7 @@ ZEPHIR_DOC_METHOD(Phalcon_DiInterface, set); * * @param string name * @param mixed definition - * @return Phalcon\Di\ServiceInterface + * @return \Phalcon\Di\ServiceInterface */ ZEPHIR_DOC_METHOD(Phalcon_DiInterface, setShared); @@ -58,7 +58,7 @@ ZEPHIR_DOC_METHOD(Phalcon_DiInterface, remove); * @param string name * @param mixed definition * @param boolean shared - * @return Phalcon\Di\ServiceInterface + * @return \Phalcon\Di\ServiceInterface */ ZEPHIR_DOC_METHOD(Phalcon_DiInterface, attempt); diff --git a/ext/phalcon/escaper.zep.c b/ext/phalcon/escaper.zep.c index 9ac3dd53f1a..c8adfb2f229 100644 --- a/ext/phalcon/escaper.zep.c +++ b/ext/phalcon/escaper.zep.c @@ -155,13 +155,13 @@ PHP_METHOD(Phalcon_Escaper, detectEncoding) { ; zephir_hash_move_forward_ex(_3, &_2) ) { ZEPHIR_GET_HVALUE(charset, _4); - ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 178, str, charset, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 179, str, charset, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); if (zephir_is_true(_5)) { RETURN_CCTOR(charset); } } - ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 178, str); + ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 179, str); zephir_check_call_status(); RETURN_MM(); @@ -186,11 +186,11 @@ PHP_METHOD(Phalcon_Escaper, normalizeEncoding) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_escaper_exception_ce, "Extension 'mbstring' is required", "phalcon/escaper.zep", 128); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 179, str); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 180, str); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "UTF-32", 0); - ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, str, &_1, _0); + ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 181, str, &_1, _0); zephir_check_call_status(); RETURN_MM(); @@ -213,7 +213,7 @@ PHP_METHOD(Phalcon_Escaper, escapeHtml) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_htmlQuoteType"), PH_NOISY_CC); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC); - ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, text, _0, _1); + ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 182, text, _0, _1); zephir_check_call_status(); RETURN_MM(); @@ -237,7 +237,7 @@ PHP_METHOD(Phalcon_Escaper, escapeHtmlAttr) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 3); - ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, attribute, &_1, _0); + ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 182, attribute, &_1, _0); zephir_check_call_status(); RETURN_MM(); @@ -258,7 +258,7 @@ PHP_METHOD(Phalcon_Escaper, escapeCss) { zephir_get_strval(css, css_param); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, css); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 183, css); zephir_check_call_status(); zephir_escape_css(return_value, _0); RETURN_MM(); @@ -280,7 +280,7 @@ PHP_METHOD(Phalcon_Escaper, escapeJs) { zephir_get_strval(js, js_param); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, js); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 183, js); zephir_check_call_status(); zephir_escape_js(return_value, _0); RETURN_MM(); @@ -302,7 +302,7 @@ PHP_METHOD(Phalcon_Escaper, escapeUrl) { zephir_get_strval(url, url_param); - ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 183, url); + ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 184, url); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/events/event.zep.c b/ext/phalcon/events/event.zep.c index 878d567ade2..e52f7a888ce 100644 --- a/ext/phalcon/events/event.zep.c +++ b/ext/phalcon/events/event.zep.c @@ -13,8 +13,8 @@ #include "kernel/main.h" #include "kernel/object.h" -#include "kernel/memory.h" #include "kernel/operators.h" +#include "kernel/memory.h" #include "ext/spl/spl_exceptions.h" #include "kernel/exception.h" @@ -69,25 +69,25 @@ ZEPHIR_INIT_CLASS(Phalcon_Events_Event) { /** * Event type - * - * @var string */ PHP_METHOD(Phalcon_Events_Event, setType) { - zval *type; + zval *type_param = NULL; + zval *type = NULL; - zephir_fetch_params(0, 1, 0, &type); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &type_param); + zephir_get_strval(type, type_param); zephir_update_property_this(this_ptr, SL("_type"), type TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } /** * Event type - * - * @var string */ PHP_METHOD(Phalcon_Events_Event, getType) { @@ -98,8 +98,6 @@ PHP_METHOD(Phalcon_Events_Event, getType) { /** * Event source - * - * @var object */ PHP_METHOD(Phalcon_Events_Event, getSource) { @@ -110,8 +108,6 @@ PHP_METHOD(Phalcon_Events_Event, getSource) { /** * Event data - * - * @var mixed */ PHP_METHOD(Phalcon_Events_Event, setData) { @@ -127,8 +123,6 @@ PHP_METHOD(Phalcon_Events_Event, setData) { /** * Event data - * - * @var mixed */ PHP_METHOD(Phalcon_Events_Event, getData) { @@ -139,8 +133,6 @@ PHP_METHOD(Phalcon_Events_Event, getData) { /** * Is event cancelable? - * - * @var boolean */ PHP_METHOD(Phalcon_Events_Event, getCancelable) { diff --git a/ext/phalcon/events/manager.zep.c b/ext/phalcon/events/manager.zep.c index 705234658e0..bc15c312052 100644 --- a/ext/phalcon/events/manager.zep.c +++ b/ext/phalcon/events/manager.zep.c @@ -107,7 +107,7 @@ PHP_METHOD(Phalcon_Events_Manager, attach) { } ZEPHIR_INIT_VAR(_2); ZVAL_LONG(_2, 1); - ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 184, _2); + ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 185, _2); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_events"), eventType, priorityQueue TSRMLS_CC); } else { @@ -117,7 +117,7 @@ PHP_METHOD(Phalcon_Events_Manager, attach) { if (Z_TYPE_P(priorityQueue) == IS_OBJECT) { ZEPHIR_INIT_NVAR(_2); ZVAL_LONG(_2, priority); - ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 185, handler, _2); + ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 186, handler, _2); zephir_check_call_status(); } else { zephir_array_append(&priorityQueue, handler, PH_SEPARATE, "phalcon/events/manager.zep", 82); @@ -172,7 +172,7 @@ PHP_METHOD(Phalcon_Events_Manager, detach) { } ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 1); - ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 184, _1); + ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 185, _1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_1); ZVAL_LONG(_1, 3); @@ -194,13 +194,13 @@ PHP_METHOD(Phalcon_Events_Manager, detach) { if (!ZEPHIR_IS_IDENTICAL(_5, handler)) { zephir_array_fetch_string(&_6, data, SL("data"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC); zephir_array_fetch_string(&_7, data, SL("priority"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 185, _6, _7); + ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 186, _6, _7); zephir_check_call_status(); } } zephir_update_property_array(this_ptr, SL("_events"), eventType, newPriorityQueue TSRMLS_CC); } else { - ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 186, handler, priorityQueue, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 187, handler, priorityQueue, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); if (!ZEPHIR_IS_FALSE_IDENTICAL(key)) { zephir_array_unset(&priorityQueue, key, PH_SEPARATE); @@ -362,7 +362,7 @@ PHP_METHOD(Phalcon_Events_Manager, dettachAll) { * Internal handler to call a queue of events * * @param \SplPriorityQueue|array queue - * @param Phalcon\Events\Event event + * @param \Phalcon\Events\Event event * @return mixed */ PHP_METHOD(Phalcon_Events_Manager, fireQueue) { @@ -388,7 +388,7 @@ PHP_METHOD(Phalcon_Events_Manager, fireQueue) { zephir_get_class(_1, queue, 0 TSRMLS_CC); ZEPHIR_SINIT_VAR(_2); ZVAL_STRING(&_2, "Unexpected value type: expected object of type SplPriorityQueue, %s given", 0); - ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 187, &_2, _1); + ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 188, &_2, _1); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); @@ -614,9 +614,9 @@ PHP_METHOD(Phalcon_Events_Manager, fire) { if (_3) { ZEPHIR_INIT_NVAR(event); object_init_ex(event, phalcon_events_event_ce); - ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 189, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event); + ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 190, fireEvents, event); zephir_check_call_status(); } } @@ -630,10 +630,10 @@ PHP_METHOD(Phalcon_Events_Manager, fire) { if (Z_TYPE_P(event) == IS_NULL) { ZEPHIR_INIT_NVAR(event); object_init_ex(event, phalcon_events_event_ce); - ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 189, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event); + ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 190, fireEvents, event); zephir_check_call_status(); } } diff --git a/ext/phalcon/filter.zep.c b/ext/phalcon/filter.zep.c index 30b575a4c5a..0e5845486ce 100644 --- a/ext/phalcon/filter.zep.c +++ b/ext/phalcon/filter.zep.c @@ -250,16 +250,16 @@ PHP_METHOD(Phalcon_Filter, _sanitize) { if (ZEPHIR_IS_STRING(filter, "email")) { ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "FILTER_SANITIZE_EMAIL", 0); - ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 191, &_3); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, _4); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, _4); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "int")) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 519); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, &_3); zephir_check_call_status(); RETURN_MM(); } @@ -269,14 +269,14 @@ PHP_METHOD(Phalcon_Filter, _sanitize) { if (ZEPHIR_IS_STRING(filter, "absint")) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, zephir_get_intval(value)); - ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 192, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 193, &_3); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "string")) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 513); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, &_3); zephir_check_call_status(); RETURN_MM(); } @@ -286,7 +286,7 @@ PHP_METHOD(Phalcon_Filter, _sanitize) { add_assoc_long_ex(_2, SS("flags"), 4096); ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 520); - ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3, _2); + ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 192, value, &_3, _2); zephir_check_call_status(); RETURN_MM(); } @@ -298,7 +298,7 @@ PHP_METHOD(Phalcon_Filter, _sanitize) { ZVAL_STRING(_6, "/[^A-Za-z0-9]/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_FUNCTION("preg_replace", NULL, 28, _6, _7, value); + ZEPHIR_RETURN_CALL_FUNCTION("preg_replace", NULL, 29, _6, _7, value); zephir_check_temp_parameter(_6); zephir_check_temp_parameter(_7); zephir_check_call_status(); @@ -309,13 +309,13 @@ PHP_METHOD(Phalcon_Filter, _sanitize) { RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "striptags")) { - ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 193, value); + ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 194, value); zephir_check_call_status(); RETURN_MM(); } if (ZEPHIR_IS_STRING(filter, "lower")) { if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, value); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 195, value); zephir_check_call_status(); RETURN_MM(); } @@ -324,7 +324,7 @@ PHP_METHOD(Phalcon_Filter, _sanitize) { } if (ZEPHIR_IS_STRING(filter, "upper")) { if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, value); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 196, value); zephir_check_call_status(); RETURN_MM(); } diff --git a/ext/phalcon/flash/direct.zep.c b/ext/phalcon/flash/direct.zep.c index ff5d9c6d11c..98ab9bac0ed 100644 --- a/ext/phalcon/flash/direct.zep.c +++ b/ext/phalcon/flash/direct.zep.c @@ -89,7 +89,7 @@ PHP_METHOD(Phalcon_Flash_Direct, output) { } } if (remove) { - ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 196); + ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 197); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/flash/session.zep.c b/ext/phalcon/flash/session.zep.c index 1efd06c2b45..6ea58471bf5 100644 --- a/ext/phalcon/flash/session.zep.c +++ b/ext/phalcon/flash/session.zep.c @@ -281,7 +281,7 @@ PHP_METHOD(Phalcon_Flash_Session, output) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 196); + ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 197); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -302,7 +302,7 @@ PHP_METHOD(Phalcon_Flash_Session, clear) { ZVAL_BOOL(_0, 1); ZEPHIR_CALL_METHOD(NULL, this_ptr, "_getsessionmessages", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 196); + ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 197); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/forms/element.zep.c b/ext/phalcon/forms/element.zep.c index e7701b63d05..9f1f187934d 100644 --- a/ext/phalcon/forms/element.zep.c +++ b/ext/phalcon/forms/element.zep.c @@ -151,7 +151,7 @@ PHP_METHOD(Phalcon_Forms_Element, getName) { * Sets the element filters * * @param array|string filters - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ PHP_METHOD(Phalcon_Forms_Element, setFilters) { @@ -226,8 +226,8 @@ PHP_METHOD(Phalcon_Forms_Element, getFilters) { /** * Adds a group of validators * - * @param Phalcon\Validation\ValidatorInterface[] - * @return Phalcon\Forms\ElementInterface + * @param \Phalcon\Validation\ValidatorInterface[] + * @return \Phalcon\Forms\ElementInterface */ PHP_METHOD(Phalcon_Forms_Element, addValidators) { @@ -363,7 +363,7 @@ PHP_METHOD(Phalcon_Forms_Element, prepareAttributes) { * * @param string attribute * @param mixed value - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ PHP_METHOD(Phalcon_Forms_Element, setAttribute) { @@ -452,7 +452,7 @@ PHP_METHOD(Phalcon_Forms_Element, getAttributes) { * * @param string option * @param mixed value - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ PHP_METHOD(Phalcon_Forms_Element, setUserOption) { @@ -501,7 +501,7 @@ PHP_METHOD(Phalcon_Forms_Element, getUserOption) { * Sets options for the element * * @param array options - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ PHP_METHOD(Phalcon_Forms_Element, setUserOptions) { @@ -619,7 +619,7 @@ PHP_METHOD(Phalcon_Forms_Element, label) { * or there is no value available for the element in _POST * * @param mixed value - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ PHP_METHOD(Phalcon_Forms_Element, setDefault) { diff --git a/ext/phalcon/forms/element/check.zep.c b/ext/phalcon/forms/element/check.zep.c index d2bc5503ce3..fb18ed9c129 100644 --- a/ext/phalcon/forms/element/check.zep.c +++ b/ext/phalcon/forms/element/check.zep.c @@ -54,7 +54,7 @@ PHP_METHOD(Phalcon_Forms_Element_Check, render) { ZVAL_BOOL(_2, 1); ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 197, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 198, _1); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/forms/element/date.zep.c b/ext/phalcon/forms/element/date.zep.c index c00de18cb01..b4b8ee87742 100644 --- a/ext/phalcon/forms/element/date.zep.c +++ b/ext/phalcon/forms/element/date.zep.c @@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_Date, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 198, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 199, _1); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/forms/element/email.zep.c b/ext/phalcon/forms/element/email.zep.c index 10daf4398b9..574d0e199f5 100644 --- a/ext/phalcon/forms/element/email.zep.c +++ b/ext/phalcon/forms/element/email.zep.c @@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_Email, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 199, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 200, _1); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/forms/element/file.zep.c b/ext/phalcon/forms/element/file.zep.c index 70d7eaa7379..325078ba37f 100644 --- a/ext/phalcon/forms/element/file.zep.c +++ b/ext/phalcon/forms/element/file.zep.c @@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_File, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 200, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 201, _1); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/forms/element/hidden.zep.c b/ext/phalcon/forms/element/hidden.zep.c index 653ac0a0b80..582bb699903 100644 --- a/ext/phalcon/forms/element/hidden.zep.c +++ b/ext/phalcon/forms/element/hidden.zep.c @@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_Hidden, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 201, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 202, _1); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/forms/element/numeric.zep.c b/ext/phalcon/forms/element/numeric.zep.c index 0d58d68f440..8e3ed366ac6 100644 --- a/ext/phalcon/forms/element/numeric.zep.c +++ b/ext/phalcon/forms/element/numeric.zep.c @@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_Numeric, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 202, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 203, _1); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/forms/element/password.zep.c b/ext/phalcon/forms/element/password.zep.c index bad4d1b3e08..86ceec3f4c7 100644 --- a/ext/phalcon/forms/element/password.zep.c +++ b/ext/phalcon/forms/element/password.zep.c @@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_Password, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 203, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 204, _1); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/forms/element/radio.zep.c b/ext/phalcon/forms/element/radio.zep.c index 7ef61441588..ef825aa4381 100644 --- a/ext/phalcon/forms/element/radio.zep.c +++ b/ext/phalcon/forms/element/radio.zep.c @@ -54,7 +54,7 @@ PHP_METHOD(Phalcon_Forms_Element_Radio, render) { ZVAL_BOOL(_2, 1); ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 204, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 205, _1); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/forms/element/select.zep.c b/ext/phalcon/forms/element/select.zep.c index 1c6af3a03a7..d80f769ee81 100644 --- a/ext/phalcon/forms/element/select.zep.c +++ b/ext/phalcon/forms/element/select.zep.c @@ -16,6 +16,7 @@ #include "kernel/fcall.h" #include "kernel/operators.h" #include "kernel/memory.h" +#include "kernel/hash.h" /** @@ -61,7 +62,7 @@ PHP_METHOD(Phalcon_Forms_Element_Select, __construct) { zephir_update_property_this(this_ptr, SL("_optionsValues"), options TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 205, name, attributes); + ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 206, name, attributes); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -71,7 +72,7 @@ PHP_METHOD(Phalcon_Forms_Element_Select, __construct) { * Set the choice's options * * @param array|object options - * @return Phalcon\Forms\Element + * @return \Phalcon\Forms\Element */ PHP_METHOD(Phalcon_Forms_Element_Select, setOptions) { @@ -106,14 +107,29 @@ PHP_METHOD(Phalcon_Forms_Element_Select, getOptions) { */ PHP_METHOD(Phalcon_Forms_Element_Select, addOption) { - zval *option; + HashTable *_1; + HashPosition _0; + zval *option, *key = NULL, *value = NULL, **_2; - zephir_fetch_params(0, 1, 0, &option); - - - - zephir_update_property_array_append(this_ptr, SL("_optionsValues"), option TSRMLS_CC); - RETURN_THISW(); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &option); + + + + if (Z_TYPE_P(option) == IS_ARRAY) { + zephir_is_iterable(option, &_1, &_0, 0, 0, "phalcon/forms/element/select.zep", 85); + for ( + ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS + ; zephir_hash_move_forward_ex(_1, &_0) + ) { + ZEPHIR_GET_HMKEY(key, _1, _0); + ZEPHIR_GET_HVALUE(value, _2); + zephir_update_property_array(this_ptr, SL("_optionsValues"), key, value TSRMLS_CC); + } + } else { + zephir_update_property_array_append(this_ptr, SL("_optionsValues"), option TSRMLS_CC); + } + RETURN_THIS(); } @@ -140,7 +156,7 @@ PHP_METHOD(Phalcon_Forms_Element_Select, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); _2 = zephir_fetch_nproperty_this(this_ptr, SL("_optionsValues"), PH_NOISY_CC); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, _1, _2); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 207, _1, _2); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/forms/element/submit.zep.c b/ext/phalcon/forms/element/submit.zep.c index 10fee5e33b8..0b817061560 100644 --- a/ext/phalcon/forms/element/submit.zep.c +++ b/ext/phalcon/forms/element/submit.zep.c @@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_Submit, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 207, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 208, _1); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/forms/element/text.zep.c b/ext/phalcon/forms/element/text.zep.c index 52ec831bb04..1544f3a5e42 100644 --- a/ext/phalcon/forms/element/text.zep.c +++ b/ext/phalcon/forms/element/text.zep.c @@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_Text, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 208, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 209, _1); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/forms/element/textarea.zep.c b/ext/phalcon/forms/element/textarea.zep.c index 71836016d2d..2c12c6c7f93 100644 --- a/ext/phalcon/forms/element/textarea.zep.c +++ b/ext/phalcon/forms/element/textarea.zep.c @@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_TextArea, render) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 209, _1); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 210, _1); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/forms/elementinterface.zep.c b/ext/phalcon/forms/elementinterface.zep.c index e8a64f3e1b6..32a09d6ee0f 100644 --- a/ext/phalcon/forms/elementinterface.zep.c +++ b/ext/phalcon/forms/elementinterface.zep.c @@ -28,15 +28,15 @@ ZEPHIR_INIT_CLASS(Phalcon_Forms_ElementInterface) { /** * Sets the parent form to the element * - * @param Phalcon\Forms\Form form - * @return Phalcon\Forms\ElementInterface + * @param \Phalcon\Forms\Form form + * @return \Phalcon\Forms\ElementInterface */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, setForm); /** * Returns the parent form to the element * - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, getForm); @@ -44,7 +44,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, getForm); * Sets the element's name * * @param string name - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, setName); @@ -57,7 +57,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, getName); * Sets the element's filters * * @param array|string filters - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, setFilters); @@ -65,7 +65,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, setFilters); * Adds a filter to current list of filters * * @param string filter - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, addFilter); @@ -79,24 +79,24 @@ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, getFilters); /** * Adds a group of validators * - * @param Phalcon\Validation\ValidatorInterface[] + * @param \Phalcon\Validation\ValidatorInterface[] * @param boolean merge - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, addValidators); /** * Adds a validator to the element * - * @param Phalcon\Validation\ValidatorInterface - * @return Phalcon\Forms\ElementInterface + * @param \Phalcon\Validation\ValidatorInterface + * @return \Phalcon\Forms\ElementInterface */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, addValidator); /** * Returns the validators registered for the element * - * @return Phalcon\Validation\ValidatorInterface[] + * @return \Phalcon\Validation\ValidatorInterface[] */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, getValidators); @@ -115,7 +115,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, prepareAttributes); * * @param string attribute * @param mixed value - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, setAttribute); @@ -132,7 +132,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, getAttribute); * Sets default attributes for the element * * @param array attributes - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, setAttributes); @@ -146,7 +146,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, getAttributes); * * @param string option * @param mixed value - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, setUserOption); @@ -163,7 +163,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, getUserOption); * Sets options for the element * * @param array options - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, setUserOptions); @@ -178,7 +178,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, getUserOptions); * Sets the element label * * @param string label - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, setLabel); @@ -197,7 +197,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, label); * or there is no value available for the element in _POST * * @param mixed value - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, setDefault); @@ -219,7 +219,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, getValue); * Returns the messages that belongs to the element * The element needs to be attached to a form * - * @return Phalcon\Validation\Message\Group + * @return \Phalcon\Validation\Message\Group */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, getMessages); @@ -231,23 +231,23 @@ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, hasMessages); /** * Sets the validation messages related to the element * - * @param Phalcon\Validation\Message\Group group - * @return Phalcon\Forms\ElementInterface + * @param \Phalcon\Validation\Message\Group group + * @return \Phalcon\Forms\ElementInterface */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, setMessages); /** * Appends a message to the internal message list * - * @param Phalcon\Validation\Message message - * @return Phalcon\Forms\ElementInterface + * @param \Phalcon\Validation\Message message + * @return \Phalcon\Forms\ElementInterface */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, appendMessage); /** * Clears every element in the form to its default value * - * @return Phalcon\Forms\Element + * @return \Phalcon\Forms\Element */ ZEPHIR_DOC_METHOD(Phalcon_Forms_ElementInterface, clear); diff --git a/ext/phalcon/forms/form.zep.c b/ext/phalcon/forms/form.zep.c index f0408088795..a3dd9501dad 100644 --- a/ext/phalcon/forms/form.zep.c +++ b/ext/phalcon/forms/form.zep.c @@ -121,7 +121,7 @@ PHP_METHOD(Phalcon_Forms_Form, __construct) { * Sets the form's action * * @param string action - * @return Phalcon\Forms\Form + * @return \Phalcon\Forms\Form */ PHP_METHOD(Phalcon_Forms_Form, setAction) { @@ -151,7 +151,7 @@ PHP_METHOD(Phalcon_Forms_Form, getAction) { * * @param string option * @param mixed value - * @return Phalcon\Forms\Form + * @return \Phalcon\Forms\Form */ PHP_METHOD(Phalcon_Forms_Form, setUserOption) { @@ -228,7 +228,7 @@ PHP_METHOD(Phalcon_Forms_Form, getUserOptions) { * Sets the entity related to the model * * @param object entity - * @return Phalcon\Forms\Form + * @return \Phalcon\Forms\Form */ PHP_METHOD(Phalcon_Forms_Form, setEntity) { @@ -271,7 +271,7 @@ PHP_METHOD(Phalcon_Forms_Form, getElements) { * @param array data * @param object entity * @param array whitelist - * @return Phalcon\Forms\Form + * @return \Phalcon\Forms\Form */ PHP_METHOD(Phalcon_Forms_Form, bind) { @@ -446,7 +446,7 @@ PHP_METHOD(Phalcon_Forms_Form, isValid) { } else { ZEPHIR_INIT_NVAR(validation); object_init_ex(validation, phalcon_validation_ce); - ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 210, preparedValidators); + ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 211, preparedValidators); zephir_check_call_status(); } ZEPHIR_CALL_METHOD(&filters, element, "getfilters", NULL, 0); @@ -454,10 +454,10 @@ PHP_METHOD(Phalcon_Forms_Form, isValid) { if (Z_TYPE_P(filters) == IS_ARRAY) { ZEPHIR_CALL_METHOD(&_2, element, "getname", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 211, _2, filters); + ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 212, _2, filters); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 212, data, entity); + ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 213, data, entity); zephir_check_call_status(); if (zephir_fast_count_int(elementMessages TSRMLS_CC)) { ZEPHIR_CALL_METHOD(&_14, element, "getname", NULL, 0); @@ -523,7 +523,7 @@ PHP_METHOD(Phalcon_Forms_Form, getMessages) { ; zephir_hash_move_forward_ex(_2, &_1) ) { ZEPHIR_GET_HVALUE(elementMessages, _3); - ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 213, elementMessages); + ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 214, elementMessages); zephir_check_call_status(); } } @@ -535,7 +535,7 @@ PHP_METHOD(Phalcon_Forms_Form, getMessages) { * Returns the messages generated for a specific element * * @param string name - * @return Phalcon\Validation\Message\Group + * @return \Phalcon\Validation\Message\Group */ PHP_METHOD(Phalcon_Forms_Form, getMessagesFor) { @@ -582,10 +582,10 @@ PHP_METHOD(Phalcon_Forms_Form, hasMessagesFor) { /** * Adds an element to the form * - * @param Phalcon\Forms\ElementInterface element + * @param \Phalcon\Forms\ElementInterface element * @param string $postion * @param bool $type If $type is TRUE, the element wile add before $postion, else is after - * @return Phalcon\Forms\Form + * @return \Phalcon\Forms\Form */ PHP_METHOD(Phalcon_Forms_Form, add) { @@ -983,7 +983,7 @@ PHP_METHOD(Phalcon_Forms_Form, remove) { * Clears every element in the form to its default value * * @param array fields - * @return Phalcon\Forms\Form + * @return \Phalcon\Forms\Form */ PHP_METHOD(Phalcon_Forms_Form, clear) { @@ -1053,7 +1053,7 @@ PHP_METHOD(Phalcon_Forms_Form, rewind) { ZVAL_LONG(_0, 0); zephir_update_property_this(this_ptr, SL("_position"), _0 TSRMLS_CC); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_elements"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 214, _0); + ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 215, _0); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_elementsIndexed"), _1 TSRMLS_CC); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/forms/manager.zep.c b/ext/phalcon/forms/manager.zep.c index 906aea6e052..c7839e1200f 100644 --- a/ext/phalcon/forms/manager.zep.c +++ b/ext/phalcon/forms/manager.zep.c @@ -39,7 +39,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Forms_Manager) { * * @param string name * @param object entity - * @return Phalcon\Forms\Form + * @return \Phalcon\Forms\Form */ PHP_METHOD(Phalcon_Forms_Manager, create) { @@ -63,7 +63,7 @@ PHP_METHOD(Phalcon_Forms_Manager, create) { } ZEPHIR_INIT_VAR(form); object_init_ex(form, phalcon_forms_form_ce); - ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 215, entity); + ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 216, entity); zephir_check_call_status(); zephir_update_property_array(this_ptr, SL("_forms"), name, form TSRMLS_CC); RETURN_CCTOR(form); diff --git a/ext/phalcon/http/cookie.zep.c b/ext/phalcon/http/cookie.zep.c index 9ee2b695050..91de2372986 100644 --- a/ext/phalcon/http/cookie.zep.c +++ b/ext/phalcon/http/cookie.zep.c @@ -56,6 +56,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Http_Cookie) { zend_declare_property_bool(phalcon_http_cookie_ce, SL("_httpOnly"), 1, ZEND_ACC_PROTECTED TSRMLS_CC); + zend_class_implements(phalcon_http_cookie_ce TSRMLS_CC, 1, phalcon_http_cookieinterface_ce); zend_class_implements(phalcon_http_cookie_ce TSRMLS_CC, 1, phalcon_di_injectionawareinterface_ce); return SUCCESS; @@ -163,7 +164,7 @@ PHP_METHOD(Phalcon_Http_Cookie, getDI) { * Sets the cookie's value * * @param string value - * @return Phalcon\Http\Cookie + * @return \Phalcon\Http\Cookie */ PHP_METHOD(Phalcon_Http_Cookie, setValue) { @@ -322,16 +323,20 @@ PHP_METHOD(Phalcon_Http_Cookie, send) { zephir_check_temp_parameter(_1); zephir_check_call_status(); ZEPHIR_CPY_WRT(session, _0); - ZEPHIR_INIT_VAR(_2); - ZEPHIR_CONCAT_SV(_2, "_PHCOOKIE_", name); - ZEPHIR_CALL_METHOD(NULL, session, "set", NULL, 0, _2, definition); + ZEPHIR_CALL_METHOD(&_0, session, "isstarted", NULL, 0); zephir_check_call_status(); + if (zephir_is_true(_0)) { + ZEPHIR_INIT_VAR(_2); + ZEPHIR_CONCAT_SV(_2, "_PHCOOKIE_", name); + ZEPHIR_CALL_METHOD(NULL, session, "set", NULL, 0, _2, definition); + zephir_check_call_status(); + } } _3 = zephir_fetch_nproperty_this(this_ptr, SL("_useEncryption"), PH_NOISY_CC); if (zephir_is_true(_3)) { if (!(ZEPHIR_IS_EMPTY(value))) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "A dependency injection object is required to access the 'filter' service", "phalcon/http/cookie.zep", 258); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "A dependency injection object is required to access the 'filter' service", "phalcon/http/cookie.zep", 260); return; } ZEPHIR_INIT_NVAR(_1); @@ -349,7 +354,7 @@ PHP_METHOD(Phalcon_Http_Cookie, send) { } else { ZEPHIR_CPY_WRT(encryptValue, value); } - ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, encryptValue, expire, path, domain, secure, httpOnly); + ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 217, name, encryptValue, expire, path, domain, secure, httpOnly); zephir_check_call_status(); RETURN_THIS(); @@ -362,7 +367,7 @@ PHP_METHOD(Phalcon_Http_Cookie, send) { PHP_METHOD(Phalcon_Http_Cookie, restore) { int ZEPHIR_LAST_CALL_STATUS; - zval *dependencyInjector, *expire, *domain, *path, *secure, *httpOnly, *session = NULL, *definition = NULL, *_0, *_1, *_2, *_3; + zval *dependencyInjector, *expire, *domain, *path, *secure, *httpOnly, *session = NULL, *definition = NULL, *_0, *_1, *_2 = NULL, *_3, *_4; ZEPHIR_MM_GROW(); @@ -376,26 +381,30 @@ PHP_METHOD(Phalcon_Http_Cookie, restore) { ZEPHIR_CALL_METHOD(&session, dependencyInjector, "getshared", NULL, 0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_3); - ZEPHIR_CONCAT_SV(_3, "_PHCOOKIE_", _2); - ZEPHIR_CALL_METHOD(&definition, session, "get", NULL, 0, _3); + ZEPHIR_CALL_METHOD(&_2, session, "isstarted", NULL, 0); zephir_check_call_status(); - if (Z_TYPE_P(definition) == IS_ARRAY) { - if (zephir_array_isset_string_fetch(&expire, definition, SS("expire"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_expire"), expire TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&domain, definition, SS("domain"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_domain"), domain TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&path, definition, SS("path"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_path"), path TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&secure, definition, SS("secure"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_secure"), secure TSRMLS_CC); - } - if (zephir_array_isset_string_fetch(&httpOnly, definition, SS("httpOnly"), 1 TSRMLS_CC)) { - zephir_update_property_this(this_ptr, SL("_httpOnly"), httpOnly TSRMLS_CC); + if (zephir_is_true(_2)) { + _3 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); + ZEPHIR_INIT_VAR(_4); + ZEPHIR_CONCAT_SV(_4, "_PHCOOKIE_", _3); + ZEPHIR_CALL_METHOD(&definition, session, "get", NULL, 0, _4); + zephir_check_call_status(); + if (Z_TYPE_P(definition) == IS_ARRAY) { + if (zephir_array_isset_string_fetch(&expire, definition, SS("expire"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_expire"), expire TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&domain, definition, SS("domain"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_domain"), domain TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&path, definition, SS("path"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_path"), path TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&secure, definition, SS("secure"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_secure"), secure TSRMLS_CC); + } + if (zephir_array_isset_string_fetch(&httpOnly, definition, SS("httpOnly"), 1 TSRMLS_CC)) { + zephir_update_property_this(this_ptr, SL("_httpOnly"), httpOnly TSRMLS_CC); + } } } } @@ -434,17 +443,21 @@ PHP_METHOD(Phalcon_Http_Cookie, delete) { zephir_check_temp_parameter(_2); zephir_check_call_status(); ZEPHIR_CPY_WRT(session, _1); - ZEPHIR_INIT_VAR(_3); - ZEPHIR_CONCAT_SV(_3, "_PHCOOKIE_", name); - ZEPHIR_CALL_METHOD(NULL, session, "remove", NULL, 0, _3); + ZEPHIR_CALL_METHOD(&_1, session, "isstarted", NULL, 0); zephir_check_call_status(); + if (zephir_is_true(_1)) { + ZEPHIR_INIT_VAR(_3); + ZEPHIR_CONCAT_SV(_3, "_PHCOOKIE_", name); + ZEPHIR_CALL_METHOD(NULL, session, "remove", NULL, 0, _3); + zephir_check_call_status(); + } } zephir_update_property_this(this_ptr, SL("_value"), ZEPHIR_GLOBAL(global_null) TSRMLS_CC); ZEPHIR_INIT_NVAR(_2); zephir_time(_2); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, (zephir_get_numberval(_2) - 691200)); - ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly); + ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 217, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/http/cookieinterface.zep.c b/ext/phalcon/http/cookieinterface.zep.c new file mode 100644 index 00000000000..7eb5bf116e7 --- /dev/null +++ b/ext/phalcon/http/cookieinterface.zep.c @@ -0,0 +1,119 @@ + +#ifdef HAVE_CONFIG_H +#include "../../ext_config.h" +#endif + +#include +#include "../../php_ext.h" +#include "../../ext.h" + +#include + +#include "kernel/main.h" + + +/** + * Phalcon\Http\CookieInterface + * + * Interface for Phalcon\Http\Cookie + */ +ZEPHIR_INIT_CLASS(Phalcon_Http_CookieInterface) { + + ZEPHIR_REGISTER_INTERFACE(Phalcon\\Http, CookieInterface, phalcon, http_cookieinterface, phalcon_http_cookieinterface_method_entry); + + return SUCCESS; + +} + +/** + * Sets the cookie's value + * + * @param string value + * @return \Phalcon\Http\CookieInterface + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setValue); + +/** + * Returns the cookie's value + * + * @param string|array filters + * @param string defaultValue + * @return mixed + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getValue); + +/** + * Sends the cookie to the HTTP client + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, send); + +/** + * Deletes the cookie + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, delete); + +/** + * Sets if the cookie must be encrypted/decrypted automatically + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, useEncryption); + +/** + * Check if the cookie is using implicit encryption + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, isUsingEncryption); + +/** + * Sets the cookie's expiration time + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setExpiration); + +/** + * Returns the current expiration time + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getExpiration); + +/** + * Sets the cookie's expiration time + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setPath); + +/** + * Returns the current cookie's name + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getName); + +/** + * Returns the current cookie's path + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getPath); + +/** + * Sets the domain that the cookie is available to + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setDomain); + +/** + * Returns the domain that the cookie is available to + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getDomain); + +/** + * Sets if the cookie must only be sent when the connection is secure (HTTPS) + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setSecure); + +/** + * Returns whether the cookie must only be sent when the connection is secure (HTTPS) + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getSecure); + +/** + * Sets if the cookie is accessible only through the HTTP protocol + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, setHttpOnly); + +/** + * Returns if the cookie is accessible only through the HTTP protocol + */ +ZEPHIR_DOC_METHOD(Phalcon_Http_CookieInterface, getHttpOnly); + diff --git a/ext/phalcon/http/cookieinterface.zep.h b/ext/phalcon/http/cookieinterface.zep.h new file mode 100644 index 00000000000..e3470a38473 --- /dev/null +++ b/ext/phalcon/http/cookieinterface.zep.h @@ -0,0 +1,58 @@ + +extern zend_class_entry *phalcon_http_cookieinterface_ce; + +ZEPHIR_INIT_CLASS(Phalcon_Http_CookieInterface); + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setvalue, 0, 0, 1) + ZEND_ARG_INFO(0, value) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_getvalue, 0, 0, 0) + ZEND_ARG_INFO(0, filters) + ZEND_ARG_INFO(0, defaultValue) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_useencryption, 0, 0, 1) + ZEND_ARG_INFO(0, useEncryption) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setexpiration, 0, 0, 1) + ZEND_ARG_INFO(0, expire) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setpath, 0, 0, 1) + ZEND_ARG_INFO(0, path) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setdomain, 0, 0, 1) + ZEND_ARG_INFO(0, domain) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_setsecure, 0, 0, 1) + ZEND_ARG_INFO(0, secure) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_cookieinterface_sethttponly, 0, 0, 1) + ZEND_ARG_INFO(0, httpOnly) +ZEND_END_ARG_INFO() + +ZEPHIR_INIT_FUNCS(phalcon_http_cookieinterface_method_entry) { + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setValue, arginfo_phalcon_http_cookieinterface_setvalue) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getValue, arginfo_phalcon_http_cookieinterface_getvalue) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, send, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, delete, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, useEncryption, arginfo_phalcon_http_cookieinterface_useencryption) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, isUsingEncryption, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setExpiration, arginfo_phalcon_http_cookieinterface_setexpiration) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getExpiration, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setPath, arginfo_phalcon_http_cookieinterface_setpath) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getName, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getPath, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setDomain, arginfo_phalcon_http_cookieinterface_setdomain) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getDomain, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setSecure, arginfo_phalcon_http_cookieinterface_setsecure) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getSecure, NULL) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, setHttpOnly, arginfo_phalcon_http_cookieinterface_sethttponly) + PHP_ABSTRACT_ME(Phalcon_Http_CookieInterface, getHttpOnly, NULL) + PHP_FE_END +}; diff --git a/ext/phalcon/http/request.zep.c b/ext/phalcon/http/request.zep.c index 2c7c58a6cf1..e1003bcbe54 100644 --- a/ext/phalcon/http/request.zep.c +++ b/ext/phalcon/http/request.zep.c @@ -143,7 +143,7 @@ PHP_METHOD(Phalcon_Http_Request, get) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -206,7 +206,7 @@ PHP_METHOD(Phalcon_Http_Request, getPost) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -275,12 +275,12 @@ PHP_METHOD(Phalcon_Http_Request, getPut) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getrawbody", NULL, 0); zephir_check_call_status(); Z_SET_ISREF_P(put); - ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 218, _0, put); + ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 219, _0, put); Z_UNSET_ISREF_P(put); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_putCache"), put TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -346,7 +346,7 @@ PHP_METHOD(Phalcon_Http_Request, getQuery) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 218, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -653,7 +653,7 @@ PHP_METHOD(Phalcon_Http_Request, getHeader) { ZVAL_STRING(&_0, "-", 0); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "_", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, header, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, header, &_0, &_1); zephir_check_call_status(); ZEPHIR_INIT_VAR(name); zephir_fast_strtoupper(name, _2); @@ -829,7 +829,7 @@ PHP_METHOD(Phalcon_Http_Request, getServerAddress) { } ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "localhost", 0); - ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 219, &_0); + ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 220, &_0); zephir_check_call_status(); RETURN_MM(); @@ -1045,7 +1045,7 @@ PHP_METHOD(Phalcon_Http_Request, isMethod) { } - ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); if (Z_TYPE_P(methods) == IS_STRING) { _0 = strict; @@ -1120,7 +1120,7 @@ PHP_METHOD(Phalcon_Http_Request, isPost) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "POST")); @@ -1136,7 +1136,7 @@ PHP_METHOD(Phalcon_Http_Request, isGet) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "GET")); @@ -1152,7 +1152,7 @@ PHP_METHOD(Phalcon_Http_Request, isPut) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PUT")); @@ -1168,7 +1168,7 @@ PHP_METHOD(Phalcon_Http_Request, isPatch) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PATCH")); @@ -1184,7 +1184,7 @@ PHP_METHOD(Phalcon_Http_Request, isHead) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "HEAD")); @@ -1200,7 +1200,7 @@ PHP_METHOD(Phalcon_Http_Request, isDelete) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "DELETE")); @@ -1216,7 +1216,7 @@ PHP_METHOD(Phalcon_Http_Request, isOptions) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 221); zephir_check_call_status(); RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "OPTIONS")); @@ -1267,7 +1267,7 @@ PHP_METHOD(Phalcon_Http_Request, hasFiles) { } } if (Z_TYPE_P(error) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 222, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); numberFiles += zephir_get_numberval(_4); } @@ -1314,7 +1314,7 @@ PHP_METHOD(Phalcon_Http_Request, hasFileHelper) { } } if (Z_TYPE_P(value) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 222, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); numberFiles += zephir_get_numberval(_4); } @@ -1366,7 +1366,7 @@ PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) { zephir_array_fetch_string(&_6, input, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC); zephir_array_fetch_string(&_7, input, SL("size"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC); zephir_array_fetch_string(&_8, input, SL("error"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 222, _4, _5, _6, _7, _8, prefix); + ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 223, _4, _5, _6, _7, _8, prefix); zephir_check_call_status(); zephir_is_iterable(smoothInput, &_11, &_10, 0, 0, "phalcon/http/request.zep", 714); for ( @@ -1400,7 +1400,7 @@ PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) { ZEPHIR_INIT_NVAR(_16); object_init_ex(_16, phalcon_http_request_file_ce); zephir_array_fetch_string(&_17, file, SL("key"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 711 TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, dataFile, _17); + ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 224, dataFile, _17); zephir_check_call_status(); zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 711); } @@ -1414,7 +1414,7 @@ PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) { if (_13) { ZEPHIR_INIT_NVAR(_16); object_init_ex(_16, phalcon_http_request_file_ce); - ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, input, prefix); + ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 224, input, prefix); zephir_check_call_status(); zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 716); } @@ -1490,7 +1490,7 @@ PHP_METHOD(Phalcon_Http_Request, smoothFiles) { zephir_array_fetch(&_7, tmp_names, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC); zephir_array_fetch(&_8, sizes, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC); zephir_array_fetch(&_9, errors, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 222, _5, _6, _7, _8, _9, p); + ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 223, _5, _6, _7, _8, _9, p); zephir_check_call_status(); zephir_is_iterable(parentFiles, &_12, &_11, 0, 0, "phalcon/http/request.zep", 755); for ( @@ -1547,7 +1547,7 @@ PHP_METHOD(Phalcon_Http_Request, getHeaders) { ZVAL_STRING(&_8, " ", 0); zephir_fast_str_replace(&_4, &_7, &_8, _6 TSRMLS_CC); zephir_fast_strtolower(_3, _4); - ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3); + ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 225, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_10); ZEPHIR_SINIT_NVAR(_11); @@ -1566,7 +1566,7 @@ PHP_METHOD(Phalcon_Http_Request, getHeaders) { ZVAL_STRING(&_7, " ", 0); zephir_fast_str_replace(&_4, &_5, &_7, name TSRMLS_CC); zephir_fast_strtolower(_3, _4); - ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3); + ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 225, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_6); ZEPHIR_SINIT_NVAR(_8); @@ -1647,7 +1647,7 @@ PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) { ZVAL_LONG(&_2, -1); ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 1); - ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 225, &_1, _0, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 226, &_1, _0, &_2, &_3); zephir_check_call_status(); zephir_is_iterable(_4, &_7, &_6, 0, 0, "phalcon/http/request.zep", 827); for ( @@ -1665,7 +1665,7 @@ PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) { ZVAL_LONG(&_2, -1); ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 1); - ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 225, &_1, _9, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 226, &_1, _9, &_2, &_3); zephir_check_call_status(); zephir_is_iterable(_10, &_12, &_11, 0, 0, "phalcon/http/request.zep", 824); for ( @@ -1805,7 +1805,7 @@ PHP_METHOD(Phalcon_Http_Request, getAcceptableContent) { ZVAL_STRING(_0, "HTTP_ACCEPT", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 227, _0, _1); zephir_check_temp_parameter(_0); zephir_check_temp_parameter(_1); zephir_check_call_status(); @@ -1827,7 +1827,7 @@ PHP_METHOD(Phalcon_Http_Request, getBestAccept) { zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 228, _0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1848,7 +1848,7 @@ PHP_METHOD(Phalcon_Http_Request, getClientCharsets) { ZVAL_STRING(_0, "HTTP_ACCEPT_CHARSET", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 227, _0, _1); zephir_check_temp_parameter(_0); zephir_check_temp_parameter(_1); zephir_check_call_status(); @@ -1870,7 +1870,7 @@ PHP_METHOD(Phalcon_Http_Request, getBestCharset) { zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 228, _0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1891,7 +1891,7 @@ PHP_METHOD(Phalcon_Http_Request, getLanguages) { ZVAL_STRING(_0, "HTTP_ACCEPT_LANGUAGE", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 227, _0, _1); zephir_check_temp_parameter(_0); zephir_check_temp_parameter(_1); zephir_check_call_status(); @@ -1913,7 +1913,7 @@ PHP_METHOD(Phalcon_Http_Request, getBestLanguage) { zephir_check_call_status(); ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 228, _0, _1); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1973,7 +1973,7 @@ PHP_METHOD(Phalcon_Http_Request, getDigestAuth) { ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 2); Z_SET_ISREF_P(matches); - ZEPHIR_CALL_FUNCTION(&_2, "preg_match_all", NULL, 27, _0, digest, matches, _1); + ZEPHIR_CALL_FUNCTION(&_2, "preg_match_all", NULL, 28, _0, digest, matches, _1); zephir_check_temp_parameter(_0); Z_UNSET_ISREF_P(matches); zephir_check_call_status(); diff --git a/ext/phalcon/http/request/file.zep.c b/ext/phalcon/http/request/file.zep.c index 91a2f7678f3..9cd738b9b8b 100644 --- a/ext/phalcon/http/request/file.zep.c +++ b/ext/phalcon/http/request/file.zep.c @@ -79,7 +79,6 @@ ZEPHIR_INIT_CLASS(Phalcon_Http_Request_File) { } /** - * @var string|null */ PHP_METHOD(Phalcon_Http_Request_File, getError) { @@ -89,7 +88,6 @@ PHP_METHOD(Phalcon_Http_Request_File, getError) { } /** - * @var string|null */ PHP_METHOD(Phalcon_Http_Request_File, getKey) { @@ -99,7 +97,6 @@ PHP_METHOD(Phalcon_Http_Request_File, getKey) { } /** - * @var string */ PHP_METHOD(Phalcon_Http_Request_File, getExtension) { @@ -132,12 +129,12 @@ PHP_METHOD(Phalcon_Http_Request_File, __construct) { zephir_update_property_this(this_ptr, SL("_name"), name TSRMLS_CC); ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "PATHINFO_EXTENSION", 0); - ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 228, &_0); + ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 229, &_0); zephir_check_call_status(); if (zephir_is_true(_1)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_LONG(&_0, 4); - ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 69, name, &_0); + ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 71, name, &_0); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_extension"), _2 TSRMLS_CC); } @@ -214,15 +211,15 @@ PHP_METHOD(Phalcon_Http_Request_File, getRealType) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 16); - ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 229, &_0); + ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 230, &_0); zephir_check_call_status(); if (Z_TYPE_P(finfo) != IS_RESOURCE) { RETURN_MM_STRING("", 1); } _1 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, finfo, _1); + ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 231, finfo, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, finfo); + ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 232, finfo); zephir_check_call_status(); RETURN_CCTOR(mime); @@ -243,7 +240,7 @@ PHP_METHOD(Phalcon_Http_Request_File, isUploadedFile) { zephir_check_call_status(); _0 = Z_TYPE_P(tmp) == IS_STRING; if (_0) { - ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 232, tmp); + ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 233, tmp); zephir_check_call_status(); _0 = zephir_is_true(_1); } @@ -277,7 +274,7 @@ PHP_METHOD(Phalcon_Http_Request_File, moveTo) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC); - ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 233, _0, destination); + ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 234, _0, destination); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/http/response.zep.c b/ext/phalcon/http/response.zep.c index 5500577d24f..a3c3bbfcab2 100644 --- a/ext/phalcon/http/response.zep.c +++ b/ext/phalcon/http/response.zep.c @@ -189,7 +189,7 @@ PHP_METHOD(Phalcon_Http_Response, setStatusCode) { if (_4) { ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "HTTP/", 0); - ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 234, key, &_5); + ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 235, key, &_5); zephir_check_call_status(); _4 = zephir_is_true(_6); } @@ -378,7 +378,7 @@ PHP_METHOD(Phalcon_Http_Response, setCookies) { /** * Returns coookies set by the user * - * @return Phalcon\Http\Response\CookiesInterface + * @return \Phalcon\Http\Response\CookiesInterface */ PHP_METHOD(Phalcon_Http_Response, getCookies) { @@ -396,7 +396,7 @@ PHP_METHOD(Phalcon_Http_Response, getCookies) { * * @param string name * @param string value - * @return Phalcon\Http\Response + * @return \Phalcon\Http\Response */ PHP_METHOD(Phalcon_Http_Response, setHeader) { @@ -589,7 +589,7 @@ PHP_METHOD(Phalcon_Http_Response, setNotModified) { * * @param string contentType * @param string charset - * @return Phalcon\Http\Response + * @return \Phalcon\Http\Response */ PHP_METHOD(Phalcon_Http_Response, setContentType) { @@ -677,7 +677,7 @@ PHP_METHOD(Phalcon_Http_Response, setEtag) { * @param string|array location * @param boolean externalRedirect * @param int statusCode - * @return Phalcon\Http\Response + * @return \Phalcon\Http\Response */ PHP_METHOD(Phalcon_Http_Response, redirect) { @@ -716,7 +716,7 @@ PHP_METHOD(Phalcon_Http_Response, redirect) { if (_0) { ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "://", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 234, location, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 235, location, &_1); zephir_check_call_status(); _0 = zephir_is_true(_2); } @@ -824,7 +824,7 @@ PHP_METHOD(Phalcon_Http_Response, setContent) { * * @param mixed content * @param int jsonOptions - * @return Phalcon\Http\Response + * @return \Phalcon\Http\Response */ PHP_METHOD(Phalcon_Http_Response, setJsonContent) { @@ -854,7 +854,7 @@ PHP_METHOD(Phalcon_Http_Response, setJsonContent) { * Appends a string to the HTTP response body * * @param string content - * @return Phalcon\Http\Response + * @return \Phalcon\Http\Response */ PHP_METHOD(Phalcon_Http_Response, appendContent) { @@ -975,7 +975,7 @@ PHP_METHOD(Phalcon_Http_Response, send) { _1 = (zephir_fast_strlen_ev(file)) ? 1 : 0; } if (_1) { - ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 235, file); + ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 236, file); zephir_check_call_status(); } } @@ -989,7 +989,7 @@ PHP_METHOD(Phalcon_Http_Response, send) { * * @param string filePath * @param string attachmentName - * @return Phalcon\Http\Response + * @return \Phalcon\Http\Response */ PHP_METHOD(Phalcon_Http_Response, setFileToSend) { diff --git a/ext/phalcon/http/response/cookies.zep.c b/ext/phalcon/http/response/cookies.zep.c index df2cf0e1111..e2e83c1b9c5 100644 --- a/ext/phalcon/http/response/cookies.zep.c +++ b/ext/phalcon/http/response/cookies.zep.c @@ -102,24 +102,17 @@ PHP_METHOD(Phalcon_Http_Response_Cookies, isUsingEncryption) { /** * Sets a cookie to be sent at the end of the request * This method overrides any cookie set before with the same name - * - * @param string name - * @param mixed value - * @param int expire - * @param string path - * @param boolean secure - * @param string domain - * @param boolean httpOnly - * @return Phalcon\Http\Response\Cookies */ PHP_METHOD(Phalcon_Http_Response_Cookies, set) { + zval *_3; + zend_bool secure, httpOnly; int expire, ZEPHIR_LAST_CALL_STATUS; - zval *name_param = NULL, *value = NULL, *expire_param = NULL, *path_param = NULL, *secure = NULL, *domain_param = NULL, *httpOnly = NULL, *cookie = NULL, *encryption, *dependencyInjector, *response = NULL, *_0, *_1 = NULL, *_2; + zval *name_param = NULL, *value = NULL, *expire_param = NULL, *path_param = NULL, *secure_param = NULL, *domain_param = NULL, *httpOnly_param = NULL, *cookie = NULL, *encryption, *dependencyInjector, *response = NULL, *_0, *_1, *_2 = NULL, *_4 = NULL, *_5; zval *name = NULL, *path = NULL, *domain = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 6, &name_param, &value, &expire_param, &path_param, &secure, &domain_param, &httpOnly); + zephir_fetch_params(1, 1, 6, &name_param, &value, &expire_param, &path_param, &secure_param, &domain_param, &httpOnly_param); if (unlikely(Z_TYPE_P(name_param) != IS_STRING && Z_TYPE_P(name_param) != IS_NULL)) { zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'name' must be a string") TSRMLS_CC); @@ -146,8 +139,10 @@ PHP_METHOD(Phalcon_Http_Response_Cookies, set) { } else { zephir_get_strval(path, path_param); } - if (!secure) { - secure = ZEPHIR_GLOBAL(global_null); + if (!secure_param) { + secure = 0; + } else { + secure = zephir_get_boolval(secure_param); } if (!domain_param) { ZEPHIR_INIT_VAR(domain); @@ -165,8 +160,10 @@ PHP_METHOD(Phalcon_Http_Response_Cookies, set) { ZVAL_EMPTY_STRING(domain); } } - if (!httpOnly) { - httpOnly = ZEPHIR_GLOBAL(global_null); + if (!httpOnly_param) { + httpOnly = 0; + } else { + httpOnly = zephir_get_boolval(httpOnly_param); } @@ -175,48 +172,64 @@ PHP_METHOD(Phalcon_Http_Response_Cookies, set) { ZEPHIR_OBS_VAR(cookie); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_cookies"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&cookie, _0, name, 0 TSRMLS_CC))) { - ZEPHIR_INIT_NVAR(cookie); - object_init_ex(cookie, phalcon_http_cookie_ce); - ZEPHIR_INIT_VAR(_1); - ZVAL_LONG(_1, expire); - ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name, value, _1, path, secure, domain, httpOnly); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); + ZEPHIR_INIT_VAR(_3); + zephir_create_array(_3, 7, 0 TSRMLS_CC); + zephir_array_fast_append(_3, name); + zephir_array_fast_append(_3, value); + ZEPHIR_INIT_VAR(_4); + ZVAL_LONG(_4, expire); + zephir_array_fast_append(_3, _4); + zephir_array_fast_append(_3, path); + ZEPHIR_INIT_NVAR(_4); + ZVAL_BOOL(_4, secure); + zephir_array_fast_append(_3, _4); + zephir_array_fast_append(_3, domain); + ZEPHIR_INIT_NVAR(_4); + ZVAL_BOOL(_4, httpOnly); + zephir_array_fast_append(_3, _4); + ZEPHIR_INIT_NVAR(_4); + ZVAL_STRING(_4, "Phalcon\\Http\\Cookie", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&_2, _1, "get", NULL, 0, _4, _3); + zephir_check_temp_parameter(_4); zephir_check_call_status(); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, _2); + ZEPHIR_CPY_WRT(cookie, _2); + _5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 0, _5); zephir_check_call_status(); if (zephir_is_true(encryption)) { - ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption); + ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 0, encryption); zephir_check_call_status(); } zephir_update_property_array(this_ptr, SL("_cookies"), name, cookie TSRMLS_CC); } else { - ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 239, value); + ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 0, value); zephir_check_call_status(); - ZEPHIR_INIT_NVAR(_1); - ZVAL_LONG(_1, expire); - ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 240, _1); + ZEPHIR_INIT_NVAR(_4); + ZVAL_LONG(_4, expire); + ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 0, _4); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 241, path); + ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 0, path); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 242, secure); + ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 0, (secure ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 243, domain); + ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 0, domain); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 244, httpOnly); + ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 0, (httpOnly ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_registered"), PH_NOISY_CC); - if (ZEPHIR_IS_FALSE_IDENTICAL(_2)) { + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_registered"), PH_NOISY_CC); + if (ZEPHIR_IS_FALSE_IDENTICAL(_1)) { ZEPHIR_OBS_VAR(dependencyInjector); zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_cookie_exception_ce, "A dependency injection object is required to access the 'response' service", "phalcon/http/response/cookies.zep", 138); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_cookie_exception_ce, "A dependency injection object is required to access the 'response' service", "phalcon/http/response/cookies.zep", 130); return; } - ZEPHIR_INIT_NVAR(_1); - ZVAL_STRING(_1, "response", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&response, dependencyInjector, "getshared", NULL, 0, _1); - zephir_check_temp_parameter(_1); + ZEPHIR_INIT_NVAR(_4); + ZVAL_STRING(_4, "response", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&response, dependencyInjector, "getshared", NULL, 0, _4); + zephir_check_temp_parameter(_4); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, response, "setcookies", NULL, 0, this_ptr); zephir_check_call_status(); @@ -231,7 +244,8 @@ PHP_METHOD(Phalcon_Http_Response_Cookies, set) { PHP_METHOD(Phalcon_Http_Response_Cookies, get) { int ZEPHIR_LAST_CALL_STATUS; - zval *name_param = NULL, *dependencyInjector, *encryption, *cookie = NULL, *_0; + zval *_3; + zval *name_param = NULL, *dependencyInjector, *encryption, *cookie = NULL, *_0, *_1, *_2 = NULL, *_4; zval *name = NULL; ZEPHIR_MM_GROW(); @@ -255,19 +269,25 @@ PHP_METHOD(Phalcon_Http_Response_Cookies, get) { if (zephir_array_isset_fetch(&cookie, _0, name, 0 TSRMLS_CC)) { RETURN_CCTOR(cookie); } - ZEPHIR_INIT_NVAR(cookie); - object_init_ex(cookie, phalcon_http_cookie_ce); - ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); + ZEPHIR_INIT_VAR(_3); + zephir_create_array(_3, 1, 0 TSRMLS_CC); + zephir_array_fast_append(_3, name); + ZEPHIR_INIT_VAR(_4); + ZVAL_STRING(_4, "Phalcon\\Http\\Cookie", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&_2, _1, "get", NULL, 0, _4, _3); + zephir_check_temp_parameter(_4); zephir_check_call_status(); + ZEPHIR_CPY_WRT(cookie, _2); ZEPHIR_OBS_VAR(dependencyInjector); zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) { - ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 0, dependencyInjector); zephir_check_call_status(); ZEPHIR_OBS_VAR(encryption); zephir_read_property_this(&encryption, this_ptr, SL("_useEncryption"), PH_NOISY_CC); if (zephir_is_true(encryption)) { - ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption); + ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 0, encryption); zephir_check_call_status(); } } @@ -362,11 +382,11 @@ PHP_METHOD(Phalcon_Http_Response_Cookies, send) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 54); + ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 55); zephir_check_call_status(); if (!(zephir_is_true(_0))) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_cookies"), PH_NOISY_CC); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/cookies.zep", 243); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/cookies.zep", 236); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) diff --git a/ext/phalcon/http/response/cookiesinterface.zep.c b/ext/phalcon/http/response/cookiesinterface.zep.c index 45d8413941b..29d0eb6e45a 100644 --- a/ext/phalcon/http/response/cookiesinterface.zep.c +++ b/ext/phalcon/http/response/cookiesinterface.zep.c @@ -37,15 +37,6 @@ ZEPHIR_DOC_METHOD(Phalcon_Http_Response_CookiesInterface, isUsingEncryption); /** * Sets a cookie to be sent at the end of the request - * - * @param string name - * @param mixed value - * @param int expire - * @param string path - * @param boolean secure - * @param string domain - * @param boolean httpOnly - * @return Phalcon\Http\Response\CookiesInterface */ ZEPHIR_DOC_METHOD(Phalcon_Http_Response_CookiesInterface, set); diff --git a/ext/phalcon/http/response/headers.zep.c b/ext/phalcon/http/response/headers.zep.c index 100e5b1900d..d92f6799a58 100644 --- a/ext/phalcon/http/response/headers.zep.c +++ b/ext/phalcon/http/response/headers.zep.c @@ -13,9 +13,9 @@ #include "kernel/main.h" #include "kernel/object.h" +#include "kernel/operators.h" #include "kernel/memory.h" #include "kernel/array.h" -#include "kernel/operators.h" #include "kernel/fcall.h" #include "kernel/hash.h" #include "kernel/concat.h" @@ -43,65 +43,67 @@ ZEPHIR_INIT_CLASS(Phalcon_Http_Response_Headers) { /** * Sets a header to be sent at the end of the request - * - * @param string name - * @param string value */ PHP_METHOD(Phalcon_Http_Response_Headers, set) { - zval *name, *value; + zval *name_param = NULL, *value_param = NULL; + zval *name = NULL, *value = NULL; - zephir_fetch_params(0, 2, 0, &name, &value); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 2, 0, &name_param, &value_param); + zephir_get_strval(name, name_param); + zephir_get_strval(value, value_param); zephir_update_property_array(this_ptr, SL("_headers"), name, value TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } /** * Gets a header value from the internal bag - * - * @param string name - * @return string */ PHP_METHOD(Phalcon_Http_Response_Headers, get) { - zval *name, *headers, *headerValue; + zval *name_param = NULL, *headers, *headerValue; + zval *name = NULL; - zephir_fetch_params(0, 1, 0, &name); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &name_param); + zephir_get_strval(name, name_param); headers = zephir_fetch_nproperty_this(this_ptr, SL("_headers"), PH_NOISY_CC); if (zephir_array_isset_fetch(&headerValue, headers, name, 1 TSRMLS_CC)) { - RETURN_CTORW(headerValue); + RETURN_CTOR(headerValue); } - RETURN_BOOL(0); + RETURN_MM_BOOL(0); } /** * Sets a raw header to be sent at the end of the request - * - * @param string header */ PHP_METHOD(Phalcon_Http_Response_Headers, setRaw) { - zval *header; + zval *header_param = NULL; + zval *header = NULL; - zephir_fetch_params(0, 1, 0, &header); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &header_param); + zephir_get_strval(header, header_param); zephir_update_property_array(this_ptr, SL("_headers"), header, ZEPHIR_GLOBAL(global_null) TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } /** * Removes a header to be sent at the end of the request - * - * @param string header Header name */ PHP_METHOD(Phalcon_Http_Response_Headers, remove) { @@ -135,11 +137,11 @@ PHP_METHOD(Phalcon_Http_Response_Headers, send) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 54); + ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 55); zephir_check_call_status(); if (!(zephir_is_true(_0))) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_headers"), PH_NOISY_CC); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/headers.zep", 98); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/http/response/headers.zep", 90); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -149,10 +151,10 @@ PHP_METHOD(Phalcon_Http_Response_Headers, send) { if (!(ZEPHIR_IS_EMPTY(value))) { ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_VSV(_5, header, ": ", value); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, _5, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 237, _5, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); } else { - ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, header, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 237, header, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); } } @@ -189,7 +191,7 @@ PHP_METHOD(Phalcon_Http_Response_Headers, toArray) { } /** - * Restore a Phalcon\Http\Response\Headers object + * Restore a \Phalcon\Http\Response\Headers object */ PHP_METHOD(Phalcon_Http_Response_Headers, __set_state) { @@ -215,14 +217,14 @@ PHP_METHOD(Phalcon_Http_Response_Headers, __set_state) { } ZEPHIR_OBS_VAR(dataHeaders); if (zephir_array_isset_string_fetch(&dataHeaders, data, SS("_headers"), 0 TSRMLS_CC)) { - zephir_is_iterable(dataHeaders, &_1, &_0, 0, 0, "phalcon/http/response/headers.zep", 130); + zephir_is_iterable(dataHeaders, &_1, &_0, 0, 0, "phalcon/http/response/headers.zep", 122); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HMKEY(key, _1, _0); ZEPHIR_GET_HVALUE(value, _2); - ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 246, key, value); + ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 238, key, value); zephir_check_call_status(); } } diff --git a/ext/phalcon/http/response/headersinterface.zep.c b/ext/phalcon/http/response/headersinterface.zep.c index f8b6f18a995..73df55549e9 100644 --- a/ext/phalcon/http/response/headersinterface.zep.c +++ b/ext/phalcon/http/response/headersinterface.zep.c @@ -27,24 +27,16 @@ ZEPHIR_INIT_CLASS(Phalcon_Http_Response_HeadersInterface) { /** * Sets a header to be sent at the end of the request - * - * @param string name - * @param string value */ ZEPHIR_DOC_METHOD(Phalcon_Http_Response_HeadersInterface, set); /** * Gets a header value from the internal bag - * - * @param string name - * @return string */ ZEPHIR_DOC_METHOD(Phalcon_Http_Response_HeadersInterface, get); /** * Sets a raw header to be sent at the end of the request - * - * @param string header */ ZEPHIR_DOC_METHOD(Phalcon_Http_Response_HeadersInterface, setRaw); @@ -59,7 +51,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Http_Response_HeadersInterface, send); ZEPHIR_DOC_METHOD(Phalcon_Http_Response_HeadersInterface, reset); /** - * Restore a Phalcon\Http\Response\Headers object + * Restore a \Phalcon\Http\Response\Headers object */ ZEPHIR_DOC_METHOD(Phalcon_Http_Response_HeadersInterface, __set_state); diff --git a/ext/phalcon/http/responseinterface.zep.c b/ext/phalcon/http/responseinterface.zep.c index b2d57c17cf1..247c927b11d 100644 --- a/ext/phalcon/http/responseinterface.zep.c +++ b/ext/phalcon/http/responseinterface.zep.c @@ -40,7 +40,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Http_ResponseInterface, getHeaders); * * @param string name * @param string value - * @return Phalcon\Http\ResponseInterface + * @return \Phalcon\Http\ResponseInterface */ ZEPHIR_DOC_METHOD(Phalcon_Http_ResponseInterface, setHeader); @@ -69,7 +69,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Http_ResponseInterface, setNotModified); * * @param string contentType * @param string charset - * @return Phalcon\Http\ResponseInterface + * @return \Phalcon\Http\ResponseInterface */ ZEPHIR_DOC_METHOD(Phalcon_Http_ResponseInterface, setContentType); @@ -79,7 +79,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Http_ResponseInterface, setContentType); * @param string location * @param boolean externalRedirect * @param int statusCode - * @return Phalcon\Http\ResponseInterface + * @return \Phalcon\Http\ResponseInterface */ ZEPHIR_DOC_METHOD(Phalcon_Http_ResponseInterface, redirect); @@ -96,7 +96,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Http_ResponseInterface, setContent); * * * @param string content - * @return Phalcon\Http\ResponseInterface + * @return \Phalcon\Http\ResponseInterface */ ZEPHIR_DOC_METHOD(Phalcon_Http_ResponseInterface, setJsonContent); @@ -104,7 +104,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Http_ResponseInterface, setJsonContent); * Appends a string to the HTTP response body * * @param string content - * @return Phalcon\Http\ResponseInterface + * @return \Phalcon\Http\ResponseInterface */ ZEPHIR_DOC_METHOD(Phalcon_Http_ResponseInterface, appendContent); diff --git a/ext/phalcon/image/adapter.zep.c b/ext/phalcon/image/adapter.zep.c index f9d6ea42db5..1750552ce33 100644 --- a/ext/phalcon/image/adapter.zep.c +++ b/ext/phalcon/image/adapter.zep.c @@ -89,8 +89,6 @@ PHP_METHOD(Phalcon_Image_Adapter, getRealpath) { /** * Image width - * - * @var int */ PHP_METHOD(Phalcon_Image_Adapter, getWidth) { @@ -101,8 +99,6 @@ PHP_METHOD(Phalcon_Image_Adapter, getWidth) { /** * Image height - * - * @var int */ PHP_METHOD(Phalcon_Image_Adapter, getHeight) { @@ -114,9 +110,9 @@ PHP_METHOD(Phalcon_Image_Adapter, getHeight) { /** * Image type * + * * Driver dependent * - * @var int */ PHP_METHOD(Phalcon_Image_Adapter, getType) { @@ -127,8 +123,6 @@ PHP_METHOD(Phalcon_Image_Adapter, getType) { /** * Image mime type - * - * @var string */ PHP_METHOD(Phalcon_Image_Adapter, getMime) { @@ -288,7 +282,7 @@ PHP_METHOD(Phalcon_Image_Adapter, resize) { zephir_round(_8, &_9, NULL, NULL TSRMLS_CC); ZEPHIR_INIT_VAR(_10); ZVAL_LONG(_10, 1); - ZEPHIR_CALL_FUNCTION(&_11, "max", &_12, 66, _8, _10); + ZEPHIR_CALL_FUNCTION(&_11, "max", &_12, 68, _8, _10); zephir_check_call_status(); width = zephir_get_intval(_11); ZEPHIR_INIT_NVAR(_10); @@ -297,7 +291,7 @@ PHP_METHOD(Phalcon_Image_Adapter, resize) { zephir_round(_10, &_13, NULL, NULL TSRMLS_CC); ZEPHIR_INIT_VAR(_14); ZVAL_LONG(_14, 1); - ZEPHIR_CALL_FUNCTION(&_15, "max", &_12, 66, _10, _14); + ZEPHIR_CALL_FUNCTION(&_15, "max", &_12, 68, _10, _14); zephir_check_call_status(); height = zephir_get_intval(_15); ZEPHIR_INIT_NVAR(_14); @@ -652,23 +646,19 @@ PHP_METHOD(Phalcon_Image_Adapter, watermark) { PHP_METHOD(Phalcon_Image_Adapter, text) { zend_bool _0; - int offsetX, offsetY, opacity, size, ZEPHIR_LAST_CALL_STATUS; - zval *text_param = NULL, *offsetX_param = NULL, *offsetY_param = NULL, *opacity_param = NULL, *color_param = NULL, *size_param = NULL, *fontfile_param = NULL, *colors = NULL, _1, _2, *_3, _4 = zval_used_for_init, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8, *_9, *_10, *_11, *_12; + int opacity, size, ZEPHIR_LAST_CALL_STATUS; + zval *text_param = NULL, *offsetX = NULL, *offsetY = NULL, *opacity_param = NULL, *color_param = NULL, *size_param = NULL, *fontfile_param = NULL, *colors = NULL, _1, _2, *_3, _4 = zval_used_for_init, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8, *_9, *_10; zval *text = NULL, *color = NULL, *fontfile = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 6, &text_param, &offsetX_param, &offsetY_param, &opacity_param, &color_param, &size_param, &fontfile_param); + zephir_fetch_params(1, 1, 6, &text_param, &offsetX, &offsetY, &opacity_param, &color_param, &size_param, &fontfile_param); zephir_get_strval(text, text_param); - if (!offsetX_param) { - offsetX = 0; - } else { - offsetX = zephir_get_intval(offsetX_param); + if (!offsetX) { + offsetX = ZEPHIR_GLOBAL(global_false); } - if (!offsetY_param) { - offsetY = 0; - } else { - offsetY = zephir_get_intval(offsetY_param); + if (!offsetY) { + offsetY = ZEPHIR_GLOBAL(global_false); } if (!opacity_param) { opacity = 100; @@ -696,8 +686,10 @@ PHP_METHOD(Phalcon_Image_Adapter, text) { if (opacity < 0) { opacity = 0; - } else if (opacity > 100) { - opacity = 100; + } else { + if (opacity > 100) { + opacity = 100; + } } _0 = zephir_fast_strlen_ev(color) > 1; if (_0) { @@ -721,7 +713,7 @@ PHP_METHOD(Phalcon_Image_Adapter, text) { ZVAL_STRING(_5, "/./", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "$0$0", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 28, _5, _6, color); + ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 29, _5, _6, color); zephir_check_temp_parameter(_5); zephir_check_temp_parameter(_6); zephir_check_call_status(); @@ -729,24 +721,20 @@ PHP_METHOD(Phalcon_Image_Adapter, text) { } ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 2); - ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 67, color, &_4); + ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 69, color, &_4); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_STRING(&_4, "hexdec", 0); - ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 68, &_4, _7); + ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 70, &_4, _7); zephir_check_call_status(); - zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 333 TSRMLS_CC); - zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 333 TSRMLS_CC); - zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 333 TSRMLS_CC); + zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 335 TSRMLS_CC); + zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 335 TSRMLS_CC); + zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 335 TSRMLS_CC); ZEPHIR_INIT_NVAR(_5); - ZVAL_LONG(_5, offsetX); + ZVAL_LONG(_5, opacity); ZEPHIR_INIT_NVAR(_6); - ZVAL_LONG(_6, offsetY); - ZEPHIR_INIT_VAR(_11); - ZVAL_LONG(_11, opacity); - ZEPHIR_INIT_VAR(_12); - ZVAL_LONG(_12, size); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_text", NULL, 0, text, _5, _6, _11, _8, _9, _10, _12, fontfile); + ZVAL_LONG(_6, size); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_text", NULL, 0, text, offsetX, offsetY, _5, _8, _9, _10, _6, fontfile); zephir_check_call_status(); RETURN_THIS(); @@ -814,7 +802,7 @@ PHP_METHOD(Phalcon_Image_Adapter, background) { ZVAL_STRING(_5, "/./", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "$0$0", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 28, _5, _6, color); + ZEPHIR_CALL_FUNCTION(&_7, "preg_replace", NULL, 29, _5, _6, color); zephir_check_temp_parameter(_5); zephir_check_temp_parameter(_6); zephir_check_call_status(); @@ -822,15 +810,15 @@ PHP_METHOD(Phalcon_Image_Adapter, background) { } ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 2); - ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 67, color, &_4); + ZEPHIR_CALL_FUNCTION(&_7, "str_split", NULL, 69, color, &_4); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_STRING(&_4, "hexdec", 0); - ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 68, &_4, _7); + ZEPHIR_CALL_FUNCTION(&colors, "array_map", NULL, 70, &_4, _7); zephir_check_call_status(); - zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 364 TSRMLS_CC); - zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 364 TSRMLS_CC); - zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 364 TSRMLS_CC); + zephir_array_fetch_long(&_8, colors, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 366 TSRMLS_CC); + zephir_array_fetch_long(&_9, colors, 1, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 366 TSRMLS_CC); + zephir_array_fetch_long(&_10, colors, 2, PH_NOISY | PH_READONLY, "phalcon/image/adapter.zep", 366 TSRMLS_CC); ZEPHIR_INIT_NVAR(_5); ZVAL_LONG(_5, opacity); ZEPHIR_CALL_METHOD(NULL, this_ptr, "_background", NULL, 0, _8, _9, _10, _5); @@ -964,7 +952,7 @@ PHP_METHOD(Phalcon_Image_Adapter, render) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 4); - ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 69, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "pathinfo", NULL, 71, _0, &_1); zephir_check_call_status(); zephir_get_strval(_3, _2); ZEPHIR_CPY_WRT(ext, _3); diff --git a/ext/phalcon/image/adapter/gd.zep.c b/ext/phalcon/image/adapter/gd.zep.c index e255c7734b7..5221c63489d 100644 --- a/ext/phalcon/image/adapter/gd.zep.c +++ b/ext/phalcon/image/adapter/gd.zep.c @@ -55,13 +55,13 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, check) { ZVAL_NULL(version); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "GD_VERSION", 0); - ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 228, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 229, &_1); zephir_check_call_status(); if (zephir_is_true(_2)) { ZEPHIR_INIT_NVAR(version); ZEPHIR_GET_CONSTANT(version, "GD_VERSION"); } else { - ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 247); + ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 239); zephir_check_call_status(); ZEPHIR_INIT_VAR(matches); ZVAL_NULL(matches); @@ -79,7 +79,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, check) { ZVAL_STRING(&_5, "2.0.1", 0); ZEPHIR_SINIT_VAR(_6); ZVAL_STRING(&_6, ">=", 0); - ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 248, version, &_5, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 240, version, &_5, &_6); zephir_check_call_status(); if (!(zephir_is_true(_7))) { ZEPHIR_INIT_NVAR(_3); @@ -141,11 +141,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); if ((zephir_file_exists(_1 TSRMLS_CC) == SUCCESS)) { _2 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_3, "realpath", NULL, 60, _2); + ZEPHIR_CALL_FUNCTION(&_3, "realpath", NULL, 62, _2); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_realpath"), _3 TSRMLS_CC); _4 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 249, _4); + ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 241, _4); zephir_check_call_status(); if (zephir_is_true(imageinfo)) { zephir_array_fetch_long(&_5, imageinfo, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 77 TSRMLS_CC); @@ -161,35 +161,35 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { do { if (ZEPHIR_IS_LONG(_9, 1)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 250, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 242, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 2)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 251, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 243, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 3)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 252, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 244, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 15)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 253, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 245, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(_9, 16)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 254, _10); + ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 246, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC); break; @@ -214,7 +214,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { } while(0); _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _10, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 247, _10, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); } else { _16 = !width; @@ -237,14 +237,14 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) { ZVAL_LONG(&_17, width); ZEPHIR_SINIT_VAR(_18); ZVAL_LONG(&_18, height); - ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 256, &_17, &_18); + ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 248, &_17, &_18); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), _3 TSRMLS_CC); _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _4, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, _4, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _9, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 247, _9, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); zephir_update_property_this(this_ptr, SL("_realpath"), _10 TSRMLS_CC); @@ -283,7 +283,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION"); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "5.5.0", 0); - ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 240, _0, &_1); zephir_check_call_status(); if (ZEPHIR_LT_LONG(_2, 0)) { ZEPHIR_OBS_VAR(pre_width); @@ -331,11 +331,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZVAL_LONG(&_14, 0); ZEPHIR_SINIT_VAR(_15); ZVAL_LONG(&_15, 0); - ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 258, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11); + ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 250, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11); zephir_check_call_status(); if (zephir_is_true(_16)) { _17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _17); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 251, _17); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); } @@ -359,17 +359,17 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZVAL_LONG(&_15, width); ZEPHIR_SINIT_VAR(_21); ZVAL_LONG(&_21, height); - ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 260, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height); + ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 252, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height); zephir_check_call_status(); if (zephir_is_true(_16)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _10); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 251, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 261, image); + ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _22 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 262, image); + ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _24 TSRMLS_CC); } @@ -379,16 +379,16 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) { ZVAL_LONG(&_6, width); ZEPHIR_SINIT_NVAR(_12); ZVAL_LONG(&_12, height); - ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 263, _3, &_6, &_12); + ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 255, _3, &_6, &_12); zephir_check_call_status(); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _5); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 251, _5); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 261, image); + ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 262, image); + ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _22 TSRMLS_CC); } @@ -415,7 +415,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) { ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION"); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "5.5.0", 0); - ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 240, _0, &_1); zephir_check_call_status(); if (ZEPHIR_LT_LONG(_2, 0)) { ZEPHIR_INIT_VAR(_3); @@ -441,17 +441,17 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) { ZVAL_LONG(&_11, width); ZEPHIR_SINIT_VAR(_12); ZVAL_LONG(&_12, height); - ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 260, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12); + ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 252, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12); zephir_check_call_status(); if (zephir_is_true(_13)) { _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 251, _14); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 261, image); + ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 262, image); + ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _18 TSRMLS_CC); } @@ -471,16 +471,16 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) { ZVAL_LONG(_3, height); zephir_array_update_string(&rect, SL("height"), &_3, PH_COPY | PH_SEPARATE); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 264, _5, rect); + ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 256, _5, rect); zephir_check_call_status(); _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 251, _14); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 261, image); + ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _13 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 262, image); + ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _16 TSRMLS_CC); } @@ -508,20 +508,20 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) { ZVAL_LONG(&_3, 0); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, 127); - ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 265, _0, &_1, &_2, &_3, &_4); + ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 257, _0, &_1, &_2, &_3, &_4); zephir_check_call_status(); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (360 - degrees)); ZEPHIR_SINIT_NVAR(_2); ZVAL_LONG(&_2, 1); - ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 266, _5, &_1, transparent, &_2); + ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 258, _5, &_1, transparent, &_2); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 247, image, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 261, image); + ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 253, image); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 262, image); + ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 254, image); zephir_check_call_status(); _6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); @@ -534,11 +534,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) { ZVAL_LONG(&_4, 0); ZEPHIR_SINIT_VAR(_7); ZVAL_LONG(&_7, 100); - ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 267, _6, image, &_1, &_2, &_3, &_4, width, height, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 259, _6, image, &_1, &_2, &_3, &_4, width, height, &_7); zephir_check_call_status(); if (zephir_is_true(_8)) { _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _9); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _9); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_width"), width TSRMLS_CC); @@ -564,7 +564,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION"); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "5.5.0", 0); - ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 240, _0, &_1); zephir_check_call_status(); if (ZEPHIR_LT_LONG(_2, 0)) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); @@ -592,7 +592,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { ZVAL_LONG(&_11, 0); ZEPHIR_SINIT_NVAR(_12); ZVAL_LONG(&_12, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, &_12, _8); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, image, _6, &_1, &_9, &_10, &_11, &_12, _8); zephir_check_call_status(); } } else { @@ -616,18 +616,18 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { ZVAL_LONG(&_11, ((zephir_get_numberval(_7) - x) - 1)); ZEPHIR_SINIT_NVAR(_12); ZVAL_LONG(&_12, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, _8, &_12); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, image, _6, &_1, &_9, &_10, &_11, _8, &_12); zephir_check_call_status(); } } _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _5); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _5); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 261, image); + ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 253, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _14 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 262, image); + ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 254, image); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _15 TSRMLS_CC); } else { @@ -635,13 +635,13 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _3, &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 261, _3, &_1); zephir_check_call_status(); } else { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 2); - ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _4, &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 261, _4, &_1); zephir_check_call_status(); } } @@ -664,7 +664,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) { ZEPHIR_INIT_VAR(_0); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, (-18 + ((amount * 0.08)))); - ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 193, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 2); @@ -713,15 +713,15 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) { ZVAL_LONG(&_6, (amount - 8)); ZEPHIR_SINIT_VAR(_7); ZVAL_LONG(&_7, 0); - ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 270, _5, matrix, &_6, &_7); + ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 262, _5, matrix, &_6, &_7); zephir_check_call_status(); if (zephir_is_true(_8)) { _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 261, _9); + ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 253, _9); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _10 TSRMLS_CC); _11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 262, _11); + ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 254, _11); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _12 TSRMLS_CC); } @@ -747,7 +747,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZEPHIR_INIT_VAR(_0); ZEPHIR_SINIT_VAR(_1); ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127))); - ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 193, &_1); zephir_check_call_status(); zephir_round(_0, _2, NULL, NULL TSRMLS_CC); opacity = zephir_get_intval(_0); @@ -773,7 +773,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_11, 0); ZEPHIR_SINIT_VAR(_12); ZVAL_LONG(&_12, 0); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, _7, &_1, &_10, &_11, &_12, _8, _9); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, reflection, _7, &_1, &_10, &_11, &_12, _8, _9); zephir_check_call_status(); offset = 0; while (1) { @@ -814,7 +814,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_21, src_y); ZEPHIR_SINIT_NVAR(_22); ZVAL_LONG(&_22, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, line, _18, &_11, &_12, &_20, &_21, _19, &_22); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, line, _18, &_11, &_12, &_20, &_21, _19, &_22); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_11); ZVAL_LONG(&_11, 4); @@ -826,7 +826,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_21, 0); ZEPHIR_SINIT_NVAR(_22); ZVAL_LONG(&_22, dst_opacity); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 271, line, &_11, &_12, &_20, &_21, &_22); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 263, line, &_11, &_12, &_20, &_21, &_22); zephir_check_call_status(); _24 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_11); @@ -839,18 +839,18 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) { ZVAL_LONG(&_21, 0); ZEPHIR_SINIT_NVAR(_22); ZVAL_LONG(&_22, 1); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, line, &_11, &_12, &_20, &_21, _24, &_22); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 260, reflection, line, &_11, &_12, &_20, &_21, _24, &_22); zephir_check_call_status(); offset++; } _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _14); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), reflection TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 261, reflection); + ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 253, reflection); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_width"), _25 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 262, reflection); + ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 254, reflection); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_height"), _26 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -872,21 +872,21 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZEPHIR_CALL_METHOD(&_0, watermark, "render", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 272, _0); + ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 264, _0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, overlay, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 247, overlay, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, overlay); + ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 253, overlay); zephir_check_call_status(); width = zephir_get_intval(_1); - ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, overlay); + ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 254, overlay); zephir_check_call_status(); height = zephir_get_intval(_2); if (opacity < 100) { ZEPHIR_INIT_VAR(_3); ZEPHIR_SINIT_VAR(_4); ZVAL_DOUBLE(&_4, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127))); - ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 192, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 193, &_4); zephir_check_call_status(); zephir_round(_3, _5, NULL, NULL TSRMLS_CC); opacity = zephir_get_intval(_3); @@ -898,11 +898,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZVAL_LONG(&_7, 127); ZEPHIR_SINIT_VAR(_8); ZVAL_LONG(&_8, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, overlay, &_4, &_6, &_7, &_8); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 257, overlay, &_4, &_6, &_7, &_8); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 3); - ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 273, overlay, &_4); + ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 265, overlay, &_4); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 0); @@ -912,11 +912,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZVAL_LONG(&_7, width); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, height); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 274, overlay, &_4, &_6, &_7, &_8, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 266, overlay, &_4, &_6, &_7, &_8, color); zephir_check_call_status(); } _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _9, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, _9, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_4); @@ -931,10 +931,10 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) { ZVAL_LONG(&_11, width); ZEPHIR_SINIT_VAR(_12); ZVAL_LONG(&_12, height); - ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 268, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12); + ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 260, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12); zephir_check_call_status(); if (zephir_is_true(_5)) { - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, overlay); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, overlay); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -966,7 +966,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZEPHIR_INIT_VAR(_0); ZEPHIR_SINIT_VAR(_1); ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127))); - ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 193, &_1); zephir_check_call_status(); zephir_round(_0, _2, NULL, NULL TSRMLS_CC); opacity = zephir_get_intval(_0); @@ -975,7 +975,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_1, size); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, 0); - ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 275, &_1, &_4, fontfile, text); + ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 267, &_1, &_4, fontfile, text); zephir_check_call_status(); if (zephir_array_isset_long(space, 0)) { ZEPHIR_OBS_VAR(_5); @@ -1009,12 +1009,12 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { } ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (s4 - s0)); - ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 193, &_1); zephir_check_call_status(); width = (zephir_get_numberval(_12) + 10); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, (s5 - s1)); - ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 192, &_1); + ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 193, &_1); zephir_check_call_status(); height = (zephir_get_numberval(_13) + 10); if (offsetX < 0) { @@ -1034,7 +1034,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_15, b); ZEPHIR_SINIT_VAR(_16); ZVAL_LONG(&_16, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 257, _14, &_1, &_4, &_15, &_16); zephir_check_call_status(); angle = 0; _18 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -1046,17 +1046,17 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_15, offsetX); ZEPHIR_SINIT_NVAR(_16); ZVAL_LONG(&_16, offsetY); - ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 276, _18, &_1, &_4, &_15, &_16, color, fontfile, text); + ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 268, _18, &_1, &_4, &_15, &_16, color, fontfile, text); zephir_check_call_status(); } else { ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, size); - ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 277, &_1); + ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 269, &_1); zephir_check_call_status(); width = (zephir_get_intval(_12) * zephir_fast_strlen_ev(text)); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, size); - ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 278, &_1); + ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 270, &_1); zephir_check_call_status(); height = zephir_get_intval(_13); if (offsetX < 0) { @@ -1076,7 +1076,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_15, b); ZEPHIR_SINIT_NVAR(_16); ZVAL_LONG(&_16, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 257, _14, &_1, &_4, &_15, &_16); zephir_check_call_status(); _19 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); @@ -1085,7 +1085,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) { ZVAL_LONG(&_4, offsetX); ZEPHIR_SINIT_NVAR(_15); ZVAL_LONG(&_15, offsetY); - ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 279, _19, &_1, &_4, &_15, text, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 271, _19, &_1, &_4, &_15, text, color); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); @@ -1106,22 +1106,22 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZEPHIR_CALL_METHOD(&_0, mask, "render", NULL, 0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 272, _0); + ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 264, _0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, maskImage); + ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 253, maskImage); zephir_check_call_status(); mask_width = zephir_get_intval(_1); - ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, maskImage); + ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 254, maskImage); zephir_check_call_status(); mask_height = zephir_get_intval(_2); alpha = 127; - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, maskImage, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 247, maskImage, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _4 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); ZEPHIR_CALL_METHOD(&newimage, this_ptr, "_create", NULL, 0, _4, _5); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, newimage, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 247, newimage, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_6); ZVAL_LONG(&_6, 0); @@ -1131,13 +1131,13 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_8, 0); ZEPHIR_SINIT_VAR(_9); ZVAL_LONG(&_9, alpha); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, &_6, &_7, &_8, &_9); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 257, newimage, &_6, &_7, &_8, &_9); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_6); ZVAL_LONG(&_6, 0); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, 0); - ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 280, newimage, &_6, &_7, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 272, newimage, &_6, &_7, color); zephir_check_call_status(); _11 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _12 = !ZEPHIR_IS_LONG(_11, mask_width); @@ -1148,7 +1148,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { if (_12) { _14 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _15 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 256, _14, _15); + ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 248, _14, _15); zephir_check_call_status(); _16 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); _17 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); @@ -1164,9 +1164,9 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_18, mask_width); ZEPHIR_SINIT_VAR(_19); ZVAL_LONG(&_19, mask_height); - ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 260, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19); + ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 252, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 251, maskImage); zephir_check_call_status(); ZEPHIR_CPY_WRT(maskImage, tempImage); } @@ -1186,9 +1186,9 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_6, x); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, y); - ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, maskImage, &_6, &_7); + ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 273, maskImage, &_6, &_7); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, maskImage, index); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 274, maskImage, index); zephir_check_call_status(); if (zephir_array_isset_string(color, SS("red"))) { zephir_array_fetch_string(&_23, color, SL("red"), PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 431 TSRMLS_CC); @@ -1201,10 +1201,10 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { ZVAL_LONG(&_7, x); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, y); - ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, _16, &_7, &_8); + ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 273, _16, &_7, &_8); zephir_check_call_status(); _17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, _17, index); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 274, _17, index); zephir_check_call_status(); ZEPHIR_OBS_NVAR(r); zephir_array_fetch_string(&r, color, SL("red"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC); @@ -1214,22 +1214,22 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) { zephir_array_fetch_string(&b, color, SL("blue"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, alpha); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, r, g, b, &_7); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 257, newimage, r, g, b, &_7); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_7); ZVAL_LONG(&_7, x); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, y); - ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 283, newimage, &_7, &_8, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 275, newimage, &_7, &_8, color); zephir_check_call_status(); y++; } x++; } _14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, _14); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 251, _14); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 251, maskImage); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), newimage TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -1263,9 +1263,9 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) { ZVAL_LONG(&_4, b); ZEPHIR_SINIT_VAR(_5); ZVAL_LONG(&_5, opacity); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, background, &_2, &_3, &_4, &_5); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 257, background, &_2, &_3, &_4, &_5); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, background, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, background, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); _6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC); @@ -1278,11 +1278,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) { ZVAL_LONG(&_4, 0); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, 0); - ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 268, background, _6, &_2, &_3, &_4, &_5, _7, _8); + ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 260, background, _6, &_2, &_3, &_4, &_5, _7, _8); zephir_check_call_status(); if (zephir_is_true(_9)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _10); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, _10); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_image"), background TSRMLS_CC); } @@ -1310,7 +1310,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _blur) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 7); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 271, _0, &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 263, _0, &_1); zephir_check_call_status(); i++; } @@ -1349,7 +1349,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) { ZVAL_LONG(&_3, x1); ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, y1); - ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 281, _2, &_3, &_4); + ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 273, _2, &_3, &_4); zephir_check_call_status(); x2 = (x + amount); y2 = (y + amount); @@ -1362,7 +1362,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) { ZVAL_LONG(&_7, x2); ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, y2); - ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 274, _6, &_3, &_4, &_7, &_8, color); + ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 266, _6, &_3, &_4, &_7, &_8, color); zephir_check_call_status(); y += amount; } @@ -1375,9 +1375,9 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) { PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) { zend_bool _8; - zephir_fcall_cache_entry *_3 = NULL, *_6 = NULL; + zephir_fcall_cache_entry *_4 = NULL, *_6 = NULL; int quality, ZEPHIR_LAST_CALL_STATUS; - zval *file_param = NULL, *quality_param = NULL, *ext, _0 = zval_used_for_init, *_1 = NULL, *_2 = NULL, *_4, *_5 = NULL, *_7, *_9 = NULL, *_10 = NULL, *_11, *_12; + zval *file_param = NULL, *quality_param = NULL, *ext = NULL, _0 = zval_used_for_init, *_1, *_2 = NULL, *_3 = NULL, *_5 = NULL, *_7, *_9 = NULL, *_10 = NULL, *_11; zval *file = NULL; ZEPHIR_MM_GROW(); @@ -1389,112 +1389,118 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 4); - ZEPHIR_CALL_FUNCTION(&_1, "pathinfo", NULL, 69, file, &_0); + ZEPHIR_CALL_FUNCTION(&ext, "pathinfo", NULL, 71, file, &_0); zephir_check_call_status(); - ZEPHIR_INIT_VAR(ext); - zephir_fast_strtolower(ext, _1); + if (!(zephir_is_true(ext))) { + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&ext, "image_type_to_extension", NULL, 276, _1, ZEPHIR_GLOBAL(global_false)); + zephir_check_call_status(); + } + ZEPHIR_INIT_VAR(_2); + zephir_fast_strtolower(_2, ext); + ZEPHIR_CPY_WRT(ext, _2); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_3, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); - if (ZEPHIR_IS_LONG(_2, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 1); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 285, _4); + if (ZEPHIR_IS_LONG(_3, 0)) { + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 1); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _5 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 279, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); _8 = ZEPHIR_IS_LONG(_5, 0); if (!(_8)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); _8 = ZEPHIR_IS_LONG(_9, 0); } if (_8) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 2); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 2); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_LONG(&_0, quality); - ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _7, file, &_0); + ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 280, _7, file, &_0); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "png", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_5, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 3); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 3); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 281, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "wbmp", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_5, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 15); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 15); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 282, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "xbm", 0); - ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_4, 277, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_5, 0)) { - ZEPHIR_INIT_ZVAL_NREF(_4); - ZVAL_LONG(_4, 16); - zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4); + ZEPHIR_INIT_ZVAL_NREF(_1); + ZVAL_LONG(_1, 16); + zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC); + ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 278, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC); _7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _7, file); + ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 283, _7, file); zephir_check_call_status(); RETURN_MM_BOOL(1); } + ZEPHIR_INIT_NVAR(_2); + object_init_ex(_2, phalcon_image_exception_ce); ZEPHIR_INIT_VAR(_11); - object_init_ex(_11, phalcon_image_exception_ce); - ZEPHIR_INIT_VAR(_12); - ZEPHIR_CONCAT_SVS(_12, "Installed GD does not support '", ext, "' images"); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", NULL, 9, _12); + ZEPHIR_CONCAT_SVS(_11, "Installed GD does not support '", ext, "' images"); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _11); zephir_check_call_status(); - zephir_throw_exception_debug(_11, "phalcon/image/adapter/gd.zep", 537 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/image/adapter/gd.zep", 544 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -1518,29 +1524,29 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) { ZEPHIR_INIT_VAR(_0); zephir_fast_strtolower(_0, ext); zephir_get_strval(ext, _0); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_2, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _4); + ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 279, _4); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG(_6, 0); if (!(_7)) { ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG(_8, 0); } @@ -1548,45 +1554,45 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, quality); - ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _4, ZEPHIR_GLOBAL(global_null), &_1); + ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 280, _4, ZEPHIR_GLOBAL(global_null), &_1); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "png", 0); - ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_9, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _4); + ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 281, _4); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "wbmp", 0); - ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_10, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _4); + ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 282, _4); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "xbm", 0); - ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 284, ext, &_1); + ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 277, ext, &_1); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_11, 0)) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _4, ZEPHIR_GLOBAL(global_null)); + ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 283, _4, ZEPHIR_GLOBAL(global_null)); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 284); zephir_check_call_status(); RETURN_MM(); } @@ -1596,7 +1602,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) { ZEPHIR_CONCAT_SVS(_13, "Installed GD does not support '", ext, "' images"); ZEPHIR_CALL_METHOD(NULL, _12, "__construct", NULL, 9, _13); zephir_check_call_status(); - zephir_throw_exception_debug(_12, "phalcon/image/adapter/gd.zep", 565 TSRMLS_CC); + zephir_throw_exception_debug(_12, "phalcon/image/adapter/gd.zep", 572 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -1618,11 +1624,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _create) { ZVAL_LONG(&_0, width); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, height); - ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 256, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 248, &_0, &_1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, image, ZEPHIR_GLOBAL(global_false)); + ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 249, image, ZEPHIR_GLOBAL(global_false)); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true)); + ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 247, image, ZEPHIR_GLOBAL(global_true)); zephir_check_call_status(); RETURN_CCTOR(image); @@ -1638,7 +1644,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, __destruct) { ZEPHIR_OBS_VAR(image); zephir_read_property_this(&image, this_ptr, SL("_image"), PH_NOISY_CC); if (Z_TYPE_P(image) == IS_RESOURCE) { - ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, image); + ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 251, image); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/image/adapter/imagick.zep.c b/ext/phalcon/image/adapter/imagick.zep.c index 852942fb404..c3c24e84d91 100644 --- a/ext/phalcon/image/adapter/imagick.zep.c +++ b/ext/phalcon/image/adapter/imagick.zep.c @@ -70,12 +70,12 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, check) { } ZEPHIR_SINIT_VAR(_2); ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0); - ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 228, &_2); + ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 229, &_2); zephir_check_call_status(); if (zephir_is_true(_3)) { ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0); - ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_2); + ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 191, &_2); zephir_check_call_status(); zephir_update_static_property_ce(phalcon_image_adapter_imagick_ce, SL("_version"), &_4 TSRMLS_CC); } @@ -137,7 +137,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, __construct) { _2 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); if ((zephir_file_exists(_2 TSRMLS_CC) == SUCCESS)) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_4, "realpath", NULL, 60, _3); + ZEPHIR_CALL_FUNCTION(&_4, "realpath", NULL, 62, _3); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_realpath"), _4 TSRMLS_CC); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -163,7 +163,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, __construct) { _12 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_13); ZVAL_STRING(&_13, "Imagick::ALPHACHANNEL_SET", 0); - ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 190, &_13); + ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 191, &_13); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _12, "setimagealphachannel", NULL, 0, _14); zephir_check_call_status(); @@ -661,7 +661,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { while (1) { ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::COMPOSITE_DSTOUT", 0); - ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, 0); @@ -675,11 +675,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { } ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::EVALUATE_MULTIPLY", 0); - ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::CHANNEL_ALPHA", 0); - ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, opacity); @@ -722,7 +722,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::ALPHACHANNEL_SET", 0); - ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, image, "setimagealphachannel", &_25, 0, _9); zephir_check_call_status(); @@ -739,7 +739,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { _30 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::COMPOSITE_SRC", 0); - ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 191, &_14); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, 0); @@ -769,7 +769,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) { while (1) { ZEPHIR_SINIT_NVAR(_14); ZVAL_STRING(&_14, "Imagick::COMPOSITE_OVER", 0); - ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 190, &_14); + ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 191, &_14); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC); ZEPHIR_INIT_NVAR(_3); @@ -854,7 +854,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _watermark) { _3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_4); ZVAL_STRING(&_4, "Imagick::COMPOSITE_OVER", 0); - ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 190, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 191, &_4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_1); ZVAL_LONG(_1, offsetX); @@ -886,17 +886,18 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _watermark) { */ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) { - zephir_fcall_cache_entry *_6 = NULL, *_8 = NULL; - int offsetX, offsetY, opacity, r, g, b, size, ZEPHIR_LAST_CALL_STATUS; - zval *text_param = NULL, *offsetX_param = NULL, *offsetY_param = NULL, *opacity_param = NULL, *r_param = NULL, *g_param = NULL, *b_param = NULL, *size_param = NULL, *fontfile_param = NULL, *draw, *color = NULL, *pixel, *gravity = NULL, _0 = zval_used_for_init, _1, _2, _3, *_4 = NULL, *_5 = NULL, *_7 = NULL, *_9, *_10, *_11 = NULL, *_12 = NULL, *_13; + zephir_fcall_cache_entry *_7 = NULL; + zend_bool _6; + int opacity, r, g, b, size, x, y, ZEPHIR_LAST_CALL_STATUS; + zval *text_param = NULL, *offsetX = NULL, *offsetY = NULL, *opacity_param = NULL, *r_param = NULL, *g_param = NULL, *b_param = NULL, *size_param = NULL, *fontfile_param = NULL, *draw, *color = NULL, *gravity = NULL, _0 = zval_used_for_init, _1, _2, _3, *_4, *_5 = NULL, *_8, *_9, *_10, *_11 = NULL; zval *text = NULL, *fontfile = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 9, 0, &text_param, &offsetX_param, &offsetY_param, &opacity_param, &r_param, &g_param, &b_param, &size_param, &fontfile_param); + zephir_fetch_params(1, 9, 0, &text_param, &offsetX, &offsetY, &opacity_param, &r_param, &g_param, &b_param, &size_param, &fontfile_param); zephir_get_strval(text, text_param); - offsetX = zephir_get_intval(offsetX_param); - offsetY = zephir_get_intval(offsetY_param); + ZEPHIR_SEPARATE_PARAM(offsetX); + ZEPHIR_SEPARATE_PARAM(offsetY); opacity = zephir_get_intval(opacity_param); r = zephir_get_intval(r_param); g = zephir_get_intval(g_param); @@ -920,76 +921,210 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) { ZVAL_LONG(&_2, g); ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, b); - ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 188, &_0, &_1, &_2, &_3); zephir_check_call_status(); - ZEPHIR_INIT_VAR(pixel); - object_init_ex(pixel, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC)); - if (zephir_has_constructor(pixel TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(NULL, pixel, "__construct", NULL, 0, color); + ZEPHIR_INIT_VAR(_4); + object_init_ex(_4, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC)); + if (zephir_has_constructor(_4 TSRMLS_CC)) { + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 0, color); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, draw, "setfillcolor", NULL, 0, pixel); + ZEPHIR_CALL_METHOD(NULL, draw, "setfillcolor", NULL, 0, _4); zephir_check_call_status(); if (fontfile && Z_STRLEN_P(fontfile)) { ZEPHIR_CALL_METHOD(NULL, draw, "setfont", NULL, 0, fontfile); zephir_check_call_status(); } if (size) { - ZEPHIR_INIT_VAR(_4); - ZVAL_LONG(_4, size); - ZEPHIR_CALL_METHOD(NULL, draw, "setfontsize", NULL, 0, _4); + ZEPHIR_INIT_VAR(_5); + ZVAL_LONG(_5, size); + ZEPHIR_CALL_METHOD(NULL, draw, "setfontsize", NULL, 0, _5); zephir_check_call_status(); } if (opacity) { - ZEPHIR_INIT_NVAR(_4); - ZVAL_LONG(_4, opacity); - ZEPHIR_CALL_METHOD(NULL, draw, "setfillopacity", NULL, 0, _4); + ZEPHIR_INIT_NVAR(_5); + ZVAL_LONG(_5, opacity); + ZEPHIR_CALL_METHOD(NULL, draw, "setfillopacity", NULL, 0, _5); zephir_check_call_status(); } - if (offsetX < 0) { - ZEPHIR_SINIT_NVAR(_0); - ZVAL_LONG(&_0, offsetX); - ZEPHIR_CALL_FUNCTION(&_5, "abs", &_6, 192, &_0); - zephir_check_call_status(); - offsetX = zephir_get_numberval(_5); - if (offsetY < 0) { - ZEPHIR_SINIT_NVAR(_0); - ZVAL_LONG(&_0, offsetY); - ZEPHIR_CALL_FUNCTION(&_7, "abs", &_6, 192, &_0); - zephir_check_call_status(); - offsetY = zephir_get_numberval(_7); - ZEPHIR_SINIT_NVAR(_0); - ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); - ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0); - zephir_check_call_status(); + ZEPHIR_INIT_VAR(gravity); + ZVAL_NULL(gravity); + if (Z_TYPE_P(offsetX) == IS_BOOL) { + if (Z_TYPE_P(offsetY) == IS_BOOL) { + ZEPHIR_INIT_NVAR(offsetX); + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, 0); + _6 = zephir_is_true(offsetX); + if (_6) { + _6 = zephir_is_true(offsetY); + } + if (_6) { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + if (zephir_is_true(offsetX)) { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_EAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + if (zephir_is_true(offsetY)) { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_CENTER", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } } else { - ZEPHIR_SINIT_NVAR(_0); - ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0); - ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0); - zephir_check_call_status(); + if (Z_TYPE_P(offsetY) == IS_LONG) { + y = zephir_get_intval(offsetY); + if (zephir_is_true(offsetX)) { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } else { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } + } + } else { + if (Z_TYPE_P(offsetX) == IS_LONG) { + x = zephir_get_intval(offsetX); + if (zephir_is_true(offsetX)) { + if (Z_TYPE_P(offsetY) == IS_BOOL) { + if (zephir_is_true(offsetY)) { + ZEPHIR_INIT_NVAR(offsetY); + if (x < 0) { + ZEPHIR_INIT_NVAR(offsetX); + ZVAL_LONG(offsetX, (x * -1)); + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTH", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } else { + ZEPHIR_INIT_NVAR(offsetY); + if (x < 0) { + ZEPHIR_INIT_NVAR(offsetX); + ZVAL_LONG(offsetX, (x * -1)); + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_EAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetY, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_WEST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } else { + if (Z_TYPE_P(offsetY) == IS_LONG) { + x = zephir_get_intval(offsetX); + y = zephir_get_intval(offsetY); + if (x < 0) { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, (x * -1)); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, (x * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } else { + ZEPHIR_INIT_NVAR(offsetX); + if (y < 0) { + ZVAL_LONG(offsetX, 0); + ZEPHIR_INIT_NVAR(offsetY); + ZVAL_LONG(offsetY, (y * -1)); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHWEST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } else { + ZVAL_LONG(offsetX, 0); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHWEST", 0); + ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_7, 191, &_0); + zephir_check_call_status(); + } + } + } + } + } } } ZEPHIR_CALL_METHOD(NULL, draw, "setgravity", NULL, 0, gravity); zephir_check_call_status(); - _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_INIT_NVAR(_4); - ZVAL_LONG(_4, 0); - ZEPHIR_CALL_METHOD(NULL, _9, "setiteratorindex", NULL, 0, _4); + _8 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); + ZEPHIR_INIT_NVAR(_5); + ZVAL_LONG(_5, 0); + ZEPHIR_CALL_METHOD(NULL, _8, "setiteratorindex", NULL, 0, _5); zephir_check_call_status(); while (1) { - _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_INIT_NVAR(_4); - ZVAL_LONG(_4, offsetX); - ZEPHIR_INIT_NVAR(_11); - ZVAL_LONG(_11, offsetY); - ZEPHIR_INIT_NVAR(_12); - ZVAL_LONG(_12, 0); - ZEPHIR_CALL_METHOD(NULL, _10, "annotateimage", NULL, 0, draw, _4, _11, _12, text); + _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); + ZEPHIR_INIT_NVAR(_5); + ZVAL_LONG(_5, 0); + ZEPHIR_CALL_METHOD(NULL, _9, "annotateimage", NULL, 0, draw, offsetX, offsetY, _5, text); zephir_check_call_status(); - _13 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(&_5, _13, "nextimage", NULL, 0); + _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(&_11, _10, "nextimage", NULL, 0); zephir_check_call_status(); - if (ZEPHIR_IS_FALSE_IDENTICAL(_5)) { + if (ZEPHIR_IS_FALSE_IDENTICAL(_11)) { break; } } @@ -1039,7 +1174,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _mask) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_5); ZVAL_STRING(&_5, "Imagick::COMPOSITE_DSTIN", 0); - ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 190, &_5); + ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 191, &_5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_2); ZVAL_LONG(_2, 0); @@ -1048,7 +1183,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _mask) { ZEPHIR_CALL_METHOD(&ret, _4, "compositeimage", NULL, 0, mask, _6, _2, _8); zephir_check_call_status(); if (!ZEPHIR_IS_TRUE_IDENTICAL(ret)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 453); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 531); return; } _9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -1092,7 +1227,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { ZVAL_LONG(&_2, g); ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, b); - ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3); + ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 188, &_0, &_1, &_2, &_3); zephir_check_call_status(); ZEPHIR_INIT_VAR(pixel1); object_init_ex(pixel1, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC)); @@ -1131,7 +1266,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { if (!(zephir_is_true(_9))) { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::ALPHACHANNEL_SET", 0); - ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, background, "setimagealphachannel", &_13, 0, _11); zephir_check_call_status(); @@ -1140,11 +1275,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::EVALUATE_MULTIPLY", 0); - ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::CHANNEL_ALPHA", 0); - ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_4); ZVAL_LONG(_4, opacity); @@ -1158,7 +1293,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { _20 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::COMPOSITE_DISSOLVE", 0); - ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 191, &_0); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_4); ZVAL_LONG(_4, 0); @@ -1167,7 +1302,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) { ZEPHIR_CALL_METHOD(&ret, background, "compositeimage", &_23, 0, _20, _21, _4, _22); zephir_check_call_status(); if (!ZEPHIR_IS_TRUE_IDENTICAL(ret)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 492); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_image_exception_ce, "Imagick::compositeImage failed", "phalcon/image/adapter/imagick.zep", 570); return; } _24 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -1297,7 +1432,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 4); - ZEPHIR_CALL_FUNCTION(&ext, "pathinfo", NULL, 69, file, &_0); + ZEPHIR_CALL_FUNCTION(&ext, "pathinfo", NULL, 71, file, &_0); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_CALL_METHOD(NULL, _1, "setformat", NULL, 0, ext); @@ -1317,7 +1452,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { zephir_update_property_this(this_ptr, SL("_mime"), _7 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_9, 140, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_9, 19, ext, &_0); zephir_check_call_status(); if (ZEPHIR_IS_LONG(_8, 0)) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); @@ -1325,7 +1460,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "w", 0); - ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 292, file, &_0); + ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 285, file, &_0); zephir_check_call_status(); _11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_CALL_METHOD(NULL, _11, "writeimagesfile", NULL, 0, fp); @@ -1335,13 +1470,13 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { } else { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_12, "strcasecmp", &_9, 140, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_12, "strcasecmp", &_9, 19, ext, &_0); zephir_check_call_status(); _13 = ZEPHIR_IS_LONG(_12, 0); if (!(_13)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_14, "strcasecmp", &_9, 140, ext, &_0); + ZEPHIR_CALL_FUNCTION(&_14, "strcasecmp", &_9, 19, ext, &_0); zephir_check_call_status(); _13 = ZEPHIR_IS_LONG(_14, 0); } @@ -1349,7 +1484,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) { _10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "Imagick::COMPRESSION_JPEG", 0); - ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 190, &_0); + ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 191, &_0); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _10, "setimagecompression", NULL, 0, _15); zephir_check_call_status(); @@ -1403,7 +1538,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _render) { zephir_update_property_this(this_ptr, SL("_mime"), _2 TSRMLS_CC); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "gif", 0); - ZEPHIR_CALL_FUNCTION(&_4, "strcasecmp", &_5, 140, extension, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "strcasecmp", &_5, 19, extension, &_3); zephir_check_call_status(); if (ZEPHIR_IS_LONG_IDENTICAL(_4, 0)) { ZEPHIR_CALL_METHOD(NULL, image, "optimizeimagelayers", NULL, 0); @@ -1411,20 +1546,20 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _render) { } else { ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "jpg", 0); - ZEPHIR_CALL_FUNCTION(&_6, "strcasecmp", &_5, 140, extension, &_3); + ZEPHIR_CALL_FUNCTION(&_6, "strcasecmp", &_5, 19, extension, &_3); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG_IDENTICAL(_6, 0); if (!(_7)) { ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "jpeg", 0); - ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_5, 140, extension, &_3); + ZEPHIR_CALL_FUNCTION(&_8, "strcasecmp", &_5, 19, extension, &_3); zephir_check_call_status(); _7 = ZEPHIR_IS_LONG_IDENTICAL(_8, 0); } if (_7) { ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "Imagick::COMPRESSION_JPEG", 0); - ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 190, &_3); + ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 191, &_3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, image, "setimagecompression", NULL, 0, _9); zephir_check_call_status(); diff --git a/ext/phalcon/loader.zep.c b/ext/phalcon/loader.zep.c index 8234b732ddf..f8b979c5c15 100644 --- a/ext/phalcon/loader.zep.c +++ b/ext/phalcon/loader.zep.c @@ -360,7 +360,7 @@ PHP_METHOD(Phalcon_Loader, register) { ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "autoLoad", 1); zephir_array_fast_append(_1, _2); - ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 293, _1); + ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 286, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_registered"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } @@ -387,7 +387,7 @@ PHP_METHOD(Phalcon_Loader, unregister) { ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "autoLoad", 1); zephir_array_fast_append(_1, _2); - ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 294, _1); + ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 287, _1); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_registered"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } @@ -498,7 +498,7 @@ PHP_METHOD(Phalcon_Loader, autoLoad) { zephir_check_temp_parameter(_9); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath); + ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 288, filePath); zephir_check_call_status(); if (zephir_is_true(_11)) { if (Z_TYPE_P(eventsManager) == IS_OBJECT) { @@ -569,7 +569,7 @@ PHP_METHOD(Phalcon_Loader, autoLoad) { zephir_check_temp_parameter(_9); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath); + ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 288, filePath); zephir_check_call_status(); if (zephir_is_true(_11)) { if (Z_TYPE_P(eventsManager) == IS_OBJECT) { @@ -627,7 +627,7 @@ PHP_METHOD(Phalcon_Loader, autoLoad) { zephir_check_temp_parameter(_9); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath); + ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 288, filePath); zephir_check_call_status(); if (zephir_is_true(_11)) { if (Z_TYPE_P(eventsManager) == IS_OBJECT) { @@ -658,7 +658,7 @@ PHP_METHOD(Phalcon_Loader, autoLoad) { } /** - * Get the path when a class was found + * Get the path when a class was found */ PHP_METHOD(Phalcon_Loader, getFoundPath) { diff --git a/ext/phalcon/logger/adapter.zep.c b/ext/phalcon/logger/adapter.zep.c index f4b29aa8295..c32a2e8447b 100644 --- a/ext/phalcon/logger/adapter.zep.c +++ b/ext/phalcon/logger/adapter.zep.c @@ -516,7 +516,7 @@ PHP_METHOD(Phalcon_Logger_Adapter, alert) { } /** - * Logs messages to the internal logger. Appends logs to the logger + * Logs messages to the internal logger. Appends logs to the logger */ PHP_METHOD(Phalcon_Logger_Adapter, log) { @@ -572,7 +572,7 @@ PHP_METHOD(Phalcon_Logger_Adapter, log) { if (zephir_is_true(_3)) { ZEPHIR_INIT_VAR(_4); object_init_ex(_4, phalcon_logger_item_ce); - ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 52, toggledMessage, toggledType, timestamp, context); + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 53, toggledMessage, toggledType, timestamp, context); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_queue"), _4 TSRMLS_CC); } else { diff --git a/ext/phalcon/logger/adapter/file.zep.c b/ext/phalcon/logger/adapter/file.zep.c index 934633a54ac..d23805dc88c 100644 --- a/ext/phalcon/logger/adapter/file.zep.c +++ b/ext/phalcon/logger/adapter/file.zep.c @@ -119,7 +119,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_File, __construct) { ZEPHIR_INIT_NVAR(mode); ZVAL_STRING(mode, "ab", 1); } - ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 292, name, mode); + ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 285, name, mode); zephir_check_call_status(); if (Z_TYPE_P(handler) != IS_RESOURCE) { ZEPHIR_INIT_VAR(_0); @@ -154,7 +154,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_File, getFormatter) { if (Z_TYPE_P(_0) != IS_OBJECT) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_logger_formatter_line_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 289); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC); } @@ -243,7 +243,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_File, __wakeup) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_logger_exception_ce, "Logger must be opened in append or write mode", "phalcon/logger/adapter/file.zep", 152); return; } - ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 292, path, mode); + ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 285, path, mode); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_fileHandler"), _1 TSRMLS_CC); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/logger/adapter/firephp.zep.c b/ext/phalcon/logger/adapter/firephp.zep.c index 98754178b0a..a8775666cf3 100644 --- a/ext/phalcon/logger/adapter/firephp.zep.c +++ b/ext/phalcon/logger/adapter/firephp.zep.c @@ -110,15 +110,15 @@ PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) { if (!ZEPHIR_IS_TRUE_IDENTICAL(_1)) { ZEPHIR_SINIT_VAR(_2); ZVAL_STRING(&_2, "X-Wf-Protocol-1: http://meta.wildfirehq.org/Protocol/JsonStream/0.2", 0); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, &_2); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "X-Wf-1-Plugin-1: http://meta.firephp.org/Wildfire/Plugin/FirePHP/Library-FirePHPCore/0.3", 0); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, &_2); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "X-Wf-Structure-1: http://meta.firephp.org/Wildfire/Structure/FirePHP/FirebugConsole/0.1", 0); - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, &_2); zephir_check_call_status(); zephir_update_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_initialized"), &(ZEPHIR_GLOBAL(global_true)) TSRMLS_CC); } @@ -132,7 +132,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) { zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_LONG(&_2, 4500); - ZEPHIR_CALL_FUNCTION(&chunk, "str_split", NULL, 67, format, &_2); + ZEPHIR_CALL_FUNCTION(&chunk, "str_split", NULL, 69, format, &_2); zephir_check_call_status(); zephir_is_iterable(chunk, &_8, &_7, 0, 0, "phalcon/logger/adapter/firephp.zep", 102); for ( @@ -148,7 +148,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) { if (zephir_array_isset_long(chunk, (zephir_get_numberval(key) + 1))) { zephir_concat_self_str(&content, SL("|\\") TSRMLS_CC); } - ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, content); + ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 237, content); zephir_check_call_status(); _10 = zephir_fetch_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_index") TSRMLS_CC); ZEPHIR_INIT_ZVAL_NREF(_11); diff --git a/ext/phalcon/logger/adapter/stream.zep.c b/ext/phalcon/logger/adapter/stream.zep.c index 7eaa93cebce..afe4cd90754 100644 --- a/ext/phalcon/logger/adapter/stream.zep.c +++ b/ext/phalcon/logger/adapter/stream.zep.c @@ -93,7 +93,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_Stream, __construct) { ZEPHIR_INIT_NVAR(mode); ZVAL_STRING(mode, "ab", 1); } - ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 292, name, mode); + ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 285, name, mode); zephir_check_call_status(); if (!(zephir_is_true(stream))) { ZEPHIR_INIT_VAR(_0); @@ -126,7 +126,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_Stream, getFormatter) { if (Z_TYPE_P(_0) != IS_OBJECT) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_logger_formatter_line_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 289); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC); } diff --git a/ext/phalcon/logger/adapter/syslog.zep.c b/ext/phalcon/logger/adapter/syslog.zep.c index 7a45a2445e3..d1f207ecdf6 100644 --- a/ext/phalcon/logger/adapter/syslog.zep.c +++ b/ext/phalcon/logger/adapter/syslog.zep.c @@ -76,7 +76,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_Syslog, __construct) { ZEPHIR_INIT_NVAR(facility); ZVAL_LONG(facility, 8); } - ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 297, name, option, facility); + ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 290, name, option, facility); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_opened"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } @@ -147,7 +147,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_Syslog, logInternal) { } zephir_array_fetch_long(&_3, appliedFormat, 0, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC); zephir_array_fetch_long(&_4, appliedFormat, 1, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 298, _3, _4); + ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 291, _3, _4); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -167,7 +167,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_Syslog, close) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_opened"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 299); + ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 292); zephir_check_call_status(); } ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/logger/adapterinterface.zep.c b/ext/phalcon/logger/adapterinterface.zep.c index 41c585b8ae0..2b3dd4003ec 100644 --- a/ext/phalcon/logger/adapterinterface.zep.c +++ b/ext/phalcon/logger/adapterinterface.zep.c @@ -28,14 +28,14 @@ ZEPHIR_INIT_CLASS(Phalcon_Logger_AdapterInterface) { /** * Sets the message formatter * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, setFormatter); /** * Returns the internal formatter * - * @return Phalcon\Logger\FormatterInterface + * @return \Phalcon\Logger\FormatterInterface */ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, getFormatter); @@ -43,7 +43,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, getFormatter); * Filters the logs sent to the handlers to be greater or equals than a specific level * * @param int level - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, setLogLevel); @@ -57,28 +57,28 @@ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, getLogLevel); /** * Sends/Writes messages to the file log * - * @return Phalcon\Logger\Adapter1 + * @return \Phalcon\Logger\Adapter1 */ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, log); /** * Starts a transaction * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, begin); /** * Commits the internal transaction * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, commit); /** * Rollbacks the internal transaction * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, rollback); @@ -90,49 +90,49 @@ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, close); /** * Sends/Writes a debug message to the log * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, debug); /** * Sends/Writes an error message to the log * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, error); /** * Sends/Writes an info message to the log * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, info); /** * Sends/Writes a notice message to the log * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, notice); /** * Sends/Writes a warning message to the log * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, warning); /** * Sends/Writes an alert message to the log * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, alert); /** * Sends/Writes an emergency message to the log * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ ZEPHIR_DOC_METHOD(Phalcon_Logger_AdapterInterface, emergency); diff --git a/ext/phalcon/logger/formatter.zep.c b/ext/phalcon/logger/formatter.zep.c index f1848453482..e038dc84a7d 100644 --- a/ext/phalcon/logger/formatter.zep.c +++ b/ext/phalcon/logger/formatter.zep.c @@ -126,7 +126,7 @@ PHP_METHOD(Phalcon_Logger_Formatter, interpolate) { ZEPHIR_CONCAT_SVS(_4, "{", key, "}"); zephir_array_update_zval(&replace, _4, &value, PH_COPY | PH_SEPARATE); } - ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 53, message, replace); + ZEPHIR_RETURN_CALL_FUNCTION("strtr", NULL, 54, message, replace); zephir_check_call_status(); RETURN_MM(); } diff --git a/ext/phalcon/logger/formatter/firephp.zep.c b/ext/phalcon/logger/formatter/firephp.zep.c index a17c0fbda0a..62973c1f6d1 100644 --- a/ext/phalcon/logger/formatter/firephp.zep.c +++ b/ext/phalcon/logger/formatter/firephp.zep.c @@ -188,15 +188,15 @@ PHP_METHOD(Phalcon_Logger_Formatter_Firephp, format) { ZVAL_STRING(&_3, "5.3.6", 0); ZEPHIR_SINIT_VAR(_4); ZVAL_STRING(&_4, "<", 0); - ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 248, _1, &_3, &_4); + ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 240, _1, &_3, &_4); zephir_check_call_status(); if (!(zephir_is_true(_0))) { param = (2) ? 1 : 0; } - ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 150, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 151, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); Z_SET_ISREF_P(backtrace); - ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 170, backtrace); + ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 171, backtrace); Z_UNSET_ISREF_P(backtrace); zephir_check_call_status(); if (zephir_array_isset_string(lastTrace, SS("file"))) { diff --git a/ext/phalcon/logger/formatter/line.zep.c b/ext/phalcon/logger/formatter/line.zep.c index 11ada20682b..8fbd10cb556 100644 --- a/ext/phalcon/logger/formatter/line.zep.c +++ b/ext/phalcon/logger/formatter/line.zep.c @@ -13,8 +13,8 @@ #include "kernel/main.h" #include "kernel/object.h" -#include "kernel/memory.h" #include "kernel/operators.h" +#include "kernel/memory.h" #include "kernel/string.h" #include "kernel/fcall.h" #include "kernel/concat.h" @@ -50,8 +50,6 @@ ZEPHIR_INIT_CLASS(Phalcon_Logger_Formatter_Line) { /** * Default date format - * - * @var string */ PHP_METHOD(Phalcon_Logger_Formatter_Line, getDateFormat) { @@ -62,25 +60,25 @@ PHP_METHOD(Phalcon_Logger_Formatter_Line, getDateFormat) { /** * Default date format - * - * @var string */ PHP_METHOD(Phalcon_Logger_Formatter_Line, setDateFormat) { - zval *dateFormat; + zval *dateFormat_param = NULL; + zval *dateFormat = NULL; - zephir_fetch_params(0, 1, 0, &dateFormat); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &dateFormat_param); + zephir_get_strval(dateFormat, dateFormat_param); zephir_update_property_this(this_ptr, SL("_dateFormat"), dateFormat TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } /** * Format applied to each message - * - * @var string */ PHP_METHOD(Phalcon_Logger_Formatter_Line, getFormat) { @@ -91,18 +89,20 @@ PHP_METHOD(Phalcon_Logger_Formatter_Line, getFormat) { /** * Format applied to each message - * - * @var string */ PHP_METHOD(Phalcon_Logger_Formatter_Line, setFormat) { - zval *format; + zval *format_param = NULL; + zval *format = NULL; - zephir_fetch_params(0, 1, 0, &format); + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &format_param); + zephir_get_strval(format, format_param); zephir_update_property_this(this_ptr, SL("_format"), format TSRMLS_CC); + ZEPHIR_MM_RESTORE(); } @@ -168,7 +168,7 @@ PHP_METHOD(Phalcon_Logger_Formatter_Line, format) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dateFormat"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_2); ZVAL_LONG(&_2, timestamp); - ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 300, _1, &_2); + ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 293, _1, &_2); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_2); ZVAL_STRING(&_2, "%date%", 0); diff --git a/ext/phalcon/logger/item.zep.c b/ext/phalcon/logger/item.zep.c index 59238352c41..df992b18e7f 100644 --- a/ext/phalcon/logger/item.zep.c +++ b/ext/phalcon/logger/item.zep.c @@ -56,8 +56,6 @@ ZEPHIR_INIT_CLASS(Phalcon_Logger_Item) { /** * Log type - * - * @var integer */ PHP_METHOD(Phalcon_Logger_Item, getType) { @@ -68,8 +66,6 @@ PHP_METHOD(Phalcon_Logger_Item, getType) { /** * Log message - * - * @var string */ PHP_METHOD(Phalcon_Logger_Item, getMessage) { @@ -80,8 +76,6 @@ PHP_METHOD(Phalcon_Logger_Item, getMessage) { /** * Log timestamp - * - * @var integer */ PHP_METHOD(Phalcon_Logger_Item, getTime) { diff --git a/ext/phalcon/mvc/application.zep.c b/ext/phalcon/mvc/application.zep.c index afedb2d0563..a9443bc462e 100644 --- a/ext/phalcon/mvc/application.zep.c +++ b/ext/phalcon/mvc/application.zep.c @@ -271,7 +271,7 @@ PHP_METHOD(Phalcon_Mvc_Application, getDefaultModule) { * Handles a MVC request * * @param string uri - * @return Phalcon\Http\ResponseInterface|boolean + * @return \Phalcon\Http\ResponseInterface|boolean */ PHP_METHOD(Phalcon_Mvc_Application, handle) { diff --git a/ext/phalcon/mvc/collection.zep.c b/ext/phalcon/mvc/collection.zep.c index 428efcd0f1e..b23e098c599 100644 --- a/ext/phalcon/mvc/collection.zep.c +++ b/ext/phalcon/mvc/collection.zep.c @@ -537,7 +537,7 @@ PHP_METHOD(Phalcon_Mvc_Collection, cloneResult) { * Returns a collection resultset * * @param array params - * @param Phalcon\Mvc\Collection collection + * @param \Phalcon\Mvc\Collection collection * @param \MongoDb connection * @param boolean unique * @return array @@ -628,7 +628,7 @@ PHP_METHOD(Phalcon_Mvc_Collection, _getResultset) { } ZEPHIR_INIT_VAR(collections); array_init(collections); - ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 301, documentsCursor); + ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 294, documentsCursor); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/collection.zep", 440); for ( @@ -648,7 +648,7 @@ PHP_METHOD(Phalcon_Mvc_Collection, _getResultset) { * Perform a count over a resultset * * @param array params - * @param Phalcon\Mvc\Collection collection + * @param \Phalcon\Mvc\Collection collection * @param \MongoDb connection * @return int */ @@ -716,7 +716,7 @@ PHP_METHOD(Phalcon_Mvc_Collection, _getGroupResultset) { /** * Executes internal hooks before save a document * - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\DiInterface dependencyInjector * @param boolean disableEvents * @param boolean exists * @return boolean @@ -1211,7 +1211,7 @@ PHP_METHOD(Phalcon_Mvc_Collection, save) { zephir_update_property_this(this_ptr, SL("_errorMessages"), _1 TSRMLS_CC); ZEPHIR_OBS_VAR(disableEvents); zephir_read_static_property_ce(&disableEvents, phalcon_mvc_collection_ce, SL("_disableEvents") TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 302, dependencyInjector, disableEvents, exists); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 295, dependencyInjector, disableEvents, exists); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(_2)) { RETURN_MM_BOOL(0); @@ -1240,7 +1240,7 @@ PHP_METHOD(Phalcon_Mvc_Collection, save) { } else { success = 0; } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 303, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 296, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists); zephir_check_call_status(); RETURN_MM(); @@ -1250,7 +1250,7 @@ PHP_METHOD(Phalcon_Mvc_Collection, save) { * Find a document by its id (_id) * * @param string|\MongoId id - * @return Phalcon\Mvc\Collection + * @return \Phalcon\Mvc\Collection */ PHP_METHOD(Phalcon_Mvc_Collection, findById) { @@ -1760,7 +1760,7 @@ PHP_METHOD(Phalcon_Mvc_Collection, toArray) { zephir_check_call_status(); ZEPHIR_INIT_VAR(data); array_init(data); - ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 23, this_ptr); + ZEPHIR_CALL_FUNCTION(&_0, "get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/collection.zep", 1244); for ( @@ -1795,7 +1795,7 @@ PHP_METHOD(Phalcon_Mvc_Collection, serialize) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "toarray", NULL, 0); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -1829,7 +1829,7 @@ PHP_METHOD(Phalcon_Mvc_Collection, unserialize) { } - ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(attributes) == IS_ARRAY) { ZEPHIR_CALL_CE_STATIC(&dependencyInjector, phalcon_di_ce, "getdefault", &_0, 1); diff --git a/ext/phalcon/mvc/collection/behavior/timestampable.zep.c b/ext/phalcon/mvc/collection/behavior/timestampable.zep.c index a50a9a9ff3e..1b5ed81f567 100644 --- a/ext/phalcon/mvc/collection/behavior/timestampable.zep.c +++ b/ext/phalcon/mvc/collection/behavior/timestampable.zep.c @@ -84,7 +84,7 @@ PHP_METHOD(Phalcon_Mvc_Collection_Behavior_Timestampable, notify) { ZVAL_NULL(timestamp); ZEPHIR_OBS_VAR(format); if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format); + ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 293, format); zephir_check_call_status(); } else { ZEPHIR_OBS_VAR(generator); diff --git a/ext/phalcon/mvc/collection/document.zep.c b/ext/phalcon/mvc/collection/document.zep.c index 5904ee4bff5..770e59bd4c2 100644 --- a/ext/phalcon/mvc/collection/document.zep.c +++ b/ext/phalcon/mvc/collection/document.zep.c @@ -222,7 +222,7 @@ PHP_METHOD(Phalcon_Mvc_Collection_Document, toArray) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 23, this_ptr); + ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/mvc/collection/manager.zep.c b/ext/phalcon/mvc/collection/manager.zep.c index d6429b61313..f8e6ede872b 100644 --- a/ext/phalcon/mvc/collection/manager.zep.c +++ b/ext/phalcon/mvc/collection/manager.zep.c @@ -140,8 +140,8 @@ PHP_METHOD(Phalcon_Mvc_Collection_Manager, setCustomEventsManager) { /** * Returns a custom events manager related to a model * - * @param Phalcon\Mvc\CollectionInterface $model - * @return Phalcon\Events\ManagerInterface + * @param \Phalcon\Mvc\CollectionInterface $model + * @return \Phalcon\Events\ManagerInterface */ PHP_METHOD(Phalcon_Mvc_Collection_Manager, getCustomEventsManager) { @@ -324,7 +324,7 @@ PHP_METHOD(Phalcon_Mvc_Collection_Manager, isUsingImplicitObjectIds) { /** * Returns the connection related to a model * - * @param Phalcon\Mvc\CollectionInterface $model + * @param \Phalcon\Mvc\CollectionInterface $model * @return \Mongo */ PHP_METHOD(Phalcon_Mvc_Collection_Manager, getConnection) { diff --git a/ext/phalcon/mvc/collectioninterface.zep.c b/ext/phalcon/mvc/collectioninterface.zep.c index ac37627e2b7..0a4f27a34a8 100644 --- a/ext/phalcon/mvc/collectioninterface.zep.c +++ b/ext/phalcon/mvc/collectioninterface.zep.c @@ -93,7 +93,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_CollectionInterface, getMessages); ZEPHIR_DOC_METHOD(Phalcon_Mvc_CollectionInterface, appendMessage); /** - * Creates/Updates a collection based on the values in the atributes + * Creates/Updates a collection based on the values in the attributes */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_CollectionInterface, save); @@ -101,7 +101,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_CollectionInterface, save); * Find a document by its id * * @param string id - * @return Phalcon\Mvc\Collection + * @return \Phalcon\Mvc\Collection */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_CollectionInterface, findById); diff --git a/ext/phalcon/mvc/micro.zep.c b/ext/phalcon/mvc/micro.zep.c index 4fa50b73509..b3ca7b390ea 100644 --- a/ext/phalcon/mvc/micro.zep.c +++ b/ext/phalcon/mvc/micro.zep.c @@ -134,7 +134,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, setDI) { * * @param string routePattern * @param callable handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ PHP_METHOD(Phalcon_Mvc_Micro, map) { @@ -174,7 +174,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, map) { * * @param string routePattern * @param callable handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ PHP_METHOD(Phalcon_Mvc_Micro, get) { @@ -214,7 +214,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, get) { * * @param string routePattern * @param callable handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ PHP_METHOD(Phalcon_Mvc_Micro, post) { @@ -254,7 +254,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, post) { * * @param string $routePattern * @param callable $handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ PHP_METHOD(Phalcon_Mvc_Micro, put) { @@ -294,7 +294,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, put) { * * @param string $routePattern * @param callable $handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ PHP_METHOD(Phalcon_Mvc_Micro, patch) { @@ -334,7 +334,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, patch) { * * @param string routePattern * @param callable handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ PHP_METHOD(Phalcon_Mvc_Micro, head) { @@ -374,7 +374,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, head) { * * @param string routePattern * @param callable handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ PHP_METHOD(Phalcon_Mvc_Micro, delete) { @@ -414,7 +414,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, delete) { * * @param string routePattern * @param callable handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ PHP_METHOD(Phalcon_Mvc_Micro, options) { @@ -484,7 +484,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, mount) { if (zephir_is_true(_0)) { ZEPHIR_INIT_VAR(lazyHandler); object_init_ex(lazyHandler, phalcon_mvc_micro_lazyloader_ce); - ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 304, mainHandler); + ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 297, mainHandler); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(lazyHandler, mainHandler); @@ -551,7 +551,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, mount) { * Sets a handler that will be called when the router doesn't match any of the defined routes * * @param callable handler - * @return Phalcon\Mvc\Micro + * @return \Phalcon\Mvc\Micro */ PHP_METHOD(Phalcon_Mvc_Micro, notFound) { @@ -570,7 +570,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, notFound) { * Sets a handler that will be called when an exception is thrown handling the route * * @param callable handler - * @return Phalcon\Mvc\Micro + * @return \Phalcon\Mvc\Micro */ PHP_METHOD(Phalcon_Mvc_Micro, error) { @@ -621,7 +621,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, getRouter) { * @param string serviceName * @param mixed definition * @param boolean shared - * @return Phalcon\DI\ServiceInterface + * @return \Phalcon\Di\ServiceInterface */ PHP_METHOD(Phalcon_Mvc_Micro, setService) { @@ -656,11 +656,11 @@ PHP_METHOD(Phalcon_Mvc_Micro, setService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 305, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 298, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); @@ -696,11 +696,11 @@ PHP_METHOD(Phalcon_Mvc_Micro, hasService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 306, serviceName); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 299, serviceName); zephir_check_call_status(); RETURN_MM(); @@ -739,11 +739,11 @@ PHP_METHOD(Phalcon_Mvc_Micro, getService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 307, serviceName); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 300, serviceName); zephir_check_call_status(); RETURN_MM(); @@ -770,11 +770,11 @@ PHP_METHOD(Phalcon_Mvc_Micro, getSharedService) { if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { ZEPHIR_INIT_NVAR(dependencyInjector); object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce); - ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174); + ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 175); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); } - ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 308, serviceName); + ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 301, serviceName); zephir_check_call_status(); RETURN_MM(); @@ -1258,7 +1258,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, offsetUnset) { * Appends a before middleware to be called before execute the route * * @param callable handler - * @return Phalcon\Mvc\Micro + * @return \Phalcon\Mvc\Micro */ PHP_METHOD(Phalcon_Mvc_Micro, before) { @@ -1277,7 +1277,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, before) { * Appends an 'after' middleware to be called after execute the route * * @param callable handler - * @return Phalcon\Mvc\Micro + * @return \Phalcon\Mvc\Micro */ PHP_METHOD(Phalcon_Mvc_Micro, after) { @@ -1296,7 +1296,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, after) { * Appends a 'finish' middleware to be called when the request is finished * * @param callable handler - * @return Phalcon\Mvc\Micro + * @return \Phalcon\Mvc\Micro */ PHP_METHOD(Phalcon_Mvc_Micro, finish) { diff --git a/ext/phalcon/mvc/micro/collection.zep.c b/ext/phalcon/mvc/micro/collection.zep.c index ba52b900287..fcad2fca92b 100644 --- a/ext/phalcon/mvc/micro/collection.zep.c +++ b/ext/phalcon/mvc/micro/collection.zep.c @@ -155,7 +155,7 @@ PHP_METHOD(Phalcon_Mvc_Micro_Collection, getHandlers) { * * @param mixed handler * @param boolean lazy - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ PHP_METHOD(Phalcon_Mvc_Micro_Collection, setHandler) { @@ -228,7 +228,7 @@ PHP_METHOD(Phalcon_Mvc_Micro_Collection, getHandler) { * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ PHP_METHOD(Phalcon_Mvc_Micro_Collection, map) { @@ -269,7 +269,7 @@ PHP_METHOD(Phalcon_Mvc_Micro_Collection, map) { * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ PHP_METHOD(Phalcon_Mvc_Micro_Collection, get) { @@ -311,7 +311,7 @@ PHP_METHOD(Phalcon_Mvc_Micro_Collection, get) { * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ PHP_METHOD(Phalcon_Mvc_Micro_Collection, post) { @@ -353,7 +353,7 @@ PHP_METHOD(Phalcon_Mvc_Micro_Collection, post) { * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ PHP_METHOD(Phalcon_Mvc_Micro_Collection, put) { @@ -395,7 +395,7 @@ PHP_METHOD(Phalcon_Mvc_Micro_Collection, put) { * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ PHP_METHOD(Phalcon_Mvc_Micro_Collection, patch) { @@ -437,7 +437,7 @@ PHP_METHOD(Phalcon_Mvc_Micro_Collection, patch) { * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ PHP_METHOD(Phalcon_Mvc_Micro_Collection, head) { @@ -479,7 +479,7 @@ PHP_METHOD(Phalcon_Mvc_Micro_Collection, head) { * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ PHP_METHOD(Phalcon_Mvc_Micro_Collection, delete) { @@ -520,7 +520,7 @@ PHP_METHOD(Phalcon_Mvc_Micro_Collection, delete) { * * @param string routePattern * @param callable handler - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ PHP_METHOD(Phalcon_Mvc_Micro_Collection, options) { diff --git a/ext/phalcon/mvc/micro/collectioninterface.zep.c b/ext/phalcon/mvc/micro/collectioninterface.zep.c index d20ce1af7bd..e84d4952ae8 100644 --- a/ext/phalcon/mvc/micro/collectioninterface.zep.c +++ b/ext/phalcon/mvc/micro/collectioninterface.zep.c @@ -47,7 +47,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, getHandlers); * * @param mixed handler * @param boolean lazy - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, setHandler); @@ -74,7 +74,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, getHandler); * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, map); @@ -84,7 +84,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, map); * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, get); @@ -94,7 +94,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, get); * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, post); @@ -104,7 +104,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, post); * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, put); @@ -114,7 +114,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, put); * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, patch); @@ -124,7 +124,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, patch); * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, head); @@ -134,7 +134,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, head); * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, delete); @@ -144,7 +144,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, delete); * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Micro_CollectionInterface, options); diff --git a/ext/phalcon/mvc/model.zep.c b/ext/phalcon/mvc/model.zep.c index 60b78102cb3..d2a0caf06ae 100644 --- a/ext/phalcon/mvc/model.zep.c +++ b/ext/phalcon/mvc/model.zep.c @@ -40,7 +40,6 @@ * when interacting with databases while is also easy to use. * * - * * $robot = new Robots(); * $robot->type = 'mechanical'; * $robot->name = 'Astro Boy'; @@ -48,7 +47,7 @@ * if ($robot->save() == false) { * echo "Umh, We can store robots: "; * foreach ($robot->getMessages() as $message) { - * echo message; + * echo message; * } * } else { * echo "Great, a new robot was saved successfully!"; @@ -138,7 +137,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __construct) { zephir_check_call_status(); } if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 135); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 134); return; } zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); @@ -150,7 +149,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __construct) { zephir_check_call_status(); ZEPHIR_CPY_WRT(modelsManager, _1); if (Z_TYPE_P(modelsManager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 146); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 145); return; } } @@ -243,7 +242,7 @@ PHP_METHOD(Phalcon_Mvc_Model, getModelsMetaData) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _0); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 215); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 214); return; } ZEPHIR_INIT_VAR(_2); @@ -253,7 +252,7 @@ PHP_METHOD(Phalcon_Mvc_Model, getModelsMetaData) { zephir_check_call_status(); ZEPHIR_CPY_WRT(metaData, _1); if (Z_TYPE_P(metaData) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsMetadata' is not valid", "phalcon/mvc/model.zep", 223); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsMetadata' is not valid", "phalcon/mvc/model.zep", 222); return; } zephir_update_property_this(this_ptr, SL("_modelsMetaData"), metaData TSRMLS_CC); @@ -290,14 +289,14 @@ PHP_METHOD(Phalcon_Mvc_Model, getModelsManager) { * $robot->name = 'WALL·E'; * $robot->created_at = date('Y-m-d'); * if ($robot->save() == false) { - * $transaction->rollback("Can't save robot"); + * $transaction->rollback("Can't save robot"); * } * * $robotPart = new RobotParts(); * $robotPart->setTransaction($transaction); * $robotPart->type = 'head'; * if ($robotPart->save() == false) { - * $transaction->rollback("Robot part cannot be saved"); + * $transaction->rollback("Robot part cannot be saved"); * } * * $transaction->commit(); @@ -644,7 +643,7 @@ PHP_METHOD(Phalcon_Mvc_Model, getWriteConnection) { * @param array data * @param array dataColumnMap array to transform keys of data to another * @param array whiteList - * @return Phalcon\Mvc\Model + * @return \Phalcon\Mvc\Model */ PHP_METHOD(Phalcon_Mvc_Model, assign) { @@ -671,7 +670,7 @@ PHP_METHOD(Phalcon_Mvc_Model, assign) { if (Z_TYPE_P(dataColumnMap) == IS_ARRAY) { ZEPHIR_INIT_VAR(dataMapped); array_init(dataMapped); - zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 437); + zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 436); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -700,7 +699,7 @@ PHP_METHOD(Phalcon_Mvc_Model, assign) { } ZEPHIR_CALL_METHOD(&_3, metaData, "getattributes", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(_3, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 489); + zephir_is_iterable(_3, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 488); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -716,7 +715,7 @@ PHP_METHOD(Phalcon_Mvc_Model, assign) { ZEPHIR_CONCAT_SVS(_8, "Column '", attribute, "' doesn\\'t make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_9, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_7, "phalcon/mvc/model.zep", 459 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model.zep", 458 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -760,12 +759,12 @@ PHP_METHOD(Phalcon_Mvc_Model, assign) { *)); * * - * @param Phalcon\Mvc\ModelInterface|Phalcon\Mvc\Model\Row base + * @param \Phalcon\Mvc\ModelInterface|Phalcon\Mvc\Model\Row base * @param array data * @param array columnMap * @param int dirtyState * @param boolean keepSnapshots - * @return Phalcon\Mvc\Model + * @return \Phalcon\Mvc\Model */ PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { @@ -802,7 +801,7 @@ PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { ZVAL_LONG(_0, dirtyState); ZEPHIR_CALL_METHOD(NULL, instance, "setdirtystate", NULL, 0, _0); zephir_check_call_status(); - zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 589); + zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 588); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -823,7 +822,7 @@ PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model.zep", 532 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model.zep", 531 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -839,12 +838,12 @@ PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { _6 = Z_TYPE_P(value) != IS_NULL; } if (_6) { - zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 544 TSRMLS_CC); + zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 543 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_7, 0)) { ZEPHIR_SINIT_NVAR(_8); ZVAL_LONG(&_8, 10); - ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_9, 25, value, &_8); + ZEPHIR_CALL_FUNCTION(&castValue, "intval", &_9, 26, value, &_8); zephir_check_call_status(); break; } @@ -863,7 +862,7 @@ PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { } while(0); } else { - zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 565 TSRMLS_CC); + zephir_array_fetch_long(&_7, attribute, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 564 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_7, 0) || ZEPHIR_IS_LONG(_7, 9) || ZEPHIR_IS_LONG(_7, 3) || ZEPHIR_IS_LONG(_7, 7) || ZEPHIR_IS_LONG(_7, 8)) { ZEPHIR_INIT_NVAR(castValue); @@ -876,7 +875,7 @@ PHP_METHOD(Phalcon_Mvc_Model, cloneResultMap) { } ZEPHIR_OBS_NVAR(attributeName); - zephir_array_fetch_long(&attributeName, attribute, 0, PH_NOISY, "phalcon/mvc/model.zep", 581 TSRMLS_CC); + zephir_array_fetch_long(&attributeName, attribute, 0, PH_NOISY, "phalcon/mvc/model.zep", 580 TSRMLS_CC); zephir_update_property_zval_zval(instance, attributeName, castValue TSRMLS_CC); } } @@ -929,7 +928,7 @@ PHP_METHOD(Phalcon_Mvc_Model, cloneResultMapHydrate) { ZEPHIR_INIT_VAR(hydrateObject); object_init(hydrateObject); } - zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 663); + zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 662); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -947,7 +946,7 @@ PHP_METHOD(Phalcon_Mvc_Model, cloneResultMapHydrate) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 642 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 641 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -986,10 +985,10 @@ PHP_METHOD(Phalcon_Mvc_Model, cloneResultMapHydrate) { *)); * * - * @param Phalcon\Mvc\ModelInterface $base + * @param \Phalcon\Mvc\ModelInterface $base * @param array data * @param int dirtyState - * @return Phalcon\Mvc\ModelInterface + * @return \Phalcon\Mvc\ModelInterface */ PHP_METHOD(Phalcon_Mvc_Model, cloneResult) { @@ -1019,7 +1018,7 @@ PHP_METHOD(Phalcon_Mvc_Model, cloneResult) { ZVAL_LONG(_0, dirtyState); ZEPHIR_CALL_METHOD(NULL, instance, "setdirtystate", NULL, 0, _0); zephir_check_call_status(); - zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 710); + zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 709); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -1027,7 +1026,7 @@ PHP_METHOD(Phalcon_Mvc_Model, cloneResult) { ZEPHIR_GET_HMKEY(key, _2, _1); ZEPHIR_GET_HVALUE(value, _3); if (Z_TYPE_P(key) != IS_STRING) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid key in array data provided to dumpResult()", "phalcon/mvc/model.zep", 702); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid key in array data provided to dumpResult()", "phalcon/mvc/model.zep", 701); return; } zephir_update_property_zval_zval(instance, key, value TSRMLS_CC); @@ -1095,7 +1094,7 @@ PHP_METHOD(Phalcon_Mvc_Model, find) { ZEPHIR_INIT_VAR(params); array_init(params); if (Z_TYPE_P(parameters) != IS_NULL) { - zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 756); + zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 755); } } else { ZEPHIR_CPY_WRT(params, parameters); @@ -1164,7 +1163,7 @@ PHP_METHOD(Phalcon_Mvc_Model, find) { * * * @param string|array parameters - * @return Phalcon\Mvc\Model + * @return \Phalcon\Mvc\Model */ PHP_METHOD(Phalcon_Mvc_Model, findFirst) { @@ -1192,7 +1191,7 @@ PHP_METHOD(Phalcon_Mvc_Model, findFirst) { ZEPHIR_INIT_VAR(params); array_init(params); if (Z_TYPE_P(parameters) != IS_NULL) { - zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 843); + zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 842); } } else { ZEPHIR_CPY_WRT(params, parameters); @@ -1279,12 +1278,12 @@ PHP_METHOD(Phalcon_Mvc_Model, query) { ZEPHIR_CALL_METHOD(NULL, criteria, "__construct", NULL, 0); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 309, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 302, dependencyInjector); zephir_check_call_status(); } ZEPHIR_INIT_NVAR(_2); zephir_get_called_class(_2 TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, _2); + ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 303, _2); zephir_check_call_status(); RETURN_CCTOR(criteria); @@ -1293,8 +1292,8 @@ PHP_METHOD(Phalcon_Mvc_Model, query) { /** * Checks if the current record already exists or not * - * @param Phalcon\Mvc\Model\MetadataInterface metaData - * @param Phalcon\Db\AdapterInterface connection + * @param \Phalcon\Mvc\Model\MetadataInterface metaData + * @param \Phalcon\Db\AdapterInterface connection * @param string|array table * @return boolean */ @@ -1470,7 +1469,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _exists) { * @param string function * @param string alias * @param array parameters - * @return Phalcon\Mvc\Model\ResultsetInterface + * @return \Phalcon\Mvc\Model\ResultsetInterface */ PHP_METHOD(Phalcon_Mvc_Model, _groupResult) { @@ -1518,7 +1517,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _groupResult) { ZEPHIR_INIT_VAR(params); array_init(params); if (Z_TYPE_P(parameters) != IS_NULL) { - zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 1092); + zephir_array_append(¶ms, parameters, PH_SEPARATE, "phalcon/mvc/model.zep", 1093); } } else { ZEPHIR_CPY_WRT(params, parameters); @@ -1526,7 +1525,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _groupResult) { ZEPHIR_OBS_VAR(groupColumn); if (!(zephir_array_isset_string_fetch(&groupColumn, params, SS("column"), 0 TSRMLS_CC))) { ZEPHIR_INIT_NVAR(groupColumn); - ZVAL_LONG(groupColumn, '*'); + ZVAL_STRING(groupColumn, "*", 1); } ZEPHIR_OBS_VAR(distinctColumn); if (zephir_array_isset_string_fetch(&distinctColumn, params, SS("distinct"), 0 TSRMLS_CC)) { @@ -1588,7 +1587,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _groupResult) { * echo "There are ", $number, "\n"; * * //How many mechanical robots are there? - * $number = Robots::count("type='mechanical'"); + * $number = Robots::count("type = 'mechanical'"); * echo "There are ", $number, " mechanical robots\n"; * * @@ -1634,7 +1633,7 @@ PHP_METHOD(Phalcon_Mvc_Model, count) { * echo "The total price of robots is ", $sum, "\n"; * * //How much are mechanical robots? - * $sum = Robots::sum(array("type='mechanical'", 'column' => 'price')); + * $sum = Robots::sum(array("type = 'mechanical'", 'column' => 'price')); * echo "The total price of mechanical robots is ", $sum, "\n"; * * @@ -1975,7 +1974,7 @@ PHP_METHOD(Phalcon_Mvc_Model, validate) { if (ZEPHIR_IS_FALSE_IDENTICAL(_0)) { ZEPHIR_CALL_METHOD(&_1, validator, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1392); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1393); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -2026,7 +2025,7 @@ PHP_METHOD(Phalcon_Mvc_Model, validationHasFailed) { } /** - * Returns all the validation messages + * Returns array of validation messages * * * $robot = new Robots(); @@ -2067,7 +2066,7 @@ PHP_METHOD(Phalcon_Mvc_Model, getMessages) { ZEPHIR_INIT_VAR(filtered); array_init(filtered); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_errorMessages"), PH_NOISY_CC); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1458); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 1459); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -2076,7 +2075,7 @@ PHP_METHOD(Phalcon_Mvc_Model, getMessages) { ZEPHIR_CALL_METHOD(&_5, message, "getfield", NULL, 0); zephir_check_call_status(); if (ZEPHIR_IS_EQUAL(_5, filter)) { - zephir_array_append(&filtered, message, PH_SEPARATE, "phalcon/mvc/model.zep", 1455); + zephir_array_append(&filtered, message, PH_SEPARATE, "phalcon/mvc/model.zep", 1456); } } RETURN_CCTOR(filtered); @@ -2107,7 +2106,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { zephir_check_call_status(); if (zephir_fast_count_int(belongsTo TSRMLS_CC)) { error = 0; - zephir_is_iterable(belongsTo, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1601); + zephir_is_iterable(belongsTo, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1602); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -2120,7 +2119,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { if (Z_TYPE_P(foreignKey) == IS_ARRAY) { if (zephir_array_isset_string(foreignKey, SS("action"))) { ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1502 TSRMLS_CC); + zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1503 TSRMLS_CC); action = zephir_get_intval(_4); } } @@ -2139,7 +2138,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { ZEPHIR_CALL_METHOD(&referencedFields, relation, "getreferencedfields", NULL, 0); zephir_check_call_status(); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1538); + zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1539); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) @@ -2148,11 +2147,11 @@ PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { ZEPHIR_GET_HVALUE(field, _9); ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, field, PH_SILENT_CC); - zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1531 TSRMLS_CC); + zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1532 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVSV(_11, "[", _10, "] = ?", position); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1531); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1532); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1532); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1533); if (Z_TYPE_P(value) == IS_NULL) { numberNull++; } @@ -2163,15 +2162,15 @@ PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysRestrict) { zephir_fetch_property_zval(&value, this_ptr, fields, PH_SILENT_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVS(_11, "[", referencedFields, "] = ?0"); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1543); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1544); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1544); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1545); if (Z_TYPE_P(value) == IS_NULL) { validateWithNulls = 1; } } ZEPHIR_OBS_NVAR(extraConditions); if (zephir_array_isset_string_fetch(&extraConditions, foreignKey, SS("conditions"), 0 TSRMLS_CC)) { - zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1555); + zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1556); } if (validateWithNulls) { ZEPHIR_OBS_NVAR(allowNulls); @@ -2256,7 +2255,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { ZEPHIR_CALL_METHOD(&relations, manager, "gethasoneandhasmany", NULL, 0, this_ptr); zephir_check_call_status(); if (zephir_fast_count_int(relations TSRMLS_CC)) { - zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1715); + zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1716); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -2269,7 +2268,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { if (Z_TYPE_P(foreignKey) == IS_ARRAY) { if (zephir_array_isset_string(foreignKey, SS("action"))) { ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1654 TSRMLS_CC); + zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1655 TSRMLS_CC); action = zephir_get_intval(_4); } } @@ -2287,7 +2286,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { ZEPHIR_INIT_NVAR(bindParams); array_init(bindParams); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1682); + zephir_is_iterable(fields, &_8, &_7, 0, 0, "phalcon/mvc/model.zep", 1683); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) @@ -2296,23 +2295,23 @@ PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseCascade) { ZEPHIR_GET_HVALUE(field, _9); ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, field, PH_SILENT_CC); - zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1679 TSRMLS_CC); + zephir_array_fetch(&_10, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1680 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVSV(_11, "[", _10, "] = ?", position); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1679); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1680); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1680); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1681); } } else { ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, fields, PH_SILENT_CC); ZEPHIR_INIT_LNVAR(_11); ZEPHIR_CONCAT_SVS(_11, "[", referencedFields, "] = ?0"); - zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1684); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1685); + zephir_array_append(&conditions, _11, PH_SEPARATE, "phalcon/mvc/model.zep", 1685); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1686); } ZEPHIR_OBS_NVAR(extraConditions); if (zephir_array_isset_string_fetch(&extraConditions, foreignKey, SS("conditions"), 0 TSRMLS_CC)) { - zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1692); + zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1693); } ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -2356,7 +2355,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { zephir_check_call_status(); if (zephir_fast_count_int(relations TSRMLS_CC)) { error = 0; - zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1834); + zephir_is_iterable(relations, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 1835); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -2369,7 +2368,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { if (Z_TYPE_P(foreignKey) == IS_ARRAY) { if (zephir_array_isset_string(foreignKey, SS("action"))) { ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1762 TSRMLS_CC); + zephir_array_fetch_string(&_4, foreignKey, SL("action"), PH_NOISY, "phalcon/mvc/model.zep", 1763 TSRMLS_CC); action = zephir_get_intval(_4); } } @@ -2387,7 +2386,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { ZEPHIR_INIT_NVAR(bindParams); array_init(bindParams); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/mvc/model.zep", 1794); + zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/mvc/model.zep", 1795); for ( ; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS ; zephir_hash_move_forward_ex(_7, &_6) @@ -2396,23 +2395,23 @@ PHP_METHOD(Phalcon_Mvc_Model, _checkForeignKeysReverseRestrict) { ZEPHIR_GET_HVALUE(field, _8); ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, field, PH_SILENT_CC); - zephir_array_fetch(&_9, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1790 TSRMLS_CC); + zephir_array_fetch(&_9, referencedFields, position, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 1791 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVSV(_10, "[", _9, "] = ?", position); - zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1790); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1791); + zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1791); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1792); } } else { ZEPHIR_OBS_NVAR(value); zephir_fetch_property_zval(&value, this_ptr, fields, PH_SILENT_CC); ZEPHIR_INIT_LNVAR(_10); ZEPHIR_CONCAT_SVS(_10, "[", referencedFields, "] = ?0"); - zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1796); - zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1797); + zephir_array_append(&conditions, _10, PH_SEPARATE, "phalcon/mvc/model.zep", 1797); + zephir_array_append(&bindParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 1798); } ZEPHIR_OBS_NVAR(extraConditions); if (zephir_array_isset_string_fetch(&extraConditions, foreignKey, SS("conditions"), 0 TSRMLS_CC)) { - zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1804); + zephir_array_append(&conditions, extraConditions, PH_SEPARATE, "phalcon/mvc/model.zep", 1805); } ZEPHIR_INIT_NVAR(_12); zephir_create_array(_12, 2, 0 TSRMLS_CC); @@ -2539,7 +2538,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _preSave) { ZEPHIR_CALL_METHOD(&emptyStringValues, metaData, "getemptystringattributes", NULL, 0, this_ptr); zephir_check_call_status(); error = 0; - zephir_is_iterable(notNull, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 2000); + zephir_is_iterable(notNull, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 2001); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -2556,7 +2555,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _preSave) { ZEPHIR_CONCAT_SVS(_7, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 1936 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 1937 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -2745,8 +2744,8 @@ PHP_METHOD(Phalcon_Mvc_Model, _postSave) { /** * Sends a pre-build INSERT SQL statement to the relational database system * - * @param Phalcon\Mvc\Model\MetadataInterface metaData - * @param Phalcon\Db\AdapterInterface connection + * @param \Phalcon\Mvc\Model\MetadataInterface metaData + * @param \Phalcon\Db\AdapterInterface connection * @param string|array table * @param boolean|string identityField * @return boolean @@ -2788,7 +2787,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_INIT_NVAR(columnMap); ZVAL_NULL(columnMap); } - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 2184); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 2185); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -2804,7 +2803,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2138 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2139 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -2830,23 +2829,23 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Column '", field, "' have not defined a bind data type"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2162 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2163 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2165); - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2165); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2165); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2166); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2166); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2166); } else { if (zephir_array_isset(defaultValues, field)) { ZEPHIR_CALL_METHOD(&_8, connection, "getdefaultvalue", &_9, 0); zephir_check_call_status(); - zephir_array_append(&values, _8, PH_SEPARATE, "phalcon/mvc/model.zep", 2170); + zephir_array_append(&values, _8, PH_SEPARATE, "phalcon/mvc/model.zep", 2171); } else { - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2172); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2173); } - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2175); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2175); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2176); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2176); } } } @@ -2858,7 +2857,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { zephir_check_call_status(); useExplicitIdentity = zephir_get_boolval(_8); if (useExplicitIdentity) { - zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2193); + zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2194); } if (Z_TYPE_P(columnMap) == IS_ARRAY) { ZEPHIR_OBS_NVAR(attributeField); @@ -2869,7 +2868,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Identity column '", identityField, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2201 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2202 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -2884,12 +2883,12 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { } if (_6) { if (useExplicitIdentity) { - zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2214); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2214); + zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2215); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2215); } } else { if (!(useExplicitIdentity)) { - zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2222); + zephir_array_append(&fields, identityField, PH_SEPARATE, "phalcon/mvc/model.zep", 2223); } ZEPHIR_OBS_NVAR(bindType); if (!(zephir_array_isset_fetch(&bindType, bindDataTypes, identityField, 0 TSRMLS_CC))) { @@ -2899,17 +2898,17 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { ZEPHIR_CONCAT_SVS(_4, "Identity column '", identityField, "' isn\\'t part of the table columns"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2229 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 2230 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2232); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2232); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2233); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2233); } } else { if (useExplicitIdentity) { - zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2236); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2236); + zephir_array_append(&values, defaultValue, PH_SEPARATE, "phalcon/mvc/model.zep", 2237); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2237); } } } @@ -2953,8 +2952,8 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowInsert) { /** * Sends a pre-build UPDATE SQL statement to the relational database system * - * @param Phalcon\Mvc\Model\MetaDataInterface metaData - * @param Phalcon\Db\AdapterInterface connection + * @param \Phalcon\Mvc\Model\MetaDataInterface metaData + * @param \Phalcon\Db\AdapterInterface connection * @param string|array table * @return boolean */ @@ -3007,7 +3006,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_INIT_NVAR(columnMap); ZVAL_NULL(columnMap); } - zephir_is_iterable(nonPrimary, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 2436); + zephir_is_iterable(nonPrimary, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 2437); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -3022,7 +3021,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CONCAT_SVS(_6, "Column '", field, "' have not defined a bind data type"); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2335 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2336 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -3035,7 +3034,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CONCAT_SVS(_6, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2343 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2344 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -3045,9 +3044,9 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_OBS_NVAR(value); if (zephir_fetch_property_zval(&value, this_ptr, attributeField, PH_SILENT_CC)) { if (!(useDynamicUpdate)) { - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2359); - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2359); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2360); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2360); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2360); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2361); } else { ZEPHIR_OBS_NVAR(snapshotValue); if (!(zephir_array_isset_fetch(&snapshotValue, snapshot, attributeField, 0 TSRMLS_CC))) { @@ -3069,9 +3068,9 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { break; } if (ZEPHIR_IS_LONG(bindType, 3) || ZEPHIR_IS_LONG(bindType, 7)) { - ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 311, snapshotValue); + ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 304, snapshotValue); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 311, value); + ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 304, value); zephir_check_call_status(); changed = !ZEPHIR_IS_IDENTICAL(_1, _9); break; @@ -3089,15 +3088,15 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { } } if (changed) { - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2422); - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2422); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2423); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2423); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2423); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 2424); } } } else { - zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2428); - zephir_array_append(&values, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2428); - zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2428); + zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/mvc/model.zep", 2429); + zephir_array_append(&values, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2429); + zephir_array_append(&bindTypes, bindSkip, PH_SEPARATE, "phalcon/mvc/model.zep", 2429); } } } @@ -3114,12 +3113,12 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CALL_METHOD(&primaryKeys, metaData, "getprimarykeyattributes", NULL, 0, this_ptr); zephir_check_call_status(); if (!(zephir_fast_count_int(primaryKeys TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 2455); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 2456); return; } ZEPHIR_INIT_NVAR(uniqueParams); array_init(uniqueParams); - zephir_is_iterable(primaryKeys, &_13, &_12, 0, 0, "phalcon/mvc/model.zep", 2478); + zephir_is_iterable(primaryKeys, &_13, &_12, 0, 0, "phalcon/mvc/model.zep", 2479); for ( ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS ; zephir_hash_move_forward_ex(_13, &_12) @@ -3134,7 +3133,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { ZEPHIR_CONCAT_SVS(_6, "Column '", field, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2466 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model.zep", 2467 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -3143,9 +3142,9 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { } ZEPHIR_OBS_NVAR(value); if (zephir_fetch_property_zval(&value, this_ptr, attributeField, PH_SILENT_CC)) { - zephir_array_append(&uniqueParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2473); + zephir_array_append(&uniqueParams, value, PH_SEPARATE, "phalcon/mvc/model.zep", 2474); } else { - zephir_array_append(&uniqueParams, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2475); + zephir_array_append(&uniqueParams, ZEPHIR_GLOBAL(global_null), PH_SEPARATE, "phalcon/mvc/model.zep", 2476); } } } @@ -3163,8 +3162,8 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) { /** * Saves related records that must be stored prior to save the master record * - * @param Phalcon\Db\AdapterInterface connection - * @param Phalcon\Mvc\ModelInterface[] related + * @param \Phalcon\Db\AdapterInterface connection + * @param \Phalcon\Mvc\ModelInterface[] related * @return boolean */ PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { @@ -3189,7 +3188,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmodelsmanager", NULL, 0); zephir_check_call_status(); ZEPHIR_CPY_WRT(manager, _0); - zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2584); + zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2585); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -3206,7 +3205,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { if (Z_TYPE_P(record) != IS_OBJECT) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_5, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects can be stored as part of belongs-to relations", "phalcon/mvc/model.zep", 2533); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects can be stored as part of belongs-to relations", "phalcon/mvc/model.zep", 2534); return; } ZEPHIR_CALL_METHOD(&columns, relation, "getfields", NULL, 0); @@ -3218,7 +3217,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { if (Z_TYPE_P(columns) == IS_ARRAY) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_6, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2542); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2543); return; } ZEPHIR_CALL_METHOD(&_0, record, "save", NULL, 0); @@ -3226,7 +3225,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _preSaveRelatedRecords) { if (!(zephir_is_true(_0))) { ZEPHIR_CALL_METHOD(&_7, record, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_7, &_9, &_8, 0, 0, "phalcon/mvc/model.zep", 2571); + zephir_is_iterable(_7, &_9, &_8, 0, 0, "phalcon/mvc/model.zep", 2572); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) @@ -3280,7 +3279,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmodelsmanager", NULL, 0); zephir_check_call_status(); ZEPHIR_CPY_WRT(manager, _0); - zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2772); + zephir_is_iterable(related, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 2773); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -3303,7 +3302,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (_5) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_6, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects/arrays can be stored as part of has-many/has-one/has-many-to-many relations", "phalcon/mvc/model.zep", 2623); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only objects/arrays can be stored as part of has-many/has-one/has-many-to-many relations", "phalcon/mvc/model.zep", 2624); return; } ZEPHIR_CALL_METHOD(&columns, relation, "getfields", NULL, 0); @@ -3315,7 +3314,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (Z_TYPE_P(columns) == IS_ARRAY) { ZEPHIR_CALL_METHOD(NULL, connection, "rollback", &_7, 0, (nesting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2632); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not implemented", "phalcon/mvc/model.zep", 2633); return; } if (Z_TYPE_P(record) == IS_OBJECT) { @@ -3335,7 +3334,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CONCAT_SVS(_10, "The column '", columns, "' needs to be present in the model"); ZEPHIR_CALL_METHOD(NULL, _9, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2646 TSRMLS_CC); + zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2647 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -3350,7 +3349,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CALL_METHOD(&intermediateReferencedFields, relation, "getintermediatereferencedfields", NULL, 0); zephir_check_call_status(); } - zephir_is_iterable(relatedRecords, &_14, &_13, 0, 0, "phalcon/mvc/model.zep", 2761); + zephir_is_iterable(relatedRecords, &_14, &_13, 0, 0, "phalcon/mvc/model.zep", 2762); for ( ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS ; zephir_hash_move_forward_ex(_14, &_13) @@ -3365,7 +3364,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (!(zephir_is_true(_12))) { ZEPHIR_CALL_METHOD(&_16, recordAfter, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_16, &_18, &_17, 0, 0, "phalcon/mvc/model.zep", 2703); + zephir_is_iterable(_16, &_18, &_17, 0, 0, "phalcon/mvc/model.zep", 2704); for ( ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS ; zephir_hash_move_forward_ex(_18, &_17) @@ -3398,7 +3397,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { if (!(zephir_is_true(_16))) { ZEPHIR_CALL_METHOD(&_23, intermediateModel, "getmessages", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_23, &_25, &_24, 0, 0, "phalcon/mvc/model.zep", 2755); + zephir_is_iterable(_23, &_25, &_24, 0, 0, "phalcon/mvc/model.zep", 2756); for ( ; zephir_hash_get_current_data_ex(_25, (void**) &_26, &_24) == SUCCESS ; zephir_hash_move_forward_ex(_25, &_24) @@ -3427,7 +3426,7 @@ PHP_METHOD(Phalcon_Mvc_Model, _postSaveRelatedRecords) { ZEPHIR_CONCAT_SVSVS(_10, "There are no defined relations for the model '", className, "' using alias '", name, "'"); ZEPHIR_CALL_METHOD(NULL, _9, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2764 TSRMLS_CC); + zephir_throw_exception_debug(_9, "phalcon/mvc/model.zep", 2765 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -3543,9 +3542,9 @@ PHP_METHOD(Phalcon_Mvc_Model, save) { ZEPHIR_INIT_NVAR(_4); object_init_ex(_4, phalcon_mvc_model_validationfailed_ce); _3 = zephir_fetch_nproperty_this(this_ptr, SL("_errorMessages"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 312, this_ptr, _3); + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 305, this_ptr, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 2877 TSRMLS_CC); + zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 2878 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -3563,11 +3562,6 @@ PHP_METHOD(Phalcon_Mvc_Model, save) { ZVAL_LONG(_3, 0); zephir_update_property_this(this_ptr, SL("_dirtyState"), _3 TSRMLS_CC); } - if (ZEPHIR_GLOBAL(orm).events) { - ZEPHIR_CALL_METHOD(&_2, this_ptr, "_postsave", NULL, 0, success, exists); - zephir_check_call_status(); - ZEPHIR_CPY_WRT(success, _2); - } if (Z_TYPE_P(related) == IS_ARRAY) { if (ZEPHIR_IS_FALSE_IDENTICAL(success)) { ZEPHIR_INIT_NVAR(_1); @@ -3579,6 +3573,11 @@ PHP_METHOD(Phalcon_Mvc_Model, save) { zephir_check_call_status(); } } + if (ZEPHIR_GLOBAL(orm).events) { + ZEPHIR_CALL_METHOD(&_2, this_ptr, "_postsave", NULL, 0, success, exists); + zephir_check_call_status(); + ZEPHIR_CPY_WRT(success, _2); + } if (ZEPHIR_IS_FALSE_IDENTICAL(success)) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "_canceloperation", NULL, 0); zephir_check_call_status(); @@ -3781,10 +3780,10 @@ PHP_METHOD(Phalcon_Mvc_Model, delete) { ZVAL_NULL(columnMap); } if (!(zephir_fast_count_int(primaryKeys TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 3061); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A primary key must be defined in the model in order to perform the operation", "phalcon/mvc/model.zep", 3062); return; } - zephir_is_iterable(primaryKeys, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 3102); + zephir_is_iterable(primaryKeys, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 3103); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -3798,7 +3797,7 @@ PHP_METHOD(Phalcon_Mvc_Model, delete) { ZEPHIR_CONCAT_SVS(_7, "Column '", primaryKey, "' have not defined a bind data type"); ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3073 TSRMLS_CC); + zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3074 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -3811,7 +3810,7 @@ PHP_METHOD(Phalcon_Mvc_Model, delete) { ZEPHIR_CONCAT_SVS(_7, "Column '", primaryKey, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3081 TSRMLS_CC); + zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3082 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -3826,17 +3825,17 @@ PHP_METHOD(Phalcon_Mvc_Model, delete) { ZEPHIR_CONCAT_SVS(_7, "Cannot delete the record because the primary key attribute: '", attributeField, "' wasn't set"); ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3091 TSRMLS_CC); + zephir_throw_exception_debug(_6, "phalcon/mvc/model.zep", 3092 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 3097); + zephir_array_append(&values, value, PH_SEPARATE, "phalcon/mvc/model.zep", 3098); ZEPHIR_CALL_METHOD(&_2, writeConnection, "escapeidentifier", &_9, 0, primaryKey); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_VS(_7, _2, " = ?"); - zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model.zep", 3098); - zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 3099); + zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model.zep", 3099); + zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model.zep", 3100); } if (ZEPHIR_GLOBAL(orm).events) { zephir_update_property_this(this_ptr, SL("_skipped"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); @@ -3919,7 +3918,7 @@ PHP_METHOD(Phalcon_Mvc_Model, refresh) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC); if (!ZEPHIR_IS_LONG(_0, 0)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3177); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3178); return; } ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0); @@ -3944,7 +3943,7 @@ PHP_METHOD(Phalcon_Mvc_Model, refresh) { ZEPHIR_CALL_METHOD(&_1, this_ptr, "_exists", NULL, 0, metaData, readConnection, table); zephir_check_call_status(); if (!(zephir_is_true(_1))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3199); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3200); return; } ZEPHIR_OBS_NVAR(uniqueKey); @@ -3953,14 +3952,14 @@ PHP_METHOD(Phalcon_Mvc_Model, refresh) { ZEPHIR_OBS_VAR(uniqueParams); zephir_read_property_this(&uniqueParams, this_ptr, SL("_uniqueParams"), PH_NOISY_CC); if (Z_TYPE_P(uniqueParams) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3207); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record cannot be refreshed because it does not exist or is deleted", "phalcon/mvc/model.zep", 3208); return; } ZEPHIR_INIT_VAR(fields); array_init(fields); ZEPHIR_CALL_METHOD(&_1, metaData, "getattributes", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3221); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3222); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -3969,7 +3968,7 @@ PHP_METHOD(Phalcon_Mvc_Model, refresh) { ZEPHIR_INIT_NVAR(_5); zephir_create_array(_5, 1, 0 TSRMLS_CC); zephir_array_fast_append(_5, attribute); - zephir_array_append(&fields, _5, PH_SEPARATE, "phalcon/mvc/model.zep", 3215); + zephir_array_append(&fields, _5, PH_SEPARATE, "phalcon/mvc/model.zep", 3216); } ZEPHIR_CALL_METHOD(&dialect, readConnection, "getdialect", NULL, 0); zephir_check_call_status(); @@ -4118,7 +4117,7 @@ PHP_METHOD(Phalcon_Mvc_Model, skipAttributes) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3302); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3303); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -4170,7 +4169,7 @@ PHP_METHOD(Phalcon_Mvc_Model, skipAttributesOnCreate) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3333); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3334); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -4220,7 +4219,7 @@ PHP_METHOD(Phalcon_Mvc_Model, skipAttributesOnUpdate) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3362); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3363); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -4270,7 +4269,7 @@ PHP_METHOD(Phalcon_Mvc_Model, allowEmptyStringValues) { ZEPHIR_INIT_VAR(keysAttributes); array_init(keysAttributes); - zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3391); + zephir_is_iterable(attributes, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3392); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -4611,7 +4610,7 @@ PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) { if (Z_TYPE_P(columnMap) == IS_ARRAY) { ZEPHIR_INIT_VAR(snapshot); array_init(snapshot); - zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3605); + zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3606); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -4630,7 +4629,7 @@ PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3586 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3587 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -4647,7 +4646,7 @@ PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) { ZEPHIR_CONCAT_SVS(_4, "Column '", key, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_5, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3595 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model.zep", 3596 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { @@ -4712,12 +4711,12 @@ PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_OBS_VAR(snapshot); zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC); if (Z_TYPE_P(snapshot) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3644); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3645); return; } _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC); if (!ZEPHIR_IS_LONG(_0, 0)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3651); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3652); return; } ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0); @@ -4739,7 +4738,7 @@ PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3683 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3684 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -4751,7 +4750,7 @@ PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3687 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3688 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -4764,7 +4763,7 @@ PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not defined on the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3695 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3696 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -4776,14 +4775,14 @@ PHP_METHOD(Phalcon_Mvc_Model, hasChanged) { ZEPHIR_CONCAT_SVS(_3, "The field '", fieldName, "' was not found in the snapshot"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3702 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3703 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } RETURN_MM_BOOL(!ZEPHIR_IS_EQUAL(value, originalValue)); } ZEPHIR_INIT_NVAR(_1); - zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3738); + zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3739); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -4821,12 +4820,12 @@ PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) { ZEPHIR_OBS_VAR(snapshot); zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC); if (Z_TYPE_P(snapshot) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3751); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3752); return; } _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC); if (!ZEPHIR_IS_LONG(_0, 0)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3758); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3759); return; } ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0); @@ -4842,7 +4841,7 @@ PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) { ZEPHIR_INIT_VAR(changed); array_init(changed); ZEPHIR_INIT_VAR(_1); - zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3812); + zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3813); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -4850,17 +4849,17 @@ PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) { ZEPHIR_GET_HMKEY(name, _3, _2); ZEPHIR_GET_HVALUE(_1, _4); if (!(zephir_array_isset(snapshot, name))) { - zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3791); + zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3792); continue; } ZEPHIR_OBS_NVAR(value); if (!(zephir_fetch_property_zval(&value, this_ptr, name, PH_SILENT_CC))) { - zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3799); + zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3800); continue; } - zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3806 TSRMLS_CC); + zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3807 TSRMLS_CC); if (!ZEPHIR_IS_EQUAL(value, _5)) { - zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3807); + zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3808); continue; } } @@ -4908,7 +4907,7 @@ PHP_METHOD(Phalcon_Mvc_Model, useDynamicUpdate) { * * @param string alias * @param array arguments - * @return Phalcon\Mvc\Model\ResultsetInterface + * @return \Phalcon\Mvc\Model\ResultsetInterface */ PHP_METHOD(Phalcon_Mvc_Model, getRelated) { @@ -4940,7 +4939,7 @@ PHP_METHOD(Phalcon_Mvc_Model, getRelated) { ZEPHIR_CONCAT_SVSVS(_3, "There is no defined relations for the model '", className, "' using alias '", alias, "'"); ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3854 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3855 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -5093,7 +5092,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __call) { ZEPHIR_CONCAT_SVSVS(_2, "The method '", method, "' doesn't exist on model '", modelName, "'"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3946 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3947 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -5111,16 +5110,13 @@ PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { zval *_6, *_7; zend_class_entry *_5, *_8; int ZEPHIR_LAST_CALL_STATUS; - zval *method_param = NULL, *arguments = NULL, *extraMethod = NULL, *type = NULL, *modelName, *value, *model, *attributes = NULL, *field = NULL, *extraMethodFirst = NULL, *metaData = NULL, _0 = zval_used_for_init, *_1 = NULL, *_2 = NULL, *_4 = NULL; + zval *method_param = NULL, *arguments, *extraMethod = NULL, *type = NULL, *modelName, *value, *model, *attributes = NULL, *field = NULL, *extraMethodFirst = NULL, *metaData = NULL, _0 = zval_used_for_init, *_1 = NULL, *_2 = NULL, *_4 = NULL; zval *method = NULL, *_3; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 1, &method_param, &arguments); + zephir_fetch_params(1, 2, 0, &method_param, &arguments); zephir_get_strval(method, method_param); - if (!arguments) { - arguments = ZEPHIR_GLOBAL(global_null); - } ZEPHIR_INIT_VAR(extraMethod); @@ -5162,7 +5158,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { ZEPHIR_CONCAT_SVSVS(_2, "The static method '", method, "' doesn't exist on model '", modelName, "'"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3997 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3998 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -5174,7 +5170,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { ZEPHIR_CONCAT_SVS(_3, "The static method '", method, "' requires one argument"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4001 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4002 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -5197,7 +5193,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { if (zephir_array_isset(attributes, extraMethod)) { ZEPHIR_CPY_WRT(field, extraMethod); } else { - ZEPHIR_CALL_FUNCTION(&extraMethodFirst, "lcfirst", NULL, 65, extraMethod); + ZEPHIR_CALL_FUNCTION(&extraMethodFirst, "lcfirst", NULL, 67, extraMethod); zephir_check_call_status(); if (zephir_array_isset(attributes, extraMethodFirst)) { ZEPHIR_CPY_WRT(field, extraMethodFirst); @@ -5211,7 +5207,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __callStatic) { ZEPHIR_CONCAT_SVS(_2, "Cannot resolve attribute '", extraMethod, "' in the model"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4035 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4036 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -5276,7 +5272,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __set) { zephir_check_call_status(); ZEPHIR_INIT_VAR(related); array_init(related); - zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4099); + zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4100); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -5285,7 +5281,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __set) { ZEPHIR_GET_HVALUE(item, _3); if (Z_TYPE_P(item) == IS_OBJECT) { if (zephir_instance_of_ev(item, phalcon_mvc_modelinterface_ce TSRMLS_CC)) { - zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4086); + zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4087); } } else { ZEPHIR_INIT_NVAR(lowerKey); @@ -5323,7 +5319,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __set) { * Magic method to get related records using the relation alias as a property * * @param string property - * @return Phalcon\Mvc\Model\Resultset|Phalcon\Mvc\Model + * @return \Phalcon\Mvc\Model\Resultset|Phalcon\Mvc\Model */ PHP_METHOD(Phalcon_Mvc_Model, __get) { @@ -5447,7 +5443,7 @@ PHP_METHOD(Phalcon_Mvc_Model, serialize) { ZEPHIR_CALL_METHOD(&_0, this_ptr, "toarray", NULL, 0); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -5481,13 +5477,13 @@ PHP_METHOD(Phalcon_Mvc_Model, unserialize) { } - ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&attributes, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(attributes) == IS_ARRAY) { ZEPHIR_CALL_CE_STATIC(&dependencyInjector, phalcon_di_ce, "getdefault", &_0, 1); zephir_check_call_status(); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4223); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4224); return; } zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC); @@ -5498,13 +5494,13 @@ PHP_METHOD(Phalcon_Mvc_Model, unserialize) { zephir_check_call_status(); ZEPHIR_CPY_WRT(manager, _1); if (Z_TYPE_P(manager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4236); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4237); return; } zephir_update_property_this(this_ptr, SL("_modelsManager"), manager TSRMLS_CC); ZEPHIR_CALL_METHOD(NULL, manager, "initialize", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4255); + zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4256); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -5531,7 +5527,7 @@ PHP_METHOD(Phalcon_Mvc_Model, dump) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 23, this_ptr); + ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM(); @@ -5571,7 +5567,7 @@ PHP_METHOD(Phalcon_Mvc_Model, toArray) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_0, metaData, "getattributes", NULL, 0, this_ptr); zephir_check_call_status(); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4319); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4320); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -5587,7 +5583,7 @@ PHP_METHOD(Phalcon_Mvc_Model, toArray) { ZEPHIR_CONCAT_SVS(_5, "Column '", attribute, "' doesn't make part of the column map"); ZEPHIR_CALL_METHOD(NULL, _4, "__construct", &_6, 9, _5); zephir_check_call_status(); - zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4297 TSRMLS_CC); + zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4298 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } else { diff --git a/ext/phalcon/mvc/model.zep.h b/ext/phalcon/mvc/model.zep.h index ae6691137d0..f92f60b9f5f 100644 --- a/ext/phalcon/mvc/model.zep.h +++ b/ext/phalcon/mvc/model.zep.h @@ -370,7 +370,7 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model___call, 0, 0, 2) ZEND_ARG_INFO(0, arguments) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model___callstatic, 0, 0, 1) +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model___callstatic, 0, 0, 2) ZEND_ARG_INFO(0, method) ZEND_ARG_INFO(0, arguments) ZEND_END_ARG_INFO() diff --git a/ext/phalcon/mvc/model/behavior.zep.c b/ext/phalcon/mvc/model/behavior.zep.c index 0b383c0cc82..2454eb58dc8 100644 --- a/ext/phalcon/mvc/model/behavior.zep.c +++ b/ext/phalcon/mvc/model/behavior.zep.c @@ -148,7 +148,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Behavior, notify) { /** * Acts as fallbacks when a missing method is called on the model * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @param string method * @param array arguments */ diff --git a/ext/phalcon/mvc/model/behavior/timestampable.zep.c b/ext/phalcon/mvc/model/behavior/timestampable.zep.c index 25fa1f50ad7..fb14f196916 100644 --- a/ext/phalcon/mvc/model/behavior/timestampable.zep.c +++ b/ext/phalcon/mvc/model/behavior/timestampable.zep.c @@ -84,7 +84,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Behavior_Timestampable, notify) { ZVAL_NULL(timestamp); ZEPHIR_OBS_VAR(format); if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format); + ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 293, format); zephir_check_call_status(); } else { ZEPHIR_OBS_VAR(generator); diff --git a/ext/phalcon/mvc/model/behaviorinterface.zep.c b/ext/phalcon/mvc/model/behaviorinterface.zep.c index 4f51fcc995d..9d8b1a58161 100644 --- a/ext/phalcon/mvc/model/behaviorinterface.zep.c +++ b/ext/phalcon/mvc/model/behaviorinterface.zep.c @@ -40,7 +40,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_BehaviorInterface, notify); /** * Calls a method when it's missing in the model * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @param string method * @param array arguments */ diff --git a/ext/phalcon/mvc/model/criteria.zep.c b/ext/phalcon/mvc/model/criteria.zep.c index 7cd026776a2..6007c0d1763 100644 --- a/ext/phalcon/mvc/model/criteria.zep.c +++ b/ext/phalcon/mvc/model/criteria.zep.c @@ -208,7 +208,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, distinct) { * * * @param string|array columns - * @return Phalcon\Mvc\Model\Criteria + * @return \Phalcon\Mvc\Model\Criteria */ PHP_METHOD(Phalcon_Mvc_Model_Criteria, columns) { @@ -715,9 +715,9 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, betweenWhere) { ZEPHIR_INIT_VAR(nextHiddenParam); ZVAL_LONG(nextHiddenParam, (zephir_get_numberval(hiddenParam) + 1)); ZEPHIR_INIT_VAR(minimumKey); - ZEPHIR_CONCAT_SV(minimumKey, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(minimumKey, "ACP", hiddenParam); ZEPHIR_INIT_VAR(maximumKey); - ZEPHIR_CONCAT_SV(maximumKey, "AP", nextHiddenParam); + ZEPHIR_CONCAT_SV(maximumKey, "ACP", nextHiddenParam); ZEPHIR_INIT_VAR(_0); ZEPHIR_CONCAT_VSVSVS(_0, expr, " BETWEEN :", minimumKey, ": AND :", maximumKey, ":"); ZEPHIR_INIT_VAR(_1); @@ -768,9 +768,9 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, notBetweenWhere) { ZEPHIR_INIT_VAR(nextHiddenParam); ZVAL_LONG(nextHiddenParam, (zephir_get_numberval(hiddenParam) + 1)); ZEPHIR_INIT_VAR(minimumKey); - ZEPHIR_CONCAT_SV(minimumKey, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(minimumKey, "ACP", hiddenParam); ZEPHIR_INIT_VAR(maximumKey); - ZEPHIR_CONCAT_SV(maximumKey, "AP", nextHiddenParam); + ZEPHIR_CONCAT_SV(maximumKey, "ACP", nextHiddenParam); ZEPHIR_INIT_VAR(_0); ZEPHIR_CONCAT_VSVSVS(_0, expr, " NOT BETWEEN :", minimumKey, ": AND :", maximumKey, ":"); ZEPHIR_INIT_VAR(_1); @@ -826,17 +826,17 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, inWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 451); + zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 450); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(value, _2); ZEPHIR_INIT_NVAR(key); - ZEPHIR_CONCAT_SV(key, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(key, "ACP", hiddenParam); ZEPHIR_INIT_NVAR(queryKey); ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":"); - zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 442); + zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 441); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); ZEPHIR_SEPARATE(hiddenParam); zephir_increment(hiddenParam); @@ -892,17 +892,17 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, notInWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 488); + zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 487); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(value, _2); ZEPHIR_INIT_NVAR(key); - ZEPHIR_CONCAT_SV(key, "AP", hiddenParam); + ZEPHIR_CONCAT_SV(key, "ACP", hiddenParam); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVS(_3, ":", key, ":"); - zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 478); + zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 477); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); ZEPHIR_SEPARATE(hiddenParam); zephir_increment(hiddenParam); @@ -1304,11 +1304,11 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { zend_class_entry *_2; int ZEPHIR_LAST_CALL_STATUS; zval *data = NULL; - zval *modelName = NULL; - zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *attribute = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *columnMap = NULL, *_0 = NULL, *_1 = NULL, **_5, *_8 = NULL, *_9 = NULL; + zval *modelName = NULL, *operator = NULL, *_10; + zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *operator_param = NULL, *attribute = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *columnMap = NULL, *_0 = NULL, *_1 = NULL, **_5, *_8 = NULL, *_9 = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 3, 0, &dependencyInjector, &modelName_param, &data_param); + zephir_fetch_params(1, 3, 1, &dependencyInjector, &modelName_param, &data_param, &operator_param); if (unlikely(Z_TYPE_P(modelName_param) != IS_STRING && Z_TYPE_P(modelName_param) != IS_NULL)) { zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'modelName' must be a string") TSRMLS_CC); @@ -1323,6 +1323,22 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } data = data_param; + if (!operator_param) { + ZEPHIR_INIT_VAR(operator); + ZVAL_STRING(operator, "AND", 1); + } else { + if (unlikely(Z_TYPE_P(operator_param) != IS_STRING && Z_TYPE_P(operator_param) != IS_NULL)) { + zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'operator' must be a string") TSRMLS_CC); + RETURN_MM_NULL(); + } + + if (likely(Z_TYPE_P(operator_param) == IS_STRING)) { + zephir_get_strval(operator, operator_param); + } else { + ZEPHIR_INIT_VAR(operator); + ZVAL_EMPTY_STRING(operator); + } + } ZEPHIR_INIT_VAR(conditions); @@ -1347,7 +1363,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { zephir_check_call_status(); ZEPHIR_INIT_VAR(bind); array_init(bind); - zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 732); + zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 731); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -1360,7 +1376,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } if (_6) { ZEPHIR_OBS_NVAR(attribute); - zephir_array_fetch(&attribute, columnMap, field, PH_NOISY, "phalcon/mvc/model/criteria.zep", 709 TSRMLS_CC); + zephir_array_fetch(&attribute, columnMap, field, PH_NOISY, "phalcon/mvc/model/criteria.zep", 708 TSRMLS_CC); } else { ZEPHIR_CPY_WRT(attribute, field); } @@ -1374,7 +1390,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { if (ZEPHIR_IS_LONG(type, 2)) { ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] LIKE :", field, ":"); - zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 721); + zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 720); ZEPHIR_INIT_LNVAR(_9); ZEPHIR_CONCAT_SVS(_9, "%", value, "%"); zephir_array_update_zval(&bind, field, &_9, PH_COPY | PH_SEPARATE); @@ -1382,7 +1398,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] = :", field, ":"); - zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 728); + zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 727); zephir_array_update_zval(&bind, field, &value, PH_COPY | PH_SEPARATE); } } @@ -1396,13 +1412,15 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) { } if (zephir_fast_count_int(conditions TSRMLS_CC)) { ZEPHIR_INIT_NVAR(_0); - zephir_fast_join_str(_0, SL(" AND "), conditions TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 313, _0); + ZEPHIR_INIT_VAR(_10); + ZEPHIR_CONCAT_SVS(_10, " ", operator, " "); + zephir_fast_join(_0, _10, conditions TSRMLS_CC); + ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 306, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 314, bind); + ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 307, bind); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, modelName); + ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 303, modelName); zephir_check_call_status(); RETURN_CCTOR(criteria); @@ -1422,7 +1440,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, execute) { ZEPHIR_CALL_METHOD(&model, this_ptr, "getmodelname", NULL, 0); zephir_check_call_status(); if (Z_TYPE_P(model) != IS_STRING) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 756); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 755); return; } ZEPHIR_CALL_METHOD(&_0, this_ptr, "getparams", NULL, 0); diff --git a/ext/phalcon/mvc/model/criteria.zep.h b/ext/phalcon/mvc/model/criteria.zep.h index 5b288581d29..b06011aeef7 100644 --- a/ext/phalcon/mvc/model/criteria.zep.h +++ b/ext/phalcon/mvc/model/criteria.zep.h @@ -179,6 +179,7 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_criteria_frominput, 0, 0, 3) ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 0) ZEND_ARG_INFO(0, modelName) ZEND_ARG_ARRAY_INFO(0, data, 0) + ZEND_ARG_INFO(0, operator) ZEND_END_ARG_INFO() ZEPHIR_INIT_FUNCS(phalcon_mvc_model_criteria_method_entry) { diff --git a/ext/phalcon/mvc/model/criteriainterface.zep.c b/ext/phalcon/mvc/model/criteriainterface.zep.c index fe422ed974e..f73f312ed94 100644 --- a/ext/phalcon/mvc/model/criteriainterface.zep.c +++ b/ext/phalcon/mvc/model/criteriainterface.zep.c @@ -67,7 +67,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, orderBy); * * @param int limit * @param int offset - * @return Phalcon\Mvc\Model\CriteriaInterface + * @return \Phalcon\Mvc\Model\CriteriaInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, limit); @@ -87,7 +87,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, sharedLock); * @param string conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\CriteriaInterface + * @return \Phalcon\Mvc\Model\CriteriaInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, andWhere); @@ -97,7 +97,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, andWhere); * @param string conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\CriteriaInterface + * @return \Phalcon\Mvc\Model\CriteriaInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, orWhere); @@ -111,7 +111,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, orWhere); * @param string expr * @param mixed minimum * @param mixed maximum - * @return Phalcon\Mvc\Model\CriteriaInterface + * @return \Phalcon\Mvc\Model\CriteriaInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, betweenWhere); @@ -125,7 +125,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, betweenWhere); * @param string expr * @param mixed minimum * @param mixed maximum - * @return Phalcon\Mvc\Model\CriteriaInterface + * @return \Phalcon\Mvc\Model\CriteriaInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, notBetweenWhere); @@ -185,11 +185,6 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, getOrder); */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, getParams); -/** - * Builds a Phalcon\Mvc\Model\Criteria based on an input array like _POST - */ -ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_CriteriaInterface, fromInput); - /** * Executes a find using the parameters built with the criteria */ diff --git a/ext/phalcon/mvc/model/criteriainterface.zep.h b/ext/phalcon/mvc/model/criteriainterface.zep.h index 48ff22db331..fcf9058dbe1 100644 --- a/ext/phalcon/mvc/model/criteriainterface.zep.h +++ b/ext/phalcon/mvc/model/criteriainterface.zep.h @@ -74,12 +74,6 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_criteriainterface_notinwhere, 0 ZEND_ARG_ARRAY_INFO(0, values, 0) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_criteriainterface_frominput, 0, 0, 3) - ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 0) - ZEND_ARG_INFO(0, modelName) - ZEND_ARG_ARRAY_INFO(0, data, 0) -ZEND_END_ARG_INFO() - ZEPHIR_INIT_FUNCS(phalcon_mvc_model_criteriainterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, setModelName, arginfo_phalcon_mvc_model_criteriainterface_setmodelname) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getModelName, NULL) @@ -102,7 +96,6 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_criteriainterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getLimit, NULL) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getOrder, NULL) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, getParams, NULL) - ZEND_FENTRY(fromInput, NULL, arginfo_phalcon_mvc_model_criteriainterface_frominput, ZEND_ACC_STATIC|ZEND_ACC_ABSTRACT|ZEND_ACC_PUBLIC) PHP_ABSTRACT_ME(Phalcon_Mvc_Model_CriteriaInterface, execute, NULL) PHP_FE_END }; diff --git a/ext/phalcon/mvc/model/manager.zep.c b/ext/phalcon/mvc/model/manager.zep.c index 344cc3406bc..7313d4c2ae3 100644 --- a/ext/phalcon/mvc/model/manager.zep.c +++ b/ext/phalcon/mvc/model/manager.zep.c @@ -30,13 +30,13 @@ * This components controls the initialization of models, keeping record of relations * between the different models of the application. * - * A ModelsManager is injected to a model via a Dependency Injector/Services Container such as Phalcon\DI. + * A ModelsManager is injected to a model via a Dependency Injector/Services Container such as Phalcon\Di. * * - * use Phalcon\DI; + * use Phalcon\Di; * use Phalcon\Mvc\Model\Manager as ModelsManager; * - * $di = new DI(); + * $di = new Di(); * * $di->set('modelsManager', function() { * return new ModelsManager(); @@ -1081,7 +1081,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasOne) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 1); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _1, referencedModel, fields, referencedFields, options); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -1168,7 +1168,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, addBelongsTo) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, 0); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _1, referencedModel, fields, referencedFields, options); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -1255,7 +1255,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasMany) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, 2); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _0, referencedModel, fields, referencedFields, options); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -1365,9 +1365,9 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasManyToMany) { object_init_ex(relation, phalcon_mvc_model_relation_ce); ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, 4); - ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options); + ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 308, _0, referencedModel, fields, referencedFields, options); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 316, intermediateFields, intermediateModel, intermediateReferencedFields); + ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 309, intermediateFields, intermediateModel, intermediateReferencedFields); zephir_check_call_status(); ZEPHIR_OBS_VAR(alias); if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) { @@ -1683,7 +1683,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { ZEPHIR_INIT_VAR(findParams); array_init(findParams); if (Z_TYPE_P(findParamsOne) == IS_ARRAY) { - zephir_is_iterable(findParamsOne, &_3, &_2, 0, 0, "phalcon/mvc/model/manager.zep", 1140); + zephir_is_iterable(findParamsOne, &_3, &_2, 0, 0, "phalcon/mvc/model/manager.zep", 1137); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -1696,12 +1696,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } if (_5) { if (!(zephir_array_isset_long(findParams, 0))) { - zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1131); + zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1128); } else { - zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1133 TSRMLS_CC); + zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1130 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSV(_1, "(", _6, ") AND ", value); - zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1133); + zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1130); } continue; } @@ -1715,7 +1715,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } } if (Z_TYPE_P(findParamsTwo) == IS_ARRAY) { - zephir_is_iterable(findParamsTwo, &_8, &_7, 0, 0, "phalcon/mvc/model/manager.zep", 1174); + zephir_is_iterable(findParamsTwo, &_8, &_7, 0, 0, "phalcon/mvc/model/manager.zep", 1171); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) @@ -1728,12 +1728,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } if (_5) { if (!(zephir_array_isset_long(findParams, 0))) { - zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1152); + zephir_array_update_long(&findParams, 0, &value, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1149); } else { - zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1154 TSRMLS_CC); + zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1151 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSV(_1, "(", _6, ") AND ", value); - zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1154); + zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1151); } continue; } @@ -1749,7 +1749,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } else { if (Z_TYPE_P(value) == IS_ARRAY) { ZEPHIR_INIT_NVAR(_11); - zephir_array_fetch(&_6, findParams, key, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1166 TSRMLS_CC); + zephir_array_fetch(&_6, findParams, key, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1163 TSRMLS_CC); zephir_fast_array_merge(_11, &(_6), &(value) TSRMLS_CC); zephir_array_update_zval(&findParams, key, &_11, PH_COPY | PH_SEPARATE); } @@ -1761,12 +1761,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { } else { if (Z_TYPE_P(findParamsTwo) == IS_STRING) { if (!(zephir_array_isset_long(findParams, 0))) { - zephir_array_update_long(&findParams, 0, &findParamsTwo, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1177); + zephir_array_update_long(&findParams, 0, &findParamsTwo, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1174); } else { - zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1179 TSRMLS_CC); + zephir_array_fetch_long(&_6, findParams, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1176 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSV(_1, "(", _6, ") AND ", findParamsTwo); - zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1179); + zephir_array_update_long(&findParams, 0, &_1, PH_COPY | PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1176); } } } @@ -1777,7 +1777,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, _mergeFindParameters) { /** * Helper method to query records based on a relation definition * - * @return Phalcon\Mvc\Model\Resultset\Simple|Phalcon\Mvc\Model\Resultset\Simple|false + * @return \Phalcon\Mvc\Model\Resultset\Simple|Phalcon\Mvc\Model\Resultset\Simple|false */ PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { @@ -1829,12 +1829,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { if (Z_TYPE_P(fields) != IS_ARRAY) { ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVSVS(_1, "[", intermediateModel, "].[", intermediateFields, "] = :APR0:"); - zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1230); + zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1227); ZEPHIR_CALL_METHOD(&_2, record, "readattribute", NULL, 0, fields); zephir_check_call_status(); zephir_array_update_string(&placeholders, SL("APR0"), &_2, PH_COPY | PH_SEPARATE); } else { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1233); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1230); return; } ZEPHIR_INIT_VAR(joinConditions); @@ -1846,12 +1846,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVSVSVSVS(_1, "[", intermediateModel, "].[", intermediateFields, "] = [", referencedModel, "].[", _2, "]"); - zephir_array_append(&joinConditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1243); + zephir_array_append(&joinConditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1240); } else { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1245); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1242); return; } - ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 317, extraParameters, parameters); + ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 310, extraParameters, parameters); zephir_check_call_status(); ZEPHIR_CALL_METHOD(&builder, this_ptr, "createbuilder", NULL, 0, _2); zephir_check_call_status(); @@ -1880,7 +1880,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_1); ZEPHIR_CONCAT_SVS(_1, "[", _6, "] = :APR0:"); - zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1272); + zephir_array_append(&conditions, _1, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1269); ZEPHIR_CALL_METHOD(&_7, record, "readattribute", NULL, 0, fields); zephir_check_call_status(); zephir_array_update_string(&placeholders, SL("APR0"), &_7, PH_COPY | PH_SEPARATE); @@ -1889,17 +1889,17 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&_6, relation, "getreferencedfields", NULL, 0); zephir_check_call_status(); - zephir_is_iterable(_6, &_9, &_8, 0, 0, "phalcon/mvc/model/manager.zep", 1284); + zephir_is_iterable(_6, &_9, &_8, 0, 0, "phalcon/mvc/model/manager.zep", 1281); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) ) { ZEPHIR_GET_HMKEY(refPosition, _9, _8); ZEPHIR_GET_HVALUE(field, _10); - zephir_array_fetch(&_11, referencedFields, refPosition, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1281 TSRMLS_CC); + zephir_array_fetch(&_11, referencedFields, refPosition, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1278 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SVSVS(_12, "[", _11, "] = :APR", refPosition, ":"); - zephir_array_append(&conditions, _12, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1281); + zephir_array_append(&conditions, _12, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1278); ZEPHIR_CALL_METHOD(&_7, record, "readattribute", &_13, 0, field); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_14); @@ -1916,10 +1916,10 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { ZEPHIR_CALL_METHOD(&_2, record, "getdi", NULL, 0); zephir_check_call_status(); zephir_array_update_string(&findParams, SL("di"), &_2, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 317, findParams, parameters); + ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 310, findParams, parameters); zephir_check_call_status(); if (Z_TYPE_P(extraParameters) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 317, findArguments, extraParameters); + ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 310, findArguments, extraParameters); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(findParams, findArguments); @@ -1938,7 +1938,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) { ZVAL_STRING(retrieveMethod, "find", 1); break; } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown relation type", "phalcon/mvc/model/manager.zep", 1320); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown relation type", "phalcon/mvc/model/manager.zep", 1317); return; } while(0); @@ -2126,8 +2126,8 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, getBelongsToRecords) { RETURN_MM_BOOL(0); } ZEPHIR_OBS_VAR(relations); - zephir_array_fetch(&relations, belongsTo, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1407 TSRMLS_CC); - zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1408 TSRMLS_CC); + zephir_array_fetch(&relations, belongsTo, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1404 TSRMLS_CC); + zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1405 TSRMLS_CC); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getrelationrecords", NULL, 0, _2, method, record, parameters); zephir_check_call_status(); RETURN_MM(); @@ -2188,8 +2188,8 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, getHasManyRecords) { RETURN_MM_BOOL(0); } ZEPHIR_OBS_VAR(relations); - zephir_array_fetch(&relations, hasMany, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1437 TSRMLS_CC); - zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1438 TSRMLS_CC); + zephir_array_fetch(&relations, hasMany, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1434 TSRMLS_CC); + zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1435 TSRMLS_CC); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getrelationrecords", NULL, 0, _2, method, record, parameters); zephir_check_call_status(); RETURN_MM(); @@ -2250,8 +2250,8 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, getHasOneRecords) { RETURN_MM_BOOL(0); } ZEPHIR_OBS_VAR(relations); - zephir_array_fetch(&relations, hasOne, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1467 TSRMLS_CC); - zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1468 TSRMLS_CC); + zephir_array_fetch(&relations, hasOne, keyRelation, PH_NOISY, "phalcon/mvc/model/manager.zep", 1464 TSRMLS_CC); + zephir_array_fetch_long(&_2, relations, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/manager.zep", 1465 TSRMLS_CC); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "getrelationrecords", NULL, 0, _2, method, record, parameters); zephir_check_call_status(); RETURN_MM(); @@ -2420,13 +2420,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelations) { if (Z_TYPE_P(belongsTo) == IS_ARRAY) { ZEPHIR_OBS_VAR(relations); if (zephir_array_isset_fetch(&relations, belongsTo, entityName, 0 TSRMLS_CC)) { - zephir_is_iterable(relations, &_1, &_0, 0, 0, "phalcon/mvc/model/manager.zep", 1567); + zephir_is_iterable(relations, &_1, &_0, 0, 0, "phalcon/mvc/model/manager.zep", 1564); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(relation, _2); - zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1565); + zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1562); } } } @@ -2434,13 +2434,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelations) { if (Z_TYPE_P(hasMany) == IS_ARRAY) { ZEPHIR_OBS_NVAR(relations); if (zephir_array_isset_fetch(&relations, hasMany, entityName, 0 TSRMLS_CC)) { - zephir_is_iterable(relations, &_4, &_3, 0, 0, "phalcon/mvc/model/manager.zep", 1579); + zephir_is_iterable(relations, &_4, &_3, 0, 0, "phalcon/mvc/model/manager.zep", 1576); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) ) { ZEPHIR_GET_HVALUE(relation, _5); - zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1577); + zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1574); } } } @@ -2448,13 +2448,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelations) { if (Z_TYPE_P(hasOne) == IS_ARRAY) { ZEPHIR_OBS_NVAR(relations); if (zephir_array_isset_fetch(&relations, hasOne, entityName, 0 TSRMLS_CC)) { - zephir_is_iterable(relations, &_7, &_6, 0, 0, "phalcon/mvc/model/manager.zep", 1591); + zephir_is_iterable(relations, &_7, &_6, 0, 0, "phalcon/mvc/model/manager.zep", 1588); for ( ; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS ; zephir_hash_move_forward_ex(_7, &_6) ) { ZEPHIR_GET_HVALUE(relation, _8); - zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1589); + zephir_array_append(&allRelations, relation, PH_SEPARATE, "phalcon/mvc/model/manager.zep", 1586); } } } @@ -2557,7 +2557,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, createQuery) { ZEPHIR_OBS_VAR(dependencyInjector); zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1648); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1645); return; } ZEPHIR_INIT_VAR(_1); @@ -2610,7 +2610,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, executeQuery) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _0); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1668); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1665); return; } ZEPHIR_INIT_VAR(_2); @@ -2658,7 +2658,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, createBuilder) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _0); if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1700); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injection object is required to access ORM services", "phalcon/mvc/model/manager.zep", 1697); return; } ZEPHIR_INIT_VAR(_2); @@ -2740,7 +2740,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, getNamespaceAlias) { ZEPHIR_CONCAT_SVS(_2, "Namespace alias '", alias, "' is not registered"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/manager.zep", 1735 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/manager.zep", 1732 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; diff --git a/ext/phalcon/mvc/model/managerinterface.zep.c b/ext/phalcon/mvc/model/managerinterface.zep.c index d3d6a96e4ff..427de07d54c 100644 --- a/ext/phalcon/mvc/model/managerinterface.zep.c +++ b/ext/phalcon/mvc/model/managerinterface.zep.c @@ -169,9 +169,9 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, existsHasOne); * @param string method * @param string modelName * @param string modelRelation - * @param Phalcon\Mvc\Model record + * @param \Phalcon\Mvc\Model record * @param array parameters - * @return Phalcon\Mvc\Model\ResultsetInterface + * @return \Phalcon\Mvc\Model\ResultsetInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, getBelongsToRecords); @@ -181,9 +181,9 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, getBelongsToRecords); * @param string method * @param string modelName * @param string modelRelation - * @param Phalcon\Mvc\Model record + * @param \Phalcon\Mvc\Model record * @param array parameters - * @return Phalcon\Mvc\Model\ResultsetInterface + * @return \Phalcon\Mvc\Model\ResultsetInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, getHasManyRecords); @@ -193,9 +193,9 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, getHasManyRecords); * @param string method * @param string modelName * @param string modelRelation - * @param Phalcon\Mvc\Model record + * @param \Phalcon\Mvc\Model record * @param array parameters - * @return Phalcon\Mvc\Model\ResultsetInterface + * @return \Phalcon\Mvc\Model\ResultsetInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, getHasOneRecords); @@ -235,7 +235,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, getHasOneAndHasMany); * Query all the relationships defined on a model * * @param string modelName - * @return Phalcon\Mvc\Model\RelationInterface[] + * @return \Phalcon\Mvc\Model\RelationInterface[] */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, getRelations); @@ -252,7 +252,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, getRelationsBetween); * Creates a Phalcon\Mvc\Model\Query without execute it * * @param string phql - * @return Phalcon\Mvc\Model\QueryInterface + * @return \Phalcon\Mvc\Model\QueryInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, createQuery); @@ -261,7 +261,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, createQuery); * * @param string phql * @param array placeholders - * @return Phalcon\Mvc\Model\QueryInterface + * @return \Phalcon\Mvc\Model\QueryInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, executeQuery); @@ -269,7 +269,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, executeQuery); * Creates a Phalcon\Mvc\Model\Query\Builder * * @param string params - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, createBuilder); @@ -283,7 +283,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, addBehavior); * Notify the behaviors that are listening in the model * * @param string eventName - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, notifyEvent); @@ -292,7 +292,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, notifyEvent); * This method expects that the endpoint listeners/behaviors returns true * meaning that a least one is implemented * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @param string eventName * @param array data * @return boolean @@ -302,7 +302,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, missingMethod); /** * Returns the last query created or executed in the models manager * - * @return Phalcon\Mvc\Model\QueryInterface + * @return \Phalcon\Mvc\Model\QueryInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, getLastQuery); @@ -311,7 +311,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, getLastQuery); * * @param string modelName * @param string alias - * @return Phalcon\Mvc\Model\Relation + * @return \Phalcon\Mvc\Model\Relation */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, getRelationByAlias); diff --git a/ext/phalcon/mvc/model/message.zep.c b/ext/phalcon/mvc/model/message.zep.c index 29abe8a58ae..4b63cf82189 100644 --- a/ext/phalcon/mvc/model/message.zep.c +++ b/ext/phalcon/mvc/model/message.zep.c @@ -70,7 +70,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_Message) { * @param string message * @param string|array field * @param string type - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model */ PHP_METHOD(Phalcon_Mvc_Model_Message, __construct) { diff --git a/ext/phalcon/mvc/model/metadata/apc.zep.c b/ext/phalcon/mvc/model/metadata/apc.zep.c index 0185a569795..ac6f6059d3c 100644 --- a/ext/phalcon/mvc/model/metadata/apc.zep.c +++ b/ext/phalcon/mvc/model/metadata/apc.zep.c @@ -111,7 +111,7 @@ PHP_METHOD(Phalcon_Mvc_Model_MetaData_Apc, read) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_prefix"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); - ZEPHIR_CALL_FUNCTION(&data, "apc_fetch", NULL, 79, _1); + ZEPHIR_CALL_FUNCTION(&data, "apc_fetch", NULL, 81, _1); zephir_check_call_status(); if (Z_TYPE_P(data) == IS_ARRAY) { RETURN_CCTOR(data); @@ -149,7 +149,7 @@ PHP_METHOD(Phalcon_Mvc_Model_MetaData_Apc, write) { ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); _2 = zephir_fetch_nproperty_this(this_ptr, SL("_ttl"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "apc_store", NULL, 80, _1, data, _2); + ZEPHIR_CALL_FUNCTION(NULL, "apc_store", NULL, 82, _1, data, _2); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/mvc/model/metadata/libmemcached.zep.c b/ext/phalcon/mvc/model/metadata/libmemcached.zep.c index 62d443d61d5..21767e5a5b4 100644 --- a/ext/phalcon/mvc/model/metadata/libmemcached.zep.c +++ b/ext/phalcon/mvc/model/metadata/libmemcached.zep.c @@ -104,9 +104,9 @@ PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 312, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -214,7 +214,7 @@ PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, reset) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 320); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 313); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/mvc/model/metadata/memcache.zep.c b/ext/phalcon/mvc/model/metadata/memcache.zep.c index 49478e4c667..105c694442a 100644 --- a/ext/phalcon/mvc/model/metadata/memcache.zep.c +++ b/ext/phalcon/mvc/model/metadata/memcache.zep.c @@ -111,9 +111,9 @@ PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 314, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -221,7 +221,7 @@ PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, reset) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 320); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 313); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/mvc/model/metadata/redis.zep.c b/ext/phalcon/mvc/model/metadata/redis.zep.c index 06ec581489a..19e62fb5e95 100644 --- a/ext/phalcon/mvc/model/metadata/redis.zep.c +++ b/ext/phalcon/mvc/model/metadata/redis.zep.c @@ -111,9 +111,9 @@ PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 315, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -221,7 +221,7 @@ PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, reset) { zephir_check_call_status(); } } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_redis_ce, this_ptr, "reset", &_5, 320); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_redis_ce, this_ptr, "reset", &_5, 313); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/mvc/model/metadata/strategyinterface.zep.c b/ext/phalcon/mvc/model/metadata/strategyinterface.zep.c index c13aebefd12..e2192d53ab6 100644 --- a/ext/phalcon/mvc/model/metadata/strategyinterface.zep.c +++ b/ext/phalcon/mvc/model/metadata/strategyinterface.zep.c @@ -23,8 +23,8 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_MetaData_StrategyInterface) { /** * The meta-data is obtained by reading the column descriptions from the database information schema * - * @param Phalcon\Mvc\ModelInterface model - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\Mvc\ModelInterface model + * @param \Phalcon\DiInterface dependencyInjector * @return array */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaData_StrategyInterface, getMetaData); @@ -32,8 +32,8 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaData_StrategyInterface, getMetaData); /** * Read the model's column map, this can't be inferred * - * @param Phalcon\Mvc\ModelInterface model - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\Mvc\ModelInterface model + * @param \Phalcon\DiInterface dependencyInjector * @return array * @todo Not implemented */ diff --git a/ext/phalcon/mvc/model/metadata/xcache.zep.c b/ext/phalcon/mvc/model/metadata/xcache.zep.c index f01176e6c03..21843a8ff37 100644 --- a/ext/phalcon/mvc/model/metadata/xcache.zep.c +++ b/ext/phalcon/mvc/model/metadata/xcache.zep.c @@ -114,7 +114,7 @@ PHP_METHOD(Phalcon_Mvc_Model_MetaData_Xcache, read) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_prefix"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); - ZEPHIR_CALL_FUNCTION(&data, "xcache_get", NULL, 81, _1); + ZEPHIR_CALL_FUNCTION(&data, "xcache_get", NULL, 83, _1); zephir_check_call_status(); if (Z_TYPE_P(data) == IS_ARRAY) { RETURN_CCTOR(data); @@ -155,7 +155,7 @@ PHP_METHOD(Phalcon_Mvc_Model_MetaData_Xcache, write) { ZEPHIR_INIT_VAR(_1); ZEPHIR_CONCAT_SVV(_1, "$PMM$", _0, key); _2 = zephir_fetch_nproperty_this(this_ptr, SL("_ttl"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 82, _1, data, _2); + ZEPHIR_CALL_FUNCTION(NULL, "xcache_set", NULL, 84, _1, data, _2); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/mvc/model/metadatainterface.zep.c b/ext/phalcon/mvc/model/metadatainterface.zep.c index 443ef58826b..d2725186828 100644 --- a/ext/phalcon/mvc/model/metadatainterface.zep.c +++ b/ext/phalcon/mvc/model/metadatainterface.zep.c @@ -33,14 +33,14 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, setStrategy); /** * Return the strategy to obtain the meta-data * - * @return Phalcon\Mvc\Model\MetaData\StrategyInterface + * @return \Phalcon\Mvc\Model\MetaData\StrategyInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getStrategy); /** * Reads meta-data for certain model * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, readMetaData); @@ -48,7 +48,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, readMetaData); /** * Reads meta-data for certain model using a MODEL_* constant * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @param int index * @return mixed */ @@ -57,7 +57,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, readMetaDataIndex); /** * Writes meta-data for certain model using a MODEL_* constant * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @param int index * @param mixed data */ @@ -66,7 +66,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, writeMetaDataIndex); /** * Reads the ordered/reversed column map for certain model * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, readColumnMap); @@ -74,7 +74,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, readColumnMap); /** * Reads column-map information for certain model using a MODEL_* constant * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @param int index */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, readColumnMapIndex); @@ -82,7 +82,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, readColumnMapIndex); /** * Returns table attributes names (fields) * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getAttributes); @@ -90,7 +90,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getAttributes); /** * Returns an array of fields which are part of the primary key * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getPrimaryKeyAttributes); @@ -98,7 +98,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getPrimaryKeyAttributes); /** * Returns an arrau of fields which are not part of the primary key * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getNonPrimaryKeyAttributes); @@ -106,7 +106,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getNonPrimaryKeyAttribute /** * Returns an array of not null attributes * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getNotNullAttributes); @@ -114,7 +114,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getNotNullAttributes); /** * Returns attributes and their data types * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getDataTypes); @@ -122,7 +122,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getDataTypes); /** * Returns attributes which types are numerical * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getDataTypesNumeric); @@ -130,7 +130,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getDataTypesNumeric); /** * Returns the name of identity field (if one is present) * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return string */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getIdentityField); @@ -138,7 +138,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getIdentityField); /** * Returns attributes and their bind data types * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getBindTypes); @@ -146,7 +146,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getBindTypes); /** * Returns attributes that must be ignored from the INSERT SQL generation * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getAutomaticCreateAttributes); @@ -154,7 +154,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getAutomaticCreateAttribu /** * Returns attributes that must be ignored from the UPDATE SQL generation * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, getAutomaticUpdateAttributes); @@ -170,7 +170,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, setAutomaticCreateAttribu ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, setAutomaticUpdateAttributes); /** - * Set the attributes that allow empty string values + * Set the attributes that allow empty string values */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_MetaDataInterface, setEmptyStringAttributes); diff --git a/ext/phalcon/mvc/model/orm.c b/ext/phalcon/mvc/model/orm.c index 4abfdce1608..8e397ecc11c 100644 --- a/ext/phalcon/mvc/model/orm.c +++ b/ext/phalcon/mvc/model/orm.c @@ -56,7 +56,7 @@ void phalcon_orm_singlequotes(zval *return_value, zval *str TSRMLS_DC) { if (Z_TYPE_P(str) != IS_STRING) { RETURN_ZVAL(str, 1, 0); - } + } marker = Z_STRVAL_P(str); @@ -81,8 +81,8 @@ void phalcon_orm_singlequotes(zval *return_value, zval *str TSRMLS_DC) { if (escaped_str.len) { RETURN_STRINGL(escaped_str.c, escaped_str.len, 0); - } else { - smart_str_free(&escaped_str); - RETURN_EMPTY_STRING(); } + + smart_str_free(&escaped_str); + RETURN_EMPTY_STRING(); } diff --git a/ext/phalcon/mvc/model/query.zep.c b/ext/phalcon/mvc/model/query.zep.c index 47e7a4d720e..3ac5be446a8 100644 --- a/ext/phalcon/mvc/model/query.zep.c +++ b/ext/phalcon/mvc/model/query.zep.c @@ -14,10 +14,10 @@ #include "kernel/main.h" #include "kernel/object.h" #include "kernel/fcall.h" +#include "kernel/array.h" #include "kernel/memory.h" -#include "kernel/exception.h" #include "kernel/operators.h" -#include "kernel/array.h" +#include "kernel/exception.h" #include "kernel/concat.h" #include "kernel/hash.h" #include "ext/spl/spl_exceptions.h" @@ -38,7 +38,7 @@ * WHERE b.name = :name: ORDER BY c.name"; * * $result = manager->executeQuery($phql, array( - * "name": "Lamborghini" + * "name" => "Lamborghini" * )); * * foreach ($result as $row) { @@ -90,6 +90,8 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_Query) { zend_declare_property_null(phalcon_mvc_model_query_ce, SL("_bindTypes"), ZEND_ACC_PROTECTED TSRMLS_CC); + zend_declare_property_null(phalcon_mvc_model_query_ce, SL("_enableImplicitJoins"), ZEND_ACC_PROTECTED TSRMLS_CC); + zend_declare_property_null(phalcon_mvc_model_query_ce, SL("_irPhqlCache"), ZEND_ACC_STATIC|ZEND_ACC_PROTECTED TSRMLS_CC); zend_declare_class_constant_long(phalcon_mvc_model_query_ce, SL("TYPE_SELECT"), 309 TSRMLS_CC); @@ -110,15 +112,16 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_Query) { * Phalcon\Mvc\Model\Query constructor * * @param string phql - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\DiInterface dependencyInjector */ PHP_METHOD(Phalcon_Mvc_Model_Query, __construct) { + zend_bool _0; int ZEPHIR_LAST_CALL_STATUS; - zval *phql = NULL, *dependencyInjector = NULL; + zval *phql = NULL, *dependencyInjector = NULL, *options = NULL, *enableImplicitJoins; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 0, 2, &phql, &dependencyInjector); + zephir_fetch_params(1, 0, 3, &phql, &dependencyInjector, &options); if (!phql) { phql = ZEPHIR_GLOBAL(global_null); @@ -126,6 +129,9 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, __construct) { if (!dependencyInjector) { dependencyInjector = ZEPHIR_GLOBAL(global_null); } + if (!options) { + options = ZEPHIR_GLOBAL(global_null); + } if (Z_TYPE_P(phql) != IS_NULL) { @@ -135,6 +141,16 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, __construct) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdi", NULL, 0, dependencyInjector); zephir_check_call_status(); } + _0 = Z_TYPE_P(options) == IS_ARRAY; + if (_0) { + ZEPHIR_OBS_VAR(enableImplicitJoins); + _0 = zephir_array_isset_string_fetch(&enableImplicitJoins, options, SS("enable_implicit_joins"), 0 TSRMLS_CC); + } + if (_0) { + zephir_update_property_this(this_ptr, SL("_enableImplicitJoins"), (ZEPHIR_IS_TRUE(enableImplicitJoins)) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); + } else { + zephir_update_property_this(this_ptr, SL("_enableImplicitJoins"), (ZEPHIR_GLOBAL(orm).enable_implicit_joins) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); + } ZEPHIR_MM_RESTORE(); } @@ -158,7 +174,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, setDI) { zephir_check_temp_parameter(_0); zephir_check_call_status(); if (Z_TYPE_P(manager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsManager' is invalid", "phalcon/mvc/model/query.zep", 137); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsManager' is invalid", "phalcon/mvc/model/query.zep", 147); return; } ZEPHIR_INIT_NVAR(_0); @@ -167,7 +183,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, setDI) { zephir_check_temp_parameter(_0); zephir_check_call_status(); if (Z_TYPE_P(metaData) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsMetaData' is invalid", "phalcon/mvc/model/query.zep", 142); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Injected service 'modelsMetaData' is invalid", "phalcon/mvc/model/query.zep", 152); return; } zephir_update_property_this(this_ptr, SL("_manager"), manager TSRMLS_CC); @@ -235,7 +251,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_OBS_VAR(columnName); - zephir_array_fetch_string(&columnName, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 186 TSRMLS_CC); + zephir_array_fetch_string(&columnName, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 196 TSRMLS_CC); ZEPHIR_OBS_VAR(sqlColumnAliases); zephir_read_property_this(&sqlColumnAliases, this_ptr, SL("_sqlColumnAliases"), PH_NOISY_CC); if (zephir_array_isset(sqlColumnAliases, columnName)) { @@ -259,7 +275,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Unknown model or alias '", columnDomain, "' (11), when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 212 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 222 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -275,7 +291,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "There is no model related to model or alias '", columnDomain, "', when executing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 229 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 239 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -295,7 +311,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSVSV(_2, "Column '", columnName, "' doesn't belong to the model or alias '", columnDomain, "', when executing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 239 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 249 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -307,7 +323,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_INIT_VAR(hasModel); ZVAL_BOOL(hasModel, 0); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); - zephir_is_iterable(_1, &_4, &_3, 0, 0, "phalcon/mvc/model/query.zep", 269); + zephir_is_iterable(_1, &_4, &_3, 0, 0, "phalcon/mvc/model/query.zep", 279); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -325,7 +341,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "The column '", columnName, "' is ambiguous, when preparing: ", _8); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 260 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 270 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -340,14 +356,14 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Column '", columnName, "' doesn't belong to any of the selected models (1), when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 270 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 280 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_VAR(models); zephir_read_property_this(&models, this_ptr, SL("_models"), PH_NOISY_CC); if (Z_TYPE_P(models) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The models list was not loaded correctly", "phalcon/mvc/model/query.zep", 278); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The models list was not loaded correctly", "phalcon/mvc/model/query.zep", 288); return; } ZEPHIR_INIT_VAR(className); @@ -361,7 +377,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Can't obtain model's source from models list: '", className, "', when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 286 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 296 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -382,7 +398,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getQualified) { ZEPHIR_CONCAT_SVSV(_2, "Column '", columnName, "' doesn't belong to any of the selected models (3), when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 303 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 313 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -415,13 +431,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getCallArgument) { - zephir_array_fetch_string(&_0, argument, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 326 TSRMLS_CC); + zephir_array_fetch_string(&_0, argument, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 336 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 352)) { zephir_create_array(return_value, 1, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("all"), 1); RETURN_MM(); } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 323, argument); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 316, argument); zephir_check_call_status(); RETURN_MM(); @@ -448,8 +464,8 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) { ZEPHIR_INIT_VAR(whenClauses); array_init(whenClauses); - zephir_array_fetch_string(&_0, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 340 TSRMLS_CC); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 355); + zephir_array_fetch_string(&_0, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 350 TSRMLS_CC); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 365); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -459,30 +475,30 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) { ZEPHIR_INIT_NVAR(_4); zephir_create_array(_4, 3, 0 TSRMLS_CC); add_assoc_stringl_ex(_4, SS("type"), SL("when"), 1); - zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 344 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6); + zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 354 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _6); zephir_check_call_status(); zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE); - zephir_array_fetch_string(&_8, whenExpr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 345 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _8); + zephir_array_fetch_string(&_8, whenExpr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 355 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _8); zephir_check_call_status(); zephir_array_update_string(&_4, SL("then"), &_5, PH_COPY | PH_SEPARATE); - zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 346); + zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 356); } else { ZEPHIR_INIT_NVAR(_4); zephir_create_array(_4, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(_4, SS("type"), SL("else"), 1); - zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 350 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6); + zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 360 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _6); zephir_check_call_status(); zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE); - zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 351); + zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 361); } } zephir_create_array(return_value, 3, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("case"), 1); - zephir_array_fetch_string(&_6, expr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 357 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6); + zephir_array_fetch_string(&_6, expr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 367 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 316, _6); zephir_check_call_status(); zephir_array_update_string(&return_value, SL("expr"), &_5, PH_COPY | PH_SEPARATE); zephir_array_update_string(&return_value, SL("when-clauses"), &whenClauses, PH_COPY | PH_SEPARATE); @@ -519,19 +535,19 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { ZEPHIR_INIT_VAR(functionArgs); if (zephir_array_isset_long(arguments, 0)) { array_init(functionArgs); - zephir_is_iterable(arguments, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 383); + zephir_is_iterable(arguments, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 393); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(argument, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, argument); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 317, argument); zephir_check_call_status(); - zephir_array_append(&functionArgs, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 381); + zephir_array_append(&functionArgs, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 391); } } else { zephir_create_array(functionArgs, 1, 0 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, arguments); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 317, arguments); zephir_check_call_status(); zephir_array_fast_append(functionArgs, _3); } @@ -539,7 +555,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { zephir_create_array(return_value, 4, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("functionCall"), 1); ZEPHIR_OBS_VAR(_5); - zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 391 TSRMLS_CC); + zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 401 TSRMLS_CC); zephir_array_update_string(&return_value, SL("name"), &_5, PH_COPY | PH_SEPARATE); zephir_array_update_string(&return_value, SL("arguments"), &functionArgs, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_6); @@ -550,7 +566,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { zephir_create_array(return_value, 3, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("functionCall"), 1); ZEPHIR_OBS_NVAR(_5); - zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 398 TSRMLS_CC); + zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 408 TSRMLS_CC); zephir_array_update_string(&return_value, SL("name"), &_5, PH_COPY | PH_SEPARATE); zephir_array_update_string(&return_value, SL("arguments"), &functionArgs, PH_COPY | PH_SEPARATE); RETURN_MM(); @@ -559,7 +575,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) { zephir_create_array(return_value, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("functionCall"), 1); ZEPHIR_OBS_NVAR(_5); - zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 407 TSRMLS_CC); + zephir_array_fetch_string(&_5, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 417 TSRMLS_CC); zephir_array_update_string(&return_value, SL("name"), &_5, PH_COPY | PH_SEPARATE); RETURN_MM(); @@ -601,12 +617,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { if (!ZEPHIR_IS_LONG(exprType, 409)) { ZEPHIR_OBS_VAR(exprLeft); if (zephir_array_isset_string_fetch(&exprLeft, expr, SS("left"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 323, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 316, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } ZEPHIR_OBS_VAR(exprRight); if (zephir_array_isset_string_fetch(&exprRight, expr, SS("right"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 323, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 316, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); } } @@ -684,7 +700,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { break; } if (ZEPHIR_IS_LONG(exprType, 355)) { - ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 325, expr); + ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 318, expr); zephir_check_call_status(); break; } @@ -771,7 +787,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("literal"), 1); ZEPHIR_OBS_VAR(_2); - zephir_array_fetch_string(&_2, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 525 TSRMLS_CC); + zephir_array_fetch_string(&_2, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 535 TSRMLS_CC); zephir_array_update_string(&exprReturn, SL("value"), &_2, PH_COPY | PH_SEPARATE); break; } @@ -791,9 +807,9 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { } if (ZEPHIR_IS_LONG(exprType, 260)) { ZEPHIR_OBS_VAR(value); - zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 537 TSRMLS_CC); + zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 547 TSRMLS_CC); if (quoting == 1) { - if (zephir_memnstr_str(value, SL("'"), "phalcon/mvc/model/query.zep", 542)) { + if (zephir_memnstr_str(value, SL("'"), "phalcon/mvc/model/query.zep", 552)) { ZEPHIR_INIT_VAR(escapedValue); phalcon_orm_singlequotes(escapedValue, value TSRMLS_CC); } else { @@ -815,7 +831,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("placeholder"), 1); ZEPHIR_INIT_VAR(_3); - zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 555 TSRMLS_CC); + zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 565 TSRMLS_CC); ZEPHIR_SINIT_VAR(_5); ZVAL_STRING(&_5, "?", 0); ZEPHIR_SINIT_VAR(_6); @@ -828,7 +844,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_INIT_NVAR(exprReturn); zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("placeholder"), 1); - zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 559 TSRMLS_CC); + zephir_array_fetch_string(&_4, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 569 TSRMLS_CC); ZEPHIR_INIT_VAR(_7); ZEPHIR_CONCAT_SV(_7, ":", _4); zephir_array_update_string(&exprReturn, SL("value"), &_7, PH_COPY | PH_SEPARATE); @@ -836,14 +852,14 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { } if (ZEPHIR_IS_LONG(exprType, 277)) { ZEPHIR_OBS_NVAR(value); - zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 563 TSRMLS_CC); - if (zephir_memnstr_str(value, SL(":"), "phalcon/mvc/model/query.zep", 564)) { + zephir_array_fetch_string(&value, expr, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 573 TSRMLS_CC); + if (zephir_memnstr_str(value, SL(":"), "phalcon/mvc/model/query.zep", 574)) { ZEPHIR_INIT_VAR(valueParts); zephir_fast_explode_str(valueParts, SL(":"), value, LONG_MAX TSRMLS_CC); ZEPHIR_OBS_VAR(name); - zephir_array_fetch_long(&name, valueParts, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 567 TSRMLS_CC); + zephir_array_fetch_long(&name, valueParts, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 577 TSRMLS_CC); ZEPHIR_OBS_VAR(bindType); - zephir_array_fetch_long(&bindType, valueParts, 1, PH_NOISY, "phalcon/mvc/model/query.zep", 568 TSRMLS_CC); + zephir_array_fetch_long(&bindType, valueParts, 1, PH_NOISY, "phalcon/mvc/model/query.zep", 578 TSRMLS_CC); do { if (ZEPHIR_IS_STRING(bindType, "str")) { ZEPHIR_INIT_NVAR(_3); @@ -927,7 +943,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_7, "Bind value is required for array type placeholder: ", name); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 607 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 617 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -938,7 +954,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_10, "Bind type requires an array in placeholder: ", name); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 611 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 621 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -949,7 +965,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_10, "At least one value must be bound in placeholder: ", name); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 615 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 625 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -969,7 +985,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_10, "Unknown bind type: ", bindType); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 627 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 637 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -1124,17 +1140,17 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { zephir_create_array(exprReturn, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(exprReturn, SS("type"), SL("literal"), 1); ZEPHIR_OBS_NVAR(_2); - zephir_array_fetch_string(&_2, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 700 TSRMLS_CC); + zephir_array_fetch_string(&_2, expr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 710 TSRMLS_CC); zephir_array_update_string(&exprReturn, SL("value"), &_2, PH_COPY | PH_SEPARATE); break; } if (ZEPHIR_IS_LONG(exprType, 350)) { - ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 326, expr); + ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 319, expr); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(exprType, 409)) { - ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 327, expr); + ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 320, expr); zephir_check_call_status(); break; } @@ -1144,7 +1160,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { add_assoc_stringl_ex(exprReturn, SS("type"), SL("select"), 1); ZEPHIR_INIT_NVAR(_3); ZVAL_BOOL(_3, 1); - ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 328, expr, _3); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 321, expr, _3); zephir_check_call_status(); zephir_array_update_string(&exprReturn, SL("value"), &_12, PH_COPY | PH_SEPARATE); break; @@ -1155,7 +1171,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { ZEPHIR_CONCAT_SV(_7, "Unknown expression type ", exprType); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 716 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 726 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -1163,29 +1179,29 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { RETURN_CCTOR(exprReturn); } if (zephir_array_isset_string(expr, SS("domain"))) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 325, expr); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 318, expr); zephir_check_call_status(); RETURN_MM(); } if (zephir_array_isset_long(expr, 0)) { ZEPHIR_INIT_VAR(listItems); array_init(listItems); - zephir_is_iterable(expr, &_14, &_13, 0, 0, "phalcon/mvc/model/query.zep", 737); + zephir_is_iterable(expr, &_14, &_13, 0, 0, "phalcon/mvc/model/query.zep", 747); for ( ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS ; zephir_hash_move_forward_ex(_14, &_13) ) { ZEPHIR_GET_HVALUE(exprListItem, _15); - ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 323, exprListItem); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 316, exprListItem); zephir_check_call_status(); - zephir_array_append(&listItems, _12, PH_SEPARATE, "phalcon/mvc/model/query.zep", 735); + zephir_array_append(&listItems, _12, PH_SEPARATE, "phalcon/mvc/model/query.zep", 745); } zephir_create_array(return_value, 2, 0 TSRMLS_CC); add_assoc_stringl_ex(return_value, SS("type"), SL("list"), 1); zephir_array_fast_append(return_value, listItems); RETURN_MM(); } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown expression", "phalcon/mvc/model/query.zep", 740); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Unknown expression", "phalcon/mvc/model/query.zep", 750); return; } @@ -1193,17 +1209,15 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) { /** * Resolves a column from its intermediate representation into an array used to determine * if the resultset produced is simple or complex - * - * @param array column - * @return array */ PHP_METHOD(Phalcon_Mvc_Model_Query, _getSelectColumn) { int ZEPHIR_LAST_CALL_STATUS; + zephir_fcall_cache_entry *_5 = NULL; HashTable *_2; HashPosition _1; - zval *column_param = NULL, *sqlColumns, *columnType, *sqlAliases, *modelName = NULL, *source = NULL, *columnDomain, *sqlColumnAlias = NULL, *preparedAlias = NULL, *sqlExprColumn = NULL, *sqlAliasesModels, *sqlColumn, *columnData, *balias, *_0, **_3, *_5 = NULL, *_6 = NULL; - zval *column = NULL, *_4 = NULL; + zval *column_param = NULL, *sqlColumns, *columnType, *sqlAliases, *modelName = NULL, *source = NULL, *columnDomain, *sqlColumnAlias = NULL, *preparedAlias = NULL, *sqlExprColumn = NULL, *sqlAliasesModels, *sqlColumn = NULL, *columnData, *balias, *eager, *_0, **_3, *_4 = NULL, *_6, *_7 = NULL, *_8 = NULL, *_9; + zval *column = NULL; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 1, 0, &column_param); @@ -1214,95 +1228,119 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getSelectColumn) { ZEPHIR_OBS_VAR(columnType); if (!(zephir_array_isset_string_fetch(&columnType, column, SS("type"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 757); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 764); return; } ZEPHIR_INIT_VAR(sqlColumns); array_init(sqlColumns); + ZEPHIR_OBS_VAR(eager); + zephir_array_isset_string_fetch(&eager, column, SS("eager"), 0 TSRMLS_CC); if (ZEPHIR_IS_LONG(columnType, 352)) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_models"), PH_NOISY_CC); - zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 773); + zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model/query.zep", 794); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) ) { ZEPHIR_GET_HMKEY(modelName, _2, _1); ZEPHIR_GET_HVALUE(source, _3); - ZEPHIR_INIT_NVAR(_4); - zephir_create_array(_4, 3, 0 TSRMLS_CC); - add_assoc_stringl_ex(_4, SS("type"), SL("object"), 1); - zephir_array_update_string(&_4, SL("model"), &modelName, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_4, SL("column"), &source, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 771); + ZEPHIR_INIT_NVAR(sqlColumn); + zephir_create_array(sqlColumn, 4, 0 TSRMLS_CC); + add_assoc_stringl_ex(sqlColumn, SS("type"), SL("object"), 1); + zephir_array_update_string(&sqlColumn, SL("model"), &modelName, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlColumn, SL("column"), &source, PH_COPY | PH_SEPARATE); + ZEPHIR_CALL_FUNCTION(&_4, "lcfirst", &_5, 67, modelName); + zephir_check_call_status(); + zephir_array_update_string(&sqlColumn, SL("balias"), &_4, PH_COPY | PH_SEPARATE); + if (Z_TYPE_P(eager) != IS_NULL) { + zephir_array_update_string(&sqlColumn, SL("eager"), &eager, PH_COPY | PH_SEPARATE); + zephir_array_fetch_string(&_6, column, SL("eagerType"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 789 TSRMLS_CC); + zephir_array_update_string(&sqlColumn, SL("eagerType"), &_6, PH_COPY | PH_SEPARATE); + } + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 792); } RETURN_CCTOR(sqlColumns); } if (!(zephir_array_isset_string(column, SS("column")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 777); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 798); return; } if (ZEPHIR_IS_LONG(columnType, 353)) { ZEPHIR_OBS_VAR(sqlAliases); zephir_read_property_this(&sqlAliases, this_ptr, SL("_sqlAliases"), PH_NOISY_CC); ZEPHIR_OBS_VAR(columnDomain); - zephir_array_fetch_string(&columnDomain, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 790 TSRMLS_CC); + zephir_array_fetch_string(&columnDomain, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 811 TSRMLS_CC); ZEPHIR_OBS_VAR(source); if (!(zephir_array_isset_fetch(&source, sqlAliases, columnDomain, 0 TSRMLS_CC))) { - ZEPHIR_INIT_VAR(_5); - object_init_ex(_5, phalcon_mvc_model_exception_ce); + ZEPHIR_INIT_VAR(_7); + object_init_ex(_7, phalcon_mvc_model_exception_ce); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_6); - ZEPHIR_CONCAT_SVSV(_6, "Unknown model or alias '", columnDomain, "' (2), when preparing: ", _0); - ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 9, _6); + ZEPHIR_INIT_VAR(_8); + ZEPHIR_CONCAT_SVSV(_8, "Unknown model or alias '", columnDomain, "' (2), when preparing: ", _0); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", NULL, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 793 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 814 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_CPY_WRT(sqlColumnAlias, source); + ZEPHIR_OBS_VAR(preparedAlias); + zephir_array_isset_string_fetch(&preparedAlias, column, SS("balias"), 0 TSRMLS_CC); ZEPHIR_OBS_VAR(sqlAliasesModels); zephir_read_property_this(&sqlAliasesModels, this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch(&modelName, sqlAliasesModels, columnDomain, PH_NOISY, "phalcon/mvc/model/query.zep", 805 TSRMLS_CC); - if (ZEPHIR_IS_EQUAL(columnDomain, modelName)) { - ZEPHIR_CALL_FUNCTION(&preparedAlias, "lcfirst", NULL, 65, modelName); - zephir_check_call_status(); - } else { - ZEPHIR_CPY_WRT(preparedAlias, columnDomain); + zephir_array_fetch(&modelName, sqlAliasesModels, columnDomain, PH_NOISY, "phalcon/mvc/model/query.zep", 828 TSRMLS_CC); + if (Z_TYPE_P(preparedAlias) != IS_STRING) { + if (ZEPHIR_IS_EQUAL(columnDomain, modelName)) { + ZEPHIR_CALL_FUNCTION(&preparedAlias, "lcfirst", &_5, 67, modelName); + zephir_check_call_status(); + } else { + ZEPHIR_CPY_WRT(preparedAlias, columnDomain); + } + } + ZEPHIR_INIT_NVAR(sqlColumn); + zephir_create_array(sqlColumn, 4, 0 TSRMLS_CC); + add_assoc_stringl_ex(sqlColumn, SS("type"), SL("object"), 1); + zephir_array_update_string(&sqlColumn, SL("model"), &modelName, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlColumn, SL("column"), &sqlColumnAlias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlColumn, SL("balias"), &preparedAlias, PH_COPY | PH_SEPARATE); + if (Z_TYPE_P(eager) != IS_NULL) { + zephir_array_update_string(&sqlColumn, SL("eager"), &eager, PH_COPY | PH_SEPARATE); + zephir_array_fetch_string(&_6, column, SL("eagerType"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 854 TSRMLS_CC); + zephir_array_update_string(&sqlColumn, SL("eagerType"), &_6, PH_COPY | PH_SEPARATE); } - ZEPHIR_INIT_NVAR(_4); - zephir_create_array(_4, 4, 0 TSRMLS_CC); - add_assoc_stringl_ex(_4, SS("type"), SL("object"), 1); - zephir_array_update_string(&_4, SL("model"), &modelName, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_4, SL("column"), &sqlColumnAlias, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_4, SL("balias"), &preparedAlias, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 824); + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 857); RETURN_CCTOR(sqlColumns); } if (ZEPHIR_IS_LONG(columnType, 354)) { - ZEPHIR_INIT_VAR(sqlColumn); + ZEPHIR_INIT_NVAR(sqlColumn); zephir_create_array(sqlColumn, 1, 0 TSRMLS_CC); add_assoc_stringl_ex(sqlColumn, SS("type"), SL("scalar"), 1); ZEPHIR_OBS_VAR(columnData); - zephir_array_fetch_string(&columnData, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 838 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 323, columnData); + zephir_array_fetch_string(&columnData, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 871 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 316, columnData); zephir_check_call_status(); ZEPHIR_OBS_VAR(balias); if (zephir_array_isset_string_fetch(&balias, sqlExprColumn, SS("balias"), 0 TSRMLS_CC)) { zephir_array_update_string(&sqlColumn, SL("balias"), &balias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&sqlColumn, SL("sqlAlias"), &balias, PH_COPY | PH_SEPARATE); } + if (Z_TYPE_P(eager) != IS_NULL) { + zephir_array_update_string(&sqlColumn, SL("eager"), &eager, PH_COPY | PH_SEPARATE); + zephir_array_fetch_string(&_9, column, SL("eagerType"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 884 TSRMLS_CC); + zephir_array_update_string(&sqlColumn, SL("eagerType"), &_9, PH_COPY | PH_SEPARATE); + } zephir_array_update_string(&sqlColumn, SL("column"), &sqlExprColumn, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 850); + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 888); RETURN_CCTOR(sqlColumns); } - ZEPHIR_INIT_NVAR(_5); - object_init_ex(_5, phalcon_mvc_model_exception_ce); - ZEPHIR_INIT_LNVAR(_6); - ZEPHIR_CONCAT_SV(_6, "Unknown type of column ", columnType); - ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 9, _6); + ZEPHIR_INIT_NVAR(_7); + object_init_ex(_7, phalcon_mvc_model_exception_ce); + ZEPHIR_INIT_LNVAR(_8); + ZEPHIR_CONCAT_SV(_8, "Unknown type of column ", columnType); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", NULL, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 855 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 893 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -1311,7 +1349,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getSelectColumn) { /** * Resolves a table in a SELECT statement checking if the model exists * - * @param Phalcon\Mvc\Model\ManagerInterface manager + * @param \Phalcon\Mvc\Model\ManagerInterface manager * @param array qualifiedName * @return string */ @@ -1327,7 +1365,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getTable) { ZEPHIR_OBS_VAR(modelName); if (!(zephir_array_isset_string_fetch(&modelName, qualifiedName, SS("name"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 870); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 908); return; } ZEPHIR_CALL_METHOD(&model, manager, "load", NULL, 0, modelName); @@ -1348,10 +1386,6 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getTable) { /** * Resolves a JOIN clause checking if the associated models exist - * - * @param Phalcon\Mvc\Model\ManagerInterface manager - * @param array join - * @return array */ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoin) { @@ -1365,17 +1399,17 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoin) { ZEPHIR_OBS_VAR(qualified); if (zephir_array_isset_string_fetch(&qualified, join, SS("qualified"), 0 TSRMLS_CC)) { - zephir_array_fetch_string(&_0, qualified, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 897 TSRMLS_CC); + zephir_array_fetch_string(&_0, qualified, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 932 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 355)) { ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_string(&modelName, qualified, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 899 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 901)) { + zephir_array_fetch_string(&modelName, qualified, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 934 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 936)) { ZEPHIR_INIT_VAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_2, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 903 TSRMLS_CC); + zephir_array_fetch_long(&_2, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 938 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_1, manager, "getnamespacealias", NULL, 0, _2); zephir_check_call_status(); - zephir_array_fetch_long(&_3, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 903 TSRMLS_CC); + zephir_array_fetch_long(&_3, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 938 TSRMLS_CC); ZEPHIR_INIT_VAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _1, "\\", _3); } else { @@ -1397,7 +1431,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoin) { RETURN_MM(); } } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 921); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 956); return; } @@ -1420,7 +1454,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoinType) { ZEPHIR_OBS_VAR(type); if (!(zephir_array_isset_string_fetch(&type, join, SS("type"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 935); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 970); return; } do { @@ -1448,7 +1482,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoinType) { ZEPHIR_CONCAT_SVSV(_2, "Unknown join type ", type, ", when preparing: ", _1); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 956 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/model/query.zep", 991 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -1461,7 +1495,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoinType) { * @param string joinSource * @param string modelAlias * @param string joinAlias - * @param Phalcon\Mvc\Model\RelationInterface relation + * @param \Phalcon\Mvc\Model\RelationInterface relation * @return array */ PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { @@ -1508,7 +1542,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_long_ex(_2, SS("type"), 355); zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_2, SL("name"), &fields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _2); zephir_check_call_status(); zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_4); @@ -1516,14 +1550,14 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _4); zephir_check_call_status(); zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE); zephir_array_fast_append(sqlJoinConditions, _0); } else { ZEPHIR_INIT_VAR(sqlJoinPartialConditions); array_init(sqlJoinPartialConditions); - zephir_is_iterable(fields, &_6, &_5, 0, 0, "phalcon/mvc/model/query.zep", 1044); + zephir_is_iterable(fields, &_6, &_5, 0, 0, "phalcon/mvc/model/query.zep", 1079); for ( ; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS ; zephir_hash_move_forward_ex(_6, &_5) @@ -1539,7 +1573,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { ZEPHIR_CONCAT_SVSVSV(_10, "The number of fields must be equal to the number of referenced fields in join ", modelAlias, "-", joinAlias, ", when preparing: ", _9); ZEPHIR_CALL_METHOD(NULL, _8, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 1020 TSRMLS_CC); + zephir_throw_exception_debug(_8, "phalcon/mvc/model/query.zep", 1055 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -1552,7 +1586,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_long_ex(_2, SS("type"), 355); zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_2, SL("name"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _2); zephir_check_call_status(); zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_NVAR(_4); @@ -1560,10 +1594,10 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("name"), &referencedField, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 318, _4); zephir_check_call_status(); zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlJoinPartialConditions, _0, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1041); + zephir_array_append(&sqlJoinPartialConditions, _0, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1076); } } zephir_create_array(return_value, 3, 0 TSRMLS_CC); @@ -1581,7 +1615,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) { * @param string joinSource * @param string modelAlias * @param string joinAlias - * @param Phalcon\Mvc\Model\RelationInterface relation + * @param \Phalcon\Mvc\Model\RelationInterface relation * @return array */ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { @@ -1623,7 +1657,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { ZEPHIR_CALL_METHOD(&referencedModelName, relation, "getreferencedmodel", NULL, 0); zephir_check_call_status(); if (Z_TYPE_P(fields) == IS_ARRAY) { - zephir_is_iterable(fields, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1169); + zephir_is_iterable(fields, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1204); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -1638,12 +1672,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { ZEPHIR_CONCAT_SVSVSV(_5, "The number of fields must be equal to the number of referenced fields in join ", modelAlias, "-", joinAlias, ", when preparing: ", _4); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_6, 9, _5); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 1140 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 1175 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_NVAR(intermediateField); - zephir_array_fetch(&intermediateField, intermediateFields, position, PH_NOISY, "phalcon/mvc/model/query.zep", 1146 TSRMLS_CC); + zephir_array_fetch(&intermediateField, intermediateFields, position, PH_NOISY, "phalcon/mvc/model/query.zep", 1181 TSRMLS_CC); ZEPHIR_INIT_NVAR(sqlEqualsJoinCondition); zephir_create_array(sqlEqualsJoinCondition, 4, 0 TSRMLS_CC); add_assoc_stringl_ex(sqlEqualsJoinCondition, SS("type"), SL("binary-op"), 1); @@ -1653,7 +1687,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_long_ex(_8, SS("type"), 355); zephir_array_update_string(&_8, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_8, SL("name"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _8); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _8); zephir_check_call_status(); zephir_array_update_string(&sqlEqualsJoinCondition, SL("left"), &_7, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_NVAR(_10); @@ -1661,7 +1695,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_stringl_ex(_10, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_10, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_10, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _10); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _10); zephir_check_call_status(); zephir_array_update_string(&sqlEqualsJoinCondition, SL("right"), &_7, PH_COPY | PH_SEPARATE); } @@ -1683,7 +1717,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_long_ex(_12, SS("type"), 355); zephir_array_update_string(&_12, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_12, SL("name"), &fields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _12); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _12); zephir_check_call_status(); zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_13); @@ -1691,7 +1725,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_stringl_ex(_13, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_13, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_13, SL("name"), &intermediateFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _13); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _13); zephir_check_call_status(); zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE); zephir_array_fast_append(_10, _11); @@ -1712,7 +1746,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_long_ex(_14, SS("type"), 355); zephir_array_update_string(&_14, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_14, SL("name"), &intermediateReferencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _14); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _14); zephir_check_call_status(); zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE); ZEPHIR_INIT_VAR(_15); @@ -1720,7 +1754,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { add_assoc_stringl_ex(_15, SS("type"), SL("qualified"), 1); zephir_array_update_string(&_15, SL("domain"), &referencedModelName, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_15, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _15); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 318, _15); zephir_check_call_status(); zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE); zephir_array_fast_append(_10, _11); @@ -1739,12 +1773,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) { */ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { - zval *_28 = NULL, *_29 = NULL; - zephir_fcall_cache_entry *_3 = NULL, *_4 = NULL, *_8 = NULL, *_13 = NULL, *_20 = NULL, *_21 = NULL, *_23 = NULL, *_24 = NULL; + zval *_17 = NULL, *_18 = NULL, *_40 = NULL; + zephir_fcall_cache_entry *_3 = NULL, *_4 = NULL, *_8 = NULL, *_13 = NULL, *_31 = NULL, *_32 = NULL, *_35 = NULL, *_36 = NULL; int ZEPHIR_LAST_CALL_STATUS; - HashTable *_1, *_10, *_15, *_18, *_26; - HashPosition _0, _9, _14, _17, _25; - zval *select, *models, *sqlAliases, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *modelsInstances, *fromModels = NULL, *sqlJoins, *joinModels, *joinSources, *joinTypes, *joinPreCondition, *joinPrepared, *manager = NULL, *selectJoins = NULL, *joinItem = NULL, *joins, *joinData = NULL, *schema = NULL, *source = NULL, *model = NULL, *realModelName = NULL, *completeSource = NULL, *joinType = NULL, *aliasExpr = NULL, *alias = NULL, *joinAliasName = NULL, *joinExpr = NULL, *fromModelName = NULL, *joinAlias = NULL, *joinModel = NULL, *joinSource = NULL, *preCondition = NULL, *modelNameAlias = NULL, *relation = NULL, *relations = NULL, *modelAlias = NULL, *sqlJoin = NULL, *sqlJoinItem = NULL, **_2, *_5 = NULL, *_6, *_7 = NULL, **_11, *_12 = NULL, **_16, **_19, *_22 = NULL, **_27; + HashTable *_1, *_10, *_15, *_20, *_26, *_29, *_38; + HashPosition _0, _9, _14, _19, _25, _28, _37; + zval *select, *models, *sqlAliases, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *modelsInstances, *fromModels = NULL, *sqlJoins, *joinModels, *joinSources, *joinTypes, *joinPreCondition, *joinPrepared, *manager, *selectJoins = NULL, *joinItem = NULL, *joins, *joinData = NULL, *schema = NULL, *source = NULL, *model = NULL, *realModelName = NULL, *completeSource = NULL, *joinType = NULL, *aliasExpr = NULL, *alias = NULL, *joinAliasName = NULL, *joinExpr = NULL, *fromModelName = NULL, *joinAlias = NULL, *joinModel = NULL, *joinSource = NULL, *preCondition = NULL, *modelNameAlias = NULL, *relation = NULL, *relations = NULL, *modelAlias = NULL, *sqlJoin = NULL, *sqlJoinItem = NULL, *selectTables = NULL, *tables, *tableItem = NULL, **_2, *_5 = NULL, *_6, *_7 = NULL, **_11, *_12 = NULL, **_16, **_21, *_22, *_23 = NULL, *_24 = NULL, **_27, **_30, *_33 = NULL, *_34, **_39; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 1, 0, &select); @@ -1778,8 +1812,17 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { array_init(joinPrepared); ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tables); + zephir_array_fetch_string(&tables, select, SL("tables"), PH_NOISY, "phalcon/mvc/model/query.zep", 1295 TSRMLS_CC); + if (!(zephir_array_isset_long(tables, 0))) { + ZEPHIR_INIT_VAR(selectTables); + zephir_create_array(selectTables, 1, 0 TSRMLS_CC); + zephir_array_fast_append(selectTables, tables); + } else { + ZEPHIR_CPY_WRT(selectTables, tables); + } ZEPHIR_OBS_VAR(joins); - zephir_array_fetch_string(&joins, select, SL("joins"), PH_NOISY, "phalcon/mvc/model/query.zep", 1260 TSRMLS_CC); + zephir_array_fetch_string(&joins, select, SL("joins"), PH_NOISY, "phalcon/mvc/model/query.zep", 1302 TSRMLS_CC); if (!(zephir_array_isset_long(joins, 0))) { ZEPHIR_INIT_VAR(selectJoins); zephir_create_array(selectJoins, 1, 0 TSRMLS_CC); @@ -1787,32 +1830,32 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { } else { ZEPHIR_CPY_WRT(selectJoins, joins); } - zephir_is_iterable(selectJoins, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1409); + zephir_is_iterable(selectJoins, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1451); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(joinItem, _2); - ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 329, manager, joinItem); + ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 322, manager, joinItem); zephir_check_call_status(); ZEPHIR_OBS_NVAR(source); - zephir_array_fetch_string(&source, joinData, SL("source"), PH_NOISY, "phalcon/mvc/model/query.zep", 1273 TSRMLS_CC); + zephir_array_fetch_string(&source, joinData, SL("source"), PH_NOISY, "phalcon/mvc/model/query.zep", 1315 TSRMLS_CC); ZEPHIR_OBS_NVAR(schema); - zephir_array_fetch_string(&schema, joinData, SL("schema"), PH_NOISY, "phalcon/mvc/model/query.zep", 1274 TSRMLS_CC); + zephir_array_fetch_string(&schema, joinData, SL("schema"), PH_NOISY, "phalcon/mvc/model/query.zep", 1316 TSRMLS_CC); ZEPHIR_OBS_NVAR(model); - zephir_array_fetch_string(&model, joinData, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 1275 TSRMLS_CC); + zephir_array_fetch_string(&model, joinData, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 1317 TSRMLS_CC); ZEPHIR_OBS_NVAR(realModelName); - zephir_array_fetch_string(&realModelName, joinData, SL("modelName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1276 TSRMLS_CC); + zephir_array_fetch_string(&realModelName, joinData, SL("modelName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1318 TSRMLS_CC); ZEPHIR_INIT_NVAR(completeSource); zephir_create_array(completeSource, 2, 0 TSRMLS_CC); zephir_array_fast_append(completeSource, source); zephir_array_fast_append(completeSource, schema); - ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 330, joinItem); + ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 323, joinItem); zephir_check_call_status(); ZEPHIR_OBS_NVAR(aliasExpr); if (zephir_array_isset_string_fetch(&aliasExpr, joinItem, SS("alias"), 0 TSRMLS_CC)) { ZEPHIR_OBS_NVAR(alias); - zephir_array_fetch_string(&alias, aliasExpr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1289 TSRMLS_CC); + zephir_array_fetch_string(&alias, aliasExpr, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1331 TSRMLS_CC); if (zephir_array_isset(joinModels, alias)) { ZEPHIR_INIT_NVAR(_5); object_init_ex(_5, phalcon_mvc_model_exception_ce); @@ -1821,11 +1864,11 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { ZEPHIR_CONCAT_SVSV(_7, "Cannot use '", alias, "' as join alias because it was already used, when preparing: ", _6); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1295 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1337 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1301); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1343); zephir_array_update_zval(&joinTypes, alias, &joinType, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliases, alias, &alias, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&joinModels, alias, &realModelName, PH_COPY | PH_SEPARATE); @@ -1844,7 +1887,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { ZEPHIR_CONCAT_SVSV(_7, "Cannot use '", realModelName, "' as join alias because it was already used, when preparing: ", _6); ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1354 TSRMLS_CC); + zephir_throw_exception_debug(_5, "phalcon/mvc/model/query.zep", 1396 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -1866,7 +1909,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), sqlModelsAliases TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), sqlAliasesModelsInstances TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_modelsInstances"), modelsInstances TSRMLS_CC); - zephir_is_iterable(joinPrepared, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 1429); + zephir_is_iterable(joinPrepared, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 1471); for ( ; zephir_hash_get_current_data_ex(_10, (void**) &_11, &_9) == SUCCESS ; zephir_hash_move_forward_ex(_10, &_9) @@ -1875,102 +1918,141 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) { ZEPHIR_GET_HVALUE(joinItem, _11); ZEPHIR_OBS_NVAR(joinExpr); if (zephir_array_isset_string_fetch(&joinExpr, joinItem, SS("conditions"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 323, joinExpr); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 316, joinExpr); zephir_check_call_status(); zephir_array_update_zval(&joinPreCondition, joinAliasName, &_12, PH_COPY | PH_SEPARATE); } } - ZEPHIR_OBS_NVAR(manager); - zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); - ZEPHIR_INIT_NVAR(_5); - zephir_is_iterable(fromModels, &_15, &_14, 0, 0, "phalcon/mvc/model/query.zep", 1537); + _6 = zephir_fetch_nproperty_this(this_ptr, SL("_enableImplicitJoins"), PH_NOISY_CC); + if (!(zephir_is_true(_6))) { + ZEPHIR_INIT_NVAR(_5); + zephir_is_iterable(joinPrepared, &_15, &_14, 0, 0, "phalcon/mvc/model/query.zep", 1482); + for ( + ; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS + ; zephir_hash_move_forward_ex(_15, &_14) + ) { + ZEPHIR_GET_HMKEY(joinAliasName, _15, _14); + ZEPHIR_GET_HVALUE(_5, _16); + ZEPHIR_OBS_NVAR(joinType); + zephir_array_fetch(&joinType, joinTypes, joinAliasName, PH_NOISY, "phalcon/mvc/model/query.zep", 1473 TSRMLS_CC); + ZEPHIR_OBS_NVAR(joinSource); + zephir_array_fetch(&joinSource, joinSources, joinAliasName, PH_NOISY, "phalcon/mvc/model/query.zep", 1474 TSRMLS_CC); + ZEPHIR_OBS_NVAR(preCondition); + zephir_array_fetch(&preCondition, joinPreCondition, joinAliasName, PH_NOISY, "phalcon/mvc/model/query.zep", 1475 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_17); + zephir_create_array(_17, 3, 0 TSRMLS_CC); + zephir_array_update_string(&_17, SL("type"), &joinType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_17, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_18); + zephir_create_array(_18, 1, 0 TSRMLS_CC); + zephir_array_fast_append(_18, preCondition); + zephir_array_update_string(&_17, SL("conditions"), &_18, PH_COPY | PH_SEPARATE); + zephir_array_append(&sqlJoins, _17, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1480); + } + RETURN_CCTOR(sqlJoins); + } + ZEPHIR_INIT_NVAR(fromModels); + array_init(fromModels); + zephir_is_iterable(selectTables, &_20, &_19, 0, 0, "phalcon/mvc/model/query.zep", 1496); + for ( + ; zephir_hash_get_current_data_ex(_20, (void**) &_21, &_19) == SUCCESS + ; zephir_hash_move_forward_ex(_20, &_19) + ) { + ZEPHIR_GET_HVALUE(tableItem, _21); + zephir_array_fetch_string(&_22, tableItem, SL("qualifiedName"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1490 TSRMLS_CC); + ZEPHIR_OBS_NVAR(_23); + zephir_array_fetch_string(&_23, _22, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1490 TSRMLS_CC); + zephir_array_update_zval(&fromModels, _23, &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE); + } + ZEPHIR_INIT_VAR(_24); + zephir_is_iterable(fromModels, &_26, &_25, 0, 0, "phalcon/mvc/model/query.zep", 1602); for ( - ; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS - ; zephir_hash_move_forward_ex(_15, &_14) + ; zephir_hash_get_current_data_ex(_26, (void**) &_27, &_25) == SUCCESS + ; zephir_hash_move_forward_ex(_26, &_25) ) { - ZEPHIR_GET_HMKEY(fromModelName, _15, _14); - ZEPHIR_GET_HVALUE(_5, _16); - zephir_is_iterable(joinModels, &_18, &_17, 0, 0, "phalcon/mvc/model/query.zep", 1535); + ZEPHIR_GET_HMKEY(fromModelName, _26, _25); + ZEPHIR_GET_HVALUE(_24, _27); + zephir_is_iterable(joinModels, &_29, &_28, 0, 0, "phalcon/mvc/model/query.zep", 1600); for ( - ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS - ; zephir_hash_move_forward_ex(_18, &_17) + ; zephir_hash_get_current_data_ex(_29, (void**) &_30, &_28) == SUCCESS + ; zephir_hash_move_forward_ex(_29, &_28) ) { - ZEPHIR_GET_HMKEY(joinAlias, _18, _17); - ZEPHIR_GET_HVALUE(joinModel, _19); + ZEPHIR_GET_HMKEY(joinAlias, _29, _28); + ZEPHIR_GET_HVALUE(joinModel, _30); ZEPHIR_OBS_NVAR(joinSource); - zephir_array_fetch(&joinSource, joinSources, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1438 TSRMLS_CC); + zephir_array_fetch(&joinSource, joinSources, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1503 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinType); - zephir_array_fetch(&joinType, joinTypes, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1443 TSRMLS_CC); + zephir_array_fetch(&joinType, joinTypes, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1508 TSRMLS_CC); ZEPHIR_OBS_NVAR(preCondition); if (!(zephir_array_isset_fetch(&preCondition, joinPreCondition, joinAlias, 0 TSRMLS_CC))) { ZEPHIR_OBS_NVAR(modelNameAlias); - zephir_array_fetch(&modelNameAlias, sqlAliasesModels, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1453 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&relation, manager, "getrelationbyalias", &_20, 0, fromModelName, modelNameAlias); + zephir_array_fetch(&modelNameAlias, sqlAliasesModels, joinAlias, PH_NOISY, "phalcon/mvc/model/query.zep", 1518 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&relation, manager, "getrelationbyalias", &_31, 0, fromModelName, modelNameAlias); zephir_check_call_status(); if (ZEPHIR_IS_FALSE_IDENTICAL(relation)) { - ZEPHIR_CALL_METHOD(&relations, manager, "getrelationsbetween", &_21, 0, fromModelName, modelNameAlias); + ZEPHIR_CALL_METHOD(&relations, manager, "getrelationsbetween", &_32, 0, fromModelName, modelNameAlias); zephir_check_call_status(); if (Z_TYPE_P(relations) == IS_ARRAY) { if (zephir_fast_count_int(relations TSRMLS_CC) != 1) { - ZEPHIR_INIT_NVAR(_22); - object_init_ex(_22, phalcon_mvc_model_exception_ce); - _6 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); + ZEPHIR_INIT_NVAR(_33); + object_init_ex(_33, phalcon_mvc_model_exception_ce); + _34 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); ZEPHIR_INIT_LNVAR(_7); - ZEPHIR_CONCAT_SVSVSV(_7, "There is more than one relation between models '", fromModelName, "' and '", joinModel, "', the join must be done using an alias, when preparing: ", _6); - ZEPHIR_CALL_METHOD(NULL, _22, "__construct", &_8, 9, _7); + ZEPHIR_CONCAT_SVSVSV(_7, "There is more than one relation between models '", fromModelName, "' and '", joinModel, "', the join must be done using an alias, when preparing: ", _34); + ZEPHIR_CALL_METHOD(NULL, _33, "__construct", &_8, 9, _7); zephir_check_call_status(); - zephir_throw_exception_debug(_22, "phalcon/mvc/model/query.zep", 1471 TSRMLS_CC); + zephir_throw_exception_debug(_33, "phalcon/mvc/model/query.zep", 1536 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_NVAR(relation); - zephir_array_fetch_long(&relation, relations, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 1477 TSRMLS_CC); + zephir_array_fetch_long(&relation, relations, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 1542 TSRMLS_CC); } } if (Z_TYPE_P(relation) == IS_OBJECT) { ZEPHIR_OBS_NVAR(modelAlias); - zephir_array_fetch(&modelAlias, sqlModelsAliases, fromModelName, PH_NOISY, "phalcon/mvc/model/query.zep", 1489 TSRMLS_CC); + zephir_array_fetch(&modelAlias, sqlModelsAliases, fromModelName, PH_NOISY, "phalcon/mvc/model/query.zep", 1554 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_12, relation, "isthrough", NULL, 0); zephir_check_call_status(); if (!(zephir_is_true(_12))) { - ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_23, 331, joinType, joinSource, modelAlias, joinAlias, relation); + ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_35, 324, joinType, joinSource, modelAlias, joinAlias, relation); zephir_check_call_status(); } else { - ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_24, 332, joinType, joinSource, modelAlias, joinAlias, relation); + ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_36, 325, joinType, joinSource, modelAlias, joinAlias, relation); zephir_check_call_status(); } if (zephir_array_isset_long(sqlJoin, 0)) { - zephir_is_iterable(sqlJoin, &_26, &_25, 0, 0, "phalcon/mvc/model/query.zep", 1507); + zephir_is_iterable(sqlJoin, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 1572); for ( - ; zephir_hash_get_current_data_ex(_26, (void**) &_27, &_25) == SUCCESS - ; zephir_hash_move_forward_ex(_26, &_25) + ; zephir_hash_get_current_data_ex(_38, (void**) &_39, &_37) == SUCCESS + ; zephir_hash_move_forward_ex(_38, &_37) ) { - ZEPHIR_GET_HVALUE(sqlJoinItem, _27); - zephir_array_append(&sqlJoins, sqlJoinItem, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1505); + ZEPHIR_GET_HVALUE(sqlJoinItem, _39); + zephir_array_append(&sqlJoins, sqlJoinItem, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1570); } } else { - zephir_array_append(&sqlJoins, sqlJoin, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1508); + zephir_array_append(&sqlJoins, sqlJoin, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1573); } } else { - ZEPHIR_INIT_NVAR(_28); - zephir_create_array(_28, 3, 0 TSRMLS_CC); - zephir_array_update_string(&_28, SL("type"), &joinType, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_28, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); - ZEPHIR_INIT_NVAR(_22); - array_init(_22); - zephir_array_update_string(&_28, SL("conditions"), &_22, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlJoins, _28, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1520); + ZEPHIR_INIT_NVAR(_17); + zephir_create_array(_17, 3, 0 TSRMLS_CC); + zephir_array_update_string(&_17, SL("type"), &joinType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_17, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_33); + array_init(_33); + zephir_array_update_string(&_17, SL("conditions"), &_33, PH_COPY | PH_SEPARATE); + zephir_array_append(&sqlJoins, _17, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1585); } } else { - ZEPHIR_INIT_NVAR(_28); - zephir_create_array(_28, 3, 0 TSRMLS_CC); - zephir_array_update_string(&_28, SL("type"), &joinType, PH_COPY | PH_SEPARATE); - zephir_array_update_string(&_28, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); - ZEPHIR_INIT_NVAR(_29); - zephir_create_array(_29, 1, 0 TSRMLS_CC); - zephir_array_fast_append(_29, preCondition); - zephir_array_update_string(&_28, SL("conditions"), &_29, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlJoins, _28, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1532); + ZEPHIR_INIT_NVAR(_18); + zephir_create_array(_18, 3, 0 TSRMLS_CC); + zephir_array_update_string(&_18, SL("type"), &joinType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_18, SL("source"), &joinSource, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_40); + zephir_create_array(_40, 1, 0 TSRMLS_CC); + zephir_array_fast_append(_40, preCondition); + zephir_array_update_string(&_18, SL("conditions"), &_40, PH_COPY | PH_SEPARATE); + zephir_array_append(&sqlJoins, _18, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1597); } } } @@ -2006,14 +2088,14 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getOrderClause) { } ZEPHIR_INIT_VAR(orderParts); array_init(orderParts); - zephir_is_iterable(orderColumns, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1578); + zephir_is_iterable(orderColumns, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1643); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(orderItem, _2); - zephir_array_fetch_string(&_3, orderItem, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1560 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 323, _3); + zephir_array_fetch_string(&_3, orderItem, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1625 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 316, _3); zephir_check_call_status(); if (zephir_array_isset_string_fetch(&orderSort, orderItem, SS("sort"), 1 TSRMLS_CC)) { ZEPHIR_INIT_NVAR(orderPartSort); @@ -2035,7 +2117,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getOrderClause) { zephir_create_array(orderPartSort, 1, 0 TSRMLS_CC); zephir_array_fast_append(orderPartSort, orderPartExpr); } - zephir_array_append(&orderParts, orderPartSort, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1575); + zephir_array_append(&orderParts, orderPartSort, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1640); } RETURN_CCTOR(orderParts); @@ -2063,19 +2145,19 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getGroupClause) { ZEPHIR_INIT_VAR(groupParts); if (zephir_array_isset_long(group, 0)) { array_init(groupParts); - zephir_is_iterable(group, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1596); + zephir_is_iterable(group, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1661); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(groupItem, _2); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, groupItem); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 316, groupItem); zephir_check_call_status(); - zephir_array_append(&groupParts, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1594); + zephir_array_append(&groupParts, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1659); } } else { zephir_create_array(groupParts, 1, 0 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, group); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 316, group); zephir_check_call_status(); zephir_array_fast_append(groupParts, _3); } @@ -2104,13 +2186,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getLimitClause) { ZEPHIR_OBS_VAR(number); if (zephir_array_isset_string_fetch(&number, limitClause, SS("number"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, number); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 316, number); zephir_check_call_status(); zephir_array_update_string(&limit, SL("number"), &_0, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(offset); if (zephir_array_isset_string_fetch(&offset, limitClause, SS("offset"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, offset); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 316, offset); zephir_check_call_status(); zephir_array_update_string(&limit, SL("offset"), &_0, PH_COPY | PH_SEPARATE); } @@ -2123,12 +2205,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getLimitClause) { */ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { - zval *_30 = NULL; - zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_11 = NULL, *_25 = NULL, *_31 = NULL; - HashTable *_1, *_23, *_27; - HashPosition _0, _22, _26; - int position, ZEPHIR_LAST_CALL_STATUS; - zval *ast = NULL, *merge = NULL, *sqlModels, *sqlTables, *sqlAliases, *sqlColumns, *select = NULL, *tables, *columns, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *models, *modelsInstances, *selectedModels = NULL, *manager, *metaData, *selectedModel = NULL, *qualifiedName = NULL, *modelName = NULL, *nsAlias = NULL, *realModelName = NULL, *model = NULL, *schema = NULL, *source = NULL, *completeSource = NULL, *alias = NULL, *joins, *sqlJoins = NULL, *selectColumns = NULL, *sqlColumnAliases, *column = NULL, *sqlColumn = NULL, *sqlSelect, *distinct, *having, *where, *groupBy, *order, *limit, **_2, *_3 = NULL, *_4, *_6, *_7 = NULL, *_9, *_10 = NULL, *_12, *_13, *_14, *_15, *_16, *_17, *_18, *_19, *_20, *_21, **_24, **_28, _29 = zval_used_for_init, *_32 = NULL; + zval *_19 = NULL, *_20 = NULL, *_21 = NULL; + zval *_16 = NULL; + zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_11 = NULL, *_17 = NULL, *_18 = NULL, *_32 = NULL, *_36 = NULL, *_40 = NULL; + HashTable *_1, *_13, *_34, *_38; + HashPosition _0, _12, _33, _37; + int position, number, ZEPHIR_LAST_CALL_STATUS; + zval *ast = NULL, *merge = NULL, *sqlModels, *sqlTables, *sqlAliases, *sqlColumns, *select = NULL, *tables, *columns, *sqlAliasesModels, *sqlModelsAliases, *sqlAliasesModelsInstances, *models, *modelsInstances, *selectedModels = NULL, *manager, *metaData, *selectedModel = NULL, *qualifiedName = NULL, *modelName = NULL, *nsAlias = NULL, *realModelName = NULL, *model = NULL, *schema = NULL, *source = NULL, *completeSource = NULL, *alias = NULL, *joins, *sqlJoins = NULL, *selectColumns = NULL, *sqlColumnAliases, *column = NULL, *sqlColumn = NULL, *sqlSelect, *distinct, *having, *where, *groupBy, *order, *limit, *tempModels, *tempModelsInstances, *tempSqlAliases, *tempSqlModelsAliases, *tempSqlAliasesModelsInstances, *tempSqlAliasesModels, *with = NULL, *withs = NULL, *withItem = NULL, *automaticJoins, *relation = NULL, *joinAlias = NULL, *relationModel = NULL, *bestAlias = NULL, *eagerType = NULL, **_2, *_3 = NULL, *_4, *_6, *_7 = NULL, *_9, *_10 = NULL, **_14, _15 = zval_used_for_init, *_22, *_23, *_24, *_25, *_26, *_27, *_28, *_29, *_30, *_31, **_35, **_39, *_41 = NULL; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 0, 2, &ast, &merge); @@ -2159,22 +2242,22 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } ZEPHIR_OBS_VAR(tables); if (!(zephir_array_isset_string_fetch(&tables, select, SS("tables"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1648); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1716); return; } ZEPHIR_OBS_VAR(columns); if (!(zephir_array_isset_string_fetch(&columns, select, SS("columns"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1652); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted SELECT AST", "phalcon/mvc/model/query.zep", 1720); return; } ZEPHIR_INIT_VAR(sqlModels); array_init(sqlModels); ZEPHIR_INIT_VAR(sqlTables); array_init(sqlTables); - ZEPHIR_INIT_VAR(sqlAliases); - array_init(sqlAliases); ZEPHIR_INIT_VAR(sqlColumns); array_init(sqlColumns); + ZEPHIR_INIT_VAR(sqlAliases); + array_init(sqlAliases); ZEPHIR_INIT_VAR(sqlAliasesModels); array_init(sqlAliasesModels); ZEPHIR_INIT_VAR(sqlModelsAliases); @@ -2192,35 +2275,45 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } else { ZEPHIR_CPY_WRT(selectedModels, tables); } + if (!(zephir_array_isset_long(columns, 0))) { + ZEPHIR_INIT_VAR(selectColumns); + zephir_create_array(selectColumns, 1, 0 TSRMLS_CC); + zephir_array_fast_append(selectColumns, columns); + } else { + ZEPHIR_CPY_WRT(selectColumns, columns); + } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); ZEPHIR_OBS_VAR(metaData); zephir_read_property_this(&metaData, this_ptr, SL("_metaData"), PH_NOISY_CC); if (Z_TYPE_P(manager) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A models-manager is required to execute the query", "phalcon/mvc/model/query.zep", 1706); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A models-manager is required to execute the query", "phalcon/mvc/model/query.zep", 1782); return; } if (Z_TYPE_P(metaData) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A meta-data is required to execute the query", "phalcon/mvc/model/query.zep", 1710); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A meta-data is required to execute the query", "phalcon/mvc/model/query.zep", 1786); return; } - zephir_is_iterable(selectedModels, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1784); + number = 0; + ZEPHIR_INIT_VAR(automaticJoins); + array_init(automaticJoins); + zephir_is_iterable(selectedModels, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 1913); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(selectedModel, _2); ZEPHIR_OBS_NVAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, selectedModel, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1716 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, selectedModel, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1795 TSRMLS_CC); ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1717 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 1722)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1796 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 1799)) { ZEPHIR_INIT_NVAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1724 TSRMLS_CC); + zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1801 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, manager, "getnamespacealias", &_5, 0, _4); zephir_check_call_status(); - zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1724 TSRMLS_CC); + zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1801 TSRMLS_CC); ZEPHIR_INIT_NVAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _3, "\\", _6); } else { @@ -2249,10 +2342,10 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { object_init_ex(_7, phalcon_mvc_model_exception_ce); _9 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); ZEPHIR_INIT_LNVAR(_10); - ZEPHIR_CONCAT_SVSV(_10, "Alias '", alias, "' is already used, when preparing: ", _9); + ZEPHIR_CONCAT_SVSV(_10, "Alias '", alias, "' is used more than once, when preparing: ", _9); ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_11, 9, _10); zephir_check_call_status(); - zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 1752 TSRMLS_CC); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 1825 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -2261,7 +2354,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { zephir_array_update_zval(&sqlModelsAliases, realModelName, &alias, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, alias, &model, PH_COPY | PH_SEPARATE); if (Z_TYPE_P(completeSource) == IS_ARRAY) { - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1764); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1837); } else { ZEPHIR_INIT_NVAR(completeSource); zephir_create_array(completeSource, 3, 0 TSRMLS_CC); @@ -2271,14 +2364,100 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } zephir_array_update_zval(&models, realModelName, &alias, PH_COPY | PH_SEPARATE); } else { + ZEPHIR_CPY_WRT(alias, source); zephir_array_update_zval(&sqlAliases, realModelName, &source, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModels, realModelName, &realModelName, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlModelsAliases, realModelName, &realModelName, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&models, realModelName, &source, PH_COPY | PH_SEPARATE); } - zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1778); - zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1779); + ZEPHIR_OBS_NVAR(with); + if (zephir_array_isset_string_fetch(&with, selectedModel, SS("with"), 0 TSRMLS_CC)) { + if (!(zephir_array_isset_long(with, 0))) { + ZEPHIR_INIT_NVAR(withs); + zephir_create_array(withs, 1, 0 TSRMLS_CC); + zephir_array_fast_append(withs, with); + } else { + ZEPHIR_CPY_WRT(withs, with); + } + zephir_is_iterable(withs, &_13, &_12, 0, 0, "phalcon/mvc/model/query.zep", 1905); + for ( + ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS + ; zephir_hash_move_forward_ex(_13, &_12) + ) { + ZEPHIR_GET_HVALUE(withItem, _14); + ZEPHIR_SINIT_NVAR(_15); + ZVAL_LONG(&_15, number); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SV(_16, "AA", &_15); + ZEPHIR_CPY_WRT(joinAlias, _16); + ZEPHIR_OBS_NVAR(relationModel); + zephir_array_fetch_string(&relationModel, withItem, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1865 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&relation, manager, "getrelationbyalias", &_17, 0, realModelName, relationModel); + zephir_check_call_status(); + if (Z_TYPE_P(relation) == IS_OBJECT) { + ZEPHIR_INIT_NVAR(_7); + ZVAL_STRING(_7, "alias", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&bestAlias, relation, "getoption", NULL, 0, _7); + zephir_check_temp_parameter(_7); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&relationModel, relation, "getreferencedmodel", NULL, 0); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&eagerType, relation, "gettype", NULL, 0); + zephir_check_call_status(); + } else { + ZEPHIR_CALL_METHOD(&relation, manager, "getrelationsbetween", &_18, 0, realModelName, relationModel); + zephir_check_call_status(); + if (Z_TYPE_P(relation) == IS_OBJECT) { + ZEPHIR_INIT_NVAR(_7); + ZVAL_STRING(_7, "alias", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(&bestAlias, relation, "getoption", NULL, 0, _7); + zephir_check_temp_parameter(_7); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&relationModel, relation, "getreferencedmodel", NULL, 0); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&eagerType, relation, "gettype", NULL, 0); + zephir_check_call_status(); + } else { + ZEPHIR_INIT_NVAR(_7); + object_init_ex(_7, phalcon_mvc_model_exception_ce); + _9 = zephir_fetch_nproperty_this(this_ptr, SL("_phql"), PH_NOISY_CC); + ZEPHIR_INIT_LNVAR(_10); + ZEPHIR_CONCAT_SVSVSV(_10, "Can't find a relationship between '", realModelName, "' and '", relationModel, "' when preparing: ", _9); + ZEPHIR_CALL_METHOD(NULL, _7, "__construct", &_11, 9, _10); + zephir_check_call_status(); + zephir_throw_exception_debug(_7, "phalcon/mvc/model/query.zep", 1879 TSRMLS_CC); + ZEPHIR_MM_RESTORE(); + return; + } + } + ZEPHIR_INIT_NVAR(_19); + zephir_create_array(_19, 5, 0 TSRMLS_CC); + add_assoc_long_ex(_19, SS("type"), 353); + zephir_array_update_string(&_19, SL("column"), &joinAlias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_19, SL("eager"), &alias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_19, SL("eagerType"), &eagerType, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_19, SL("balias"), &bestAlias, PH_COPY | PH_SEPARATE); + zephir_array_append(&selectColumns, _19, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1889); + ZEPHIR_INIT_NVAR(_20); + zephir_create_array(_20, 3, 0 TSRMLS_CC); + add_assoc_long_ex(_20, SS("type"), 360); + ZEPHIR_INIT_NVAR(_21); + zephir_create_array(_21, 2, 0 TSRMLS_CC); + add_assoc_long_ex(_21, SS("type"), 355); + zephir_array_update_string(&_21, SL("name"), &relationModel, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_20, SL("qualified"), &_21, PH_COPY | PH_SEPARATE); + ZEPHIR_INIT_NVAR(_21); + zephir_create_array(_21, 2, 0 TSRMLS_CC); + add_assoc_long_ex(_21, SS("type"), 355); + zephir_array_update_string(&_21, SL("name"), &joinAlias, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&_20, SL("alias"), &_21, PH_COPY | PH_SEPARATE); + zephir_array_append(&automaticJoins, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1901); + number++; + } + } + zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1907); + zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1908); zephir_array_update_zval(&modelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); } if (!(zephir_is_true(merge))) { @@ -2289,68 +2468,85 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), sqlModelsAliases TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), sqlAliasesModelsInstances TSRMLS_CC); } else { + ZEPHIR_OBS_VAR(tempModels); + zephir_read_property_this(&tempModels, this_ptr, SL("_models"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempModelsInstances); + zephir_read_property_this(&tempModelsInstances, this_ptr, SL("_modelsInstances"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlAliases); + zephir_read_property_this(&tempSqlAliases, this_ptr, SL("_sqlAliases"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlAliasesModels); + zephir_read_property_this(&tempSqlAliasesModels, this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlModelsAliases); + zephir_read_property_this(&tempSqlModelsAliases, this_ptr, SL("_sqlModelsAliases"), PH_NOISY_CC); + ZEPHIR_OBS_VAR(tempSqlAliasesModelsInstances); + zephir_read_property_this(&tempSqlAliasesModelsInstances, this_ptr, SL("_sqlAliasesModelsInstances"), PH_NOISY_CC); ZEPHIR_INIT_NVAR(_7); _9 = zephir_fetch_nproperty_this(this_ptr, SL("_models"), PH_NOISY_CC); zephir_fast_array_merge(_7, &(_9), &(models) TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_models"), _7 TSRMLS_CC); - ZEPHIR_INIT_VAR(_12); - _13 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); - zephir_fast_array_merge(_12, &(_13), &(modelsInstances) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_modelsInstances"), _12 TSRMLS_CC); - ZEPHIR_INIT_VAR(_14); - _15 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliases"), PH_NOISY_CC); - zephir_fast_array_merge(_14, &(_15), &(sqlAliases) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlAliases"), _14 TSRMLS_CC); - ZEPHIR_INIT_VAR(_16); - _17 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); - zephir_fast_array_merge(_16, &(_17), &(sqlAliasesModels) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlAliasesModels"), _16 TSRMLS_CC); - ZEPHIR_INIT_VAR(_18); - _19 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlModelsAliases"), PH_NOISY_CC); - zephir_fast_array_merge(_18, &(_19), &(sqlModelsAliases) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), _18 TSRMLS_CC); - ZEPHIR_INIT_VAR(_20); - _21 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModelsInstances"), PH_NOISY_CC); - zephir_fast_array_merge(_20, &(_21), &(sqlAliasesModelsInstances) TSRMLS_CC); - zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), _20 TSRMLS_CC); + ZEPHIR_INIT_VAR(_22); + _23 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); + zephir_fast_array_merge(_22, &(_23), &(modelsInstances) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_modelsInstances"), _22 TSRMLS_CC); + ZEPHIR_INIT_VAR(_24); + _25 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliases"), PH_NOISY_CC); + zephir_fast_array_merge(_24, &(_25), &(sqlAliases) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliases"), _24 TSRMLS_CC); + ZEPHIR_INIT_VAR(_26); + _27 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModels"), PH_NOISY_CC); + zephir_fast_array_merge(_26, &(_27), &(sqlAliasesModels) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModels"), _26 TSRMLS_CC); + ZEPHIR_INIT_VAR(_28); + _29 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlModelsAliases"), PH_NOISY_CC); + zephir_fast_array_merge(_28, &(_29), &(sqlModelsAliases) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), _28 TSRMLS_CC); + ZEPHIR_INIT_VAR(_30); + _31 = zephir_fetch_nproperty_this(this_ptr, SL("_sqlAliasesModelsInstances"), PH_NOISY_CC); + zephir_fast_array_merge(_30, &(_31), &(sqlAliasesModelsInstances) TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), _30 TSRMLS_CC); } ZEPHIR_OBS_VAR(joins); - if (zephir_array_isset_string_fetch(&joins, select, SS("joins"), 0 TSRMLS_CC)) { - if (zephir_fast_count_int(joins TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", NULL, 333, select); + zephir_array_isset_string_fetch(&joins, select, SS("joins"), 0 TSRMLS_CC); + if (zephir_fast_count_int(joins TSRMLS_CC)) { + if (zephir_fast_count_int(automaticJoins TSRMLS_CC)) { + if (zephir_array_isset_long(joins, 0)) { + ZEPHIR_INIT_NVAR(_7); + zephir_fast_array_merge(_7, &(joins), &(automaticJoins) TSRMLS_CC); + zephir_array_update_string(&select, SL("joins"), &_7, PH_COPY | PH_SEPARATE); + } else { + zephir_array_append(&automaticJoins, joins, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1945); + zephir_array_update_string(&select, SL("joins"), &automaticJoins, PH_COPY | PH_SEPARATE); + } + } + ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", &_32, 326, select); + zephir_check_call_status(); + } else { + if (zephir_fast_count_int(automaticJoins TSRMLS_CC)) { + zephir_array_update_string(&select, SL("joins"), &automaticJoins, PH_COPY | PH_SEPARATE); + ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", &_32, 326, select); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(sqlJoins); array_init(sqlJoins); } - } else { - ZEPHIR_INIT_NVAR(sqlJoins); - array_init(sqlJoins); - } - if (!(zephir_array_isset_long(columns, 0))) { - ZEPHIR_INIT_VAR(selectColumns); - zephir_create_array(selectColumns, 1, 0 TSRMLS_CC); - zephir_array_fast_append(selectColumns, columns); - } else { - ZEPHIR_CPY_WRT(selectColumns, columns); } position = 0; ZEPHIR_INIT_VAR(sqlColumnAliases); array_init(sqlColumnAliases); - zephir_is_iterable(selectColumns, &_23, &_22, 0, 0, "phalcon/mvc/model/query.zep", 1857); + zephir_is_iterable(selectColumns, &_34, &_33, 0, 0, "phalcon/mvc/model/query.zep", 1998); for ( - ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS - ; zephir_hash_move_forward_ex(_23, &_22) + ; zephir_hash_get_current_data_ex(_34, (void**) &_35, &_33) == SUCCESS + ; zephir_hash_move_forward_ex(_34, &_33) ) { - ZEPHIR_GET_HVALUE(column, _24); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_25, 334, column); + ZEPHIR_GET_HVALUE(column, _35); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_36, 327, column); zephir_check_call_status(); - zephir_is_iterable(_3, &_27, &_26, 0, 0, "phalcon/mvc/model/query.zep", 1856); + zephir_is_iterable(_3, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 1997); for ( - ; zephir_hash_get_current_data_ex(_27, (void**) &_28, &_26) == SUCCESS - ; zephir_hash_move_forward_ex(_27, &_26) + ; zephir_hash_get_current_data_ex(_38, (void**) &_39, &_37) == SUCCESS + ; zephir_hash_move_forward_ex(_38, &_37) ) { - ZEPHIR_GET_HVALUE(sqlColumn, _28); + ZEPHIR_GET_HVALUE(sqlColumn, _39); ZEPHIR_OBS_NVAR(alias); if (zephir_array_isset_string_fetch(&alias, column, SS("alias"), 0 TSRMLS_CC)) { zephir_array_update_string(&sqlColumn, SL("balias"), &alias, PH_COPY | PH_SEPARATE); @@ -2362,15 +2558,15 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { if (zephir_array_isset_string_fetch(&alias, sqlColumn, SS("balias"), 0 TSRMLS_CC)) { zephir_array_update_zval(&sqlColumns, alias, &sqlColumn, PH_COPY | PH_SEPARATE); } else { - zephir_array_fetch_string(&_4, sqlColumn, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1846 TSRMLS_CC); + zephir_array_fetch_string(&_4, sqlColumn, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1987 TSRMLS_CC); if (ZEPHIR_IS_STRING(_4, "scalar")) { - ZEPHIR_SINIT_NVAR(_29); - ZVAL_LONG(&_29, position); - ZEPHIR_INIT_LNVAR(_30); - ZEPHIR_CONCAT_SV(_30, "_", &_29); - zephir_array_update_zval(&sqlColumns, _30, &sqlColumn, PH_COPY | PH_SEPARATE); + ZEPHIR_SINIT_NVAR(_15); + ZVAL_LONG(&_15, position); + ZEPHIR_INIT_LNVAR(_16); + ZEPHIR_CONCAT_SV(_16, "_", &_15); + zephir_array_update_zval(&sqlColumns, _16, &sqlColumn, PH_COPY | PH_SEPARATE); } else { - zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1849); + zephir_array_append(&sqlColumns, sqlColumn, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1990); } } } @@ -2392,37 +2588,45 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) { } ZEPHIR_OBS_VAR(where); if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_31, 323, where); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_40, 316, where); zephir_check_call_status(); zephir_array_update_string(&sqlSelect, SL("where"), &_3, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(groupBy); if (zephir_array_isset_string_fetch(&groupBy, ast, SS("groupBy"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getgroupclause", NULL, 335, groupBy); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getgroupclause", NULL, 328, groupBy); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("group"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("group"), &_41, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(having); if (zephir_array_isset_string_fetch(&having, ast, SS("having"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getexpression", &_31, 323, having); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getexpression", &_40, 316, having); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("having"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("having"), &_41, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(order); if (zephir_array_isset_string_fetch(&order, ast, SS("orderBy"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getorderclause", NULL, 336, order); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getorderclause", NULL, 329, order); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("order"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("order"), &_41, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(limit); if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getlimitclause", NULL, 337, limit); + ZEPHIR_CALL_METHOD(&_41, this_ptr, "_getlimitclause", NULL, 330, limit); zephir_check_call_status(); - zephir_array_update_string(&sqlSelect, SL("limit"), &_32, PH_COPY | PH_SEPARATE); + zephir_array_update_string(&sqlSelect, SL("limit"), &_41, PH_COPY | PH_SEPARATE); } if (zephir_array_isset_string(ast, SS("forUpdate"))) { zephir_array_update_string(&sqlSelect, SL("forUpdate"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE); } + if (zephir_is_true(merge)) { + zephir_update_property_this(this_ptr, SL("_models"), tempModels TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_modelsInstances"), tempModelsInstances TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliases"), tempSqlAliases TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModels"), tempSqlAliasesModels TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlModelsAliases"), tempSqlModelsAliases TSRMLS_CC); + zephir_update_property_this(this_ptr, SL("_sqlAliasesModelsInstances"), tempSqlAliasesModelsInstances TSRMLS_CC); + } RETURN_CCTOR(sqlSelect); } @@ -2445,30 +2649,30 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { ZEPHIR_OBS_VAR(ast); zephir_read_property_this(&ast, this_ptr, SL("_ast"), PH_NOISY_CC); if (!(zephir_array_isset_string(ast, SS("qualifiedName")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 1920); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 2070); return; } if (!(zephir_array_isset_string(ast, SS("values")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 1924); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 2074); return; } ZEPHIR_OBS_VAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, ast, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 1927 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, ast, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2077 TSRMLS_CC); if (!(zephir_array_isset_string(qualifiedName, SS("name")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 1931); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted INSERT AST", "phalcon/mvc/model/query.zep", 2081); return; } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1935 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 1938)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2085 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2088)) { ZEPHIR_INIT_VAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_1, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1940 TSRMLS_CC); + zephir_array_fetch_long(&_1, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2090 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_0, manager, "getnamespacealias", NULL, 0, _1); zephir_check_call_status(); - zephir_array_fetch_long(&_2, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1940 TSRMLS_CC); + zephir_array_fetch_long(&_2, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2090 TSRMLS_CC); ZEPHIR_INIT_VAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _0, "\\", _2); } else { @@ -2491,8 +2695,8 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { notQuoting = 0; ZEPHIR_INIT_VAR(exprValues); array_init(exprValues); - zephir_array_fetch_string(&_1, ast, SL("values"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1956 TSRMLS_CC); - zephir_is_iterable(_1, &_5, &_4, 0, 0, "phalcon/mvc/model/query.zep", 1965); + zephir_array_fetch_string(&_1, ast, SL("values"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2106 TSRMLS_CC); + zephir_is_iterable(_1, &_5, &_4, 0, 0, "phalcon/mvc/model/query.zep", 2115); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -2501,12 +2705,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { ZEPHIR_INIT_NVAR(_7); zephir_create_array(_7, 2, 0 TSRMLS_CC); ZEPHIR_OBS_NVAR(_8); - zephir_array_fetch_string(&_8, exprValue, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 1960 TSRMLS_CC); + zephir_array_fetch_string(&_8, exprValue, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2110 TSRMLS_CC); zephir_array_update_string(&_7, SL("type"), &_8, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 323, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 316, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_array_update_string(&_7, SL("value"), &_0, PH_COPY | PH_SEPARATE); - zephir_array_append(&exprValues, _7, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1962); + zephir_array_append(&exprValues, _7, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2112); } ZEPHIR_INIT_VAR(sqlInsert); zephir_create_array(sqlInsert, 2, 0 TSRMLS_CC); @@ -2518,14 +2722,14 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { if (zephir_array_isset_string_fetch(&fields, ast, SS("fields"), 0 TSRMLS_CC)) { ZEPHIR_INIT_VAR(sqlFields); array_init(sqlFields); - zephir_is_iterable(fields, &_11, &_10, 0, 0, "phalcon/mvc/model/query.zep", 1987); + zephir_is_iterable(fields, &_11, &_10, 0, 0, "phalcon/mvc/model/query.zep", 2137); for ( ; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS ; zephir_hash_move_forward_ex(_11, &_10) ) { ZEPHIR_GET_HVALUE(field, _12); ZEPHIR_OBS_NVAR(name); - zephir_array_fetch_string(&name, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 1976 TSRMLS_CC); + zephir_array_fetch_string(&name, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2126 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_0, metaData, "hasattribute", &_13, 0, model, name); zephir_check_call_status(); if (!(zephir_is_true(_0))) { @@ -2536,11 +2740,11 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) { ZEPHIR_CONCAT_SVSVSV(_15, "The model '", modelName, "' doesn't have the attribute '", name, "', when preparing: ", _14); ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_16, 9, _15); zephir_check_call_status(); - zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 1980 TSRMLS_CC); + zephir_throw_exception_debug(_3, "phalcon/mvc/model/query.zep", 2130 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } - zephir_array_append(&sqlFields, name, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1984); + zephir_array_append(&sqlFields, name, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2134); } zephir_array_update_string(&sqlInsert, SL("fields"), &sqlFields, PH_COPY | PH_SEPARATE); } @@ -2568,17 +2772,17 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { zephir_read_property_this(&ast, this_ptr, SL("_ast"), PH_NOISY_CC); ZEPHIR_OBS_VAR(update); if (!(zephir_array_isset_string_fetch(&update, ast, SS("update"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2011); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2161); return; } ZEPHIR_OBS_VAR(tables); if (!(zephir_array_isset_string_fetch(&tables, update, SS("tables"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2015); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2165); return; } ZEPHIR_OBS_VAR(values); if (!(zephir_array_isset_string_fetch(&values, update, SS("values"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2019); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted UPDATE AST", "phalcon/mvc/model/query.zep", 2169); return; } ZEPHIR_INIT_VAR(models); @@ -2602,23 +2806,23 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); - zephir_is_iterable(updateTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2094); + zephir_is_iterable(updateTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2244); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(table, _2); ZEPHIR_OBS_NVAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2042 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2192 TSRMLS_CC); ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2043 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2048)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2193 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2198)) { ZEPHIR_INIT_NVAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2050 TSRMLS_CC); + zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2200 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, manager, "getnamespacealias", &_5, 0, _4); zephir_check_call_status(); - zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2050 TSRMLS_CC); + zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2200 TSRMLS_CC); ZEPHIR_INIT_NVAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _3, "\\", _6); } else { @@ -2645,17 +2849,17 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { ZEPHIR_OBS_NVAR(alias); if (zephir_array_isset_string_fetch(&alias, table, SS("alias"), 0 TSRMLS_CC)) { zephir_array_update_zval(&sqlAliases, alias, &alias, PH_COPY | PH_SEPARATE); - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2076); - zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2077); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2226); + zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2227); zephir_array_update_zval(&sqlAliasesModelsInstances, alias, &model, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&models, alias, &realModelName, PH_COPY | PH_SEPARATE); } else { zephir_array_update_zval(&sqlAliases, realModelName, &source, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2083); + zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2233); zephir_array_update_zval(&models, realModelName, &source, PH_COPY | PH_SEPARATE); } - zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2087); + zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2237); zephir_array_update_zval(&modelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); } zephir_update_property_this(this_ptr, SL("_models"), models TSRMLS_CC); @@ -2674,27 +2878,27 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { ZEPHIR_CPY_WRT(updateValues, values); } notQuoting = 0; - zephir_is_iterable(updateValues, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 2119); + zephir_is_iterable(updateValues, &_10, &_9, 0, 0, "phalcon/mvc/model/query.zep", 2268); for ( ; zephir_hash_get_current_data_ex(_10, (void**) &_11, &_9) == SUCCESS ; zephir_hash_move_forward_ex(_10, &_9) ) { ZEPHIR_GET_HVALUE(updateValue, _11); - zephir_array_fetch_string(&_4, updateValue, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2110 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 323, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_4, updateValue, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2260 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 316, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); - zephir_array_append(&sqlFields, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2110); + zephir_array_append(&sqlFields, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2260); ZEPHIR_OBS_NVAR(exprColumn); - zephir_array_fetch_string(&exprColumn, updateValue, SL("expr"), PH_NOISY, "phalcon/mvc/model/query.zep", 2111 TSRMLS_CC); + zephir_array_fetch_string(&exprColumn, updateValue, SL("expr"), PH_NOISY, "phalcon/mvc/model/query.zep", 2261 TSRMLS_CC); ZEPHIR_INIT_NVAR(_13); zephir_create_array(_13, 2, 0 TSRMLS_CC); ZEPHIR_OBS_NVAR(_14); - zephir_array_fetch_string(&_14, exprColumn, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2113 TSRMLS_CC); + zephir_array_fetch_string(&_14, exprColumn, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2263 TSRMLS_CC); zephir_array_update_string(&_13, SL("type"), &_14, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 316, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_array_update_string(&_13, SL("value"), &_15, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlValues, _13, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2115); + zephir_array_append(&sqlValues, _13, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2265); } ZEPHIR_INIT_VAR(sqlUpdate); zephir_create_array(sqlUpdate, 4, 0 TSRMLS_CC); @@ -2706,13 +2910,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) { if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) { ZEPHIR_SINIT_VAR(_16); ZVAL_BOOL(&_16, 1); - ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, where, &_16); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 316, where, &_16); zephir_check_call_status(); zephir_array_update_string(&sqlUpdate, SL("where"), &_15, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(limit); if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 337, limit); + ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 330, limit); zephir_check_call_status(); zephir_array_update_string(&sqlUpdate, SL("limit"), &_15, PH_COPY | PH_SEPARATE); } @@ -2737,12 +2941,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { zephir_read_property_this(&ast, this_ptr, SL("_ast"), PH_NOISY_CC); ZEPHIR_OBS_VAR(delete); if (!(zephir_array_isset_string_fetch(&delete, ast, SS("delete"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2151); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2300); return; } ZEPHIR_OBS_VAR(tables); if (!(zephir_array_isset_string_fetch(&tables, delete, SS("tables"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2155); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted DELETE AST", "phalcon/mvc/model/query.zep", 2304); return; } ZEPHIR_INIT_VAR(models); @@ -2766,23 +2970,23 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { } ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); - zephir_is_iterable(deleteTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2226); + zephir_is_iterable(deleteTables, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2374); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) ) { ZEPHIR_GET_HVALUE(table, _2); ZEPHIR_OBS_NVAR(qualifiedName); - zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2177 TSRMLS_CC); + zephir_array_fetch_string(&qualifiedName, table, SL("qualifiedName"), PH_NOISY, "phalcon/mvc/model/query.zep", 2328 TSRMLS_CC); ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2178 TSRMLS_CC); - if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2186)) { + zephir_array_fetch_string(&modelName, qualifiedName, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2329 TSRMLS_CC); + if (zephir_memnstr_str(modelName, SL(":"), "phalcon/mvc/model/query.zep", 2334)) { ZEPHIR_INIT_NVAR(nsAlias); zephir_fast_explode_str(nsAlias, SL(":"), modelName, LONG_MAX TSRMLS_CC); - zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2188 TSRMLS_CC); + zephir_array_fetch_long(&_4, nsAlias, 0, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2336 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, manager, "getnamespacealias", &_5, 0, _4); zephir_check_call_status(); - zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2188 TSRMLS_CC); + zephir_array_fetch_long(&_6, nsAlias, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2336 TSRMLS_CC); ZEPHIR_INIT_NVAR(realModelName); ZEPHIR_CONCAT_VSV(realModelName, _3, "\\", _6); } else { @@ -2809,17 +3013,17 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { ZEPHIR_OBS_NVAR(alias); if (zephir_array_isset_string_fetch(&alias, table, SS("alias"), 0 TSRMLS_CC)) { zephir_array_update_zval(&sqlAliases, alias, &alias, PH_COPY | PH_SEPARATE); - zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2208); - zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2209); + zephir_array_append(&completeSource, alias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2356); + zephir_array_append(&sqlTables, completeSource, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2357); zephir_array_update_zval(&sqlAliasesModelsInstances, alias, &model, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&models, alias, &realModelName, PH_COPY | PH_SEPARATE); } else { zephir_array_update_zval(&sqlAliases, realModelName, &source, PH_COPY | PH_SEPARATE); zephir_array_update_zval(&sqlAliasesModelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); - zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2215); + zephir_array_append(&sqlTables, source, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2363); zephir_array_update_zval(&models, realModelName, &source, PH_COPY | PH_SEPARATE); } - zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2219); + zephir_array_append(&sqlModels, realModelName, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2367); zephir_array_update_zval(&modelsInstances, realModelName, &model, PH_COPY | PH_SEPARATE); } zephir_update_property_this(this_ptr, SL("_models"), models TSRMLS_CC); @@ -2834,13 +3038,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) { if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) { ZEPHIR_SINIT_VAR(_9); ZVAL_BOOL(&_9, 1); - ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 323, where, &_9); + ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 316, where, &_9); zephir_check_call_status(); zephir_array_update_string(&sqlDelete, SL("where"), &_3, PH_COPY | PH_SEPARATE); } ZEPHIR_OBS_VAR(limit); if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 337, limit); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 330, limit); zephir_check_call_status(); zephir_array_update_string(&sqlDelete, SL("limit"), &_10, PH_COPY | PH_SEPARATE); } @@ -2880,7 +3084,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { _0 = zephir_fetch_static_property_ce(phalcon_mvc_model_query_ce, SL("_irPhqlCache") TSRMLS_CC); if (zephir_array_isset_fetch(&irPhql, _0, uniqueId, 0 TSRMLS_CC)) { if (Z_TYPE_P(irPhql) == IS_ARRAY) { - zephir_array_fetch_string(&_1, ast, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2277 TSRMLS_CC); + zephir_array_fetch_string(&_1, ast, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2425 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_type"), _1 TSRMLS_CC); RETURN_CCTOR(irPhql); } @@ -2892,22 +3096,22 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { zephir_update_property_this(this_ptr, SL("_type"), type TSRMLS_CC); do { if (ZEPHIR_IS_LONG(type, 309)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 328); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 321); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 306)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 338); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 331); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 300)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 339); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 332); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 303)) { - ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 340); + ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 333); zephir_check_call_status(); break; } @@ -2917,7 +3121,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { ZEPHIR_CONCAT_SVSV(_3, "Unknown statement ", type, ", when preparing: ", phql); ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/mvc/model/query.zep", 2310 TSRMLS_CC); + zephir_throw_exception_debug(_2, "phalcon/mvc/model/query.zep", 2458 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -2925,7 +3129,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, parse) { } } if (Z_TYPE_P(irPhql) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted AST", "phalcon/mvc/model/query.zep", 2316); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Corrupted AST", "phalcon/mvc/model/query.zep", 2464); return; } if (Z_TYPE_P(uniqueId) == IS_LONG) { @@ -2975,8 +3179,8 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_INIT_VAR(connectionTypes); array_init(connectionTypes); ZEPHIR_OBS_VAR(models); - zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2359 TSRMLS_CC); - zephir_is_iterable(models, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2387); + zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2507 TSRMLS_CC); + zephir_is_iterable(models, &_1, &_0, 0, 0, "phalcon/mvc/model/query.zep", 2535); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -2995,7 +3199,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_CALL_METHOD(&connection, model, "selectreadconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectReadConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2374); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectReadConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2522); return; } } else { @@ -3006,28 +3210,28 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_check_call_status(); zephir_array_update_zval(&connectionTypes, _6, &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE); if (zephir_fast_count_int(connectionTypes TSRMLS_CC) == 2) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot use models of different database systems in the same query", "phalcon/mvc/model/query.zep", 2383); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot use models of different database systems in the same query", "phalcon/mvc/model/query.zep", 2531); return; } } ZEPHIR_OBS_VAR(columns); - zephir_array_fetch_string(&columns, intermediate, SL("columns"), PH_NOISY, "phalcon/mvc/model/query.zep", 2387 TSRMLS_CC); + zephir_array_fetch_string(&columns, intermediate, SL("columns"), PH_NOISY, "phalcon/mvc/model/query.zep", 2535 TSRMLS_CC); haveObjects = 0; haveScalars = 0; isComplex = 0; numberObjects = 0; ZEPHIR_CPY_WRT(columns1, columns); - zephir_is_iterable(columns, &_8, &_7, 0, 0, "phalcon/mvc/model/query.zep", 2414); + zephir_is_iterable(columns, &_8, &_7, 0, 0, "phalcon/mvc/model/query.zep", 2562); for ( ; zephir_hash_get_current_data_ex(_8, (void**) &_9, &_7) == SUCCESS ; zephir_hash_move_forward_ex(_8, &_7) ) { ZEPHIR_GET_HVALUE(column, _9); if (Z_TYPE_P(column) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid column definition", "phalcon/mvc/model/query.zep", 2400); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid column definition", "phalcon/mvc/model/query.zep", 2548); return; } - zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2403 TSRMLS_CC); + zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2551 TSRMLS_CC); if (ZEPHIR_IS_STRING(_10, "scalar")) { if (!(zephir_array_isset_string(column, SS("balias")))) { isComplex = 1; @@ -3061,7 +3265,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { array_init(simpleColumnMap); ZEPHIR_OBS_VAR(metaData); zephir_read_property_this(&metaData, this_ptr, SL("_metaData"), PH_NOISY_CC); - zephir_is_iterable(columns, &_12, &_11, 0, 0, "phalcon/mvc/model/query.zep", 2513); + zephir_is_iterable(columns, &_12, &_11, 0, 0, "phalcon/mvc/model/query.zep", 2661); for ( ; zephir_hash_get_current_data_ex(_12, (void**) &_13, &_11) == SUCCESS ; zephir_hash_move_forward_ex(_12, &_11) @@ -3069,11 +3273,11 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_GET_HMKEY(aliasCopy, _12, _11); ZEPHIR_GET_HVALUE(column, _13); ZEPHIR_OBS_NVAR(sqlColumn); - zephir_array_fetch_string(&sqlColumn, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 2438 TSRMLS_CC); - zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2441 TSRMLS_CC); + zephir_array_fetch_string(&sqlColumn, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 2586 TSRMLS_CC); + zephir_array_fetch_string(&_10, column, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2589 TSRMLS_CC); if (ZEPHIR_IS_STRING(_10, "object")) { ZEPHIR_OBS_NVAR(modelName); - zephir_array_fetch_string(&modelName, column, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2443 TSRMLS_CC); + zephir_array_fetch_string(&modelName, column, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2591 TSRMLS_CC); ZEPHIR_OBS_NVAR(instance); _3 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&instance, _3, modelName, 0 TSRMLS_CC))) { @@ -3091,7 +3295,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_INIT_NVAR(columnMap); ZVAL_NULL(columnMap); } - zephir_is_iterable(attributes, &_18, &_17, 0, 0, "phalcon/mvc/model/query.zep", 2469); + zephir_is_iterable(attributes, &_18, &_17, 0, 0, "phalcon/mvc/model/query.zep", 2617); for ( ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS ; zephir_hash_move_forward_ex(_18, &_17) @@ -3104,7 +3308,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { ZEPHIR_INIT_LNVAR(_21); ZEPHIR_CONCAT_SVSV(_21, "_", sqlColumn, "_", attribute); zephir_array_fast_append(_20, _21); - zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2465); + zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2613); } zephir_array_update_multi(&columns1, &instance TSRMLS_CC, SL("zs"), 3, aliasCopy, SL("instance")); zephir_array_update_multi(&columns1, &attributes TSRMLS_CC, SL("zs"), 3, aliasCopy, SL("attributes")); @@ -3118,7 +3322,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_array_update_multi(&columns1, &_4 TSRMLS_CC, SL("zs"), 3, aliasCopy, SL("keepSnapshots")); } } else { - zephir_is_iterable(attributes, &_24, &_23, 0, 0, "phalcon/mvc/model/query.zep", 2487); + zephir_is_iterable(attributes, &_24, &_23, 0, 0, "phalcon/mvc/model/query.zep", 2635); for ( ; zephir_hash_get_current_data_ex(_24, (void**) &_25, &_23) == SUCCESS ; zephir_hash_move_forward_ex(_24, &_23) @@ -3128,7 +3332,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_create_array(_20, 2, 0 TSRMLS_CC); zephir_array_fast_append(_20, attribute); zephir_array_fast_append(_20, sqlColumn); - zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2485); + zephir_array_append(&selectColumns, _20, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2633); } } } else { @@ -3143,7 +3347,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_array_fast_append(columnAlias, ZEPHIR_GLOBAL(global_null)); zephir_array_fast_append(columnAlias, aliasCopy); } - zephir_array_append(&selectColumns, columnAlias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2498); + zephir_array_append(&selectColumns, columnAlias, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2646); } _26 = isComplex == 0; if (_26) { @@ -3164,7 +3368,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { if (Z_TYPE_P(bindParams) == IS_ARRAY) { ZEPHIR_INIT_VAR(processed); array_init(processed); - zephir_is_iterable(bindParams, &_28, &_27, 0, 0, "phalcon/mvc/model/query.zep", 2534); + zephir_is_iterable(bindParams, &_28, &_27, 0, 0, "phalcon/mvc/model/query.zep", 2682); for ( ; zephir_hash_get_current_data_ex(_28, (void**) &_29, &_27) == SUCCESS ; zephir_hash_move_forward_ex(_28, &_27) @@ -3190,7 +3394,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { if (Z_TYPE_P(bindTypes) == IS_ARRAY) { ZEPHIR_INIT_VAR(processedTypes); array_init(processedTypes); - zephir_is_iterable(bindTypes, &_31, &_30, 0, 0, "phalcon/mvc/model/query.zep", 2550); + zephir_is_iterable(bindTypes, &_31, &_30, 0, 0, "phalcon/mvc/model/query.zep", 2698); for ( ; zephir_hash_get_current_data_ex(_31, (void**) &_32, &_30) == SUCCESS ; zephir_hash_move_forward_ex(_31, &_30) @@ -3262,7 +3466,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { array_init(simpleColumnMap); ZEPHIR_CALL_METHOD(&_6, metaData, "getattributes", NULL, 0, model); zephir_check_call_status(); - zephir_is_iterable(_6, &_34, &_33, 0, 0, "phalcon/mvc/model/query.zep", 2633); + zephir_is_iterable(_6, &_34, &_33, 0, 0, "phalcon/mvc/model/query.zep", 2781); for ( ; zephir_hash_get_current_data_ex(_34, (void**) &_35, &_33) == SUCCESS ; zephir_hash_move_forward_ex(_34, &_33) @@ -3272,13 +3476,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_create_array(_20, 2, 0 TSRMLS_CC); zephir_array_fast_append(_20, attribute); ZEPHIR_OBS_NVAR(_36); - zephir_array_fetch(&_36, typesColumnMap, attribute, PH_NOISY, "phalcon/mvc/model/query.zep", 2631 TSRMLS_CC); + zephir_array_fetch(&_36, typesColumnMap, attribute, PH_NOISY, "phalcon/mvc/model/query.zep", 2779 TSRMLS_CC); zephir_array_fast_append(_20, _36); zephir_array_update_zval(&simpleColumnMap, attribute, &_20, PH_COPY | PH_SEPARATE); } } else { array_init(simpleColumnMap); - zephir_is_iterable(columnMap, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 2638); + zephir_is_iterable(columnMap, &_38, &_37, 0, 0, "phalcon/mvc/model/query.zep", 2786); for ( ; zephir_hash_get_current_data_ex(_38, (void**) &_39, &_37) == SUCCESS ; zephir_hash_move_forward_ex(_38, &_37) @@ -3289,7 +3493,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { zephir_create_array(_20, 2, 0 TSRMLS_CC); zephir_array_fast_append(_20, attribute); ZEPHIR_OBS_NVAR(_36); - zephir_array_fetch(&_36, typesColumnMap, column, PH_NOISY, "phalcon/mvc/model/query.zep", 2636 TSRMLS_CC); + zephir_array_fetch(&_36, typesColumnMap, column, PH_NOISY, "phalcon/mvc/model/query.zep", 2784 TSRMLS_CC); zephir_array_fast_append(_20, _36); zephir_array_update_zval(&simpleColumnMap, column, &_20, PH_COPY | PH_SEPARATE); } @@ -3300,12 +3504,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { isKeepingSnapshots = zephir_get_boolval(_40); } object_init_ex(return_value, phalcon_mvc_model_resultset_simple_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 341, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 334, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); RETURN_MM(); } object_init_ex(return_value, phalcon_mvc_model_resultset_complex_ce); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 342, columns1, resultData, cache); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 335, columns1, resultData, cache); zephir_check_call_status(); RETURN_MM(); @@ -3317,7 +3521,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) { * @param array intermediate * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\StatusInterface + * @return \Phalcon\Mvc\Model\Query\StatusInterface */ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { @@ -3334,7 +3538,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_string(&modelName, intermediate, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2675 TSRMLS_CC); + zephir_array_fetch_string(&modelName, intermediate, SL("model"), PH_NOISY, "phalcon/mvc/model/query.zep", 2823 TSRMLS_CC); ZEPHIR_OBS_VAR(manager); zephir_read_property_this(&manager, this_ptr, SL("_manager"), PH_NOISY_CC); ZEPHIR_OBS_VAR(model); @@ -3349,7 +3553,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2688); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2836); return; } } else { @@ -3374,16 +3578,16 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { } } ZEPHIR_OBS_VAR(values); - zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2711 TSRMLS_CC); + zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2859 TSRMLS_CC); if (zephir_fast_count_int(fields TSRMLS_CC) != zephir_fast_count_int(values TSRMLS_CC)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The column count does not match the values count", "phalcon/mvc/model/query.zep", 2717); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The column count does not match the values count", "phalcon/mvc/model/query.zep", 2865); return; } ZEPHIR_CALL_METHOD(&dialect, connection, "getdialect", NULL, 0); zephir_check_call_status(); ZEPHIR_INIT_VAR(insertValues); array_init(insertValues); - zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 2785); + zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 2933); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -3391,8 +3595,8 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_GET_HMKEY(number, _3, _2); ZEPHIR_GET_HVALUE(value, _4); ZEPHIR_OBS_NVAR(exprValue); - zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 2728 TSRMLS_CC); - zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2729 TSRMLS_CC); + zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 2876 TSRMLS_CC); + zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2877 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_5, 260) || ZEPHIR_IS_LONG(_5, 258) || ZEPHIR_IS_LONG(_5, 259)) { ZEPHIR_CALL_METHOD(&insertValue, dialect, "getsqlexpression", &_6, 0, exprValue); @@ -3406,7 +3610,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { } if (ZEPHIR_IS_LONG(_5, 273) || ZEPHIR_IS_LONG(_5, 274) || ZEPHIR_IS_LONG(_5, 277)) { if (Z_TYPE_P(bindParams) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 2746); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 2894); return; } ZEPHIR_CALL_METHOD(&_7, dialect, "getsqlexpression", &_8, 0, exprValue); @@ -3425,7 +3629,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_CONCAT_SVS(_11, "Bound parameter '", wildcard, "' cannot be replaced because it isn't in the placeholders list"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_12, 9, _11); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2751 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2899 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -3441,7 +3645,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { } while(0); ZEPHIR_OBS_NVAR(fieldName); - zephir_array_fetch(&fieldName, fields, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2761 TSRMLS_CC); + zephir_array_fetch(&fieldName, fields, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2909 TSRMLS_CC); if (automaticFields == 1) { if (Z_TYPE_P(columnMap) == IS_ARRAY) { ZEPHIR_OBS_NVAR(attributeName); @@ -3452,7 +3656,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { ZEPHIR_CONCAT_SVS(_11, "Column '", fieldName, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_12, 9, _11); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2769 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 2917 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -3473,7 +3677,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_CALL_METHOD(&_15, insertModel, "create", NULL, 0, insertValues); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 343, _15, insertModel); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 336, _15, insertModel); zephir_check_call_status(); RETURN_MM(); @@ -3485,7 +3689,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) { * @param array intermediate * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\StatusInterface + * @return \Phalcon\Mvc\Model\Query\StatusInterface */ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { @@ -3502,13 +3706,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_OBS_VAR(models); - zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2809 TSRMLS_CC); + zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2957 TSRMLS_CC); if (zephir_array_isset_long(models, 1)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Updating several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 2812); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Updating several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 2960); return; } ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 2815 TSRMLS_CC); + zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 2963 TSRMLS_CC); ZEPHIR_OBS_VAR(model); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&model, _0, modelName, 0 TSRMLS_CC))) { @@ -3520,7 +3724,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2827); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2975); return; } } else { @@ -3530,14 +3734,14 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CALL_METHOD(&dialect, connection, "getdialect", NULL, 0); zephir_check_call_status(); ZEPHIR_OBS_VAR(fields); - zephir_array_fetch_string(&fields, intermediate, SL("fields"), PH_NOISY, "phalcon/mvc/model/query.zep", 2835 TSRMLS_CC); + zephir_array_fetch_string(&fields, intermediate, SL("fields"), PH_NOISY, "phalcon/mvc/model/query.zep", 2983 TSRMLS_CC); ZEPHIR_OBS_VAR(values); - zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2836 TSRMLS_CC); + zephir_array_fetch_string(&values, intermediate, SL("values"), PH_NOISY, "phalcon/mvc/model/query.zep", 2984 TSRMLS_CC); ZEPHIR_INIT_VAR(updateValues); array_init(updateValues); ZEPHIR_CPY_WRT(selectBindParams, bindParams); ZEPHIR_CPY_WRT(selectBindTypes, bindTypes); - zephir_is_iterable(fields, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 2903); + zephir_is_iterable(fields, &_3, &_2, 0, 0, "phalcon/mvc/model/query.zep", 3051); for ( ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS ; zephir_hash_move_forward_ex(_3, &_2) @@ -3545,17 +3749,17 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_GET_HMKEY(number, _3, _2); ZEPHIR_GET_HVALUE(field, _4); ZEPHIR_OBS_NVAR(value); - zephir_array_fetch(&value, values, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2851 TSRMLS_CC); + zephir_array_fetch(&value, values, number, PH_NOISY, "phalcon/mvc/model/query.zep", 2999 TSRMLS_CC); ZEPHIR_OBS_NVAR(exprValue); - zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 2852 TSRMLS_CC); + zephir_array_fetch_string(&exprValue, value, SL("value"), PH_NOISY, "phalcon/mvc/model/query.zep", 3000 TSRMLS_CC); if (zephir_array_isset_string(field, SS("balias"))) { ZEPHIR_OBS_NVAR(fieldName); - zephir_array_fetch_string(&fieldName, field, SL("balias"), PH_NOISY, "phalcon/mvc/model/query.zep", 2855 TSRMLS_CC); + zephir_array_fetch_string(&fieldName, field, SL("balias"), PH_NOISY, "phalcon/mvc/model/query.zep", 3003 TSRMLS_CC); } else { ZEPHIR_OBS_NVAR(fieldName); - zephir_array_fetch_string(&fieldName, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 2857 TSRMLS_CC); + zephir_array_fetch_string(&fieldName, field, SL("name"), PH_NOISY, "phalcon/mvc/model/query.zep", 3005 TSRMLS_CC); } - zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2860 TSRMLS_CC); + zephir_array_fetch_string(&_5, value, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 3008 TSRMLS_CC); do { if (ZEPHIR_IS_LONG(_5, 260) || ZEPHIR_IS_LONG(_5, 258) || ZEPHIR_IS_LONG(_5, 259)) { ZEPHIR_CALL_METHOD(&updateValue, dialect, "getsqlexpression", &_6, 0, exprValue); @@ -3569,7 +3773,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { } if (ZEPHIR_IS_LONG(_5, 273) || ZEPHIR_IS_LONG(_5, 274) || ZEPHIR_IS_LONG(_5, 277)) { if (Z_TYPE_P(bindParams) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 2877); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter cannot be replaced because placeholders is not an array", "phalcon/mvc/model/query.zep", 3025); return; } ZEPHIR_CALL_METHOD(&_7, dialect, "getsqlexpression", &_8, 0, exprValue); @@ -3591,14 +3795,14 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CONCAT_SVS(_12, "Bound parameter '", wildcard, "' cannot be replaced because it's not in the placeholders list"); ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_13, 9, _12); zephir_check_call_status(); - zephir_throw_exception_debug(_11, "phalcon/mvc/model/query.zep", 2885 TSRMLS_CC); + zephir_throw_exception_debug(_11, "phalcon/mvc/model/query.zep", 3033 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } break; } if (ZEPHIR_IS_LONG(_5, 277)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/query.zep", 2890); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/query.zep", 3038); return; } ZEPHIR_INIT_NVAR(updateValue); @@ -3612,13 +3816,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { zephir_array_update_zval(&updateValues, fieldName, &updateValue, PH_COPY | PH_SEPARATE); } - ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, selectBindParams, selectBindTypes); + ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 337, model, intermediate, selectBindParams, selectBindTypes); zephir_check_call_status(); if (!(zephir_fast_count_int(records TSRMLS_CC))) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_11); ZVAL_BOOL(_11, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 336, _11); zephir_check_call_status(); RETURN_MM(); } @@ -3626,7 +3830,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2915); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 3063); return; } } else { @@ -3651,7 +3855,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_11); ZVAL_BOOL(_11, 0); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11, record); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 336, _11, record); zephir_check_call_status(); RETURN_MM(); } @@ -3662,7 +3866,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_11); ZVAL_BOOL(_11, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 336, _11); zephir_check_call_status(); RETURN_MM(); @@ -3674,7 +3878,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) { * @param array intermediate * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\StatusInterface + * @return \Phalcon\Mvc\Model\Query\StatusInterface */ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { @@ -3689,13 +3893,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { ZEPHIR_OBS_VAR(models); - zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 2962 TSRMLS_CC); + zephir_array_fetch_string(&models, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 3110 TSRMLS_CC); if (zephir_array_isset_long(models, 1)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Delete from several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 2965); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Delete from several models at the same time is still not supported", "phalcon/mvc/model/query.zep", 3113); return; } ZEPHIR_OBS_VAR(modelName); - zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 2968 TSRMLS_CC); + zephir_array_fetch_long(&modelName, models, 0, PH_NOISY, "phalcon/mvc/model/query.zep", 3116 TSRMLS_CC); ZEPHIR_OBS_VAR(model); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_modelsInstances"), PH_NOISY_CC); if (!(zephir_array_isset_fetch(&model, _0, modelName, 0 TSRMLS_CC))) { @@ -3703,13 +3907,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { ZEPHIR_CALL_METHOD(&model, _1, "load", NULL, 0, modelName); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, bindParams, bindTypes); + ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 337, model, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (!(zephir_fast_count_int(records TSRMLS_CC))) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_VAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 336, _2); zephir_check_call_status(); RETURN_MM(); } @@ -3717,7 +3921,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { ZEPHIR_CALL_METHOD(&connection, model, "selectwriteconnection", NULL, 0, intermediate, bindParams, bindTypes); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 2992); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "'selectWriteConnection' didn't return a valid connection", "phalcon/mvc/model/query.zep", 3140); return; } } else { @@ -3742,7 +3946,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_2); ZVAL_BOOL(_2, 0); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2, record); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 336, _2, record); zephir_check_call_status(); RETURN_MM(); } @@ -3753,7 +3957,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { object_init_ex(return_value, phalcon_mvc_model_query_status_ce); ZEPHIR_INIT_NVAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 336, _2); zephir_check_call_status(); RETURN_MM(); @@ -3762,11 +3966,11 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) { /** * Query the records on which the UPDATE/DELETE operation well be done * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @param array intermediate * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\ResultsetInterface + * @return \Phalcon\Mvc\Model\ResultsetInterface */ PHP_METHOD(Phalcon_Mvc_Model_Query, _getRelatedRecords) { @@ -3795,10 +3999,10 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getRelatedRecords) { zephir_array_fast_append(_0, _1); zephir_array_update_string(&selectIr, SL("columns"), &_0, PH_COPY | PH_SEPARATE); ZEPHIR_OBS_VAR(_4); - zephir_array_fetch_string(&_4, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 3053 TSRMLS_CC); + zephir_array_fetch_string(&_4, intermediate, SL("models"), PH_NOISY, "phalcon/mvc/model/query.zep", 3201 TSRMLS_CC); zephir_array_update_string(&selectIr, SL("models"), &_4, PH_COPY | PH_SEPARATE); ZEPHIR_OBS_NVAR(_4); - zephir_array_fetch_string(&_4, intermediate, SL("tables"), PH_NOISY, "phalcon/mvc/model/query.zep", 3055 TSRMLS_CC); + zephir_array_fetch_string(&_4, intermediate, SL("tables"), PH_NOISY, "phalcon/mvc/model/query.zep", 3203 TSRMLS_CC); zephir_array_update_string(&selectIr, SL("tables"), &_4, PH_COPY | PH_SEPARATE); ZEPHIR_OBS_VAR(whereConditions); if (zephir_array_isset_string_fetch(&whereConditions, intermediate, SS("where"), 0 TSRMLS_CC)) { @@ -3810,18 +4014,18 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getRelatedRecords) { } ZEPHIR_INIT_VAR(query); object_init_ex(query, phalcon_mvc_model_query_ce); - ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345); + ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 338); zephir_check_call_status(); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 346, _5); + ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 339, _5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_2); ZVAL_LONG(_2, 309); - ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 347, _2); + ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 340, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 348, selectIr); + ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 341, selectIr); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 349, bindParams, bindTypes); + ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 342, bindParams, bindTypes); zephir_check_call_status(); RETURN_MM(); @@ -3857,12 +4061,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { zephir_read_property_this(&cacheOptions, this_ptr, SL("_cacheOptions"), PH_NOISY_CC); if (Z_TYPE_P(cacheOptions) != IS_NULL) { if (Z_TYPE_P(cacheOptions) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid caching options", "phalcon/mvc/model/query.zep", 3101); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid caching options", "phalcon/mvc/model/query.zep", 3249); return; } ZEPHIR_OBS_VAR(key); if (!(zephir_array_isset_string_fetch(&key, cacheOptions, SS("key"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A cache key must be provided to identify the cached resultset in the cache backend", "phalcon/mvc/model/query.zep", 3108); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A cache key must be provided to identify the cached resultset in the cache backend", "phalcon/mvc/model/query.zep", 3256); return; } ZEPHIR_OBS_VAR(lifetime); @@ -3879,14 +4083,14 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { ZEPHIR_CALL_METHOD(&cache, _0, "getshared", NULL, 0, cacheService); zephir_check_call_status(); if (Z_TYPE_P(cache) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache service must be an object", "phalcon/mvc/model/query.zep", 3127); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache service must be an object", "phalcon/mvc/model/query.zep", 3275); return; } ZEPHIR_CALL_METHOD(&result, cache, "get", NULL, 0, key, lifetime); zephir_check_call_status(); if (Z_TYPE_P(result) != IS_NULL) { if (Z_TYPE_P(result) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache didn't return a valid resultset", "phalcon/mvc/model/query.zep", 3134); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cache didn't return a valid resultset", "phalcon/mvc/model/query.zep", 3282); return; } ZEPHIR_INIT_VAR(_1); @@ -3934,7 +4138,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { _2 = Z_TYPE_P(mergedParams) != IS_ARRAY; } if (_2) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameters must be an array", "phalcon/mvc/model/query.zep", 3188); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameters must be an array", "phalcon/mvc/model/query.zep", 3336); return; } _3 = Z_TYPE_P(mergedTypes) != IS_NULL; @@ -3942,29 +4146,29 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { _3 = Z_TYPE_P(mergedTypes) != IS_ARRAY; } if (_3) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter types must be an array", "phalcon/mvc/model/query.zep", 3192); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Bound parameter types must be an array", "phalcon/mvc/model/query.zep", 3340); return; } ZEPHIR_OBS_VAR(type); zephir_read_property_this(&type, this_ptr, SL("_type"), PH_NOISY_CC); do { if (ZEPHIR_IS_LONG(type, 309)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 350, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 343, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 306)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 351, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 344, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 300)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 352, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 345, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 303)) { - ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 353, intermediate, mergedParams, mergedTypes); + ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 346, intermediate, mergedParams, mergedTypes); zephir_check_call_status(); break; } @@ -3974,14 +4178,14 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { ZEPHIR_CONCAT_SV(_4, "Unknown statement ", type); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 3215 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query.zep", 3363 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); if (Z_TYPE_P(cacheOptions) != IS_NULL) { if (!ZEPHIR_IS_LONG(type, 309)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only PHQL statements that return resultsets can be cached", "phalcon/mvc/model/query.zep", 3227); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Only PHQL statements that return resultsets can be cached", "phalcon/mvc/model/query.zep", 3375); return; } ZEPHIR_CALL_METHOD(NULL, cache, "save", NULL, 0, key, result, lifetime); @@ -4002,7 +4206,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, execute) { * * @param array bindParams * @param array bindTypes - * @return á¹”halcon\Mvc\ModelInterface + * @return \Phalcon\Mvc\ModelInterface */ PHP_METHOD(Phalcon_Mvc_Model_Query, getSingleResult) { @@ -4026,7 +4230,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, getSingleResult) { zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 349, bindParams, bindTypes); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 342, bindParams, bindTypes); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(_1, "getfirst", NULL, 0); zephir_check_call_status(); @@ -4239,11 +4443,11 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, getSql) { _2 = zephir_fetch_nproperty_this(this_ptr, SL("_bindTypes"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_3); ZVAL_BOOL(&_3, 1); - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 350, intermediate, _1, _2, &_3); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 343, intermediate, _1, _2, &_3); zephir_check_call_status(); RETURN_MM(); } - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "This type of statement generates multiple SQL statements", "phalcon/mvc/model/query.zep", 3397); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "This type of statement generates multiple SQL statements", "phalcon/mvc/model/query.zep", 3545); return; } diff --git a/ext/phalcon/mvc/model/query.zep.h b/ext/phalcon/mvc/model/query.zep.h index f0da7e05d46..0679b7d174d 100644 --- a/ext/phalcon/mvc/model/query.zep.h +++ b/ext/phalcon/mvc/model/query.zep.h @@ -51,6 +51,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, getSql); ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query___construct, 0, 0, 0) ZEND_ARG_INFO(0, phql) ZEND_ARG_OBJ_INFO(0, dependencyInjector, Phalcon\\DiInterface, 1) + ZEND_ARG_INFO(0, options) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query_setdi, 0, 0, 1) diff --git a/ext/phalcon/mvc/model/query/base.c b/ext/phalcon/mvc/model/query/base.c index aedb69e04a6..a269177156d 100644 --- a/ext/phalcon/mvc/model/query/base.c +++ b/ext/phalcon/mvc/model/query/base.c @@ -3,17 +3,17 @@ +------------------------------------------------------------------------+ | Phalcon Framework | +------------------------------------------------------------------------+ - | Copyright (c) 2011-2014 Phalcon Team (http://www.phalconphp.com) | + | Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) | +------------------------------------------------------------------------+ - | This source file is subject to the New BSD License that is bundled | - | with this package in the file docs/LICENSE.txt. | - | | - | If you did not receive a copy of the license and are unable to | - | obtain it through the world-wide-web, please send an email | + | This source file is subject to the New BSD License that is bundled | + | with this package in the file docs/LICENSE.txt. | + | | + | If you did not receive a copy of the license and are unable to | + | obtain it through the world-wide-web, please send an email | | to license@phalconphp.com so we can send you a copy immediately. | +------------------------------------------------------------------------+ - | Authors: Andres Gutierrez | - | Eduar Carvajal | + | Authors: Andres Gutierrez | + | Eduar Carvajal | +------------------------------------------------------------------------+ */ diff --git a/ext/phalcon/mvc/model/query/builder.zep.c b/ext/phalcon/mvc/model/query/builder.zep.c index 800059ee19c..a3efc7ac9d4 100644 --- a/ext/phalcon/mvc/model/query/builder.zep.c +++ b/ext/phalcon/mvc/model/query/builder.zep.c @@ -286,8 +286,10 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getDI) { /** * Sets SELECT DISTINCT / SELECT ALL flag * - * @param bool|null distinct - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * + * $builder->distinct("status"); + * $builder->distinct(null); + * */ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, distinct) { @@ -316,11 +318,10 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getDistinct) { * Sets the columns to be queried * * + * $builder->columns("id, name"); * $builder->columns(array('id', 'name')); + * $builder->columns(array('name', 'number' => 'COUNT(*)')); * - * - * @param string|array columns - * @return Phalcon\Mvc\Model\Query\Builder */ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, columns) { @@ -353,10 +354,8 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getColumns) { * * $builder->from('Robots'); * $builder->from(array('Robots', 'RobotsParts')); + * $builder->from(array('r' => 'Robots', 'rp' => 'RobotsParts')); * - * - * @param string|array models - * @return Phalcon\Mvc\Model\Query\Builder */ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, from) { @@ -375,23 +374,34 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, from) { * Add a model to take part of the query * * + * // Load data from models Robots + * $builder->addFrom('Robots'); + * + * // Load data from model 'Robots' using 'r' as alias in PHQL * $builder->addFrom('Robots', 'r'); - * * - * @param string model - * @param string alias - * @return Phalcon\Mvc\Model\Query\Builder + * // Load data from model 'Robots' using 'r' as alias in PHQL + * // and eager load model 'RobotsParts' + * $builder->addFrom('Robots', 'r', 'RobotsParts'); + * + * // Load data from model 'Robots' using 'r' as alias in PHQL + * // and eager load models 'RobotsParts' and 'Parts' + * $builder->addFrom('Robots', 'r', ['RobotsParts', 'Parts']); + * */ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, addFrom) { - zval *model, *alias = NULL, *models = NULL, *currentModel = NULL; + zval *model, *alias = NULL, *with = NULL, *models = NULL, *currentModel = NULL; ZEPHIR_MM_GROW(); - zephir_fetch_params(1, 1, 1, &model, &alias); + zephir_fetch_params(1, 1, 2, &model, &alias, &with); if (!alias) { alias = ZEPHIR_GLOBAL(global_null); } + if (!with) { + with = ZEPHIR_GLOBAL(global_null); + } ZEPHIR_OBS_VAR(models); @@ -410,7 +420,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, addFrom) { if (Z_TYPE_P(alias) == IS_STRING) { zephir_array_update_zval(&models, alias, &model, PH_COPY | PH_SEPARATE); } else { - zephir_array_append(&models, model, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 388); + zephir_array_append(&models, model, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 395); } zephir_update_property_this(this_ptr, SL("_models"), models TSRMLS_CC); RETURN_THIS(); @@ -433,17 +443,24 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getFrom) { * Adds a INNER join to the query * * + * // Inner Join model 'Robots' with automatic conditions and alias * $builder->join('Robots'); - * $builder->join('Robots', 'r.id = RobotsParts.robots_id'); + * + * // Inner Join model 'Robots' specifing conditions + * $builder->join('Robots', 'Robots.id = RobotsParts.robots_id'); + * + * // Inner Join model 'Robots' specifing conditions and alias * $builder->join('Robots', 'r.id = RobotsParts.robots_id', 'r'); - * $builder->join('Robots', 'r.id = RobotsParts.robots_id', 'r', 'INNER'); + * + * // Left Join model 'Robots' specifing conditions, alias and type of join + * $builder->join('Robots', 'r.id = RobotsParts.robots_id', 'r', 'LEFT'); * * * @param string model * @param string conditions * @param string alias * @param string type - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, join) { @@ -491,8 +508,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, join) { * Adds a INNER join to the query * * + * // Inner Join model 'Robots' with automatic conditions and alias * $builder->innerJoin('Robots'); - * $builder->innerJoin('Robots', 'r.id = RobotsParts.robots_id'); + * + * // Inner Join model 'Robots' specifing conditions + * $builder->innerJoin('Robots', 'Robots.id = RobotsParts.robots_id'); + * + * // Inner Join model 'Robots' specifing conditions and alias * $builder->innerJoin('Robots', 'r.id = RobotsParts.robots_id', 'r'); * * @@ -500,7 +522,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, join) { * @param string conditions * @param string alias * @param string type - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, innerJoin) { @@ -553,7 +575,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, innerJoin) { * @param string model * @param string conditions * @param string alias - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, leftJoin) { @@ -606,7 +628,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, leftJoin) { * @param string model * @param string conditions * @param string alias - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, rightJoin) { @@ -661,7 +683,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, rightJoin) { * @param mixed conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, where) { @@ -714,7 +736,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, where) { * @param string conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, andWhere) { @@ -786,7 +808,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, andWhere) { * @param string conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, orWhere) { @@ -1002,7 +1024,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, inWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 757); + zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 776); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -1015,7 +1037,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, inWhere) { ZEPHIR_CPY_WRT(key, _0); ZEPHIR_INIT_NVAR(queryKey); ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":"); - zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 748); + zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 767); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); hiddenParam++; } @@ -1081,7 +1103,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, notInWhere) { array_init(bindParams); ZEPHIR_INIT_VAR(bindKeys); array_init(bindKeys); - zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 800); + zephir_is_iterable(values, &_4, &_3, 0, 0, "phalcon/mvc/model/query/builder.zep", 819); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -1094,7 +1116,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, notInWhere) { ZEPHIR_CPY_WRT(key, _0); ZEPHIR_INIT_NVAR(queryKey); ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":"); - zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 791); + zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 810); zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE); hiddenParam++; } @@ -1132,7 +1154,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getWhere) { * * * @param string|array orderBy - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, orderBy) { @@ -1321,7 +1343,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getOffset) { * * * @param string|array group - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, groupBy) { @@ -1355,13 +1377,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getGroupBy) { */ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { - HashTable *_7, *_10, *_14, *_18, *_21, *_26, *_32; - HashPosition _6, _9, _13, _17, _20, _25, _31; + HashTable *_7, *_10, *_13, *_18, *_23, *_29; + HashPosition _6, _9, _12, _17, _22, _28; zend_class_entry *_3; int ZEPHIR_LAST_CALL_STATUS; - zephir_fcall_cache_entry *_0 = NULL, *_35 = NULL; + zephir_fcall_cache_entry *_0 = NULL, *_32 = NULL; zend_bool noPrimary, _5; - zval *dependencyInjector = NULL, *models, *conditions = NULL, *model = NULL, *metaData = NULL, *modelInstance, *primaryKeys = NULL, *firstPrimaryKey, *columnMap = NULL, *modelAlias = NULL, *attributeField = NULL, *phql = NULL, *column = NULL, *columns, *selectedColumns = NULL, *selectedColumn = NULL, *selectedModel = NULL, *selectedModels, *columnAlias = NULL, *modelColumnAlias = NULL, *joins, *join = NULL, *joinModel = NULL, *joinConditions = NULL, *joinAlias = NULL, *joinType = NULL, *group = NULL, *groupItems = NULL, *groupItem = NULL, *having, *order, *orderItems, *orderItem = NULL, *limit, *number = NULL, *offset = NULL, *forUpdate, *distinct, *withModels, *hiddenParam, *_1 = NULL, *_2 = NULL, *_4 = NULL, **_8, **_11, *_12 = NULL, **_15, *_16 = NULL, **_19, **_22, *_23 = NULL, *_24 = NULL, **_27, *_28 = NULL, _29 = zval_used_for_init, _30, **_33, *_34 = NULL, *_36, *_37; + zval *dependencyInjector = NULL, *models, *conditions = NULL, *model = NULL, *metaData = NULL, *modelInstance, *primaryKeys = NULL, *firstPrimaryKey, *columnMap = NULL, *modelAlias = NULL, *attributeField = NULL, *phql = NULL, *column = NULL, *columns, *selectedColumns = NULL, *selectedColumn = NULL, *selectedModel = NULL, *selectedModels, *columnAlias = NULL, *modelColumnAlias = NULL, *joins, *join = NULL, *joinModel = NULL, *joinConditions = NULL, *joinAlias = NULL, *joinType = NULL, *group = NULL, *groupItems = NULL, *groupItem = NULL, *having, *order, *orderItems, *orderItem = NULL, *limit, *number = NULL, *offset = NULL, *forUpdate, *distinct, *_1 = NULL, *_2 = NULL, *_4 = NULL, **_8, **_11, **_14, *_15 = NULL, *_16 = NULL, **_19, *_20 = NULL, *_21 = NULL, **_24, *_25 = NULL, _26 = zval_used_for_init, _27, **_30, *_31 = NULL, *_33, *_34, *_35, *_36; ZEPHIR_MM_GROW(); @@ -1376,12 +1398,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { zephir_read_property_this(&models, this_ptr, SL("_models"), PH_NOISY_CC); if (Z_TYPE_P(models) == IS_ARRAY) { if (!(zephir_fast_count_int(models TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 981); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 1000); return; } } else { if (!(zephir_is_true(models))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 985); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "At least one model is required to build the query", "phalcon/mvc/model/query/builder.zep", 1004); return; } } @@ -1390,11 +1412,11 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (zephir_is_numeric(conditions)) { if (Z_TYPE_P(models) == IS_ARRAY) { if (zephir_fast_count_int(models TSRMLS_CC) > 1) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot build the query. Invalid condition", "phalcon/mvc/model/query/builder.zep", 997); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Cannot build the query. Invalid condition", "phalcon/mvc/model/query/builder.zep", 1017); return; } ZEPHIR_OBS_VAR(model); - zephir_array_fetch_long(&model, models, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 999 TSRMLS_CC); + zephir_array_fetch_long(&model, models, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1019 TSRMLS_CC); } else { ZEPHIR_CPY_WRT(model, models); } @@ -1433,7 +1455,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZEPHIR_CONCAT_SVS(_4, "Column '", firstPrimaryKey, "' isn't part of the column map"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _4); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/model/query/builder.zep", 1027 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/model/query/builder.zep", 1047 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -1447,7 +1469,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { } } if (noPrimary == 1) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Source related to this model does not have a primary key defined", "phalcon/mvc/model/query/builder.zep", 1042); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Source related to this model does not have a primary key defined", "phalcon/mvc/model/query/builder.zep", 1062); return; } } @@ -1474,7 +1496,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(columns) == IS_ARRAY) { ZEPHIR_INIT_VAR(selectedColumns); array_init(selectedColumns); - zephir_is_iterable(columns, &_7, &_6, 0, 0, "phalcon/mvc/model/query/builder.zep", 1074); + zephir_is_iterable(columns, &_7, &_6, 0, 0, "phalcon/mvc/model/query/builder.zep", 1098); for ( ; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS ; zephir_hash_move_forward_ex(_7, &_6) @@ -1482,11 +1504,17 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZEPHIR_GET_HMKEY(columnAlias, _7, _6); ZEPHIR_GET_HVALUE(column, _8); if (Z_TYPE_P(columnAlias) == IS_LONG) { - zephir_array_append(&selectedColumns, column, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1068); + zephir_array_append(&selectedColumns, column, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1088); } else { - ZEPHIR_INIT_LNVAR(_4); - ZEPHIR_CONCAT_VSV(_4, column, " AS ", columnAlias); - zephir_array_append(&selectedColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1070); + if (zephir_memnstr_str(columnAlias, SL("["), "phalcon/mvc/model/query/builder.zep", 1090)) { + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_VSV(_4, column, " AS ", columnAlias); + zephir_array_append(&selectedColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1091); + } else { + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_VSVS(_4, column, " AS [", columnAlias, "]"); + zephir_array_append(&selectedColumns, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1093); + } } } ZEPHIR_INIT_NVAR(_1); @@ -1499,7 +1527,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(models) == IS_ARRAY) { ZEPHIR_INIT_NVAR(selectedColumns); array_init(selectedColumns); - zephir_is_iterable(models, &_10, &_9, 0, 0, "phalcon/mvc/model/query/builder.zep", 1097); + zephir_is_iterable(models, &_10, &_9, 0, 0, "phalcon/mvc/model/query/builder.zep", 1121); for ( ; zephir_hash_get_current_data_ex(_10, (void**) &_11, &_9) == SUCCESS ; zephir_hash_move_forward_ex(_10, &_9) @@ -1512,136 +1540,115 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { } else { ZEPHIR_CONCAT_SVS(selectedColumn, "[", modelColumnAlias, "].*"); } - zephir_array_append(&selectedColumns, selectedColumn, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1094); + zephir_array_append(&selectedColumns, selectedColumn, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1118); } ZEPHIR_INIT_NVAR(_1); zephir_fast_join_str(_1, SL(", "), selectedColumns TSRMLS_CC); zephir_concat_self(&phql, _1 TSRMLS_CC); } else { - ZEPHIR_INIT_VAR(_12); - ZEPHIR_CONCAT_SVS(_12, "[", models, "].*"); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_SVS(_4, "[", models, "].*"); + zephir_concat_self(&phql, _4 TSRMLS_CC); } } if (Z_TYPE_P(models) == IS_ARRAY) { ZEPHIR_INIT_VAR(selectedModels); array_init(selectedModels); - zephir_is_iterable(models, &_14, &_13, 0, 0, "phalcon/mvc/model/query/builder.zep", 1128); + zephir_is_iterable(models, &_13, &_12, 0, 0, "phalcon/mvc/model/query/builder.zep", 1152); for ( - ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS - ; zephir_hash_move_forward_ex(_14, &_13) + ; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS + ; zephir_hash_move_forward_ex(_13, &_12) ) { - ZEPHIR_GET_HMKEY(modelAlias, _14, _13); - ZEPHIR_GET_HVALUE(model, _15); + ZEPHIR_GET_HMKEY(modelAlias, _13, _12); + ZEPHIR_GET_HVALUE(model, _14); if (Z_TYPE_P(modelAlias) == IS_STRING) { ZEPHIR_INIT_NVAR(selectedModel); - if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1112)) { + if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1136)) { ZEPHIR_CONCAT_VSVS(selectedModel, model, " AS [", modelAlias, "]"); } else { ZEPHIR_CONCAT_SVSVS(selectedModel, "[", model, "] AS [", modelAlias, "]"); } } else { - if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1118)) { + if (zephir_memnstr_str(model, SL("["), "phalcon/mvc/model/query/builder.zep", 1142)) { ZEPHIR_CPY_WRT(selectedModel, model); } else { ZEPHIR_INIT_NVAR(selectedModel); ZEPHIR_CONCAT_SVS(selectedModel, "[", model, "]"); } } - zephir_array_append(&selectedModels, selectedModel, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1125); + zephir_array_append(&selectedModels, selectedModel, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1149); } ZEPHIR_INIT_NVAR(_1); zephir_fast_join_str(_1, SL(", "), selectedModels TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " FROM ", _1); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_VAR(_15); + ZEPHIR_CONCAT_SV(_15, " FROM ", _1); + zephir_concat_self(&phql, _15 TSRMLS_CC); } else { - if (zephir_memnstr_str(models, SL("["), "phalcon/mvc/model/query/builder.zep", 1132)) { + if (zephir_memnstr_str(models, SL("["), "phalcon/mvc/model/query/builder.zep", 1156)) { + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SVS(_15, " FROM ", models, ""); + zephir_concat_self(&phql, _15 TSRMLS_CC); + } else { ZEPHIR_INIT_VAR(_16); - ZEPHIR_CONCAT_SVS(_16, " FROM ", models, ""); + ZEPHIR_CONCAT_SVS(_16, " FROM [", models, "]"); zephir_concat_self(&phql, _16 TSRMLS_CC); - } else { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SVS(_12, " FROM [", models, "]"); - zephir_concat_self(&phql, _12 TSRMLS_CC); - } - } - ZEPHIR_OBS_VAR(withModels); - zephir_read_property_this(&withModels, this_ptr, SL("_with"), PH_NOISY_CC); - if (Z_TYPE_P(withModels) == IS_ARRAY) { - ZEPHIR_INIT_NVAR(selectedColumns); - array_init(selectedColumns); - zephir_is_iterable(withModels, &_18, &_17, 0, 0, "phalcon/mvc/model/query/builder.zep", 1150); - for ( - ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS - ; zephir_hash_move_forward_ex(_18, &_17) - ) { - ZEPHIR_GET_HVALUE(model, _19); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SVS(_12, "[", model, "]"); - zephir_array_append(&selectedColumns, _12, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1147); } - ZEPHIR_INIT_NVAR(_1); - zephir_fast_join_str(_1, SL(", "), selectedColumns TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " WITH ", _1); - zephir_concat_self(&phql, _12 TSRMLS_CC); } ZEPHIR_OBS_VAR(joins); zephir_read_property_this(&joins, this_ptr, SL("_joins"), PH_NOISY_CC); if (Z_TYPE_P(joins) == IS_ARRAY) { - zephir_is_iterable(joins, &_21, &_20, 0, 0, "phalcon/mvc/model/query/builder.zep", 1212); + zephir_is_iterable(joins, &_18, &_17, 0, 0, "phalcon/mvc/model/query/builder.zep", 1222); for ( - ; zephir_hash_get_current_data_ex(_21, (void**) &_22, &_20) == SUCCESS - ; zephir_hash_move_forward_ex(_21, &_20) + ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS + ; zephir_hash_move_forward_ex(_18, &_17) ) { - ZEPHIR_GET_HVALUE(join, _22); + ZEPHIR_GET_HVALUE(join, _19); ZEPHIR_OBS_NVAR(joinModel); - zephir_array_fetch_long(&joinModel, join, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1164 TSRMLS_CC); + zephir_array_fetch_long(&joinModel, join, 0, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1174 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinConditions); - zephir_array_fetch_long(&joinConditions, join, 1, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1169 TSRMLS_CC); + zephir_array_fetch_long(&joinConditions, join, 1, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1179 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinAlias); - zephir_array_fetch_long(&joinAlias, join, 2, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1174 TSRMLS_CC); + zephir_array_fetch_long(&joinAlias, join, 2, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1184 TSRMLS_CC); ZEPHIR_OBS_NVAR(joinType); - zephir_array_fetch_long(&joinType, join, 3, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1179 TSRMLS_CC); + zephir_array_fetch_long(&joinType, join, 3, PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1189 TSRMLS_CC); if (zephir_is_true(joinType)) { - if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1185)) { + if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1195)) { + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SVSV(_15, " ", joinType, " JOIN ", joinModel); + zephir_concat_self(&phql, _15 TSRMLS_CC); + } else { ZEPHIR_INIT_LNVAR(_16); - ZEPHIR_CONCAT_SVSV(_16, " ", joinType, " JOIN ", joinModel); + ZEPHIR_CONCAT_SVSVS(_16, " ", joinType, " JOIN [", joinModel, "]"); zephir_concat_self(&phql, _16 TSRMLS_CC); - } else { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVSVS(_23, " ", joinType, " JOIN [", joinModel, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); } } else { - if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1191)) { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " JOIN ", joinModel, ""); - zephir_concat_self(&phql, _23 TSRMLS_CC); + if (zephir_memnstr_str(joinModel, SL("["), "phalcon/mvc/model/query/builder.zep", 1201)) { + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " JOIN ", joinModel, ""); + zephir_concat_self(&phql, _20 TSRMLS_CC); } else { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " JOIN [", joinModel, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " JOIN [", joinModel, "]"); + zephir_concat_self(&phql, _20 TSRMLS_CC); } } if (zephir_is_true(joinAlias)) { - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " AS [", joinAlias, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " AS [", joinAlias, "]"); + zephir_concat_self(&phql, _20 TSRMLS_CC); } if (zephir_is_true(joinConditions)) { - ZEPHIR_INIT_LNVAR(_24); - ZEPHIR_CONCAT_SV(_24, " ON ", joinConditions); - zephir_concat_self(&phql, _24 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_21); + ZEPHIR_CONCAT_SV(_21, " ON ", joinConditions); + zephir_concat_self(&phql, _21 TSRMLS_CC); } } } if (Z_TYPE_P(conditions) == IS_STRING) { if (!(ZEPHIR_IS_EMPTY(conditions))) { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " WHERE ", conditions); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SV(_15, " WHERE ", conditions); + zephir_concat_self(&phql, _15 TSRMLS_CC); } } ZEPHIR_OBS_VAR(group); @@ -1650,21 +1657,21 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(group) == IS_ARRAY) { ZEPHIR_INIT_VAR(groupItems); array_init(groupItems); - zephir_is_iterable(group, &_26, &_25, 0, 0, "phalcon/mvc/model/query/builder.zep", 1239); + zephir_is_iterable(group, &_23, &_22, 0, 0, "phalcon/mvc/model/query/builder.zep", 1249); for ( - ; zephir_hash_get_current_data_ex(_26, (void**) &_27, &_25) == SUCCESS - ; zephir_hash_move_forward_ex(_26, &_25) + ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS + ; zephir_hash_move_forward_ex(_23, &_22) ) { - ZEPHIR_GET_HVALUE(groupItem, _27); + ZEPHIR_GET_HVALUE(groupItem, _24); if (zephir_is_numeric(groupItem)) { - zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1230); + zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1240); } else { - if (zephir_memnstr_str(groupItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1232)) { - zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1233); + if (zephir_memnstr_str(groupItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1242)) { + zephir_array_append(&groupItems, groupItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1243); } else { ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, "[", groupItem, "]"); - zephir_array_append(&groupItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1235); + zephir_array_append(&groupItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1245); } } } @@ -1675,30 +1682,30 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { zephir_concat_self(&phql, _4 TSRMLS_CC); } else { if (zephir_is_numeric(group)) { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " GROUP BY ", group); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SV(_15, " GROUP BY ", group); + zephir_concat_self(&phql, _15 TSRMLS_CC); } else { - if (zephir_memnstr_str(group, SL("."), "phalcon/mvc/model/query/builder.zep", 1244)) { + if (zephir_memnstr_str(group, SL("."), "phalcon/mvc/model/query/builder.zep", 1254)) { ZEPHIR_INIT_LNVAR(_16); ZEPHIR_CONCAT_SV(_16, " GROUP BY ", group); zephir_concat_self(&phql, _16 TSRMLS_CC); } else { - if (zephir_memnstr_str(group, SL(","), "phalcon/mvc/model/query/builder.zep", 1247)) { - ZEPHIR_INIT_VAR(_28); - ZEPHIR_SINIT_VAR(_29); - ZVAL_STRING(&_29, " ", 0); - ZEPHIR_SINIT_VAR(_30); - ZVAL_STRING(&_30, "", 0); - zephir_fast_str_replace(&_28, &_29, &_30, group TSRMLS_CC); - ZEPHIR_CPY_WRT(group, _28); + if (zephir_memnstr_str(group, SL(","), "phalcon/mvc/model/query/builder.zep", 1257)) { + ZEPHIR_INIT_VAR(_25); + ZEPHIR_SINIT_VAR(_26); + ZVAL_STRING(&_26, " ", 0); + ZEPHIR_SINIT_VAR(_27); + ZVAL_STRING(&_27, "", 0); + zephir_fast_str_replace(&_25, &_26, &_27, group TSRMLS_CC); + ZEPHIR_CPY_WRT(group, _25); ZEPHIR_INIT_NVAR(groupItems); zephir_fast_explode_str(groupItems, SL(","), group, LONG_MAX TSRMLS_CC); - ZEPHIR_INIT_NVAR(_28); - zephir_fast_join_str(_28, SL("], ["), groupItems TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " GROUP BY [", _28, "]"); - zephir_concat_self(&phql, _23 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_25); + zephir_fast_join_str(_25, SL("], ["), groupItems TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_20); + ZEPHIR_CONCAT_SVS(_20, " GROUP BY [", _25, "]"); + zephir_concat_self(&phql, _20 TSRMLS_CC); } else { ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, " GROUP BY [", group, "]"); @@ -1723,21 +1730,21 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { if (Z_TYPE_P(order) == IS_ARRAY) { ZEPHIR_INIT_VAR(orderItems); array_init(orderItems); - zephir_is_iterable(order, &_32, &_31, 0, 0, "phalcon/mvc/model/query/builder.zep", 1284); + zephir_is_iterable(order, &_29, &_28, 0, 0, "phalcon/mvc/model/query/builder.zep", 1294); for ( - ; zephir_hash_get_current_data_ex(_32, (void**) &_33, &_31) == SUCCESS - ; zephir_hash_move_forward_ex(_32, &_31) + ; zephir_hash_get_current_data_ex(_29, (void**) &_30, &_28) == SUCCESS + ; zephir_hash_move_forward_ex(_29, &_28) ) { - ZEPHIR_GET_HVALUE(orderItem, _33); + ZEPHIR_GET_HVALUE(orderItem, _30); if (zephir_is_numeric(orderItem)) { - zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1275); + zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1285); } else { - if (zephir_memnstr_str(orderItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1277)) { - zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1278); + if (zephir_memnstr_str(orderItem, SL("."), "phalcon/mvc/model/query/builder.zep", 1287)) { + zephir_array_append(&orderItems, orderItem, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1288); } else { ZEPHIR_INIT_LNVAR(_4); ZEPHIR_CONCAT_SVS(_4, "[", orderItem, "]"); - zephir_array_append(&orderItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1280); + zephir_array_append(&orderItems, _4, PH_SEPARATE, "phalcon/mvc/model/query/builder.zep", 1290); } } } @@ -1747,9 +1754,9 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZEPHIR_CONCAT_SV(_4, " ORDER BY ", _1); zephir_concat_self(&phql, _4 TSRMLS_CC); } else { - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, " ORDER BY ", order); - zephir_concat_self(&phql, _12 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_15); + ZEPHIR_CONCAT_SV(_15, " ORDER BY ", order); + zephir_concat_self(&phql, _15 TSRMLS_CC); } } ZEPHIR_OBS_VAR(limit); @@ -1759,7 +1766,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { ZVAL_NULL(number); if (Z_TYPE_P(limit) == IS_ARRAY) { ZEPHIR_OBS_NVAR(number); - zephir_array_fetch_string(&number, limit, SL("number"), PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1299 TSRMLS_CC); + zephir_array_fetch_string(&number, limit, SL("number"), PH_NOISY, "phalcon/mvc/model/query/builder.zep", 1309 TSRMLS_CC); ZEPHIR_OBS_VAR(offset); if (zephir_array_isset_string_fetch(&offset, limit, SS("offset"), 0 TSRMLS_CC)) { if (!(zephir_is_numeric(offset))) { @@ -1781,45 +1788,34 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) { } } if (zephir_is_numeric(number)) { - ZEPHIR_OBS_VAR(hiddenParam); - zephir_read_property_this(&hiddenParam, this_ptr, SL("_hiddenParamNumber"), PH_NOISY_CC); - ZEPHIR_INIT_LNVAR(_4); - ZEPHIR_CONCAT_SVS(_4, " LIMIT :AP", hiddenParam, ":"); - zephir_concat_self(&phql, _4 TSRMLS_CC); - ZEPHIR_SINIT_NVAR(_29); - ZVAL_LONG(&_29, 10); - ZEPHIR_CALL_FUNCTION(&_34, "intval", &_35, 25, number, &_29); + zephir_concat_self_str(&phql, SL(" LIMIT :APL0:") TSRMLS_CC); + ZEPHIR_SINIT_NVAR(_26); + ZVAL_LONG(&_26, 10); + ZEPHIR_CALL_FUNCTION(&_31, "intval", &_32, 26, number, &_26); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_12); - ZEPHIR_CONCAT_SV(_12, "AP", hiddenParam); - zephir_update_property_array(this_ptr, SL("_bindParams"), _12, _34 TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_16); - ZEPHIR_CONCAT_SV(_16, "AP", hiddenParam); ZEPHIR_INIT_NVAR(_1); - ZVAL_LONG(_1, 1); - zephir_update_property_array(this_ptr, SL("_bindTypes"), _16, _1 TSRMLS_CC); + ZVAL_STRING(_1, "APL0", 1); + zephir_update_property_array(this_ptr, SL("_bindParams"), _1, _31 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_25); + ZVAL_STRING(_25, "APL0", 1); + ZEPHIR_INIT_VAR(_33); + ZVAL_LONG(_33, 1); + zephir_update_property_array(this_ptr, SL("_bindTypes"), _25, _33 TSRMLS_CC); if (zephir_is_numeric(offset)) { - ZEPHIR_SEPARATE(hiddenParam); - zephir_increment(hiddenParam); - ZEPHIR_INIT_LNVAR(_23); - ZEPHIR_CONCAT_SVS(_23, " OFFSET :AP", hiddenParam, ":"); - zephir_concat_self(&phql, _23 TSRMLS_CC); - ZEPHIR_SINIT_NVAR(_29); - ZVAL_LONG(&_29, 10); - ZEPHIR_CALL_FUNCTION(&_34, "intval", &_35, 25, offset, &_29); + zephir_concat_self_str(&phql, SL(" OFFSET :APL1:") TSRMLS_CC); + ZEPHIR_SINIT_NVAR(_26); + ZVAL_LONG(&_26, 10); + ZEPHIR_CALL_FUNCTION(&_31, "intval", &_32, 26, offset, &_26); zephir_check_call_status(); - ZEPHIR_INIT_LNVAR(_24); - ZEPHIR_CONCAT_SV(_24, "AP", hiddenParam); - zephir_update_property_array(this_ptr, SL("_bindParams"), _24, _34 TSRMLS_CC); + ZEPHIR_INIT_VAR(_34); + ZVAL_STRING(_34, "APL1", 1); + zephir_update_property_array(this_ptr, SL("_bindParams"), _34, _31 TSRMLS_CC); + ZEPHIR_INIT_VAR(_35); + ZVAL_STRING(_35, "APL1", 1); ZEPHIR_INIT_VAR(_36); - ZEPHIR_CONCAT_SV(_36, "AP", hiddenParam); - ZEPHIR_INIT_NVAR(_28); - ZVAL_LONG(_28, 1); - zephir_update_property_array(this_ptr, SL("_bindTypes"), _36, _28 TSRMLS_CC); + ZVAL_LONG(_36, 1); + zephir_update_property_array(this_ptr, SL("_bindTypes"), _35, _36 TSRMLS_CC); } - ZEPHIR_INIT_ZVAL_NREF(_37); - ZVAL_LONG(_37, (zephir_get_numberval(hiddenParam) + 1)); - zephir_update_property_this(this_ptr, SL("_hiddenParamNumber"), _37 TSRMLS_CC); } } forUpdate = zephir_fetch_nproperty_this(this_ptr, SL("_forUpdate"), PH_NOISY_CC); @@ -1844,21 +1840,21 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getQuery) { ZEPHIR_INIT_VAR(query); object_init_ex(query, phalcon_mvc_model_query_ce); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 354); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 347); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345, _0, _1); + ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 338, _0, _1); zephir_check_call_status(); ZEPHIR_OBS_VAR(bindParams); zephir_read_property_this(&bindParams, this_ptr, SL("_bindParams"), PH_NOISY_CC); if (Z_TYPE_P(bindParams) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 355, bindParams); + ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 348, bindParams); zephir_check_call_status(); } ZEPHIR_OBS_VAR(bindTypes); zephir_read_property_this(&bindTypes, this_ptr, SL("_bindTypes"), PH_NOISY_CC); if (Z_TYPE_P(bindTypes) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 356, bindTypes); + ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 349, bindTypes); zephir_check_call_status(); } RETURN_CCTOR(query); diff --git a/ext/phalcon/mvc/model/query/builder.zep.h b/ext/phalcon/mvc/model/query/builder.zep.h index 5174999547d..8bfcb5395fe 100644 --- a/ext/phalcon/mvc/model/query/builder.zep.h +++ b/ext/phalcon/mvc/model/query/builder.zep.h @@ -63,6 +63,7 @@ ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query_builder_addfrom, 0, 0, 1) ZEND_ARG_INFO(0, model) ZEND_ARG_INFO(0, alias) + ZEND_ARG_INFO(0, with) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_query_builder_join, 0, 0, 1) diff --git a/ext/phalcon/mvc/model/query/builderinterface.zep.c b/ext/phalcon/mvc/model/query/builderinterface.zep.c index e0093803dc3..d7222940525 100644 --- a/ext/phalcon/mvc/model/query/builderinterface.zep.c +++ b/ext/phalcon/mvc/model/query/builderinterface.zep.c @@ -36,7 +36,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, __construct); * Sets the columns to be queried * * @param string|array columns - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, columns); @@ -51,7 +51,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, getColumns); * Sets the models who makes part of the query * * @param string|array models - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, from); @@ -60,7 +60,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, from); * * @param string model * @param string alias - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, addFrom); @@ -77,7 +77,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, getFrom); * @param string model * @param string conditions * @param string alias - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, join); @@ -88,7 +88,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, join); * @param string conditions * @param string alias * @param string type - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, innerJoin); @@ -98,7 +98,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, innerJoin); * @param string model * @param string conditions * @param string alias - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, leftJoin); @@ -108,7 +108,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, leftJoin); * @param string model * @param string conditions * @param string alias - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, rightJoin); @@ -118,7 +118,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, rightJoin); * @param string conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, where); @@ -128,7 +128,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, where); * @param string conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, andWhere); @@ -138,7 +138,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, andWhere); * @param string conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, orWhere); @@ -148,7 +148,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, orWhere); * @param string expr * @param mixed minimum * @param mixed maximum - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, betweenWhere); @@ -158,7 +158,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, betweenWhere); * @param string expr * @param mixed minimum * @param mixed maximum - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, notBetweenWhere); @@ -183,7 +183,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, getWhere); * Sets a ORDER BY condition clause * * @param string orderBy - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, orderBy); @@ -198,7 +198,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, getOrderBy); * Sets a HAVING condition clause * * @param string having - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, having); @@ -214,7 +214,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, getHaving); * * @param int limit * @param int offset - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, limit); @@ -229,7 +229,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, getLimit); * Sets a LIMIT clause * * @param string group - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, groupBy); @@ -250,7 +250,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, getPhql); /** * Returns the query built * - * @return Phalcon\Mvc\Model\QueryInterface + * @return \Phalcon\Mvc\Model\QueryInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_Query_BuilderInterface, getQuery); diff --git a/ext/phalcon/mvc/model/query/generate b/ext/phalcon/mvc/model/query/generate index a0ddcfee3ec..06ef59a791d 100755 --- a/ext/phalcon/mvc/model/query/generate +++ b/ext/phalcon/mvc/model/query/generate @@ -5,7 +5,7 @@ if [ ! -f lemon ]; then fi rm -f *.o rm -f *.lo -re2c -o scanner.c scanner.re && ./lemon parser.lemon && cat base.c >> parser.c +re2c -o scanner.c scanner.re && ./lemon -s parser.lemon && cat base.c >> parser.c sed s/"\#line"/"\/\/"/g scanner.c > xx && mv -f xx scanner.c sed s/"#line"/"\/\/"/g parser.c > xx && mv -f xx parser.c sed s/YY/PP/g scanner.c > xx && mv -f xx scanner.c diff --git a/ext/phalcon/mvc/model/query/parser.c b/ext/phalcon/mvc/model/query/parser.c index 90a56f53658..b5ecb5f327f 100644 --- a/ext/phalcon/mvc/model/query/parser.c +++ b/ext/phalcon/mvc/model/query/parser.c @@ -129,7 +129,7 @@ static zval *phql_ret_select_statement(zval *S, zval *W, zval *O, zval *G, zval return ret; } -static zval *phql_ret_select_clause(zval *distinct, zval *columns, zval *tables, zval *with_list, zval *join_list) +static zval *phql_ret_select_clause(zval *distinct, zval *columns, zval *tables, zval *join_list) { zval *ret; @@ -143,10 +143,6 @@ static zval *phql_ret_select_clause(zval *distinct, zval *columns, zval *tables, add_assoc_zval(ret, "columns", columns); add_assoc_zval(ret, "tables", tables); - if (with_list) { - add_assoc_zval(ret, "with", with_list); - } - if (join_list) { add_assoc_zval(ret, "joins", join_list); } @@ -365,7 +361,7 @@ static zval *phql_ret_column_item(int type, zval *column, phql_parser_token *ide return ret; } -static zval *phql_ret_assoc_name(zval *qualified_name, phql_parser_token *alias) +static zval *phql_ret_assoc_name(zval *qualified_name, phql_parser_token *alias, zval *with) { zval *ret; @@ -373,11 +369,16 @@ static zval *phql_ret_assoc_name(zval *qualified_name, phql_parser_token *alias) MAKE_STD_ZVAL(ret); array_init(ret); add_assoc_zval(ret, "qualifiedName", qualified_name); + if (alias) { add_assoc_stringl(ret, "alias", alias->token, alias->token_len, 0); efree(alias); } + if (with) { + add_assoc_zval(ret, "with", with); + } + return ret; } @@ -455,7 +456,7 @@ static zval *phql_ret_func_call(phql_parser_token *name, zval *arguments, zval * } -// 459 "parser.c" +// 460 "parser.c" /* Next is all token values, in a form suitable for use by makeheaders. ** This section will be null unless lemon is run with the -m switch. */ @@ -505,23 +506,23 @@ static zval *phql_ret_func_call(phql_parser_token *name, zval *arguments, zval * ** defined, then do no error processing. */ #define PPCODETYPE unsigned char -#define PPNOCODE 135 +#define PPNOCODE 134 #define PPACTIONTYPE unsigned short int #define phql_TOKENTYPE phql_parser_token* typedef union { phql_TOKENTYPE pp0; - zval* pp244; - int pp269; + zval* pp162; + int pp267; } PPMINORTYPE; #define PPSTACKDEPTH 100 #define phql_ARG_SDECL phql_parser_status *status; #define phql_ARG_PDECL ,phql_parser_status *status #define phql_ARG_FETCH phql_parser_status *status = pppParser->status #define phql_ARG_STORE pppParser->status = status -#define PPNSTATE 280 -#define PPNRULE 157 +#define PPNSTATE 293 +#define PPNRULE 161 #define PPERRORSYMBOL 79 -#define PPERRSYMDT pp269 +#define PPERRSYMDT pp267 #define PP_NO_ACTION (PPNSTATE+PPNRULE+2) #define PP_ACCEPT_ACTION (PPNSTATE+PPNRULE+1) #define PP_ERROR_ACTION (PPNSTATE+PPNRULE) @@ -574,254 +575,266 @@ typedef union { ** pp_default[] Default action for each state. */ static PPACTIONTYPE pp_action[] = { - /* 0 */ 92, 98, 55, 57, 59, 61, 63, 65, 45, 47, + /* 0 */ 120, 126, 55, 57, 59, 61, 63, 65, 45, 47, /* 10 */ 67, 72, 49, 51, 53, 41, 39, 43, 37, 34, - /* 20 */ 94, 74, 69, 92, 98, 55, 57, 59, 61, 63, + /* 20 */ 122, 74, 69, 120, 126, 55, 57, 59, 61, 63, /* 30 */ 65, 45, 47, 67, 72, 49, 51, 53, 41, 39, - /* 40 */ 43, 37, 34, 94, 74, 69, 19, 20, 21, 22, - /* 50 */ 23, 106, 32, 33, 92, 98, 55, 57, 59, 61, - /* 60 */ 63, 65, 45, 47, 67, 72, 49, 51, 53, 41, - /* 70 */ 39, 43, 37, 34, 94, 74, 69, 94, 74, 69, - /* 80 */ 82, 70, 215, 207, 83, 205, 185, 85, 165, 86, - /* 90 */ 163, 193, 217, 126, 196, 160, 234, 92, 98, 55, + /* 40 */ 43, 37, 34, 122, 74, 69, 37, 34, 122, 74, + /* 50 */ 69, 166, 220, 92, 218, 45, 47, 67, 72, 49, + /* 60 */ 51, 53, 41, 39, 43, 37, 34, 122, 74, 69, + /* 70 */ 154, 429, 186, 91, 120, 126, 55, 57, 59, 61, + /* 80 */ 63, 65, 45, 47, 67, 72, 49, 51, 53, 41, + /* 90 */ 39, 43, 37, 34, 122, 74, 69, 120, 126, 55, /* 100 */ 57, 59, 61, 63, 65, 45, 47, 67, 72, 49, - /* 110 */ 51, 53, 41, 39, 43, 37, 34, 94, 74, 69, - /* 120 */ 92, 98, 55, 57, 59, 61, 63, 65, 45, 47, - /* 130 */ 67, 72, 49, 51, 53, 41, 39, 43, 37, 34, - /* 140 */ 94, 74, 69, 92, 98, 55, 57, 59, 61, 63, + /* 110 */ 51, 53, 41, 39, 43, 37, 34, 122, 74, 69, + /* 120 */ 19, 20, 21, 22, 23, 227, 32, 33, 67, 72, + /* 130 */ 49, 51, 53, 41, 39, 43, 37, 34, 122, 74, + /* 140 */ 69, 130, 238, 120, 126, 55, 57, 59, 61, 63, /* 150 */ 65, 45, 47, 67, 72, 49, 51, 53, 41, 39, - /* 160 */ 43, 37, 34, 94, 74, 69, 239, 247, 128, 45, - /* 170 */ 47, 67, 72, 49, 51, 53, 41, 39, 43, 37, - /* 180 */ 34, 94, 74, 69, 266, 273, 269, 118, 102, 92, - /* 190 */ 98, 55, 57, 59, 61, 63, 65, 45, 47, 67, - /* 200 */ 72, 49, 51, 53, 41, 39, 43, 37, 34, 94, - /* 210 */ 74, 69, 438, 1, 2, 3, 4, 5, 6, 198, - /* 220 */ 112, 79, 92, 98, 55, 57, 59, 61, 63, 65, + /* 160 */ 43, 37, 34, 122, 74, 69, 41, 39, 43, 37, + /* 170 */ 34, 122, 74, 69, 140, 8, 120, 126, 55, 57, + /* 180 */ 59, 61, 63, 65, 45, 47, 67, 72, 49, 51, + /* 190 */ 53, 41, 39, 43, 37, 34, 122, 74, 69, 120, + /* 200 */ 126, 55, 57, 59, 61, 63, 65, 45, 47, 67, + /* 210 */ 72, 49, 51, 53, 41, 39, 43, 37, 34, 122, + /* 220 */ 74, 69, 120, 126, 55, 57, 59, 61, 63, 65, /* 230 */ 45, 47, 67, 72, 49, 51, 53, 41, 39, 43, - /* 240 */ 37, 34, 94, 74, 69, 140, 107, 258, 35, 96, - /* 250 */ 6, 141, 143, 274, 124, 126, 248, 160, 131, 257, - /* 260 */ 67, 72, 49, 51, 53, 41, 39, 43, 37, 34, - /* 270 */ 94, 74, 69, 100, 413, 49, 51, 53, 41, 39, - /* 280 */ 43, 37, 34, 94, 74, 69, 268, 269, 146, 147, - /* 290 */ 153, 154, 155, 105, 109, 115, 367, 121, 84, 85, - /* 300 */ 95, 86, 150, 148, 149, 151, 152, 55, 57, 59, - /* 310 */ 61, 63, 65, 45, 47, 67, 72, 49, 51, 53, - /* 320 */ 41, 39, 43, 37, 34, 94, 74, 69, 140, 7, - /* 330 */ 254, 35, 134, 183, 141, 143, 181, 76, 191, 245, - /* 340 */ 189, 131, 41, 39, 43, 37, 34, 94, 74, 69, - /* 350 */ 252, 249, 145, 246, 261, 140, 100, 238, 35, 145, - /* 360 */ 137, 141, 143, 130, 179, 135, 156, 177, 131, 166, - /* 370 */ 130, 146, 147, 153, 154, 155, 105, 109, 115, 280, - /* 380 */ 121, 87, 186, 100, 281, 150, 148, 149, 151, 152, - /* 390 */ 192, 213, 221, 166, 282, 6, 6, 243, 146, 147, - /* 400 */ 153, 154, 155, 105, 109, 115, 138, 121, 134, 134, - /* 410 */ 123, 162, 150, 148, 149, 151, 152, 200, 242, 158, - /* 420 */ 35, 78, 283, 141, 143, 208, 204, 212, 145, 145, - /* 430 */ 201, 175, 284, 132, 173, 76, 211, 219, 227, 130, - /* 440 */ 130, 203, 156, 156, 8, 100, 145, 168, 184, 170, - /* 450 */ 172, 236, 176, 180, 159, 17, 263, 130, 277, 245, - /* 460 */ 146, 147, 153, 154, 155, 105, 109, 115, 232, 121, - /* 470 */ 241, 225, 202, 246, 150, 148, 149, 151, 152, 145, - /* 480 */ 9, 35, 209, 210, 141, 143, 132, 76, 145, 24, - /* 490 */ 130, 131, 103, 229, 233, 243, 6, 26, 138, 130, - /* 500 */ 134, 37, 34, 94, 74, 69, 100, 10, 35, 101, - /* 510 */ 15, 141, 143, 13, 11, 14, 253, 12, 131, 220, - /* 520 */ 145, 146, 147, 153, 154, 155, 105, 109, 115, 145, - /* 530 */ 121, 130, 16, 100, 139, 150, 148, 149, 151, 152, - /* 540 */ 130, 27, 18, 29, 25, 69, 77, 31, 146, 147, - /* 550 */ 153, 154, 155, 105, 109, 115, 75, 121, 81, 232, - /* 560 */ 167, 138, 150, 148, 149, 151, 152, 145, 31, 80, - /* 570 */ 28, 224, 88, 90, 197, 199, 204, 272, 130, 145, - /* 580 */ 89, 188, 412, 97, 38, 231, 104, 76, 145, 108, - /* 590 */ 130, 245, 30, 166, 40, 110, 145, 145, 271, 130, - /* 600 */ 42, 36, 113, 44, 145, 244, 216, 130, 130, 223, - /* 610 */ 114, 145, 119, 125, 145, 130, 157, 133, 46, 116, - /* 620 */ 145, 145, 130, 145, 226, 130, 145, 48, 50, 145, - /* 630 */ 235, 130, 130, 52, 130, 120, 54, 130, 145, 158, - /* 640 */ 130, 159, 136, 164, 145, 169, 313, 145, 145, 130, - /* 650 */ 145, 56, 58, 145, 60, 130, 145, 62, 130, 130, - /* 660 */ 171, 130, 314, 174, 130, 315, 111, 130, 187, 64, - /* 670 */ 66, 145, 145, 316, 145, 188, 117, 145, 68, 91, - /* 680 */ 178, 317, 130, 130, 71, 130, 145, 166, 130, 145, - /* 690 */ 145, 122, 73, 93, 161, 318, 145, 130, 145, 145, - /* 700 */ 130, 130, 182, 319, 145, 320, 321, 130, 99, 130, - /* 710 */ 130, 145, 145, 145, 145, 130, 190, 195, 206, 279, - /* 720 */ 144, 127, 130, 130, 130, 130, 188, 264, 145, 142, - /* 730 */ 129, 194, 228, 230, 188, 214, 218, 237, 166, 130, - /* 740 */ 145, 145, 222, 240, 324, 256, 166, 250, 325, 145, - /* 750 */ 145, 130, 130, 255, 251, 259, 260, 332, 366, 262, - /* 760 */ 130, 130, 265, 267, 270, 275, 276, 338, 278, + /* 240 */ 37, 34, 122, 74, 69, 168, 109, 156, 35, 95, + /* 250 */ 99, 169, 171, 26, 76, 151, 188, 81, 159, 160, + /* 260 */ 82, 111, 209, 113, 114, 17, 146, 285, 192, 208, + /* 270 */ 194, 196, 128, 200, 204, 222, 223, 455, 1, 2, + /* 280 */ 3, 4, 5, 6, 199, 173, 284, 197, 174, 175, + /* 290 */ 181, 182, 183, 133, 137, 143, 76, 149, 158, 24, + /* 300 */ 212, 217, 178, 176, 177, 179, 180, 168, 135, 271, + /* 310 */ 35, 249, 6, 169, 171, 287, 276, 110, 290, 173, + /* 320 */ 159, 49, 51, 53, 41, 39, 43, 37, 34, 122, + /* 330 */ 74, 69, 158, 384, 128, 430, 192, 208, 194, 196, + /* 340 */ 80, 200, 204, 292, 210, 122, 74, 69, 84, 84, + /* 350 */ 174, 175, 181, 182, 183, 133, 137, 143, 125, 149, + /* 360 */ 107, 107, 95, 90, 178, 176, 177, 179, 180, 55, + /* 370 */ 57, 59, 61, 63, 65, 45, 47, 67, 72, 49, + /* 380 */ 51, 53, 41, 39, 43, 37, 34, 122, 74, 69, + /* 390 */ 213, 274, 258, 35, 70, 228, 169, 171, 131, 109, + /* 400 */ 245, 265, 6, 214, 259, 230, 279, 286, 282, 234, + /* 410 */ 173, 83, 203, 6, 129, 201, 84, 128, 173, 152, + /* 420 */ 154, 207, 186, 158, 205, 162, 244, 96, 107, 85, + /* 430 */ 219, 158, 173, 174, 175, 181, 182, 183, 133, 137, + /* 440 */ 143, 94, 149, 173, 7, 158, 102, 178, 176, 177, + /* 450 */ 179, 180, 162, 232, 35, 89, 158, 169, 171, 184, + /* 460 */ 76, 112, 113, 114, 159, 211, 215, 79, 94, 78, + /* 470 */ 173, 226, 221, 217, 94, 6, 277, 240, 128, 160, + /* 480 */ 165, 84, 98, 158, 250, 163, 184, 162, 103, 95, + /* 490 */ 104, 173, 94, 107, 174, 175, 181, 182, 183, 133, + /* 500 */ 137, 143, 92, 149, 158, 173, 108, 155, 178, 176, + /* 510 */ 177, 179, 180, 168, 92, 224, 35, 258, 158, 169, + /* 520 */ 171, 184, 100, 27, 258, 173, 159, 166, 216, 257, + /* 530 */ 191, 115, 189, 254, 105, 173, 259, 124, 158, 69, + /* 540 */ 128, 110, 173, 107, 166, 281, 282, 225, 158, 252, + /* 550 */ 260, 31, 253, 10, 251, 158, 174, 175, 181, 182, + /* 560 */ 183, 133, 137, 143, 233, 149, 107, 106, 42, 173, + /* 570 */ 178, 176, 177, 179, 180, 30, 247, 35, 329, 245, + /* 580 */ 169, 171, 158, 147, 31, 229, 173, 159, 123, 328, + /* 590 */ 261, 332, 256, 270, 101, 327, 162, 173, 326, 158, + /* 600 */ 325, 128, 173, 173, 242, 246, 206, 28, 237, 18, + /* 610 */ 158, 50, 255, 202, 173, 158, 158, 174, 175, 181, + /* 620 */ 182, 183, 133, 137, 143, 121, 149, 158, 239, 173, + /* 630 */ 167, 178, 176, 177, 179, 180, 97, 269, 164, 119, + /* 640 */ 148, 263, 158, 173, 324, 264, 173, 71, 15, 132, + /* 650 */ 150, 267, 323, 161, 145, 256, 158, 173, 73, 158, + /* 660 */ 134, 170, 172, 198, 62, 173, 322, 333, 173, 60, + /* 670 */ 158, 262, 173, 66, 93, 266, 173, 195, 158, 173, + /* 680 */ 173, 158, 173, 187, 139, 158, 136, 173, 268, 158, + /* 690 */ 11, 173, 158, 158, 76, 158, 295, 185, 58, 340, + /* 700 */ 158, 173, 173, 56, 158, 272, 236, 36, 321, 54, + /* 710 */ 38, 383, 293, 157, 158, 158, 173, 127, 40, 273, + /* 720 */ 193, 173, 275, 278, 173, 173, 280, 173, 173, 158, + /* 730 */ 190, 173, 68, 52, 158, 173, 173, 158, 158, 138, + /* 740 */ 158, 158, 48, 283, 158, 13, 25, 88, 158, 158, + /* 750 */ 173, 173, 16, 248, 87, 86, 44, 46, 64, 297, + /* 760 */ 173, 294, 141, 158, 158, 296, 142, 288, 153, 289, + /* 770 */ 346, 173, 291, 158, 173, 173, 173, 12, 29, 75, + /* 780 */ 77, 144, 9, 235, 158, 117, 241, 158, 158, 158, + /* 790 */ 118, 231, 243, 296, 116, 14, }; static PPCODETYPE pp_lookahead[] = { /* 0 */ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, /* 10 */ 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, /* 20 */ 21, 22, 23, 1, 2, 3, 4, 5, 6, 7, /* 30 */ 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, - /* 40 */ 18, 19, 20, 21, 22, 23, 60, 61, 62, 63, - /* 50 */ 64, 45, 53, 54, 1, 2, 3, 4, 5, 6, - /* 60 */ 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, - /* 70 */ 17, 18, 19, 20, 21, 22, 23, 21, 22, 23, - /* 80 */ 97, 11, 12, 30, 101, 32, 103, 104, 30, 106, - /* 90 */ 32, 102, 22, 71, 105, 73, 50, 1, 2, 3, + /* 40 */ 18, 19, 20, 21, 22, 23, 19, 20, 21, 22, + /* 50 */ 23, 25, 30, 25, 32, 9, 10, 11, 12, 13, + /* 60 */ 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, + /* 70 */ 71, 45, 73, 45, 1, 2, 3, 4, 5, 6, + /* 80 */ 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, + /* 90 */ 17, 18, 19, 20, 21, 22, 23, 1, 2, 3, /* 100 */ 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, /* 110 */ 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, - /* 120 */ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, - /* 130 */ 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, - /* 140 */ 21, 22, 23, 1, 2, 3, 4, 5, 6, 7, + /* 120 */ 60, 61, 62, 63, 64, 45, 53, 54, 11, 12, + /* 130 */ 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, + /* 140 */ 23, 45, 56, 1, 2, 3, 4, 5, 6, 7, /* 150 */ 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, - /* 160 */ 18, 19, 20, 21, 22, 23, 44, 45, 72, 9, - /* 170 */ 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, - /* 180 */ 20, 21, 22, 23, 117, 118, 119, 68, 46, 1, - /* 190 */ 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, - /* 200 */ 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, - /* 210 */ 22, 23, 80, 81, 82, 83, 84, 85, 86, 25, - /* 220 */ 32, 27, 1, 2, 3, 4, 5, 6, 7, 8, + /* 160 */ 18, 19, 20, 21, 22, 23, 16, 17, 18, 19, + /* 170 */ 20, 21, 22, 23, 32, 88, 1, 2, 3, 4, + /* 180 */ 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, + /* 190 */ 15, 16, 17, 18, 19, 20, 21, 22, 23, 1, + /* 200 */ 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, + /* 210 */ 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, + /* 220 */ 22, 23, 1, 2, 3, 4, 5, 6, 7, 8, /* 230 */ 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, - /* 240 */ 19, 20, 21, 22, 23, 17, 82, 115, 20, 23, - /* 250 */ 86, 23, 24, 121, 70, 71, 111, 73, 30, 114, - /* 260 */ 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, - /* 270 */ 21, 22, 23, 45, 46, 13, 14, 15, 16, 17, - /* 280 */ 18, 19, 20, 21, 22, 23, 118, 119, 60, 61, - /* 290 */ 62, 63, 64, 65, 66, 67, 0, 69, 103, 104, - /* 300 */ 74, 106, 74, 75, 76, 77, 78, 3, 4, 5, - /* 310 */ 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, - /* 320 */ 16, 17, 18, 19, 20, 21, 22, 23, 17, 87, - /* 330 */ 25, 20, 99, 35, 23, 24, 38, 26, 30, 99, - /* 340 */ 32, 30, 16, 17, 18, 19, 20, 21, 22, 23, - /* 350 */ 110, 46, 119, 113, 58, 17, 45, 107, 20, 119, - /* 360 */ 127, 23, 24, 130, 35, 132, 133, 38, 30, 119, - /* 370 */ 130, 60, 61, 62, 63, 64, 65, 66, 67, 0, - /* 380 */ 69, 107, 25, 45, 0, 74, 75, 76, 77, 78, - /* 390 */ 33, 82, 82, 119, 0, 86, 86, 25, 60, 61, - /* 400 */ 62, 63, 64, 65, 66, 67, 25, 69, 99, 99, - /* 410 */ 128, 129, 74, 75, 76, 77, 78, 17, 46, 31, - /* 420 */ 20, 94, 0, 23, 24, 98, 99, 46, 119, 119, - /* 430 */ 30, 35, 0, 45, 38, 26, 127, 127, 55, 130, - /* 440 */ 130, 17, 133, 133, 88, 45, 119, 34, 35, 36, - /* 450 */ 37, 42, 39, 40, 30, 25, 47, 130, 49, 99, - /* 460 */ 60, 61, 62, 63, 64, 65, 66, 67, 99, 69, - /* 470 */ 110, 56, 31, 113, 74, 75, 76, 77, 78, 119, - /* 480 */ 89, 20, 28, 29, 23, 24, 45, 26, 119, 59, - /* 490 */ 130, 30, 82, 124, 125, 25, 86, 51, 25, 130, - /* 500 */ 99, 19, 20, 21, 22, 23, 45, 90, 20, 99, - /* 510 */ 58, 23, 24, 57, 91, 47, 46, 92, 30, 46, - /* 520 */ 119, 60, 61, 62, 63, 64, 65, 66, 67, 119, - /* 530 */ 69, 130, 126, 45, 133, 74, 75, 76, 77, 78, - /* 540 */ 130, 52, 126, 25, 126, 23, 93, 99, 60, 61, - /* 550 */ 62, 63, 64, 65, 66, 67, 45, 69, 96, 99, - /* 560 */ 30, 25, 74, 75, 76, 77, 78, 119, 99, 95, - /* 570 */ 122, 123, 108, 41, 100, 98, 99, 99, 130, 119, - /* 580 */ 109, 107, 46, 74, 99, 125, 46, 26, 119, 46, - /* 590 */ 130, 99, 123, 119, 99, 45, 119, 119, 120, 130, - /* 600 */ 99, 99, 30, 99, 119, 113, 99, 130, 130, 99, - /* 610 */ 46, 119, 30, 129, 119, 130, 28, 131, 99, 45, - /* 620 */ 119, 119, 130, 119, 99, 130, 119, 99, 99, 119, - /* 630 */ 99, 130, 130, 99, 130, 46, 99, 130, 119, 31, - /* 640 */ 130, 30, 46, 30, 119, 35, 30, 119, 119, 130, - /* 650 */ 119, 99, 99, 119, 99, 130, 119, 99, 130, 130, - /* 660 */ 35, 130, 30, 35, 130, 30, 99, 130, 100, 99, - /* 670 */ 99, 119, 119, 30, 119, 107, 99, 119, 99, 99, - /* 680 */ 35, 30, 130, 130, 99, 130, 119, 119, 130, 119, - /* 690 */ 119, 99, 99, 99, 99, 30, 119, 130, 119, 119, - /* 700 */ 130, 130, 35, 30, 119, 30, 30, 130, 99, 130, - /* 710 */ 130, 119, 119, 119, 119, 130, 30, 30, 30, 100, - /* 720 */ 99, 99, 130, 130, 130, 130, 107, 100, 119, 99, - /* 730 */ 99, 105, 52, 25, 107, 46, 45, 43, 119, 130, - /* 740 */ 119, 119, 46, 45, 0, 30, 119, 44, 0, 119, - /* 750 */ 119, 130, 130, 114, 45, 87, 116, 0, 0, 126, - /* 760 */ 130, 130, 48, 25, 3, 87, 116, 0, 27, + /* 240 */ 19, 20, 21, 22, 23, 17, 31, 72, 20, 119, + /* 250 */ 120, 23, 24, 51, 26, 127, 128, 96, 30, 44, + /* 260 */ 25, 100, 101, 102, 103, 25, 68, 98, 33, 34, + /* 270 */ 35, 36, 44, 38, 39, 28, 29, 80, 81, 82, + /* 280 */ 83, 84, 85, 86, 34, 116, 117, 37, 60, 61, + /* 290 */ 62, 63, 64, 65, 66, 67, 26, 69, 129, 59, + /* 300 */ 97, 98, 74, 75, 76, 77, 78, 17, 82, 112, + /* 310 */ 20, 41, 86, 23, 24, 118, 46, 30, 48, 116, + /* 320 */ 30, 13, 14, 15, 16, 17, 18, 19, 20, 21, + /* 330 */ 22, 23, 129, 0, 44, 45, 33, 34, 35, 36, + /* 340 */ 95, 38, 39, 99, 99, 21, 22, 23, 104, 104, + /* 350 */ 60, 61, 62, 63, 64, 65, 66, 67, 74, 69, + /* 360 */ 116, 116, 119, 120, 74, 75, 76, 77, 78, 3, + /* 370 */ 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, + /* 380 */ 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, + /* 390 */ 17, 58, 98, 20, 11, 12, 23, 24, 82, 31, + /* 400 */ 98, 107, 86, 30, 110, 22, 114, 115, 116, 82, + /* 410 */ 116, 99, 34, 86, 98, 37, 104, 44, 116, 70, + /* 420 */ 71, 34, 73, 129, 37, 98, 124, 30, 116, 32, + /* 430 */ 30, 129, 116, 60, 61, 62, 63, 64, 65, 66, + /* 440 */ 67, 30, 69, 116, 87, 129, 49, 74, 75, 76, + /* 450 */ 77, 78, 98, 126, 20, 44, 129, 23, 24, 132, + /* 460 */ 26, 101, 102, 103, 30, 25, 31, 27, 30, 94, + /* 470 */ 116, 82, 97, 98, 30, 86, 99, 55, 44, 44, + /* 480 */ 126, 104, 44, 129, 42, 131, 132, 98, 44, 119, + /* 490 */ 120, 116, 30, 116, 60, 61, 62, 63, 64, 65, + /* 500 */ 66, 67, 25, 69, 129, 116, 30, 98, 74, 75, + /* 510 */ 76, 77, 78, 17, 25, 126, 20, 98, 129, 23, + /* 520 */ 24, 132, 45, 52, 98, 116, 30, 25, 17, 110, + /* 530 */ 30, 104, 32, 107, 45, 116, 110, 23, 129, 23, + /* 540 */ 44, 30, 116, 116, 25, 115, 116, 45, 129, 43, + /* 550 */ 44, 98, 44, 90, 104, 129, 60, 61, 62, 63, + /* 560 */ 64, 65, 66, 67, 45, 69, 116, 119, 98, 116, + /* 570 */ 74, 75, 76, 77, 78, 122, 50, 20, 30, 98, + /* 580 */ 23, 24, 129, 30, 98, 98, 116, 30, 74, 30, + /* 590 */ 108, 0, 25, 111, 119, 30, 98, 116, 30, 129, + /* 600 */ 30, 44, 116, 116, 123, 124, 34, 121, 122, 125, + /* 610 */ 129, 98, 45, 34, 116, 129, 129, 60, 61, 62, + /* 620 */ 63, 64, 65, 66, 67, 98, 69, 129, 98, 116, + /* 630 */ 132, 74, 75, 76, 77, 78, 49, 30, 45, 98, + /* 640 */ 45, 43, 129, 116, 30, 44, 116, 98, 58, 45, + /* 650 */ 98, 25, 30, 130, 98, 25, 129, 116, 98, 129, + /* 660 */ 44, 98, 98, 34, 98, 116, 30, 0, 116, 98, + /* 670 */ 129, 45, 116, 98, 119, 45, 116, 34, 129, 116, + /* 680 */ 116, 129, 116, 98, 98, 129, 45, 116, 111, 129, + /* 690 */ 91, 116, 129, 129, 26, 129, 0, 28, 98, 0, + /* 700 */ 129, 116, 116, 98, 129, 87, 98, 98, 30, 98, + /* 710 */ 98, 0, 0, 98, 129, 129, 116, 98, 98, 113, + /* 720 */ 34, 116, 125, 47, 116, 116, 25, 116, 116, 129, + /* 730 */ 30, 116, 98, 98, 129, 116, 116, 129, 129, 44, + /* 740 */ 129, 129, 98, 3, 129, 57, 125, 119, 129, 129, + /* 750 */ 116, 116, 125, 98, 49, 30, 98, 98, 98, 0, + /* 760 */ 116, 0, 30, 129, 129, 0, 45, 87, 128, 113, + /* 770 */ 0, 116, 27, 129, 116, 116, 116, 92, 25, 44, + /* 780 */ 93, 44, 89, 45, 129, 106, 52, 129, 129, 129, + /* 790 */ 40, 44, 25, 133, 105, 46, }; -#define PP_SHIFT_USE_DFLT (-15) +#define PP_SHIFT_USE_DFLT (-2) static short pp_shift_ofst[] = { - /* 0 */ 409, 379, 384, 394, 422, 432, 46, 383, 415, 446, - /* 10 */ 452, 456, -15, 468, -15, -14, 430, -14, -15, -15, - /* 20 */ -15, -15, -15, -15, -14, -15, 489, 488, 518, 488, - /* 30 */ -15, -1, -15, -15, 488, 488, 56, 488, 56, 488, - /* 40 */ 482, 488, 482, 488, 482, 488, 249, 488, 249, 488, - /* 50 */ 326, 488, 326, 488, 326, 488, 160, 488, 160, 488, - /* 60 */ 160, 488, 160, 488, 160, 488, 160, 488, 262, 70, - /* 70 */ 488, 522, 488, 262, 511, 311, 454, 400, 194, 530, - /* 80 */ 357, 413, -15, 413, -15, -15, 530, 58, 532, -15, - /* 90 */ 488, 221, 488, 221, 226, -15, 509, -15, 488, 304, - /* 100 */ 461, 142, -15, 540, -15, 6, 561, 543, -15, 550, - /* 110 */ 488, 188, 572, 564, -15, 574, 488, 119, 582, 589, - /* 120 */ -15, 488, 22, 184, -15, -15, 488, 96, 488, 221, - /* 130 */ -15, 388, 588, 228, 221, 596, -15, 536, 338, -15, - /* 140 */ -15, 488, 522, 488, 522, -15, -15, -15, -15, -15, - /* 150 */ -15, -15, -15, -15, -15, -15, -15, -15, 611, -15, - /* 160 */ 488, 221, -15, 613, -15, -15, -15, 608, 610, 616, - /* 170 */ 625, 632, 396, 628, 635, 643, 329, 645, 651, 665, - /* 180 */ 298, 667, 673, 675, 676, -15, 530, -15, 308, 686, - /* 190 */ -15, -15, 687, 687, -15, -15, -15, -15, 400, -15, - /* 200 */ -15, 441, 424, -15, 53, 688, -15, -15, -15, -15, - /* 210 */ -15, 381, -15, 689, -15, 488, 522, 691, 311, 473, - /* 220 */ -15, 696, -15, 56, -15, 488, 221, 680, 488, 708, - /* 230 */ 488, -15, 221, -15, 488, 221, 694, 530, 122, 698, - /* 240 */ 488, 372, 744, 488, -15, 221, -15, 715, 305, 703, - /* 250 */ 709, 488, 470, 748, 715, -15, -15, -15, 46, 296, - /* 260 */ 757, -14, 758, 530, 714, 530, 738, 530, -15, 761, - /* 270 */ 488, -15, 221, -15, 46, 296, 767, 741, 530, -15, + /* 0 */ 270, 712, 761, 696, 765, 759, 526, 422, 86, 202, + /* 10 */ 590, 688, -2, 749, -2, 60, 240, 60, -2, -2, + /* 20 */ -2, -2, -2, -2, 60, -2, 471, 557, 753, 557, + /* 30 */ -2, 73, -2, -2, 557, 557, 324, 557, 324, 557, + /* 40 */ 27, 557, 27, 557, 27, 557, 117, 557, 117, 557, + /* 50 */ 150, 557, 150, 557, 150, 557, 46, 557, 46, 557, + /* 60 */ 46, 557, 46, 557, 46, 557, 46, 557, 308, 383, + /* 70 */ 557, 516, 557, 308, 735, 228, 247, 373, 440, 476, + /* 80 */ 235, -2, 476, -2, 397, 725, 705, 411, -2, 462, + /* 90 */ 28, -2, 462, -2, -2, -2, 587, 438, 462, 477, + /* 100 */ -2, -2, 444, 462, 489, -2, -2, -2, 368, 287, + /* 110 */ -2, 303, -2, -2, 476, 500, 750, -2, 557, 221, + /* 120 */ 557, 221, 514, -2, 284, -2, 557, 366, 434, 96, + /* 130 */ -2, 604, -2, 616, 668, 641, -2, 695, 557, 142, + /* 140 */ 732, 721, -2, 737, 557, 198, 553, 595, -2, 557, + /* 150 */ -1, 349, -2, -2, 557, 175, 557, 221, -2, 215, + /* 160 */ 669, 290, 221, 593, -2, 26, 496, -2, -2, 557, + /* 170 */ 516, 557, 516, -2, -2, -2, -2, -2, -2, -2, + /* 180 */ -2, -2, -2, -2, -2, -2, 557, 221, -2, 700, + /* 190 */ -2, -2, 686, 678, 643, 636, 250, 629, 622, 614, + /* 200 */ 378, 579, 570, 568, 387, 572, 565, 559, 548, -2, + /* 210 */ -2, 373, -2, -2, 435, 511, -2, 22, 400, -2, + /* 220 */ -2, -2, -2, -2, 502, -2, 80, -2, 557, 516, + /* 230 */ 747, 228, 519, -2, 738, -2, 324, -2, 557, 221, + /* 240 */ 734, 557, 767, 557, -2, 221, -2, 557, 221, 442, + /* 250 */ 476, 506, 508, 557, 567, 591, 557, -2, 221, -2, + /* 260 */ 607, 626, 598, 601, 557, 630, 667, 607, -2, -2, + /* 270 */ -2, 526, 333, 699, 60, 711, 476, 676, 476, 701, + /* 280 */ 476, -2, 740, 557, -2, 221, -2, 526, 333, 770, + /* 290 */ 745, 476, -2, }; -#define PP_REDUCE_USE_DFLT (-18) +#define PP_REDUCE_USE_DFLT (-1) static short pp_reduce_ofst[] = { - /* 0 */ 132, -18, -18, -18, -18, -18, 242, 356, 391, 417, - /* 10 */ 423, 425, -18, -18, -18, 406, -18, 416, -18, -18, - /* 20 */ -18, -18, -18, -18, 418, -18, -18, 448, -18, 469, - /* 30 */ -18, -18, -18, -18, 510, 502, -18, 485, -18, 495, - /* 40 */ -18, 501, -18, 504, -18, 519, -18, 528, -18, 529, - /* 50 */ -18, 534, -18, 537, -18, 552, -18, 553, -18, 555, - /* 60 */ -18, 558, -18, 570, -18, 571, -18, 579, -18, -18, - /* 70 */ 585, -18, 593, -18, -18, 309, 453, 327, -18, 474, - /* 80 */ 462, -17, -18, 195, -18, -18, 274, 464, 471, -18, - /* 90 */ 580, -18, 594, -18, -18, -18, -18, -18, 609, -18, - /* 100 */ 410, -18, -18, -18, -18, -18, 164, -18, -18, -18, - /* 110 */ 567, -18, -18, -18, -18, -18, 577, -18, -18, -18, - /* 120 */ -18, 592, 282, 484, -18, -18, 622, -18, 631, -18, - /* 130 */ -18, -18, 486, 233, -18, -18, -18, -18, 401, -18, - /* 140 */ -18, 630, -18, 621, -18, -18, -18, -18, -18, -18, - /* 150 */ -18, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 160 */ 595, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 170 */ -18, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 180 */ -18, -18, -18, -18, -18, -18, 568, -18, -18, -18, - /* 190 */ -18, -18, -11, 626, -18, -18, -18, -18, 477, -18, - /* 200 */ -18, -18, -18, -18, -18, -18, -18, -18, -18, -18, - /* 210 */ -18, -18, -18, -18, -18, 507, -18, -18, 310, -18, - /* 220 */ -18, -18, -18, -18, -18, 525, -18, -18, 369, -18, - /* 230 */ 460, -18, -18, -18, 531, -18, -18, 250, -18, -18, - /* 240 */ 360, -18, -18, 492, -18, -18, -18, 145, -18, -18, - /* 250 */ -18, 240, -18, -18, 639, -18, -18, -18, 668, 640, - /* 260 */ -18, 633, -18, 627, -18, 67, -18, 168, -18, -18, - /* 270 */ 478, -18, -18, -18, 678, 650, -18, -18, 619, -18, + /* 0 */ 197, -1, -1, -1, -1, -1, 357, 87, 693, 463, + /* 10 */ 599, 685, -1, -1, -1, 627, -1, 484, -1, -1, + /* 20 */ -1, -1, -1, -1, 621, -1, -1, 486, -1, 453, + /* 30 */ -1, -1, -1, -1, 608, 609, -1, 612, -1, 620, + /* 40 */ -1, 470, -1, 658, -1, 659, -1, 644, -1, 513, + /* 50 */ -1, 635, -1, 611, -1, 605, -1, 600, -1, 571, + /* 60 */ -1, 566, -1, 660, -1, 575, -1, 634, -1, -1, + /* 70 */ 549, -1, 560, -1, -1, 389, 687, 375, -1, 245, + /* 80 */ 161, -1, 312, -1, -1, -1, -1, 628, -1, 243, + /* 90 */ -1, -1, 555, -1, -1, -1, -1, 475, 130, -1, + /* 100 */ -1, -1, 448, 370, -1, -1, -1, -1, -1, -1, + /* 110 */ -1, 360, -1, -1, 427, 689, 679, -1, 541, -1, + /* 120 */ 527, -1, -1, -1, -1, -1, 619, -1, 316, -1, + /* 130 */ -1, -1, -1, -1, 226, -1, -1, -1, 586, -1, + /* 140 */ -1, -1, -1, -1, 556, -1, -1, -1, -1, 552, + /* 150 */ 128, 640, -1, -1, 409, -1, 615, -1, -1, -1, + /* 160 */ 523, 354, -1, -1, -1, -1, 498, -1, -1, 563, + /* 170 */ -1, 564, -1, -1, -1, -1, -1, -1, -1, -1, + /* 180 */ -1, -1, -1, -1, -1, -1, 585, -1, -1, -1, + /* 190 */ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + /* 200 */ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + /* 210 */ -1, 203, -1, -1, -1, -1, -1, -1, -1, -1, + /* 220 */ -1, -1, -1, -1, -1, -1, -1, -1, 487, -1, + /* 230 */ -1, 327, -1, -1, -1, -1, -1, -1, 530, -1, + /* 240 */ -1, 481, -1, 302, -1, -1, -1, 655, -1, -1, + /* 250 */ 450, -1, -1, 426, -1, -1, 419, -1, -1, -1, + /* 260 */ 482, -1, -1, -1, 294, -1, -1, 577, -1, -1, + /* 270 */ -1, 618, 606, -1, 597, -1, 377, -1, 292, -1, + /* 280 */ 430, -1, -1, 169, -1, -1, -1, 680, 656, -1, + /* 290 */ -1, 244, -1, }; static PPACTIONTYPE pp_default[] = { - /* 0 */ 437, 437, 437, 437, 437, 437, 345, 354, 359, 347, - /* 10 */ 365, 361, 285, 437, 360, 437, 362, 437, 363, 368, - /* 20 */ 369, 370, 371, 372, 437, 364, 437, 437, 346, 437, - /* 30 */ 348, 350, 351, 352, 437, 437, 373, 437, 375, 437, - /* 40 */ 376, 437, 377, 437, 378, 437, 379, 437, 380, 437, - /* 50 */ 381, 437, 382, 437, 383, 437, 384, 437, 385, 437, - /* 60 */ 386, 437, 387, 437, 388, 437, 389, 437, 390, 437, - /* 70 */ 437, 391, 437, 392, 437, 437, 289, 437, 437, 437, - /* 80 */ 302, 300, 286, 299, 303, 305, 437, 312, 323, 309, - /* 90 */ 437, 322, 437, 400, 437, 418, 437, 419, 437, 420, - /* 100 */ 437, 437, 423, 437, 396, 437, 437, 437, 399, 437, - /* 110 */ 437, 437, 437, 437, 401, 437, 437, 437, 437, 437, - /* 120 */ 402, 437, 437, 437, 403, 404, 437, 437, 437, 406, - /* 130 */ 408, 436, 411, 437, 417, 437, 409, 437, 437, 414, - /* 140 */ 416, 437, 421, 437, 422, 424, 425, 426, 427, 428, - /* 150 */ 429, 430, 431, 432, 433, 434, 415, 410, 437, 435, - /* 160 */ 437, 407, 405, 437, 310, 311, 343, 436, 437, 437, - /* 170 */ 437, 437, 437, 437, 437, 437, 437, 437, 437, 437, - /* 180 */ 437, 437, 437, 437, 437, 304, 437, 297, 342, 437, - /* 190 */ 340, 341, 437, 301, 306, 308, 307, 298, 437, 290, - /* 200 */ 292, 436, 437, 293, 296, 437, 294, 295, 291, 287, - /* 210 */ 288, 437, 394, 437, 397, 437, 393, 437, 437, 437, - /* 220 */ 395, 437, 398, 374, 349, 437, 358, 437, 437, 353, - /* 230 */ 437, 355, 357, 356, 437, 344, 437, 437, 437, 437, - /* 240 */ 437, 437, 437, 437, 326, 328, 327, 437, 437, 437, - /* 250 */ 437, 437, 437, 437, 437, 329, 331, 330, 345, 437, - /* 260 */ 437, 437, 437, 437, 437, 437, 333, 437, 334, 437, - /* 270 */ 437, 336, 337, 335, 345, 437, 437, 437, 437, 339, + /* 0 */ 454, 454, 454, 454, 454, 454, 362, 371, 376, 364, + /* 10 */ 382, 378, 298, 454, 377, 454, 379, 454, 380, 385, + /* 20 */ 386, 387, 388, 389, 454, 381, 454, 454, 363, 454, + /* 30 */ 365, 367, 368, 369, 454, 454, 390, 454, 392, 454, + /* 40 */ 393, 454, 394, 454, 395, 454, 396, 454, 397, 454, + /* 50 */ 398, 454, 399, 454, 400, 454, 401, 454, 402, 454, + /* 60 */ 403, 454, 404, 454, 405, 454, 406, 454, 407, 454, + /* 70 */ 454, 408, 454, 409, 454, 454, 302, 454, 454, 454, + /* 80 */ 313, 299, 454, 310, 350, 454, 348, 454, 351, 454, + /* 90 */ 454, 352, 454, 357, 359, 358, 349, 454, 454, 454, + /* 100 */ 353, 354, 454, 454, 454, 355, 356, 360, 453, 454, + /* 110 */ 452, 312, 314, 316, 454, 320, 331, 317, 454, 330, + /* 120 */ 454, 417, 454, 435, 454, 436, 454, 437, 454, 454, + /* 130 */ 440, 454, 413, 454, 454, 454, 416, 454, 454, 454, + /* 140 */ 454, 454, 418, 454, 454, 454, 454, 454, 419, 454, + /* 150 */ 454, 454, 420, 421, 454, 454, 454, 423, 425, 453, + /* 160 */ 428, 454, 434, 454, 426, 454, 454, 431, 433, 454, + /* 170 */ 438, 454, 439, 441, 442, 443, 444, 445, 446, 447, + /* 180 */ 448, 449, 450, 451, 432, 427, 454, 424, 422, 454, + /* 190 */ 318, 319, 454, 454, 454, 454, 454, 454, 454, 454, + /* 200 */ 454, 454, 454, 454, 454, 454, 454, 454, 454, 315, + /* 210 */ 311, 454, 303, 305, 453, 454, 306, 309, 454, 307, + /* 220 */ 308, 304, 300, 301, 454, 411, 454, 414, 454, 410, + /* 230 */ 454, 454, 454, 412, 454, 415, 391, 366, 454, 375, + /* 240 */ 454, 454, 370, 454, 372, 374, 373, 454, 361, 454, + /* 250 */ 454, 454, 454, 454, 454, 454, 454, 334, 336, 335, + /* 260 */ 454, 454, 454, 454, 454, 454, 454, 454, 337, 339, + /* 270 */ 338, 362, 454, 454, 454, 454, 454, 454, 454, 341, + /* 280 */ 454, 342, 454, 454, 344, 345, 343, 362, 454, 454, + /* 290 */ 454, 454, 347, }; #define PP_SZ_ACTTAB (sizeof(pp_action)/sizeof(pp_action[0])) @@ -915,11 +928,11 @@ static const char *ppTokenName[] = { "MINUS", "IS", "IN", "NOT", "BITWISE_NOT", "COMMA", "SELECT", "FROM", "DISTINCT", "ALL", "IDENTIFIER", "DOT", - "AS", "WITH", "INNER", "JOIN", - "CROSS", "LEFT", "OUTER", "RIGHT", - "FULL", "ON", "INSERT", "INTO", - "VALUES", "PARENTHESES_OPEN", "PARENTHESES_CLOSE", "UPDATE", - "SET", "DELETE", "WHERE", "ORDER", + "AS", "INNER", "JOIN", "CROSS", + "LEFT", "OUTER", "RIGHT", "FULL", + "ON", "INSERT", "INTO", "VALUES", + "PARENTHESES_OPEN", "PARENTHESES_CLOSE", "UPDATE", "SET", + "DELETE", "WITH", "WHERE", "ORDER", "BY", "ASC", "DESC", "GROUP", "HAVING", "FOR", "LIMIT", "OFFSET", "INTEGER", "HINTEGER", "NPLACEHOLDER", "SPLACEHOLDER", @@ -931,16 +944,16 @@ static const char *ppTokenName[] = { "update_statement", "delete_statement", "select_clause", "where_clause", "group_clause", "having_clause", "order_clause", "select_limit_clause", "for_update_clause", "distinct_all", "column_list", "associated_name_list", - "with_list_or_null", "join_list_or_null", "column_item", "expr", - "associated_name", "join_list", "with_list", "join_item", - "join_clause", "with_item", "join_type", "aliased_or_qualified_name", - "join_associated_name", "join_conditions", "values_list", "field_list", - "value_list", "value_item", "field_item", "update_clause", - "limit_clause", "update_item_list", "update_item", "qualified_name", - "new_value", "delete_clause", "order_list", "order_item", - "group_list", "group_item", "integer_or_placeholder", "argument_list", - "when_clauses", "when_clause", "function_call", "distinct_or_null", - "argument_list_or_null", "argument_item", + "join_list_or_null", "column_item", "expr", "associated_name", + "join_list", "join_item", "join_clause", "join_type", + "aliased_or_qualified_name", "join_associated_name", "join_conditions", "values_list", + "field_list", "value_list", "value_item", "field_item", + "update_clause", "limit_clause", "update_item_list", "update_item", + "qualified_name", "new_value", "delete_clause", "with_item", + "with_list", "order_list", "order_item", "group_list", + "group_item", "integer_or_placeholder", "argument_list", "when_clauses", + "when_clause", "function_call", "distinct_or_null", "argument_list_or_null", + "argument_item", }; #endif /* NDEBUG */ @@ -954,7 +967,7 @@ static const char *ppRuleName[] = { /* 3 */ "query_language ::= update_statement", /* 4 */ "query_language ::= delete_statement", /* 5 */ "select_statement ::= select_clause where_clause group_clause having_clause order_clause select_limit_clause for_update_clause", - /* 6 */ "select_clause ::= SELECT distinct_all column_list FROM associated_name_list with_list_or_null join_list_or_null", + /* 6 */ "select_clause ::= SELECT distinct_all column_list FROM associated_name_list join_list_or_null", /* 7 */ "distinct_all ::= DISTINCT", /* 8 */ "distinct_all ::= ALL", /* 9 */ "distinct_all ::=", @@ -969,142 +982,146 @@ static const char *ppRuleName[] = { /* 18 */ "associated_name_list ::= associated_name", /* 19 */ "join_list_or_null ::= join_list", /* 20 */ "join_list_or_null ::=", - /* 21 */ "with_list_or_null ::= WITH with_list", - /* 22 */ "with_list_or_null ::=", - /* 23 */ "join_list ::= join_list join_item", - /* 24 */ "join_list ::= join_item", - /* 25 */ "join_item ::= join_clause", - /* 26 */ "with_list ::= with_list with_item", - /* 27 */ "with_list ::= with_item", - /* 28 */ "with_item ::= IDENTIFIER", - /* 29 */ "join_clause ::= join_type aliased_or_qualified_name join_associated_name join_conditions", - /* 30 */ "join_associated_name ::= AS IDENTIFIER", - /* 31 */ "join_associated_name ::= IDENTIFIER", - /* 32 */ "join_associated_name ::=", - /* 33 */ "join_type ::= INNER JOIN", - /* 34 */ "join_type ::= CROSS JOIN", - /* 35 */ "join_type ::= LEFT OUTER JOIN", - /* 36 */ "join_type ::= LEFT JOIN", - /* 37 */ "join_type ::= RIGHT OUTER JOIN", - /* 38 */ "join_type ::= RIGHT JOIN", - /* 39 */ "join_type ::= FULL OUTER JOIN", - /* 40 */ "join_type ::= FULL JOIN", - /* 41 */ "join_type ::= JOIN", - /* 42 */ "join_conditions ::= ON expr", - /* 43 */ "join_conditions ::=", - /* 44 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", - /* 45 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name PARENTHESES_OPEN field_list PARENTHESES_CLOSE VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", - /* 46 */ "values_list ::= values_list COMMA value_item", - /* 47 */ "values_list ::= value_item", - /* 48 */ "value_item ::= expr", - /* 49 */ "field_list ::= field_list COMMA field_item", - /* 50 */ "field_list ::= field_item", - /* 51 */ "field_item ::= IDENTIFIER", - /* 52 */ "update_statement ::= update_clause where_clause limit_clause", - /* 53 */ "update_clause ::= UPDATE associated_name SET update_item_list", - /* 54 */ "update_item_list ::= update_item_list COMMA update_item", - /* 55 */ "update_item_list ::= update_item", - /* 56 */ "update_item ::= qualified_name EQUALS new_value", - /* 57 */ "new_value ::= expr", - /* 58 */ "delete_statement ::= delete_clause where_clause limit_clause", - /* 59 */ "delete_clause ::= DELETE FROM associated_name", - /* 60 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER", - /* 61 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER", - /* 62 */ "associated_name ::= aliased_or_qualified_name", - /* 63 */ "aliased_or_qualified_name ::= qualified_name", - /* 64 */ "where_clause ::= WHERE expr", - /* 65 */ "where_clause ::=", - /* 66 */ "order_clause ::= ORDER BY order_list", - /* 67 */ "order_clause ::=", - /* 68 */ "order_list ::= order_list COMMA order_item", - /* 69 */ "order_list ::= order_item", - /* 70 */ "order_item ::= expr", - /* 71 */ "order_item ::= expr ASC", - /* 72 */ "order_item ::= expr DESC", - /* 73 */ "group_clause ::= GROUP BY group_list", - /* 74 */ "group_clause ::=", - /* 75 */ "group_list ::= group_list COMMA group_item", - /* 76 */ "group_list ::= group_item", - /* 77 */ "group_item ::= expr", - /* 78 */ "having_clause ::= HAVING expr", - /* 79 */ "having_clause ::=", - /* 80 */ "for_update_clause ::= FOR UPDATE", - /* 81 */ "for_update_clause ::=", - /* 82 */ "select_limit_clause ::= LIMIT integer_or_placeholder", - /* 83 */ "select_limit_clause ::= LIMIT integer_or_placeholder COMMA integer_or_placeholder", - /* 84 */ "select_limit_clause ::= LIMIT integer_or_placeholder OFFSET integer_or_placeholder", - /* 85 */ "select_limit_clause ::=", - /* 86 */ "limit_clause ::= LIMIT integer_or_placeholder", - /* 87 */ "limit_clause ::=", - /* 88 */ "integer_or_placeholder ::= INTEGER", - /* 89 */ "integer_or_placeholder ::= HINTEGER", - /* 90 */ "integer_or_placeholder ::= NPLACEHOLDER", - /* 91 */ "integer_or_placeholder ::= SPLACEHOLDER", - /* 92 */ "integer_or_placeholder ::= BPLACEHOLDER", - /* 93 */ "expr ::= MINUS expr", - /* 94 */ "expr ::= expr MINUS expr", - /* 95 */ "expr ::= expr PLUS expr", - /* 96 */ "expr ::= expr TIMES expr", - /* 97 */ "expr ::= expr DIVIDE expr", - /* 98 */ "expr ::= expr MOD expr", - /* 99 */ "expr ::= expr AND expr", - /* 100 */ "expr ::= expr OR expr", - /* 101 */ "expr ::= expr BITWISE_AND expr", - /* 102 */ "expr ::= expr BITWISE_OR expr", - /* 103 */ "expr ::= expr BITWISE_XOR expr", - /* 104 */ "expr ::= expr EQUALS expr", - /* 105 */ "expr ::= expr NOTEQUALS expr", - /* 106 */ "expr ::= expr LESS expr", - /* 107 */ "expr ::= expr GREATER expr", - /* 108 */ "expr ::= expr GREATEREQUAL expr", - /* 109 */ "expr ::= expr LESSEQUAL expr", - /* 110 */ "expr ::= expr LIKE expr", - /* 111 */ "expr ::= expr NOT LIKE expr", - /* 112 */ "expr ::= expr ILIKE expr", - /* 113 */ "expr ::= expr NOT ILIKE expr", - /* 114 */ "expr ::= expr IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", - /* 115 */ "expr ::= expr NOT IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", - /* 116 */ "expr ::= PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 117 */ "expr ::= expr IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 118 */ "expr ::= expr NOT IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 119 */ "expr ::= EXISTS PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", - /* 120 */ "expr ::= expr AGAINST expr", - /* 121 */ "expr ::= CAST PARENTHESES_OPEN expr AS IDENTIFIER PARENTHESES_CLOSE", - /* 122 */ "expr ::= CONVERT PARENTHESES_OPEN expr USING IDENTIFIER PARENTHESES_CLOSE", - /* 123 */ "expr ::= CASE expr when_clauses END", - /* 124 */ "when_clauses ::= when_clauses when_clause", - /* 125 */ "when_clauses ::= when_clause", - /* 126 */ "when_clause ::= WHEN expr THEN expr", - /* 127 */ "when_clause ::= ELSE expr", - /* 128 */ "expr ::= function_call", - /* 129 */ "function_call ::= IDENTIFIER PARENTHESES_OPEN distinct_or_null argument_list_or_null PARENTHESES_CLOSE", - /* 130 */ "distinct_or_null ::= DISTINCT", - /* 131 */ "distinct_or_null ::=", - /* 132 */ "argument_list_or_null ::= argument_list", - /* 133 */ "argument_list_or_null ::=", - /* 134 */ "argument_list ::= argument_list COMMA argument_item", - /* 135 */ "argument_list ::= argument_item", - /* 136 */ "argument_item ::= TIMES", - /* 137 */ "argument_item ::= expr", - /* 138 */ "expr ::= expr IS NULL", - /* 139 */ "expr ::= expr IS NOT NULL", - /* 140 */ "expr ::= expr BETWEEN expr", - /* 141 */ "expr ::= NOT expr", - /* 142 */ "expr ::= BITWISE_NOT expr", - /* 143 */ "expr ::= PARENTHESES_OPEN expr PARENTHESES_CLOSE", - /* 144 */ "expr ::= qualified_name", - /* 145 */ "expr ::= INTEGER", - /* 146 */ "expr ::= HINTEGER", - /* 147 */ "expr ::= STRING", - /* 148 */ "expr ::= DOUBLE", - /* 149 */ "expr ::= NULL", - /* 150 */ "expr ::= TRUE", - /* 151 */ "expr ::= FALSE", - /* 152 */ "expr ::= NPLACEHOLDER", - /* 153 */ "expr ::= SPLACEHOLDER", - /* 154 */ "expr ::= BPLACEHOLDER", - /* 155 */ "qualified_name ::= IDENTIFIER DOT IDENTIFIER", - /* 156 */ "qualified_name ::= IDENTIFIER", + /* 21 */ "join_list ::= join_list join_item", + /* 22 */ "join_list ::= join_item", + /* 23 */ "join_item ::= join_clause", + /* 24 */ "join_clause ::= join_type aliased_or_qualified_name join_associated_name join_conditions", + /* 25 */ "join_associated_name ::= AS IDENTIFIER", + /* 26 */ "join_associated_name ::= IDENTIFIER", + /* 27 */ "join_associated_name ::=", + /* 28 */ "join_type ::= INNER JOIN", + /* 29 */ "join_type ::= CROSS JOIN", + /* 30 */ "join_type ::= LEFT OUTER JOIN", + /* 31 */ "join_type ::= LEFT JOIN", + /* 32 */ "join_type ::= RIGHT OUTER JOIN", + /* 33 */ "join_type ::= RIGHT JOIN", + /* 34 */ "join_type ::= FULL OUTER JOIN", + /* 35 */ "join_type ::= FULL JOIN", + /* 36 */ "join_type ::= JOIN", + /* 37 */ "join_conditions ::= ON expr", + /* 38 */ "join_conditions ::=", + /* 39 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", + /* 40 */ "insert_statement ::= INSERT INTO aliased_or_qualified_name PARENTHESES_OPEN field_list PARENTHESES_CLOSE VALUES PARENTHESES_OPEN values_list PARENTHESES_CLOSE", + /* 41 */ "values_list ::= values_list COMMA value_item", + /* 42 */ "values_list ::= value_item", + /* 43 */ "value_item ::= expr", + /* 44 */ "field_list ::= field_list COMMA field_item", + /* 45 */ "field_list ::= field_item", + /* 46 */ "field_item ::= IDENTIFIER", + /* 47 */ "update_statement ::= update_clause where_clause limit_clause", + /* 48 */ "update_clause ::= UPDATE associated_name SET update_item_list", + /* 49 */ "update_item_list ::= update_item_list COMMA update_item", + /* 50 */ "update_item_list ::= update_item", + /* 51 */ "update_item ::= qualified_name EQUALS new_value", + /* 52 */ "new_value ::= expr", + /* 53 */ "delete_statement ::= delete_clause where_clause limit_clause", + /* 54 */ "delete_clause ::= DELETE FROM associated_name", + /* 55 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER", + /* 56 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER", + /* 57 */ "associated_name ::= aliased_or_qualified_name", + /* 58 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER WITH with_item", + /* 59 */ "associated_name ::= aliased_or_qualified_name AS IDENTIFIER WITH PARENTHESES_OPEN with_list PARENTHESES_CLOSE", + /* 60 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER WITH PARENTHESES_OPEN with_list PARENTHESES_CLOSE", + /* 61 */ "associated_name ::= aliased_or_qualified_name IDENTIFIER WITH with_item", + /* 62 */ "associated_name ::= aliased_or_qualified_name WITH PARENTHESES_OPEN with_list PARENTHESES_CLOSE", + /* 63 */ "associated_name ::= aliased_or_qualified_name WITH with_item", + /* 64 */ "with_list ::= with_list COMMA with_item", + /* 65 */ "with_list ::= with_item", + /* 66 */ "with_item ::= IDENTIFIER", + /* 67 */ "aliased_or_qualified_name ::= qualified_name", + /* 68 */ "where_clause ::= WHERE expr", + /* 69 */ "where_clause ::=", + /* 70 */ "order_clause ::= ORDER BY order_list", + /* 71 */ "order_clause ::=", + /* 72 */ "order_list ::= order_list COMMA order_item", + /* 73 */ "order_list ::= order_item", + /* 74 */ "order_item ::= expr", + /* 75 */ "order_item ::= expr ASC", + /* 76 */ "order_item ::= expr DESC", + /* 77 */ "group_clause ::= GROUP BY group_list", + /* 78 */ "group_clause ::=", + /* 79 */ "group_list ::= group_list COMMA group_item", + /* 80 */ "group_list ::= group_item", + /* 81 */ "group_item ::= expr", + /* 82 */ "having_clause ::= HAVING expr", + /* 83 */ "having_clause ::=", + /* 84 */ "for_update_clause ::= FOR UPDATE", + /* 85 */ "for_update_clause ::=", + /* 86 */ "select_limit_clause ::= LIMIT integer_or_placeholder", + /* 87 */ "select_limit_clause ::= LIMIT integer_or_placeholder COMMA integer_or_placeholder", + /* 88 */ "select_limit_clause ::= LIMIT integer_or_placeholder OFFSET integer_or_placeholder", + /* 89 */ "select_limit_clause ::=", + /* 90 */ "limit_clause ::= LIMIT integer_or_placeholder", + /* 91 */ "limit_clause ::=", + /* 92 */ "integer_or_placeholder ::= INTEGER", + /* 93 */ "integer_or_placeholder ::= HINTEGER", + /* 94 */ "integer_or_placeholder ::= NPLACEHOLDER", + /* 95 */ "integer_or_placeholder ::= SPLACEHOLDER", + /* 96 */ "integer_or_placeholder ::= BPLACEHOLDER", + /* 97 */ "expr ::= MINUS expr", + /* 98 */ "expr ::= expr MINUS expr", + /* 99 */ "expr ::= expr PLUS expr", + /* 100 */ "expr ::= expr TIMES expr", + /* 101 */ "expr ::= expr DIVIDE expr", + /* 102 */ "expr ::= expr MOD expr", + /* 103 */ "expr ::= expr AND expr", + /* 104 */ "expr ::= expr OR expr", + /* 105 */ "expr ::= expr BITWISE_AND expr", + /* 106 */ "expr ::= expr BITWISE_OR expr", + /* 107 */ "expr ::= expr BITWISE_XOR expr", + /* 108 */ "expr ::= expr EQUALS expr", + /* 109 */ "expr ::= expr NOTEQUALS expr", + /* 110 */ "expr ::= expr LESS expr", + /* 111 */ "expr ::= expr GREATER expr", + /* 112 */ "expr ::= expr GREATEREQUAL expr", + /* 113 */ "expr ::= expr LESSEQUAL expr", + /* 114 */ "expr ::= expr LIKE expr", + /* 115 */ "expr ::= expr NOT LIKE expr", + /* 116 */ "expr ::= expr ILIKE expr", + /* 117 */ "expr ::= expr NOT ILIKE expr", + /* 118 */ "expr ::= expr IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", + /* 119 */ "expr ::= expr NOT IN PARENTHESES_OPEN argument_list PARENTHESES_CLOSE", + /* 120 */ "expr ::= PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 121 */ "expr ::= expr IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 122 */ "expr ::= expr NOT IN PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 123 */ "expr ::= EXISTS PARENTHESES_OPEN select_statement PARENTHESES_CLOSE", + /* 124 */ "expr ::= expr AGAINST expr", + /* 125 */ "expr ::= CAST PARENTHESES_OPEN expr AS IDENTIFIER PARENTHESES_CLOSE", + /* 126 */ "expr ::= CONVERT PARENTHESES_OPEN expr USING IDENTIFIER PARENTHESES_CLOSE", + /* 127 */ "expr ::= CASE expr when_clauses END", + /* 128 */ "when_clauses ::= when_clauses when_clause", + /* 129 */ "when_clauses ::= when_clause", + /* 130 */ "when_clause ::= WHEN expr THEN expr", + /* 131 */ "when_clause ::= ELSE expr", + /* 132 */ "expr ::= function_call", + /* 133 */ "function_call ::= IDENTIFIER PARENTHESES_OPEN distinct_or_null argument_list_or_null PARENTHESES_CLOSE", + /* 134 */ "distinct_or_null ::= DISTINCT", + /* 135 */ "distinct_or_null ::=", + /* 136 */ "argument_list_or_null ::= argument_list", + /* 137 */ "argument_list_or_null ::=", + /* 138 */ "argument_list ::= argument_list COMMA argument_item", + /* 139 */ "argument_list ::= argument_item", + /* 140 */ "argument_item ::= TIMES", + /* 141 */ "argument_item ::= expr", + /* 142 */ "expr ::= expr IS NULL", + /* 143 */ "expr ::= expr IS NOT NULL", + /* 144 */ "expr ::= expr BETWEEN expr", + /* 145 */ "expr ::= NOT expr", + /* 146 */ "expr ::= BITWISE_NOT expr", + /* 147 */ "expr ::= PARENTHESES_OPEN expr PARENTHESES_CLOSE", + /* 148 */ "expr ::= qualified_name", + /* 149 */ "expr ::= INTEGER", + /* 150 */ "expr ::= HINTEGER", + /* 151 */ "expr ::= STRING", + /* 152 */ "expr ::= DOUBLE", + /* 153 */ "expr ::= NULL", + /* 154 */ "expr ::= TRUE", + /* 155 */ "expr ::= FALSE", + /* 156 */ "expr ::= NPLACEHOLDER", + /* 157 */ "expr ::= SPLACEHOLDER", + /* 158 */ "expr ::= BPLACEHOLDER", + /* 159 */ "qualified_name ::= IDENTIFIER DOT IDENTIFIER", + /* 160 */ "qualified_name ::= IDENTIFIER", }; #endif /* NDEBUG */ @@ -1240,7 +1257,7 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 76: case 77: case 78: -// 557 "parser.lemon" +// 558 "parser.lemon" { if ((pppminor->pp0)) { if ((pppminor->pp0)->free_flag) { @@ -1249,7 +1266,7 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ efree((pppminor->pp0)); } } -// 1253 "parser.c" +// 1270 "parser.c" break; case 81: case 82: @@ -1259,6 +1276,7 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 86: case 94: case 95: + case 97: case 98: case 99: case 100: @@ -1266,27 +1284,26 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 102: case 103: case 104: - case 105: - case 106: - case 107: + case 108: + case 109: case 111: case 112: case 114: case 115: - case 117: + case 116: case 118: case 119: + case 120: case 121: case 122: case 123: case 124: - case 125: - case 127: - case 130: - case 133: -// 570 "parser.lemon" -{ zval_ptr_dtor(&(pppminor->pp244)); } -// 1290 "parser.c" + case 126: + case 129: + case 132: +// 571 "parser.lemon" +{ zval_ptr_dtor(&(pppminor->pp162)); } +// 1307 "parser.c" break; case 87: case 88: @@ -1295,14 +1312,14 @@ static void pp_destructor(PPCODETYPE ppmajor, PPMINORTYPE *pppminor){ case 91: case 92: case 93: - case 108: - case 109: - case 116: + case 105: + case 106: + case 113: + case 130: case 131: - case 132: -// 882 "parser.lemon" -{ zephir_safe_zval_ptr_dtor((pppminor->pp244)); } -// 1306 "parser.c" +// 899 "parser.lemon" +{ zephir_safe_zval_ptr_dtor((pppminor->pp162)); } +// 1323 "parser.c" break; default: break; /* If no destructor action specified: do nothing */ } @@ -1484,78 +1501,82 @@ static struct { { 81, 1 }, { 81, 1 }, { 82, 7 }, - { 86, 7 }, + { 86, 6 }, { 93, 1 }, { 93, 1 }, { 93, 0 }, { 94, 3 }, { 94, 1 }, - { 98, 1 }, - { 98, 3 }, - { 98, 3 }, - { 98, 2 }, - { 98, 1 }, + { 97, 1 }, + { 97, 3 }, + { 97, 3 }, + { 97, 2 }, + { 97, 1 }, { 95, 3 }, { 95, 1 }, - { 97, 1 }, - { 97, 0 }, - { 96, 2 }, + { 96, 1 }, { 96, 0 }, - { 101, 2 }, + { 100, 2 }, + { 100, 1 }, { 101, 1 }, - { 103, 1 }, - { 102, 2 }, - { 102, 1 }, + { 102, 4 }, + { 105, 2 }, { 105, 1 }, - { 104, 4 }, - { 108, 2 }, - { 108, 1 }, - { 108, 0 }, - { 106, 2 }, - { 106, 2 }, - { 106, 3 }, - { 106, 2 }, - { 106, 3 }, - { 106, 2 }, - { 106, 3 }, + { 105, 0 }, + { 103, 2 }, + { 103, 2 }, + { 103, 3 }, + { 103, 2 }, + { 103, 3 }, + { 103, 2 }, + { 103, 3 }, + { 103, 2 }, + { 103, 1 }, { 106, 2 }, - { 106, 1 }, - { 109, 2 }, - { 109, 0 }, + { 106, 0 }, { 83, 7 }, { 83, 10 }, - { 110, 3 }, + { 107, 3 }, + { 107, 1 }, { 110, 1 }, - { 113, 1 }, - { 111, 3 }, + { 108, 3 }, + { 108, 1 }, { 111, 1 }, - { 114, 1 }, { 84, 3 }, - { 115, 4 }, - { 117, 3 }, + { 112, 4 }, + { 114, 3 }, + { 114, 1 }, + { 115, 3 }, { 117, 1 }, + { 85, 3 }, { 118, 3 }, + { 99, 3 }, + { 99, 2 }, + { 99, 1 }, + { 99, 5 }, + { 99, 7 }, + { 99, 6 }, + { 99, 4 }, + { 99, 5 }, + { 99, 3 }, + { 120, 3 }, { 120, 1 }, - { 85, 3 }, - { 121, 3 }, - { 100, 3 }, - { 100, 2 }, - { 100, 1 }, - { 107, 1 }, + { 119, 1 }, + { 104, 1 }, { 87, 2 }, { 87, 0 }, { 90, 3 }, { 90, 0 }, - { 122, 3 }, + { 121, 3 }, + { 121, 1 }, { 122, 1 }, - { 123, 1 }, - { 123, 2 }, - { 123, 2 }, + { 122, 2 }, + { 122, 2 }, { 88, 3 }, { 88, 0 }, - { 124, 3 }, + { 123, 3 }, + { 123, 1 }, { 124, 1 }, - { 125, 1 }, { 89, 2 }, { 89, 0 }, { 92, 2 }, @@ -1564,77 +1585,77 @@ static struct { { 91, 4 }, { 91, 4 }, { 91, 0 }, - { 116, 2 }, - { 116, 0 }, - { 126, 1 }, - { 126, 1 }, - { 126, 1 }, - { 126, 1 }, - { 126, 1 }, - { 99, 2 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 3 }, - { 99, 4 }, - { 99, 3 }, - { 99, 4 }, - { 99, 5 }, - { 99, 6 }, - { 99, 3 }, - { 99, 5 }, - { 99, 6 }, - { 99, 4 }, - { 99, 3 }, - { 99, 6 }, - { 99, 6 }, - { 99, 4 }, + { 113, 2 }, + { 113, 0 }, + { 125, 1 }, + { 125, 1 }, + { 125, 1 }, + { 125, 1 }, + { 125, 1 }, + { 98, 2 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 3 }, + { 98, 4 }, + { 98, 3 }, + { 98, 4 }, + { 98, 5 }, + { 98, 6 }, + { 98, 3 }, + { 98, 5 }, + { 98, 6 }, + { 98, 4 }, + { 98, 3 }, + { 98, 6 }, + { 98, 6 }, + { 98, 4 }, + { 127, 2 }, + { 127, 1 }, + { 128, 4 }, { 128, 2 }, - { 128, 1 }, - { 129, 4 }, - { 129, 2 }, - { 99, 1 }, - { 130, 5 }, + { 98, 1 }, + { 129, 5 }, + { 130, 1 }, + { 130, 0 }, { 131, 1 }, { 131, 0 }, + { 126, 3 }, + { 126, 1 }, { 132, 1 }, - { 132, 0 }, - { 127, 3 }, - { 127, 1 }, - { 133, 1 }, - { 133, 1 }, - { 99, 3 }, - { 99, 4 }, - { 99, 3 }, - { 99, 2 }, - { 99, 2 }, - { 99, 3 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 99, 1 }, - { 119, 3 }, - { 119, 1 }, + { 132, 1 }, + { 98, 3 }, + { 98, 4 }, + { 98, 3 }, + { 98, 2 }, + { 98, 2 }, + { 98, 3 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 98, 1 }, + { 116, 3 }, + { 116, 1 }, }; static void pp_accept(ppParser*); /* Forward Declaration */ @@ -1672,11 +1693,11 @@ static void pp_reduce( ** break; */ case 0: -// 566 "parser.lemon" +// 567 "parser.lemon" { - status->ret = ppmsp[0].minor.pp244; + status->ret = ppmsp[0].minor.pp162; } -// 1680 "parser.c" +// 1701 "parser.c" break; case 1: case 2: @@ -1684,880 +1705,927 @@ static void pp_reduce( case 4: case 18: case 19: - case 24: - case 25: - case 27: - case 48: - case 55: - case 57: - case 63: - case 69: - case 76: - case 77: - case 128: + case 22: + case 23: + case 43: + case 50: + case 52: + case 65: + case 67: + case 73: + case 80: + case 81: case 132: - case 137: - case 144: -// 572 "parser.lemon" + case 136: + case 141: + case 148: +// 573 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; } -// 1706 "parser.c" +// 1727 "parser.c" break; case 5: -// 590 "parser.lemon" +// 591 "parser.lemon" { - ppgotominor.pp244 = phql_ret_select_statement(ppmsp[-6].minor.pp244, ppmsp[-5].minor.pp244, ppmsp[-2].minor.pp244, ppmsp[-4].minor.pp244, ppmsp[-3].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_select_statement(ppmsp[-6].minor.pp162, ppmsp[-5].minor.pp162, ppmsp[-2].minor.pp162, ppmsp[-4].minor.pp162, ppmsp[-3].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1713 "parser.c" +// 1734 "parser.c" break; case 6: -// 596 "parser.lemon" +// 597 "parser.lemon" { - ppgotominor.pp244 = phql_ret_select_clause(ppmsp[-5].minor.pp244, ppmsp[-4].minor.pp244, ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); - pp_destructor(26,&ppmsp[-6].minor); - pp_destructor(27,&ppmsp[-3].minor); + ppgotominor.pp162 = phql_ret_select_clause(ppmsp[-4].minor.pp162, ppmsp[-3].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); + pp_destructor(26,&ppmsp[-5].minor); + pp_destructor(27,&ppmsp[-2].minor); } -// 1722 "parser.c" +// 1743 "parser.c" break; case 7: -// 602 "parser.lemon" +// 603 "parser.lemon" { - ppgotominor.pp244 = phql_ret_distinct_all(1); + ppgotominor.pp162 = phql_ret_distinct_all(1); pp_destructor(28,&ppmsp[0].minor); } -// 1730 "parser.c" +// 1751 "parser.c" break; case 8: -// 606 "parser.lemon" +// 607 "parser.lemon" { - ppgotominor.pp244 = phql_ret_distinct_all(0); + ppgotominor.pp162 = phql_ret_distinct_all(0); pp_destructor(29,&ppmsp[0].minor); } -// 1738 "parser.c" +// 1759 "parser.c" break; case 9: case 20: - case 22: - case 32: - case 43: - case 65: - case 67: - case 74: - case 79: - case 81: + case 27: + case 38: + case 69: + case 71: + case 78: + case 83: case 85: - case 87: - case 131: - case 133: -// 610 "parser.lemon" + case 89: + case 91: + case 135: + case 137: +// 611 "parser.lemon" { - ppgotominor.pp244 = NULL; + ppgotominor.pp162 = NULL; } -// 1758 "parser.c" +// 1778 "parser.c" break; case 10: case 17: - case 46: + case 41: + case 44: case 49: - case 54: - case 68: - case 75: - case 134: -// 616 "parser.lemon" + case 64: + case 72: + case 79: + case 138: +// 617 "parser.lemon" { - ppgotominor.pp244 = phql_ret_zval_list(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_zval_list(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(25,&ppmsp[-1].minor); } -// 1773 "parser.c" +// 1794 "parser.c" break; case 11: - case 47: - case 50: - case 125: - case 135: -// 620 "parser.lemon" + case 42: + case 45: + case 129: + case 139: +// 621 "parser.lemon" { - ppgotominor.pp244 = phql_ret_zval_list(ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_zval_list(ppmsp[0].minor.pp162, NULL); } -// 1784 "parser.c" +// 1805 "parser.c" break; case 12: - case 136: -// 626 "parser.lemon" + case 140: +// 627 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_STARALL, NULL, NULL, NULL); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_STARALL, NULL, NULL, NULL); pp_destructor(17,&ppmsp[0].minor); } -// 1793 "parser.c" +// 1814 "parser.c" break; case 13: -// 630 "parser.lemon" +// 631 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_DOMAINALL, NULL, ppmsp[-2].minor.pp0, NULL); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_DOMAINALL, NULL, ppmsp[-2].minor.pp0, NULL); pp_destructor(31,&ppmsp[-1].minor); pp_destructor(17,&ppmsp[0].minor); } -// 1802 "parser.c" +// 1823 "parser.c" break; case 14: -// 634 "parser.lemon" +// 635 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-2].minor.pp244, NULL, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-2].minor.pp162, NULL, ppmsp[0].minor.pp0); pp_destructor(32,&ppmsp[-1].minor); } -// 1810 "parser.c" +// 1831 "parser.c" break; case 15: -// 638 "parser.lemon" +// 639 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-1].minor.pp244, NULL, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[-1].minor.pp162, NULL, ppmsp[0].minor.pp0); } -// 1817 "parser.c" +// 1838 "parser.c" break; case 16: -// 642 "parser.lemon" +// 643 "parser.lemon" { - ppgotominor.pp244 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[0].minor.pp244, NULL, NULL); + ppgotominor.pp162 = phql_ret_column_item(PHQL_T_EXPR, ppmsp[0].minor.pp162, NULL, NULL); } -// 1824 "parser.c" +// 1845 "parser.c" break; case 21: -// 664 "parser.lemon" + case 128: +// 667 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; - pp_destructor(33,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_zval_list(ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1832 "parser.c" +// 1853 "parser.c" + break; + case 24: +// 684 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_join_item(ppmsp[-3].minor.pp162, ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); +} +// 1860 "parser.c" + break; + case 25: +// 690 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); + pp_destructor(32,&ppmsp[-1].minor); +} +// 1868 "parser.c" break; - case 23: case 26: - case 124: -// 674 "parser.lemon" + case 46: + case 66: + case 160: +// 694 "parser.lemon" { - ppgotominor.pp244 = phql_ret_zval_list(ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); } -// 1841 "parser.c" +// 1878 "parser.c" break; case 28: - case 31: - case 51: - case 156: -// 700 "parser.lemon" +// 704 "parser.lemon" { - ppgotominor.pp244 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_INNERJOIN); + pp_destructor(33,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1851 "parser.c" +// 1887 "parser.c" break; case 29: -// 707 "parser.lemon" +// 708 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_item(ppmsp[-3].minor.pp244, ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_CROSSJOIN); + pp_destructor(35,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1858 "parser.c" +// 1896 "parser.c" break; case 30: -// 713 "parser.lemon" +// 712 "parser.lemon" { - ppgotominor.pp244 = phql_ret_qualified_name(NULL, NULL, ppmsp[0].minor.pp0); - pp_destructor(32,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_LEFTJOIN); + pp_destructor(36,&ppmsp[-2].minor); + pp_destructor(37,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1866 "parser.c" +// 1906 "parser.c" break; - case 33: -// 727 "parser.lemon" + case 31: +// 716 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_INNERJOIN); - pp_destructor(34,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_LEFTJOIN); + pp_destructor(36,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1875 "parser.c" +// 1915 "parser.c" break; - case 34: -// 731 "parser.lemon" + case 32: +// 720 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_CROSSJOIN); - pp_destructor(36,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_RIGHTJOIN); + pp_destructor(38,&ppmsp[-2].minor); + pp_destructor(37,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1884 "parser.c" +// 1925 "parser.c" break; - case 35: -// 735 "parser.lemon" + case 33: +// 724 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_LEFTJOIN); - pp_destructor(37,&ppmsp[-2].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_RIGHTJOIN); pp_destructor(38,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1894 "parser.c" +// 1934 "parser.c" break; - case 36: -// 739 "parser.lemon" + case 34: +// 728 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_LEFTJOIN); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_FULLJOIN); + pp_destructor(39,&ppmsp[-2].minor); pp_destructor(37,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1903 "parser.c" +// 1944 "parser.c" break; - case 37: -// 743 "parser.lemon" + case 35: +// 732 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_RIGHTJOIN); - pp_destructor(39,&ppmsp[-2].minor); - pp_destructor(38,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_FULLJOIN); + pp_destructor(39,&ppmsp[-1].minor); + pp_destructor(34,&ppmsp[0].minor); } -// 1913 "parser.c" +// 1953 "parser.c" break; - case 38: -// 747 "parser.lemon" + case 36: +// 736 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_RIGHTJOIN); - pp_destructor(39,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_join_type(PHQL_T_INNERJOIN); + pp_destructor(34,&ppmsp[0].minor); } -// 1922 "parser.c" +// 1961 "parser.c" + break; + case 37: +// 742 "parser.lemon" +{ + ppgotominor.pp162 = ppmsp[0].minor.pp162; + pp_destructor(40,&ppmsp[-1].minor); +} +// 1969 "parser.c" break; case 39: -// 751 "parser.lemon" +// 753 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_FULLJOIN); - pp_destructor(40,&ppmsp[-2].minor); - pp_destructor(38,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_insert_statement(ppmsp[-4].minor.pp162, NULL, ppmsp[-1].minor.pp162); + pp_destructor(41,&ppmsp[-6].minor); + pp_destructor(42,&ppmsp[-5].minor); + pp_destructor(43,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 1932 "parser.c" +// 1981 "parser.c" break; case 40: -// 755 "parser.lemon" +// 757 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_FULLJOIN); - pp_destructor(40,&ppmsp[-1].minor); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_insert_statement(ppmsp[-7].minor.pp162, ppmsp[-5].minor.pp162, ppmsp[-1].minor.pp162); + pp_destructor(41,&ppmsp[-9].minor); + pp_destructor(42,&ppmsp[-8].minor); + pp_destructor(44,&ppmsp[-6].minor); + pp_destructor(45,&ppmsp[-4].minor); + pp_destructor(43,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 1941 "parser.c" +// 1995 "parser.c" break; - case 41: -// 759 "parser.lemon" + case 47: +// 795 "parser.lemon" { - ppgotominor.pp244 = phql_ret_join_type(PHQL_T_INNERJOIN); - pp_destructor(35,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_update_statement(ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1949 "parser.c" +// 2002 "parser.c" break; - case 42: -// 765 "parser.lemon" + case 48: +// 801 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; - pp_destructor(41,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_update_clause(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); + pp_destructor(46,&ppmsp[-3].minor); + pp_destructor(47,&ppmsp[-1].minor); } -// 1957 "parser.c" +// 2011 "parser.c" break; - case 44: -// 776 "parser.lemon" + case 51: +// 817 "parser.lemon" { - ppgotominor.pp244 = phql_ret_insert_statement(ppmsp[-4].minor.pp244, NULL, ppmsp[-1].minor.pp244); - pp_destructor(42,&ppmsp[-6].minor); - pp_destructor(43,&ppmsp[-5].minor); - pp_destructor(44,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_update_item(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); + pp_destructor(3,&ppmsp[-1].minor); } -// 1969 "parser.c" +// 2019 "parser.c" break; - case 45: -// 780 "parser.lemon" + case 53: +// 829 "parser.lemon" { - ppgotominor.pp244 = phql_ret_insert_statement(ppmsp[-7].minor.pp244, ppmsp[-5].minor.pp244, ppmsp[-1].minor.pp244); - pp_destructor(42,&ppmsp[-9].minor); - pp_destructor(43,&ppmsp[-8].minor); - pp_destructor(45,&ppmsp[-6].minor); - pp_destructor(46,&ppmsp[-4].minor); - pp_destructor(44,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_delete_statement(ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162, ppmsp[0].minor.pp162); } -// 1983 "parser.c" +// 2026 "parser.c" break; - case 52: -// 818 "parser.lemon" + case 54: +// 835 "parser.lemon" { - ppgotominor.pp244 = phql_ret_update_statement(ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_delete_clause(ppmsp[0].minor.pp162); + pp_destructor(48,&ppmsp[-2].minor); + pp_destructor(27,&ppmsp[-1].minor); } -// 1990 "parser.c" +// 2035 "parser.c" break; - case 53: -// 824 "parser.lemon" + case 55: +// 841 "parser.lemon" { - ppgotominor.pp244 = phql_ret_update_clause(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); - pp_destructor(47,&ppmsp[-3].minor); - pp_destructor(48,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp0, NULL); + pp_destructor(32,&ppmsp[-1].minor); } -// 1999 "parser.c" +// 2043 "parser.c" break; case 56: -// 840 "parser.lemon" +// 845 "parser.lemon" { - ppgotominor.pp244 = phql_ret_update_item(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); - pp_destructor(3,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-1].minor.pp162, ppmsp[0].minor.pp0, NULL); } -// 2007 "parser.c" +// 2050 "parser.c" + break; + case 57: +// 849 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[0].minor.pp162, NULL, NULL); +} +// 2057 "parser.c" break; case 58: -// 852 "parser.lemon" +// 853 "parser.lemon" { - ppgotominor.pp244 = phql_ret_delete_statement(ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-4].minor.pp162, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp162); + pp_destructor(32,&ppmsp[-3].minor); + pp_destructor(49,&ppmsp[-1].minor); } -// 2014 "parser.c" +// 2066 "parser.c" break; case 59: -// 858 "parser.lemon" +// 857 "parser.lemon" { - ppgotominor.pp244 = phql_ret_delete_clause(ppmsp[0].minor.pp244); - pp_destructor(49,&ppmsp[-2].minor); - pp_destructor(27,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-6].minor.pp162, ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp162); + pp_destructor(32,&ppmsp[-5].minor); + pp_destructor(49,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2023 "parser.c" +// 2077 "parser.c" break; case 60: -// 864 "parser.lemon" +// 861 "parser.lemon" { - ppgotominor.pp244 = phql_ret_assoc_name(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp0); - pp_destructor(32,&ppmsp[-1].minor); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-5].minor.pp162, ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp162); + pp_destructor(49,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2031 "parser.c" +// 2087 "parser.c" break; case 61: -// 868 "parser.lemon" +// 865 "parser.lemon" { - ppgotominor.pp244 = phql_ret_assoc_name(ppmsp[-1].minor.pp244, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-3].minor.pp162, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp162); + pp_destructor(49,&ppmsp[-1].minor); } -// 2038 "parser.c" +// 2095 "parser.c" break; case 62: -// 872 "parser.lemon" +// 869 "parser.lemon" { - ppgotominor.pp244 = phql_ret_assoc_name(ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-4].minor.pp162, NULL, ppmsp[-1].minor.pp162); + pp_destructor(49,&ppmsp[-3].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2045 "parser.c" +// 2105 "parser.c" break; - case 64: -// 884 "parser.lemon" + case 63: +// 873 "parser.lemon" +{ + ppgotominor.pp162 = phql_ret_assoc_name(ppmsp[-2].minor.pp162, NULL, ppmsp[0].minor.pp162); + pp_destructor(49,&ppmsp[-1].minor); +} +// 2113 "parser.c" + break; + case 68: +// 901 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(50,&ppmsp[-1].minor); } -// 2053 "parser.c" +// 2121 "parser.c" break; - case 66: -// 894 "parser.lemon" + case 70: +// 911 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(51,&ppmsp[-2].minor); pp_destructor(52,&ppmsp[-1].minor); } -// 2062 "parser.c" +// 2130 "parser.c" break; - case 70: -// 914 "parser.lemon" + case 74: +// 931 "parser.lemon" { - ppgotominor.pp244 = phql_ret_order_item(ppmsp[0].minor.pp244, 0); + ppgotominor.pp162 = phql_ret_order_item(ppmsp[0].minor.pp162, 0); } -// 2069 "parser.c" +// 2137 "parser.c" break; - case 71: -// 918 "parser.lemon" + case 75: +// 935 "parser.lemon" { - ppgotominor.pp244 = phql_ret_order_item(ppmsp[-1].minor.pp244, PHQL_T_ASC); + ppgotominor.pp162 = phql_ret_order_item(ppmsp[-1].minor.pp162, PHQL_T_ASC); pp_destructor(53,&ppmsp[0].minor); } -// 2077 "parser.c" +// 2145 "parser.c" break; - case 72: -// 922 "parser.lemon" + case 76: +// 939 "parser.lemon" { - ppgotominor.pp244 = phql_ret_order_item(ppmsp[-1].minor.pp244, PHQL_T_DESC); + ppgotominor.pp162 = phql_ret_order_item(ppmsp[-1].minor.pp162, PHQL_T_DESC); pp_destructor(54,&ppmsp[0].minor); } -// 2085 "parser.c" +// 2153 "parser.c" break; - case 73: -// 928 "parser.lemon" + case 77: +// 945 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(55,&ppmsp[-2].minor); pp_destructor(52,&ppmsp[-1].minor); } -// 2094 "parser.c" +// 2162 "parser.c" break; - case 78: -// 954 "parser.lemon" + case 82: +// 971 "parser.lemon" { - ppgotominor.pp244 = ppmsp[0].minor.pp244; + ppgotominor.pp162 = ppmsp[0].minor.pp162; pp_destructor(56,&ppmsp[-1].minor); } -// 2102 "parser.c" +// 2170 "parser.c" break; - case 80: -// 964 "parser.lemon" + case 84: +// 981 "parser.lemon" { - ppgotominor.pp244 = phql_ret_for_update_clause(); + ppgotominor.pp162 = phql_ret_for_update_clause(); pp_destructor(57,&ppmsp[-1].minor); - pp_destructor(47,&ppmsp[0].minor); + pp_destructor(46,&ppmsp[0].minor); } -// 2111 "parser.c" +// 2179 "parser.c" break; - case 82: case 86: -// 974 "parser.lemon" + case 90: +// 991 "parser.lemon" { - ppgotominor.pp244 = phql_ret_limit_clause(ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_limit_clause(ppmsp[0].minor.pp162, NULL); pp_destructor(58,&ppmsp[-1].minor); } -// 2120 "parser.c" +// 2188 "parser.c" break; - case 83: -// 978 "parser.lemon" + case 87: +// 995 "parser.lemon" { - ppgotominor.pp244 = phql_ret_limit_clause(ppmsp[0].minor.pp244, ppmsp[-2].minor.pp244); + ppgotominor.pp162 = phql_ret_limit_clause(ppmsp[0].minor.pp162, ppmsp[-2].minor.pp162); pp_destructor(58,&ppmsp[-3].minor); pp_destructor(25,&ppmsp[-1].minor); } -// 2129 "parser.c" +// 2197 "parser.c" break; - case 84: -// 982 "parser.lemon" + case 88: +// 999 "parser.lemon" { - ppgotominor.pp244 = phql_ret_limit_clause(ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_limit_clause(ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(58,&ppmsp[-3].minor); pp_destructor(59,&ppmsp[-1].minor); } -// 2138 "parser.c" +// 2206 "parser.c" break; - case 88: - case 145: -// 1000 "parser.lemon" + case 92: + case 149: +// 1017 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_INTEGER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_INTEGER, ppmsp[0].minor.pp0); } -// 2146 "parser.c" +// 2214 "parser.c" break; - case 89: - case 146: -// 1004 "parser.lemon" + case 93: + case 150: +// 1021 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_HINTEGER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_HINTEGER, ppmsp[0].minor.pp0); } -// 2154 "parser.c" +// 2222 "parser.c" break; - case 90: - case 152: -// 1008 "parser.lemon" + case 94: + case 156: +// 1025 "parser.lemon" { - ppgotominor.pp244 = phql_ret_placeholder_zval(PHQL_T_NPLACEHOLDER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_placeholder_zval(PHQL_T_NPLACEHOLDER, ppmsp[0].minor.pp0); } -// 2162 "parser.c" +// 2230 "parser.c" break; - case 91: - case 153: -// 1012 "parser.lemon" + case 95: + case 157: +// 1029 "parser.lemon" { - ppgotominor.pp244 = phql_ret_placeholder_zval(PHQL_T_SPLACEHOLDER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_placeholder_zval(PHQL_T_SPLACEHOLDER, ppmsp[0].minor.pp0); } -// 2170 "parser.c" +// 2238 "parser.c" break; - case 92: - case 154: -// 1016 "parser.lemon" + case 96: + case 158: +// 1033 "parser.lemon" { - ppgotominor.pp244 = phql_ret_placeholder_zval(PHQL_T_BPLACEHOLDER, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_placeholder_zval(PHQL_T_BPLACEHOLDER, ppmsp[0].minor.pp0); } -// 2178 "parser.c" +// 2246 "parser.c" break; - case 93: -// 1022 "parser.lemon" + case 97: +// 1039 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_MINUS, NULL, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_MINUS, NULL, ppmsp[0].minor.pp162); pp_destructor(20,&ppmsp[-1].minor); } -// 2186 "parser.c" +// 2254 "parser.c" break; - case 94: -// 1026 "parser.lemon" + case 98: +// 1043 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_SUB, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_SUB, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(20,&ppmsp[-1].minor); } -// 2194 "parser.c" +// 2262 "parser.c" break; - case 95: -// 1030 "parser.lemon" + case 99: +// 1047 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ADD, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ADD, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(19,&ppmsp[-1].minor); } -// 2202 "parser.c" +// 2270 "parser.c" break; - case 96: -// 1034 "parser.lemon" + case 100: +// 1051 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_MUL, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_MUL, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(17,&ppmsp[-1].minor); } -// 2210 "parser.c" +// 2278 "parser.c" break; - case 97: -// 1038 "parser.lemon" + case 101: +// 1055 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_DIV, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_DIV, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(16,&ppmsp[-1].minor); } -// 2218 "parser.c" +// 2286 "parser.c" break; - case 98: -// 1042 "parser.lemon" + case 102: +// 1059 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_MOD, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_MOD, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(18,&ppmsp[-1].minor); } -// 2226 "parser.c" +// 2294 "parser.c" break; - case 99: -// 1046 "parser.lemon" + case 103: +// 1063 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_AND, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_AND, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(9,&ppmsp[-1].minor); } -// 2234 "parser.c" +// 2302 "parser.c" break; - case 100: -// 1050 "parser.lemon" + case 104: +// 1067 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_OR, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_OR, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(10,&ppmsp[-1].minor); } -// 2242 "parser.c" +// 2310 "parser.c" break; - case 101: -// 1054 "parser.lemon" + case 105: +// 1071 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_AND, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_AND, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(13,&ppmsp[-1].minor); } -// 2250 "parser.c" +// 2318 "parser.c" break; - case 102: -// 1058 "parser.lemon" + case 106: +// 1075 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_OR, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_OR, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(14,&ppmsp[-1].minor); } -// 2258 "parser.c" +// 2326 "parser.c" break; - case 103: -// 1062 "parser.lemon" + case 107: +// 1079 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_XOR, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_XOR, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(15,&ppmsp[-1].minor); } -// 2266 "parser.c" +// 2334 "parser.c" break; - case 104: -// 1066 "parser.lemon" + case 108: +// 1083 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_EQUALS, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_EQUALS, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(3,&ppmsp[-1].minor); } -// 2274 "parser.c" +// 2342 "parser.c" break; - case 105: -// 1070 "parser.lemon" + case 109: +// 1087 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NOTEQUALS, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NOTEQUALS, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(4,&ppmsp[-1].minor); } -// 2282 "parser.c" +// 2350 "parser.c" break; - case 106: -// 1074 "parser.lemon" + case 110: +// 1091 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_LESS, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_LESS, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(5,&ppmsp[-1].minor); } -// 2290 "parser.c" +// 2358 "parser.c" break; - case 107: -// 1078 "parser.lemon" + case 111: +// 1095 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_GREATER, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_GREATER, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(6,&ppmsp[-1].minor); } -// 2298 "parser.c" +// 2366 "parser.c" break; - case 108: -// 1082 "parser.lemon" + case 112: +// 1099 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_GREATEREQUAL, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_GREATEREQUAL, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(7,&ppmsp[-1].minor); } -// 2306 "parser.c" +// 2374 "parser.c" break; - case 109: -// 1086 "parser.lemon" + case 113: +// 1103 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_LESSEQUAL, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_LESSEQUAL, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(8,&ppmsp[-1].minor); } -// 2314 "parser.c" +// 2382 "parser.c" break; - case 110: -// 1090 "parser.lemon" + case 114: +// 1107 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_LIKE, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_LIKE, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(11,&ppmsp[-1].minor); } -// 2322 "parser.c" +// 2390 "parser.c" break; - case 111: -// 1094 "parser.lemon" + case 115: +// 1111 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NLIKE, ppmsp[-3].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NLIKE, ppmsp[-3].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(23,&ppmsp[-2].minor); pp_destructor(11,&ppmsp[-1].minor); } -// 2331 "parser.c" +// 2399 "parser.c" break; - case 112: -// 1098 "parser.lemon" + case 116: +// 1115 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ILIKE, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ILIKE, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(12,&ppmsp[-1].minor); } -// 2339 "parser.c" +// 2407 "parser.c" break; - case 113: -// 1102 "parser.lemon" + case 117: +// 1119 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NILIKE, ppmsp[-3].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NILIKE, ppmsp[-3].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(23,&ppmsp[-2].minor); pp_destructor(12,&ppmsp[-1].minor); } -// 2348 "parser.c" +// 2416 "parser.c" break; - case 114: - case 117: -// 1106 "parser.lemon" + case 118: + case 121: +// 1123 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_IN, ppmsp[-4].minor.pp244, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_IN, ppmsp[-4].minor.pp162, ppmsp[-1].minor.pp162); pp_destructor(22,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2359 "parser.c" +// 2427 "parser.c" break; - case 115: - case 118: -// 1110 "parser.lemon" + case 119: + case 122: +// 1127 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NOTIN, ppmsp[-5].minor.pp244, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NOTIN, ppmsp[-5].minor.pp162, ppmsp[-1].minor.pp162); pp_destructor(23,&ppmsp[-4].minor); pp_destructor(22,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2371 "parser.c" +// 2439 "parser.c" break; - case 116: -// 1114 "parser.lemon" + case 120: +// 1131 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_SUBQUERY, ppmsp[-1].minor.pp244, NULL); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_SUBQUERY, ppmsp[-1].minor.pp162, NULL); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2380 "parser.c" +// 2448 "parser.c" break; - case 119: -// 1126 "parser.lemon" + case 123: +// 1143 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_EXISTS, NULL, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_EXISTS, NULL, ppmsp[-1].minor.pp162); pp_destructor(65,&ppmsp[-3].minor); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2390 "parser.c" +// 2458 "parser.c" break; - case 120: -// 1130 "parser.lemon" + case 124: +// 1147 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_AGAINST, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_AGAINST, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(1,&ppmsp[-1].minor); } -// 2398 "parser.c" +// 2466 "parser.c" break; - case 121: -// 1134 "parser.lemon" + case 125: +// 1151 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_CAST, ppmsp[-3].minor.pp244, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_CAST, ppmsp[-3].minor.pp162, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); pp_destructor(66,&ppmsp[-5].minor); - pp_destructor(45,&ppmsp[-4].minor); + pp_destructor(44,&ppmsp[-4].minor); pp_destructor(32,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2409 "parser.c" +// 2477 "parser.c" break; - case 122: -// 1138 "parser.lemon" + case 126: +// 1155 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_CONVERT, ppmsp[-3].minor.pp244, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_CONVERT, ppmsp[-3].minor.pp162, phql_ret_raw_qualified_name(ppmsp[-1].minor.pp0, NULL)); pp_destructor(67,&ppmsp[-5].minor); - pp_destructor(45,&ppmsp[-4].minor); + pp_destructor(44,&ppmsp[-4].minor); pp_destructor(68,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2420 "parser.c" +// 2488 "parser.c" break; - case 123: -// 1142 "parser.lemon" + case 127: +// 1159 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_CASE, ppmsp[-2].minor.pp244, ppmsp[-1].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_CASE, ppmsp[-2].minor.pp162, ppmsp[-1].minor.pp162); pp_destructor(69,&ppmsp[-3].minor); pp_destructor(70,&ppmsp[0].minor); } -// 2429 "parser.c" +// 2497 "parser.c" break; - case 126: -// 1154 "parser.lemon" + case 130: +// 1171 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_WHEN, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_WHEN, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(71,&ppmsp[-3].minor); pp_destructor(72,&ppmsp[-1].minor); } -// 2438 "parser.c" +// 2506 "parser.c" break; - case 127: -// 1158 "parser.lemon" + case 131: +// 1175 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ELSE, ppmsp[0].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ELSE, ppmsp[0].minor.pp162, NULL); pp_destructor(73,&ppmsp[-1].minor); } -// 2446 "parser.c" +// 2514 "parser.c" break; - case 129: -// 1168 "parser.lemon" + case 133: +// 1185 "parser.lemon" { - ppgotominor.pp244 = phql_ret_func_call(ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp244, ppmsp[-2].minor.pp244); - pp_destructor(45,&ppmsp[-3].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_func_call(ppmsp[-4].minor.pp0, ppmsp[-1].minor.pp162, ppmsp[-2].minor.pp162); + pp_destructor(44,&ppmsp[-3].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2455 "parser.c" +// 2523 "parser.c" break; - case 130: -// 1174 "parser.lemon" + case 134: +// 1191 "parser.lemon" { - ppgotominor.pp244 = phql_ret_distinct(); + ppgotominor.pp162 = phql_ret_distinct(); pp_destructor(28,&ppmsp[0].minor); } -// 2463 "parser.c" +// 2531 "parser.c" break; - case 138: -// 1212 "parser.lemon" + case 142: +// 1229 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ISNULL, ppmsp[-2].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ISNULL, ppmsp[-2].minor.pp162, NULL); pp_destructor(21,&ppmsp[-1].minor); pp_destructor(74,&ppmsp[0].minor); } -// 2472 "parser.c" +// 2540 "parser.c" break; - case 139: -// 1216 "parser.lemon" + case 143: +// 1233 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ISNOTNULL, ppmsp[-3].minor.pp244, NULL); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ISNOTNULL, ppmsp[-3].minor.pp162, NULL); pp_destructor(21,&ppmsp[-2].minor); pp_destructor(23,&ppmsp[-1].minor); pp_destructor(74,&ppmsp[0].minor); } -// 2482 "parser.c" +// 2550 "parser.c" break; - case 140: -// 1220 "parser.lemon" + case 144: +// 1237 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BETWEEN, ppmsp[-2].minor.pp244, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BETWEEN, ppmsp[-2].minor.pp162, ppmsp[0].minor.pp162); pp_destructor(2,&ppmsp[-1].minor); } -// 2490 "parser.c" +// 2558 "parser.c" break; - case 141: -// 1224 "parser.lemon" + case 145: +// 1241 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_NOT, NULL, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_NOT, NULL, ppmsp[0].minor.pp162); pp_destructor(23,&ppmsp[-1].minor); } -// 2498 "parser.c" +// 2566 "parser.c" break; - case 142: -// 1228 "parser.lemon" + case 146: +// 1245 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_BITWISE_NOT, NULL, ppmsp[0].minor.pp244); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_BITWISE_NOT, NULL, ppmsp[0].minor.pp162); pp_destructor(24,&ppmsp[-1].minor); } -// 2506 "parser.c" +// 2574 "parser.c" break; - case 143: -// 1232 "parser.lemon" + case 147: +// 1249 "parser.lemon" { - ppgotominor.pp244 = phql_ret_expr(PHQL_T_ENCLOSED, ppmsp[-1].minor.pp244, NULL); - pp_destructor(45,&ppmsp[-2].minor); - pp_destructor(46,&ppmsp[0].minor); + ppgotominor.pp162 = phql_ret_expr(PHQL_T_ENCLOSED, ppmsp[-1].minor.pp162, NULL); + pp_destructor(44,&ppmsp[-2].minor); + pp_destructor(45,&ppmsp[0].minor); } -// 2515 "parser.c" +// 2583 "parser.c" break; - case 147: -// 1248 "parser.lemon" + case 151: +// 1265 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_STRING, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_STRING, ppmsp[0].minor.pp0); } -// 2522 "parser.c" +// 2590 "parser.c" break; - case 148: -// 1252 "parser.lemon" + case 152: +// 1269 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_DOUBLE, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_DOUBLE, ppmsp[0].minor.pp0); } -// 2529 "parser.c" +// 2597 "parser.c" break; - case 149: -// 1256 "parser.lemon" + case 153: +// 1273 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_NULL, NULL); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_NULL, NULL); pp_destructor(74,&ppmsp[0].minor); } -// 2537 "parser.c" +// 2605 "parser.c" break; - case 150: -// 1260 "parser.lemon" + case 154: +// 1277 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_TRUE, NULL); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_TRUE, NULL); pp_destructor(77,&ppmsp[0].minor); } -// 2545 "parser.c" +// 2613 "parser.c" break; - case 151: -// 1264 "parser.lemon" + case 155: +// 1281 "parser.lemon" { - ppgotominor.pp244 = phql_ret_literal_zval(PHQL_T_FALSE, NULL); + ppgotominor.pp162 = phql_ret_literal_zval(PHQL_T_FALSE, NULL); pp_destructor(78,&ppmsp[0].minor); } -// 2553 "parser.c" +// 2621 "parser.c" break; - case 155: -// 1285 "parser.lemon" + case 159: +// 1302 "parser.lemon" { - ppgotominor.pp244 = phql_ret_qualified_name(NULL, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp0); + ppgotominor.pp162 = phql_ret_qualified_name(NULL, ppmsp[-2].minor.pp0, ppmsp[0].minor.pp0); pp_destructor(31,&ppmsp[-1].minor); } -// 2561 "parser.c" +// 2629 "parser.c" break; }; ppgoto = ppRuleInfo[ppruleno].lhs; @@ -2599,7 +2667,7 @@ static void pp_syntax_error( ){ phql_ARG_FETCH; #define PPTOKEN (ppminor.pp0) -// 490 "parser.lemon" +// 491 "parser.lemon" if (status->scanner_state->start_length) { { @@ -2666,7 +2734,7 @@ static void pp_syntax_error( status->status = PHQL_PARSING_FAILED; -// 2670 "parser.c" +// 2738 "parser.c" phql_ARG_STORE; /* Suppress warning about unused %extra_argument variable */ } @@ -2842,17 +2910,17 @@ void phql_( +------------------------------------------------------------------------+ | Phalcon Framework | +------------------------------------------------------------------------+ - | Copyright (c) 2011-2014 Phalcon Team (http://www.phalconphp.com) | + | Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) | +------------------------------------------------------------------------+ - | This source file is subject to the New BSD License that is bundled | - | with this package in the file docs/LICENSE.txt. | - | | - | If you did not receive a copy of the license and are unable to | - | obtain it through the world-wide-web, please send an email | + | This source file is subject to the New BSD License that is bundled | + | with this package in the file docs/LICENSE.txt. | + | | + | If you did not receive a copy of the license and are unable to | + | obtain it through the world-wide-web, please send an email | | to license@phalconphp.com so we can send you a copy immediately. | +------------------------------------------------------------------------+ - | Authors: Andres Gutierrez | - | Eduar Carvajal | + | Authors: Andres Gutierrez | + | Eduar Carvajal | +------------------------------------------------------------------------+ */ diff --git a/ext/phalcon/mvc/model/query/parser.h b/ext/phalcon/mvc/model/query/parser.h index b387562ccfb..dc9e4f64b1f 100644 --- a/ext/phalcon/mvc/model/query/parser.h +++ b/ext/phalcon/mvc/model/query/parser.h @@ -30,23 +30,23 @@ #define PHQL_IDENTIFIER 30 #define PHQL_DOT 31 #define PHQL_AS 32 -#define PHQL_WITH 33 -#define PHQL_INNER 34 -#define PHQL_JOIN 35 -#define PHQL_CROSS 36 -#define PHQL_LEFT 37 -#define PHQL_OUTER 38 -#define PHQL_RIGHT 39 -#define PHQL_FULL 40 -#define PHQL_ON 41 -#define PHQL_INSERT 42 -#define PHQL_INTO 43 -#define PHQL_VALUES 44 -#define PHQL_PARENTHESES_OPEN 45 -#define PHQL_PARENTHESES_CLOSE 46 -#define PHQL_UPDATE 47 -#define PHQL_SET 48 -#define PHQL_DELETE 49 +#define PHQL_INNER 33 +#define PHQL_JOIN 34 +#define PHQL_CROSS 35 +#define PHQL_LEFT 36 +#define PHQL_OUTER 37 +#define PHQL_RIGHT 38 +#define PHQL_FULL 39 +#define PHQL_ON 40 +#define PHQL_INSERT 41 +#define PHQL_INTO 42 +#define PHQL_VALUES 43 +#define PHQL_PARENTHESES_OPEN 44 +#define PHQL_PARENTHESES_CLOSE 45 +#define PHQL_UPDATE 46 +#define PHQL_SET 47 +#define PHQL_DELETE 48 +#define PHQL_WITH 49 #define PHQL_WHERE 50 #define PHQL_ORDER 51 #define PHQL_BY 52 diff --git a/ext/phalcon/mvc/model/query/parser.lemon b/ext/phalcon/mvc/model/query/parser.lemon index 9a324bc3d39..12cdd8659e1 100644 --- a/ext/phalcon/mvc/model/query/parser.lemon +++ b/ext/phalcon/mvc/model/query/parser.lemon @@ -160,7 +160,7 @@ static zval *phql_ret_select_statement(zval *S, zval *W, zval *O, zval *G, zval return ret; } -static zval *phql_ret_select_clause(zval *distinct, zval *columns, zval *tables, zval *with_list, zval *join_list) +static zval *phql_ret_select_clause(zval *distinct, zval *columns, zval *tables, zval *join_list) { zval *ret; @@ -174,10 +174,6 @@ static zval *phql_ret_select_clause(zval *distinct, zval *columns, zval *tables, add_assoc_zval(ret, "columns", columns); add_assoc_zval(ret, "tables", tables); - if (with_list) { - add_assoc_zval(ret, "with", with_list); - } - if (join_list) { add_assoc_zval(ret, "joins", join_list); } @@ -396,7 +392,7 @@ static zval *phql_ret_column_item(int type, zval *column, phql_parser_token *ide return ret; } -static zval *phql_ret_assoc_name(zval *qualified_name, phql_parser_token *alias) +static zval *phql_ret_assoc_name(zval *qualified_name, phql_parser_token *alias, zval *with) { zval *ret; @@ -404,11 +400,16 @@ static zval *phql_ret_assoc_name(zval *qualified_name, phql_parser_token *alias) MAKE_STD_ZVAL(ret); array_init(ret); add_assoc_zval(ret, "qualifiedName", qualified_name); + if (alias) { add_assoc_stringl(ret, "alias", alias->token, alias->token_len, 0); efree(alias); } + if (with) { + add_assoc_zval(ret, "with", with); + } + return ret; } @@ -593,8 +594,8 @@ select_statement(R) ::= select_clause(S) where_clause(W) group_clause(G) having_ %destructor select_clause { zval_ptr_dtor(&$$); } -select_clause(R) ::= SELECT distinct_all(D) column_list(C) FROM associated_name_list(A) with_list_or_null(W) join_list_or_null(J) . { - R = phql_ret_select_clause(D, C, A, W, J); +select_clause(R) ::= SELECT distinct_all(D) column_list(C) FROM associated_name_list(A) join_list_or_null(J) . { + R = phql_ret_select_clause(D, C, A, J); } %destructor distinct_all { zephir_safe_zval_ptr_dtor($$); } @@ -661,14 +662,6 @@ join_list_or_null(R) ::= . { R = NULL; } -with_list_or_null(R) ::= WITH with_list(L) . { - R = L; -} - -with_list_or_null(R) ::= . { - R = NULL; -} - %destructor join_list { zval_ptr_dtor(&$$); } join_list(R) ::= join_list(L) join_item(I) . { @@ -685,22 +678,6 @@ join_item(R) ::= join_clause(C) . { R = C; } -%destructor with_list { zval_ptr_dtor(&$$); } - -with_list(R) ::= with_list(L) with_item(I) . { - R = phql_ret_zval_list(L, I); -} - -with_list(R) ::= with_item(I) . { - R = I; -} - -%destructor with_item { zval_ptr_dtor(&$$); } - -with_item(R) ::= IDENTIFIER(I) . { - R = phql_ret_qualified_name(NULL, NULL, I); -} - %destructor join_clause { zval_ptr_dtor(&$$); } /** Join + conditions + alias */ @@ -862,15 +839,55 @@ delete_clause(R) ::= DELETE FROM associated_name(A) . { %destructor associated_name { zval_ptr_dtor(&$$); } associated_name(R) ::= aliased_or_qualified_name(Q) AS IDENTIFIER(I) . { - R = phql_ret_assoc_name(Q, I); + R = phql_ret_assoc_name(Q, I, NULL); } associated_name(R) ::= aliased_or_qualified_name(Q) IDENTIFIER(I) . { - R = phql_ret_assoc_name(Q, I); + R = phql_ret_assoc_name(Q, I, NULL); } associated_name(R) ::= aliased_or_qualified_name(Q) . { - R = phql_ret_assoc_name(Q, NULL); + R = phql_ret_assoc_name(Q, NULL, NULL); +} + +associated_name(R) ::= aliased_or_qualified_name(Q) AS IDENTIFIER(I) WITH with_item(W) . { + R = phql_ret_assoc_name(Q, I, W); +} + +associated_name(R) ::= aliased_or_qualified_name(Q) AS IDENTIFIER(I) WITH PARENTHESES_OPEN with_list(W) PARENTHESES_CLOSE . { + R = phql_ret_assoc_name(Q, I, W); +} + +associated_name(R) ::= aliased_or_qualified_name(Q) IDENTIFIER(I) WITH PARENTHESES_OPEN with_list(W) PARENTHESES_CLOSE . { + R = phql_ret_assoc_name(Q, I, W); +} + +associated_name(R) ::= aliased_or_qualified_name(Q) IDENTIFIER(I) WITH with_item(W) . { + R = phql_ret_assoc_name(Q, I, W); +} + +associated_name(R) ::= aliased_or_qualified_name(Q) WITH PARENTHESES_OPEN with_list(W) PARENTHESES_CLOSE . { + R = phql_ret_assoc_name(Q, NULL, W); +} + +associated_name(R) ::= aliased_or_qualified_name(Q) WITH with_item(W) . { + R = phql_ret_assoc_name(Q, NULL, W); +} + +%destructor with_list { zval_ptr_dtor(&$$); } + +with_list(R) ::= with_list(L) COMMA with_item(I) . { + R = phql_ret_zval_list(L, I); +} + +with_list(R) ::= with_item(I) . { + R = I; +} + +%destructor with_item { zval_ptr_dtor(&$$); } + +with_item(R) ::= IDENTIFIER(I) . { + R = phql_ret_qualified_name(NULL, NULL, I); } %destructor aliased_or_qualified_name { zval_ptr_dtor(&$$); } diff --git a/ext/phalcon/mvc/model/query/scanner.c b/ext/phalcon/mvc/model/query/scanner.c index 04524f7d994..edfb871ffae 100644 --- a/ext/phalcon/mvc/model/query/scanner.c +++ b/ext/phalcon/mvc/model/query/scanner.c @@ -1,4 +1,4 @@ -/* Generated by re2c 0.13.6 on Mon Jul 6 13:03:04 2015 */ +/* Generated by re2c 0.13.6 on Wed Aug 5 14:30:06 2015 */ // 1 "scanner.re" /* diff --git a/ext/phalcon/mvc/model/queryinterface.zep.c b/ext/phalcon/mvc/model/queryinterface.zep.c index 022629919c8..b54dfa173d2 100644 --- a/ext/phalcon/mvc/model/queryinterface.zep.c +++ b/ext/phalcon/mvc/model/queryinterface.zep.c @@ -37,7 +37,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_QueryInterface, parse); * Sets the cache parameters of the query * * @param array cacheOptions - * @return Phalcon\Mvc\Model\Query + * @return \Phalcon\Mvc\Model\Query */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_QueryInterface, cache); @@ -52,7 +52,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_QueryInterface, getCacheOptions); * Tells to the query if only the first row in the resultset must be returned * * @param boolean uniqueRow - * @return Phalcon\Mvc\Model\Query + * @return \Phalcon\Mvc\Model\Query */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_QueryInterface, setUniqueRow); diff --git a/ext/phalcon/mvc/model/relation.zep.c b/ext/phalcon/mvc/model/relation.zep.c index e9a33be1b95..4c3b37a9c21 100644 --- a/ext/phalcon/mvc/model/relation.zep.c +++ b/ext/phalcon/mvc/model/relation.zep.c @@ -199,6 +199,39 @@ PHP_METHOD(Phalcon_Mvc_Model_Relation, getOptions) { } +/** + * Returns an option by the specified name + * If the option doesn't exist null is returned + */ +PHP_METHOD(Phalcon_Mvc_Model_Relation, getOption) { + + zval *name_param = NULL, *option, *_0; + zval *name = NULL; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &name_param); + + if (unlikely(Z_TYPE_P(name_param) != IS_STRING && Z_TYPE_P(name_param) != IS_NULL)) { + zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'name' must be a string") TSRMLS_CC); + RETURN_MM_NULL(); + } + + if (likely(Z_TYPE_P(name_param) == IS_STRING)) { + zephir_get_strval(name, name_param); + } else { + ZEPHIR_INIT_VAR(name); + ZVAL_EMPTY_STRING(name); + } + + + _0 = zephir_fetch_nproperty_this(this_ptr, SL("_options"), PH_NOISY_CC); + if (zephir_array_isset_fetch(&option, _0, name, 1 TSRMLS_CC)) { + RETURN_CTOR(option); + } + RETURN_MM_NULL(); + +} + /** * Check whether the relation act as a foreign key */ diff --git a/ext/phalcon/mvc/model/relation.zep.h b/ext/phalcon/mvc/model/relation.zep.h index 678cf0921d4..1b617f7f47c 100644 --- a/ext/phalcon/mvc/model/relation.zep.h +++ b/ext/phalcon/mvc/model/relation.zep.h @@ -10,6 +10,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Relation, getReferencedModel); PHP_METHOD(Phalcon_Mvc_Model_Relation, getFields); PHP_METHOD(Phalcon_Mvc_Model_Relation, getReferencedFields); PHP_METHOD(Phalcon_Mvc_Model_Relation, getOptions); +PHP_METHOD(Phalcon_Mvc_Model_Relation, getOption); PHP_METHOD(Phalcon_Mvc_Model_Relation, isForeignKey); PHP_METHOD(Phalcon_Mvc_Model_Relation, getForeignKey); PHP_METHOD(Phalcon_Mvc_Model_Relation, getParams); @@ -33,6 +34,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_relation_setintermediaterelatio ZEND_ARG_INFO(0, intermediateReferencedFields) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_relation_getoption, 0, 0, 1) + ZEND_ARG_INFO(0, name) +ZEND_END_ARG_INFO() + ZEPHIR_INIT_FUNCS(phalcon_mvc_model_relation_method_entry) { PHP_ME(Phalcon_Mvc_Model_Relation, __construct, arginfo_phalcon_mvc_model_relation___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR) PHP_ME(Phalcon_Mvc_Model_Relation, setIntermediateRelation, arginfo_phalcon_mvc_model_relation_setintermediaterelation, ZEND_ACC_PUBLIC) @@ -41,6 +46,7 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_relation_method_entry) { PHP_ME(Phalcon_Mvc_Model_Relation, getFields, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getReferencedFields, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getOptions, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Mvc_Model_Relation, getOption, arginfo_phalcon_mvc_model_relation_getoption, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, isForeignKey, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getForeignKey, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Mvc_Model_Relation, getParams, NULL, ZEND_ACC_PUBLIC) diff --git a/ext/phalcon/mvc/model/resultset.zep.c b/ext/phalcon/mvc/model/resultset.zep.c index 1c8ff514649..b0c3efcce1a 100644 --- a/ext/phalcon/mvc/model/resultset.zep.c +++ b/ext/phalcon/mvc/model/resultset.zep.c @@ -100,8 +100,8 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_Resultset) { * Phalcon\Mvc\Model\Resultset constructor * * @param array columnTypes - * @param Phalcon\Db\ResultInterface|false result - * @param Phalcon\Cache\BackendInterface cache + * @param \Phalcon\Db\ResultInterface|false result + * @param \Phalcon\Cache\BackendInterface cache */ PHP_METHOD(Phalcon_Mvc_Model_Resultset, __construct) { @@ -170,7 +170,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset, next) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_pointer"), PH_NOISY_CC); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, (zephir_get_numberval(_0) + 1)); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_1); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_1); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -219,7 +219,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset, rewind) { ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, 0); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_0); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_0); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -359,7 +359,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset, offsetGet) { if (ZEPHIR_GT_LONG(_0, index)) { ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, index); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_1); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_1); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "current", NULL, 0); zephir_check_call_status(); @@ -374,7 +374,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset, offsetGet) { * Resultsets cannot be changed. It has only been implemented to meet the definition of the ArrayAccess interface * * @param int index - * @param Phalcon\Mvc\ModelInterface value + * @param \Phalcon\Mvc\ModelInterface value */ PHP_METHOD(Phalcon_Mvc_Model_Resultset, offsetSet) { @@ -444,7 +444,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset, getFirst) { } ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, 0); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_1); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_1); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "current", NULL, 0); zephir_check_call_status(); @@ -469,7 +469,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset, getLast) { } ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, (zephir_get_numberval(count) - 1)); - ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 70, &_0); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "seek", NULL, 72, &_0); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(this_ptr, "current", NULL, 0); zephir_check_call_status(); @@ -559,7 +559,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset, getMessages) { * Updates every record in the resultset * * @param array data - * @param Closure conditionCallback + * @param \Closure conditionCallback * @return boolean */ PHP_METHOD(Phalcon_Mvc_Model_Resultset, update) { @@ -717,7 +717,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset, delete) { * * * @param callback filter - * @return Phalcon\Mvc\Model[] + * @return \Phalcon\Mvc\Model[] */ PHP_METHOD(Phalcon_Mvc_Model_Resultset, filter) { diff --git a/ext/phalcon/mvc/model/resultset/complex.zep.c b/ext/phalcon/mvc/model/resultset/complex.zep.c index 240d0d834da..5c002c790e8 100644 --- a/ext/phalcon/mvc/model/resultset/complex.zep.c +++ b/ext/phalcon/mvc/model/resultset/complex.zep.c @@ -51,8 +51,8 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_Resultset_Complex) { * Phalcon\Mvc\Model\Resultset\Complex constructor * * @param array columnTypes - * @param Phalcon\Db\ResultInterface result - * @param Phalcon\Cache\BackendInterface cache + * @param \Phalcon\Db\ResultInterface result + * @param \Phalcon\Cache\BackendInterface cache */ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, __construct) { @@ -72,7 +72,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, __construct) { zephir_update_property_this(this_ptr, SL("_columnTypes"), columnTypes TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 357, result, cache); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 350, result, cache); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -83,12 +83,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, __construct) { */ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { - zephir_fcall_cache_entry *_12 = NULL, *_14 = NULL; - zend_class_entry *_11; - HashTable *_2, *_5; - HashPosition _1, _4; + zephir_fcall_cache_entry *_13 = NULL, *_15 = NULL; + zend_class_entry *_12; + HashTable *_3, *_6; + HashPosition _2, _5; int dirtyState, ZEPHIR_LAST_CALL_STATUS; - zval *row, *hydrateMode, *alias = NULL, *activeRow = NULL, *type = NULL, *columnTypes, *column = NULL, *columnValue = NULL, *value = NULL, *attribute = NULL, *source = NULL, *attributes = NULL, *columnMap = NULL, *rowModel = NULL, *keepSnapshots = NULL, *sqlAlias = NULL, *modelName = NULL, *_0, **_3, **_6, *_7 = NULL, *_8 = NULL, *_9, *_10 = NULL, *_13, _15 = zval_used_for_init, _16 = zval_used_for_init; + zval *row, *hydrateMode, *eager, *alias = NULL, *activeRow = NULL, *type = NULL, *column = NULL, *columnValue = NULL, *value = NULL, *attribute = NULL, *source = NULL, *attributes = NULL, *columnMap = NULL, *rowModel = NULL, *keepSnapshots = NULL, *sqlAlias = NULL, *modelName = NULL, *_0, *_1, **_4, **_7, *_8 = NULL, *_9 = NULL, *_10, *_11 = NULL, *_14, _16 = zval_used_for_init, _17 = zval_used_for_init; ZEPHIR_MM_GROW(); @@ -130,41 +130,40 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { break; } while(0); - ZEPHIR_OBS_VAR(columnTypes); - zephir_read_property_this(&columnTypes, this_ptr, SL("_columnTypes"), PH_NOISY_CC); dirtyState = 0; - zephir_is_iterable(columnTypes, &_2, &_1, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 245); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_columnTypes"), PH_NOISY_CC); + zephir_is_iterable(_1, &_3, &_2, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 246); for ( - ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS - ; zephir_hash_move_forward_ex(_2, &_1) + ; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS + ; zephir_hash_move_forward_ex(_3, &_2) ) { - ZEPHIR_GET_HMKEY(alias, _2, _1); - ZEPHIR_GET_HVALUE(column, _3); + ZEPHIR_GET_HMKEY(alias, _3, _2); + ZEPHIR_GET_HVALUE(column, _4); if (Z_TYPE_P(column) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Column type is corrupt", "phalcon/mvc/model/resultset/complex.zep", 135); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Column type is corrupt", "phalcon/mvc/model/resultset/complex.zep", 133); return; } ZEPHIR_OBS_NVAR(type); - zephir_array_fetch_string(&type, column, SL("type"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 138 TSRMLS_CC); + zephir_array_fetch_string(&type, column, SL("type"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 136 TSRMLS_CC); if (ZEPHIR_IS_STRING(type, "object")) { ZEPHIR_OBS_NVAR(source); - zephir_array_fetch_string(&source, column, SL("column"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 144 TSRMLS_CC); + zephir_array_fetch_string(&source, column, SL("column"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 142 TSRMLS_CC); ZEPHIR_OBS_NVAR(attributes); - zephir_array_fetch_string(&attributes, column, SL("attributes"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 145 TSRMLS_CC); + zephir_array_fetch_string(&attributes, column, SL("attributes"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 143 TSRMLS_CC); ZEPHIR_OBS_NVAR(columnMap); - zephir_array_fetch_string(&columnMap, column, SL("columnMap"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 146 TSRMLS_CC); + zephir_array_fetch_string(&columnMap, column, SL("columnMap"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 144 TSRMLS_CC); ZEPHIR_INIT_NVAR(rowModel); array_init(rowModel); - zephir_is_iterable(attributes, &_5, &_4, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 164); + zephir_is_iterable(attributes, &_6, &_5, 0, 0, "phalcon/mvc/model/resultset/complex.zep", 162); for ( - ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS - ; zephir_hash_move_forward_ex(_5, &_4) + ; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS + ; zephir_hash_move_forward_ex(_6, &_5) ) { - ZEPHIR_GET_HVALUE(attribute, _6); + ZEPHIR_GET_HVALUE(attribute, _7); ZEPHIR_OBS_NVAR(columnValue); - ZEPHIR_INIT_LNVAR(_7); - ZEPHIR_CONCAT_SVSV(_7, "_", source, "_", attribute); - zephir_array_fetch(&columnValue, row, _7, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 157 TSRMLS_CC); + ZEPHIR_INIT_LNVAR(_8); + ZEPHIR_CONCAT_SVSV(_8, "_", source, "_", attribute); + zephir_array_fetch(&columnValue, row, _8, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 155 TSRMLS_CC); zephir_array_update_zval(&rowModel, attribute, &columnValue, PH_COPY | PH_SEPARATE); } do { @@ -175,43 +174,43 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { ZVAL_BOOL(keepSnapshots, 0); } if (ZEPHIR_GLOBAL(orm).late_state_binding) { - ZEPHIR_OBS_NVAR(_8); - zephir_array_fetch_string(&_8, column, SL("instance"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 175 TSRMLS_CC); - if (zephir_instance_of_ev(_8, phalcon_mvc_model_ce TSRMLS_CC)) { - zephir_array_fetch_string(&_9, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 176 TSRMLS_CC); + ZEPHIR_OBS_NVAR(_9); + zephir_array_fetch_string(&_9, column, SL("instance"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 173 TSRMLS_CC); + if (zephir_instance_of_ev(_9, phalcon_mvc_model_ce TSRMLS_CC)) { + zephir_array_fetch_string(&_10, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 174 TSRMLS_CC); ZEPHIR_INIT_NVAR(modelName); - zephir_get_class(modelName, _9, 0 TSRMLS_CC); + zephir_get_class(modelName, _10, 0 TSRMLS_CC); } else { ZEPHIR_INIT_NVAR(modelName); ZVAL_STRING(modelName, "Phalcon\\Mvc\\Model", 1); } - zephir_array_fetch_string(&_9, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 182 TSRMLS_CC); - ZEPHIR_INIT_NVAR(_10); - ZVAL_LONG(_10, dirtyState); - _11 = zephir_fetch_class(modelName TSRMLS_CC); - ZEPHIR_CALL_CE_STATIC(&value, _11, "cloneresultmap", NULL, 0, _9, rowModel, columnMap, _10, keepSnapshots); + zephir_array_fetch_string(&_10, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 180 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_11); + ZVAL_LONG(_11, dirtyState); + _12 = zephir_fetch_class(modelName TSRMLS_CC); + ZEPHIR_CALL_CE_STATIC(&value, _12, "cloneresultmap", NULL, 0, _10, rowModel, columnMap, _11, keepSnapshots); zephir_check_call_status(); } else { - zephir_array_fetch_string(&_13, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 190 TSRMLS_CC); - ZEPHIR_INIT_NVAR(_10); - ZVAL_LONG(_10, dirtyState); - ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmap", &_12, 0, _13, rowModel, columnMap, _10, keepSnapshots); + zephir_array_fetch_string(&_14, column, SL("instance"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 188 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_11); + ZVAL_LONG(_11, dirtyState); + ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmap", &_13, 0, _14, rowModel, columnMap, _11, keepSnapshots); zephir_check_call_status(); } break; } - ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_14, 0, rowModel, columnMap, hydrateMode); + ZEPHIR_CALL_CE_STATIC(&value, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_15, 0, rowModel, columnMap, hydrateMode); zephir_check_call_status(); break; } while(0); ZEPHIR_OBS_NVAR(attribute); - zephir_array_fetch_string(&attribute, column, SL("balias"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 204 TSRMLS_CC); + zephir_array_fetch_string(&attribute, column, SL("balias"), PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 202 TSRMLS_CC); } else { ZEPHIR_OBS_NVAR(sqlAlias); if (zephir_array_isset_string_fetch(&sqlAlias, column, SS("sqlAlias"), 0 TSRMLS_CC)) { ZEPHIR_OBS_NVAR(value); - zephir_array_fetch(&value, row, sqlAlias, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 212 TSRMLS_CC); + zephir_array_fetch(&value, row, sqlAlias, PH_NOISY, "phalcon/mvc/model/resultset/complex.zep", 210 TSRMLS_CC); } else { ZEPHIR_OBS_NVAR(value); zephir_array_isset_fetch(&value, row, alias, 0 TSRMLS_CC); @@ -219,23 +218,25 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, current) { if (zephir_array_isset_string(column, SS("balias"))) { ZEPHIR_CPY_WRT(attribute, alias); } else { - ZEPHIR_SINIT_NVAR(_15); - ZVAL_STRING(&_15, "_", 0); ZEPHIR_SINIT_NVAR(_16); - ZVAL_STRING(&_16, "", 0); + ZVAL_STRING(&_16, "_", 0); + ZEPHIR_SINIT_NVAR(_17); + ZVAL_STRING(&_17, "", 0); ZEPHIR_INIT_NVAR(attribute); - zephir_fast_str_replace(&attribute, &_15, &_16, alias TSRMLS_CC); + zephir_fast_str_replace(&attribute, &_16, &_17, alias TSRMLS_CC); } } - do { - if (ZEPHIR_IS_LONG(hydrateMode, 1)) { - zephir_array_update_zval(&activeRow, attribute, &value, PH_COPY | PH_SEPARATE); + if (!(zephir_array_isset_string_fetch(&eager, column, SS("eager"), 1 TSRMLS_CC))) { + do { + if (ZEPHIR_IS_LONG(hydrateMode, 1)) { + zephir_array_update_zval(&activeRow, attribute, &value, PH_COPY | PH_SEPARATE); + break; + } + zephir_update_property_zval_zval(activeRow, attribute, value TSRMLS_CC); break; - } - zephir_update_property_zval_zval(activeRow, attribute, value TSRMLS_CC); - break; - } while(0); + } while(0); + } } zephir_update_property_this(this_ptr, SL("_activeRow"), activeRow TSRMLS_CC); RETURN_CCTOR(activeRow); @@ -263,7 +264,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, toArray) { _0->funcs->get_current_data(_0, &ZEPHIR_TMP_ITERATOR_PTR TSRMLS_CC); ZEPHIR_CPY_WRT(current, (*ZEPHIR_TMP_ITERATOR_PTR)); } - zephir_array_append(&records, current, PH_SEPARATE, "phalcon/mvc/model/resultset/complex.zep", 258); + zephir_array_append(&records, current, PH_SEPARATE, "phalcon/mvc/model/resultset/complex.zep", 259); } _0->funcs->dtor(_0 TSRMLS_CC); RETURN_CCTOR(records); @@ -295,7 +296,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, serialize) { zephir_array_update_string(&_0, SL("rows"), &records, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_0, SL("columnTypes"), &columnTypes, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_0, SL("hydrateMode"), &hydrateMode, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 71, _0); + ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_CCTOR(serialized); @@ -327,23 +328,23 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, unserialize) { zephir_update_property_this(this_ptr, SL("_disableHydration"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(resultset) != IS_ARRAY) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/complex.zep", 303); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/complex.zep", 304); return; } - zephir_array_fetch_string(&_0, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 306 TSRMLS_CC); + zephir_array_fetch_string(&_0, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 307 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_rows"), _0 TSRMLS_CC); - zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 307 TSRMLS_CC); + zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 308 TSRMLS_CC); ZEPHIR_INIT_ZVAL_NREF(_2); ZVAL_LONG(_2, zephir_fast_count_int(_1 TSRMLS_CC)); zephir_update_property_this(this_ptr, SL("_count"), _2 TSRMLS_CC); - zephir_array_fetch_string(&_3, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 308 TSRMLS_CC); + zephir_array_fetch_string(&_3, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 309 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_cache"), _3 TSRMLS_CC); - zephir_array_fetch_string(&_4, resultset, SL("columnTypes"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 309 TSRMLS_CC); + zephir_array_fetch_string(&_4, resultset, SL("columnTypes"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 310 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_columnTypes"), _4 TSRMLS_CC); - zephir_array_fetch_string(&_5, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 310 TSRMLS_CC); + zephir_array_fetch_string(&_5, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/complex.zep", 311 TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_hydrateMode"), _5 TSRMLS_CC); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/mvc/model/resultset/simple.zep.c b/ext/phalcon/mvc/model/resultset/simple.zep.c index af6a4ebb6be..911a89b40a1 100644 --- a/ext/phalcon/mvc/model/resultset/simple.zep.c +++ b/ext/phalcon/mvc/model/resultset/simple.zep.c @@ -53,9 +53,9 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_Resultset_Simple) { * Phalcon\Mvc\Model\Resultset\Simple constructor * * @param array columnMap - * @param Phalcon\Mvc\ModelInterface|Phalcon\Mvc\Model\Row model - * @param Phalcon\Db\Result\Pdo|null result - * @param Phalcon\Cache\BackendInterface cache + * @param \Phalcon\Mvc\ModelInterface|Phalcon\Mvc\Model\Row model + * @param \Phalcon\Db\Result\Pdo|null result + * @param \Phalcon\Cache\BackendInterface cache * @param boolean keepSnapshots */ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, __construct) { @@ -78,7 +78,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, __construct) { zephir_update_property_this(this_ptr, SL("_model"), model TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_columnMap"), columnMap TSRMLS_CC); zephir_update_property_this(this_ptr, SL("_keepSnapshots"), keepSnapshots TSRMLS_CC); - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 357, result, cache); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 350, result, cache); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -136,12 +136,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, current) { _6 = zephir_fetch_nproperty_this(this_ptr, SL("_keepSnapshots"), PH_NOISY_CC); ZEPHIR_INIT_NVAR(_3); ZVAL_LONG(_3, 0); - ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 358, _2, row, columnMap, _3, _6); + ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 351, _2, row, columnMap, _3, _6); zephir_check_call_status(); } break; } - ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 359, row, columnMap, hydrateMode); + ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 352, row, columnMap, hydrateMode); zephir_check_call_status(); break; } while(0); @@ -281,7 +281,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, serialize) { ZEPHIR_OBS_NVAR(_1); zephir_read_property_this(&_1, this_ptr, SL("_hydrateMode"), PH_NOISY_CC); zephir_array_update_string(&_0, SL("hydrateMode"), &_1, PH_COPY | PH_SEPARATE); - ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 71, _0); + ZEPHIR_RETURN_CALL_FUNCTION("serialize", NULL, 73, _0); zephir_check_call_status(); RETURN_MM(); @@ -312,7 +312,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, unserialize) { } - ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 72, data); + ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 74, data); zephir_check_call_status(); if (Z_TYPE_P(resultset) != IS_ARRAY) { ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/simple.zep", 252); diff --git a/ext/phalcon/mvc/model/resultsetinterface.zep.c b/ext/phalcon/mvc/model/resultsetinterface.zep.c index 3f45c3d8da3..31818655166 100644 --- a/ext/phalcon/mvc/model/resultsetinterface.zep.c +++ b/ext/phalcon/mvc/model/resultsetinterface.zep.c @@ -34,14 +34,14 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ResultsetInterface, getType); /** * Get first row in the resultset * - * @return Phalcon\Mvc\ModelInterface + * @return \Phalcon\Mvc\ModelInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ResultsetInterface, getFirst); /** * Get last row in the resultset * - * @return Phalcon\Mvc\ModelInterface + * @return \Phalcon\Mvc\ModelInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ResultsetInterface, getLast); @@ -58,7 +58,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ResultsetInterface, isFresh); /** * Returns the associated cache for the resultset * - * @return Phalcon\Cache\BackendInterface + * @return \Phalcon\Cache\BackendInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ResultsetInterface, getCache); diff --git a/ext/phalcon/mvc/model/row.zep.c b/ext/phalcon/mvc/model/row.zep.c index a6b8cff9165..665f6ff1aa6 100644 --- a/ext/phalcon/mvc/model/row.zep.c +++ b/ext/phalcon/mvc/model/row.zep.c @@ -101,7 +101,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Row, offsetGet) { * Rows cannot be changed. It has only been implemented to meet the definition of the ArrayAccess interface * * @param string|int index - * @param Phalcon\Mvc\ModelInterface value + * @param \Phalcon\Mvc\ModelInterface value */ PHP_METHOD(Phalcon_Mvc_Model_Row, offsetSet) { @@ -210,7 +210,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Row, toArray) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 23, this_ptr); + ZEPHIR_RETURN_CALL_FUNCTION("get_object_vars", NULL, 24, this_ptr); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/mvc/model/transaction.zep.c b/ext/phalcon/mvc/model/transaction.zep.c index 71e55d30a2b..23b58272e08 100644 --- a/ext/phalcon/mvc/model/transaction.zep.c +++ b/ext/phalcon/mvc/model/transaction.zep.c @@ -83,7 +83,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_Transaction) { /** * Phalcon\Mvc\Model\Transaction constructor * - * @param Phalcon\DiInterface $ependencyInjector + * @param \Phalcon\DiInterface $ependencyInjector * @param boolean autoBegin * @param string service */ @@ -248,7 +248,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Transaction, rollback) { ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_mvc_model_transaction_failed_ce); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackRecord"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 360, rollbackMessage, _5); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 353, rollbackMessage, _5); zephir_check_call_status(); zephir_throw_exception_debug(_0, "phalcon/mvc/model/transaction.zep", 160 TSRMLS_CC); ZEPHIR_MM_RESTORE(); @@ -270,7 +270,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Transaction, getConnection) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackOnAbort"), PH_NOISY_CC); if (zephir_is_true(_0)) { - ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 361); + ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 354); zephir_check_call_status(); if (zephir_is_true(_1)) { ZEPHIR_INIT_VAR(_2); diff --git a/ext/phalcon/mvc/model/transaction/manager.zep.c b/ext/phalcon/mvc/model/transaction/manager.zep.c index 6258406d207..79235e84402 100644 --- a/ext/phalcon/mvc/model/transaction/manager.zep.c +++ b/ext/phalcon/mvc/model/transaction/manager.zep.c @@ -259,7 +259,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, get) { ZEPHIR_INIT_VAR(_3); ZVAL_STRING(_3, "rollbackPendent", 1); zephir_array_fast_append(_2, _3); - ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 362, _2); + ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 355, _2); zephir_check_call_status(); } zephir_update_property_this(this_ptr, SL("_initialized"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); @@ -321,9 +321,9 @@ PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, getOrCreateTransaction) { ZEPHIR_INIT_VAR(transaction); object_init_ex(transaction, phalcon_mvc_model_transaction_ce); _5 = zephir_fetch_nproperty_this(this_ptr, SL("_service"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 363, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5); + ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 356, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 364, this_ptr); + ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 357, this_ptr); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_transactions"), transaction TSRMLS_CC); RETURN_ON_FAILURE(zephir_property_incr(this_ptr, SL("_number") TSRMLS_CC)); diff --git a/ext/phalcon/mvc/model/validator/email.zep.c b/ext/phalcon/mvc/model/validator/email.zep.c index 1310b0b385c..ead2b41264c 100644 --- a/ext/phalcon/mvc/model/validator/email.zep.c +++ b/ext/phalcon/mvc/model/validator/email.zep.c @@ -94,7 +94,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Email, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 274); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_0); @@ -109,7 +109,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Email, validate) { ZEPHIR_INIT_VAR(_5); zephir_create_array(_5, 1, 0 TSRMLS_CC); zephir_array_update_string(&_5, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, _5); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, _5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Email", ZEPHIR_TEMP_PARAM_COPY); diff --git a/ext/phalcon/mvc/model/validator/exclusionin.zep.c b/ext/phalcon/mvc/model/validator/exclusionin.zep.c index 562cd3c1d55..bd30b607be7 100644 --- a/ext/phalcon/mvc/model/validator/exclusionin.zep.c +++ b/ext/phalcon/mvc/model/validator/exclusionin.zep.c @@ -129,7 +129,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Exclusionin, validate) { ZEPHIR_INIT_NVAR(_0); zephir_fast_join_str(_0, SL(", "), domain TSRMLS_CC); zephir_array_update_string(&_4, SL(":domain"), &_0, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Exclusion", ZEPHIR_TEMP_PARAM_COPY); diff --git a/ext/phalcon/mvc/model/validator/inclusionin.zep.c b/ext/phalcon/mvc/model/validator/inclusionin.zep.c index 4f12dea9dce..3e3358b4132 100644 --- a/ext/phalcon/mvc/model/validator/inclusionin.zep.c +++ b/ext/phalcon/mvc/model/validator/inclusionin.zep.c @@ -131,7 +131,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Inclusionin, validate) { zephir_check_temp_parameter(_0); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 365, value, domain, strict); + ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 358, value, domain, strict); zephir_check_call_status(); if (!(zephir_is_true(_5))) { ZEPHIR_INIT_NVAR(_0); @@ -149,7 +149,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Inclusionin, validate) { ZEPHIR_INIT_NVAR(_0); zephir_fast_join_str(_0, SL(", "), domain TSRMLS_CC); zephir_array_update_string(&_6, SL(":domain"), &_0, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 53, message, _6); + ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 54, message, _6); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Inclusion", ZEPHIR_TEMP_PARAM_COPY); diff --git a/ext/phalcon/mvc/model/validator/ip.zep.c b/ext/phalcon/mvc/model/validator/ip.zep.c index 0b864431c2f..afb6bf89221 100644 --- a/ext/phalcon/mvc/model/validator/ip.zep.c +++ b/ext/phalcon/mvc/model/validator/ip.zep.c @@ -148,7 +148,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Ip, validate) { zephir_array_update_string(&options, SL("flags"), &_6, PH_COPY | PH_SEPARATE); ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, 275); - ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 191, value, &_5, options); + ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 192, value, &_5, options); zephir_check_call_status(); if (!(zephir_is_true(_7))) { ZEPHIR_INIT_NVAR(_0); @@ -162,7 +162,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Ip, validate) { ZEPHIR_INIT_NVAR(_4); zephir_create_array(_4, 1, 0 TSRMLS_CC); zephir_array_update_string(&_4, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "IP", ZEPHIR_TEMP_PARAM_COPY); diff --git a/ext/phalcon/mvc/model/validator/numericality.zep.c b/ext/phalcon/mvc/model/validator/numericality.zep.c index 6bc5d51f0a8..2d739db690e 100644 --- a/ext/phalcon/mvc/model/validator/numericality.zep.c +++ b/ext/phalcon/mvc/model/validator/numericality.zep.c @@ -106,7 +106,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Numericality, validate) { ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 1, 0 TSRMLS_CC); zephir_array_update_string(&_3, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, _3); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Numericality", ZEPHIR_TEMP_PARAM_COPY); diff --git a/ext/phalcon/mvc/model/validator/presenceof.zep.c b/ext/phalcon/mvc/model/validator/presenceof.zep.c index 11a9295d1ce..ec7ce451037 100644 --- a/ext/phalcon/mvc/model/validator/presenceof.zep.c +++ b/ext/phalcon/mvc/model/validator/presenceof.zep.c @@ -104,7 +104,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_PresenceOf, validate) { ZEPHIR_INIT_VAR(_3); zephir_create_array(_3, 1, 0 TSRMLS_CC); zephir_array_update_string(&_3, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, _3); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, _3); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "PresenceOf", ZEPHIR_TEMP_PARAM_COPY); diff --git a/ext/phalcon/mvc/model/validator/regex.zep.c b/ext/phalcon/mvc/model/validator/regex.zep.c index 0f688be1f9b..a1f17fa3902 100644 --- a/ext/phalcon/mvc/model/validator/regex.zep.c +++ b/ext/phalcon/mvc/model/validator/regex.zep.c @@ -133,7 +133,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Regex, validate) { ZEPHIR_INIT_VAR(_6); zephir_create_array(_6, 1, 0 TSRMLS_CC); zephir_array_update_string(&_6, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 53, message, _6); + ZEPHIR_CALL_FUNCTION(&_7, "strtr", NULL, 54, message, _6); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_5); ZVAL_STRING(_5, "Regex", ZEPHIR_TEMP_PARAM_COPY); diff --git a/ext/phalcon/mvc/model/validator/stringlength.zep.c b/ext/phalcon/mvc/model/validator/stringlength.zep.c index 8f216356fe1..ba089b88786 100644 --- a/ext/phalcon/mvc/model/validator/stringlength.zep.c +++ b/ext/phalcon/mvc/model/validator/stringlength.zep.c @@ -118,7 +118,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) { RETURN_MM_BOOL(1); } if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value); + ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 359, value); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(length); @@ -144,7 +144,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) { zephir_create_array(_4, 2, 0 TSRMLS_CC); zephir_array_update_string(&_4, SL(":field"), &field, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL(":max"), &maximum, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "TooLong", ZEPHIR_TEMP_PARAM_COPY); @@ -174,7 +174,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) { zephir_create_array(_4, 2, 0 TSRMLS_CC); zephir_array_update_string(&_4, SL(":field"), &field, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL(":min"), &minimum, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 53, message, _4); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", &_6, 54, message, _4); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "TooShort", ZEPHIR_TEMP_PARAM_COPY); diff --git a/ext/phalcon/mvc/model/validator/uniqueness.zep.c b/ext/phalcon/mvc/model/validator/uniqueness.zep.c index 84c87ea1e19..05f03abdfe7 100644 --- a/ext/phalcon/mvc/model/validator/uniqueness.zep.c +++ b/ext/phalcon/mvc/model/validator/uniqueness.zep.c @@ -284,7 +284,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) { ZVAL_STRING(message, "Value of field: ':field' is already present in another record", 1); } } - ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_8, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_18); ZVAL_STRING(_18, "Unique", ZEPHIR_TEMP_PARAM_COPY); diff --git a/ext/phalcon/mvc/model/validator/url.zep.c b/ext/phalcon/mvc/model/validator/url.zep.c index 8e65df396c1..7008417e89f 100644 --- a/ext/phalcon/mvc/model/validator/url.zep.c +++ b/ext/phalcon/mvc/model/validator/url.zep.c @@ -95,7 +95,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Url, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 273); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_0); @@ -110,7 +110,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Url, validate) { ZEPHIR_INIT_VAR(_5); zephir_create_array(_5, 1, 0 TSRMLS_CC); zephir_array_update_string(&_5, SL(":field"), &field, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, _5); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, _5); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "Url", ZEPHIR_TEMP_PARAM_COPY); diff --git a/ext/phalcon/mvc/model/validatorinterface.zep.c b/ext/phalcon/mvc/model/validatorinterface.zep.c index 045a2a9f060..1fabd23e94e 100644 --- a/ext/phalcon/mvc/model/validatorinterface.zep.c +++ b/ext/phalcon/mvc/model/validatorinterface.zep.c @@ -35,7 +35,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ValidatorInterface, getMessages); /** * Executes the validator * - * @param Phalcon\Mvc\ModelInterface record + * @param \Phalcon\Mvc\ModelInterface record * @return boolean */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ValidatorInterface, validate); diff --git a/ext/phalcon/mvc/modelinterface.zep.c b/ext/phalcon/mvc/modelinterface.zep.c index 05472e1a30d..8aac39640cb 100644 --- a/ext/phalcon/mvc/modelinterface.zep.c +++ b/ext/phalcon/mvc/modelinterface.zep.c @@ -94,32 +94,32 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_ModelInterface, getDirtyState); /** * Assigns values to a model from an array * - * @param Phalcon\Mvc\Model object + * @param \Phalcon\Mvc\Model object * @param array data * @param array columnMap - * @return Phalcon\Mvc\Model + * @return \Phalcon\Mvc\Model */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_ModelInterface, assign); /** * Assigns values to a model from an array returning a new model * - * @param Phalcon\Mvc\Model base + * @param \Phalcon\Mvc\Model base * @param array data * @param array columnMap * @param int dirtyState * @param boolean keepSnapshots - * @return Phalcon\Mvc\Model result + * @return \Phalcon\Mvc\Model result */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_ModelInterface, cloneResultMap); /** * Assigns values to a model from an array returning a new model * - * @param Phalcon\Mvc\ModelInterface base + * @param \Phalcon\Mvc\ModelInterface base * @param array data * @param int dirtyState - * @return Phalcon\Mvc\ModelInterface + * @return \Phalcon\Mvc\ModelInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_ModelInterface, cloneResult); @@ -144,15 +144,15 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_ModelInterface, find); * Allows to query the first record that match the specified conditions * * @param array parameters - * @return Phalcon\Mvc\ModelInterface + * @return \Phalcon\Mvc\ModelInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_ModelInterface, findFirst); /** * Create a criteria for a especific model * - * @param Phalcon\DiInterface dependencyInjector - * @return Phalcon\Mvc\Model\CriteriaInterface + * @param \Phalcon\DiInterface dependencyInjector + * @return \Phalcon\Mvc\Model\CriteriaInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_ModelInterface, query); @@ -226,9 +226,9 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_ModelInterface, appendMessage); ZEPHIR_DOC_METHOD(Phalcon_Mvc_ModelInterface, validationHasFailed); /** - * Returns all the validation messages + * Returns array of validation messages * - * @return Phalcon\Mvc\Model\MessageInterface[] + * @return \Phalcon\Mvc\Model\MessageInterface[] */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_ModelInterface, getMessages); @@ -291,7 +291,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_ModelInterface, skipOperation); * * @param string alias * @param array arguments - * @return Phalcon\Mvc\Model\ResultsetInterface + * @return \Phalcon\Mvc\Model\ResultsetInterface */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_ModelInterface, getRelated); diff --git a/ext/phalcon/mvc/router.zep.c b/ext/phalcon/mvc/router.zep.c index 76aadef35b3..33c3b9115f3 100644 --- a/ext/phalcon/mvc/router.zep.c +++ b/ext/phalcon/mvc/router.zep.c @@ -142,7 +142,7 @@ PHP_METHOD(Phalcon_Mvc_Router, __construct) { add_assoc_long_ex(_1, SS("controller"), 1); ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "#^/([\\w0-9\\_\\-]+)[/]{0,1}$#u", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 74, _2, _1); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_3, 76, _2, _1); zephir_check_temp_parameter(_2); zephir_check_call_status(); zephir_array_append(&routes, _0, PH_SEPARATE, "phalcon/mvc/router.zep", 120); @@ -155,7 +155,7 @@ PHP_METHOD(Phalcon_Mvc_Router, __construct) { add_assoc_long_ex(_4, SS("params"), 3); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "#^/([\\w0-9\\_\\-]+)/([\\w0-9\\.\\_]+)(/.*)*$#u", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 74, _5, _4); + ZEPHIR_CALL_METHOD(NULL, _2, "__construct", &_3, 76, _5, _4); zephir_check_temp_parameter(_5); zephir_check_call_status(); zephir_array_append(&routes, _2, PH_SEPARATE, "phalcon/mvc/router.zep", 126); @@ -742,7 +742,7 @@ PHP_METHOD(Phalcon_Mvc_Router, handle) { ZEPHIR_OBS_VAR(notFoundPaths); zephir_read_property_this(¬FoundPaths, this_ptr, SL("_notFoundPaths"), PH_NOISY_CC); if (Z_TYPE_P(notFoundPaths) != IS_NULL) { - ZEPHIR_CALL_CE_STATIC(&parts, phalcon_mvc_router_route_ce, "getroutepaths", &_20, 75, notFoundPaths); + ZEPHIR_CALL_CE_STATIC(&parts, phalcon_mvc_router_route_ce, "getroutepaths", &_20, 77, notFoundPaths); zephir_check_call_status(); ZEPHIR_INIT_NVAR(routeFound); ZVAL_BOOL(routeFound, 1); @@ -866,7 +866,7 @@ PHP_METHOD(Phalcon_Mvc_Router, add) { ZEPHIR_INIT_VAR(route); object_init_ex(route, phalcon_mvc_router_route_ce); - ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 74, pattern, paths, httpMethods); + ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 76, pattern, paths, httpMethods); zephir_check_call_status(); do { if (ZEPHIR_IS_LONG(position, 1)) { diff --git a/ext/phalcon/mvc/router/annotations.zep.c b/ext/phalcon/mvc/router/annotations.zep.c index 9677e5f25af..0e5023e1445 100644 --- a/ext/phalcon/mvc/router/annotations.zep.c +++ b/ext/phalcon/mvc/router/annotations.zep.c @@ -326,7 +326,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Annotations, handle) { } zephir_update_property_this(this_ptr, SL("_processed"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); } - ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 367, realUri); + ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 360, realUri); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -371,13 +371,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Annotations, processControllerAnnotation) { } /** - * Checks for annotations in the public methods of the controller - * - * @param string module - * @param string namespaceName - * @param string controller - * @param string action - * @param Phalcon\Annotations\Annotation annotation + * Checks for annotations in the public methods of the controller */ PHP_METHOD(Phalcon_Mvc_Router_Annotations, processActionAnnotation) { @@ -553,7 +547,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Annotations, processActionAnnotation) { zephir_check_temp_parameter(_3); zephir_check_call_status(); if (Z_TYPE_P(converts) == IS_ARRAY) { - zephir_is_iterable(converts, &_5, &_4, 0, 0, "phalcon/mvc/router/annotations.zep", 360); + zephir_is_iterable(converts, &_5, &_4, 0, 0, "phalcon/mvc/router/annotations.zep", 354); for ( ; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS ; zephir_hash_move_forward_ex(_5, &_4) @@ -570,7 +564,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Annotations, processActionAnnotation) { zephir_check_temp_parameter(_3); zephir_check_call_status(); if (Z_TYPE_P(converts) == IS_ARRAY) { - zephir_is_iterable(converts, &_9, &_8, 0, 0, "phalcon/mvc/router/annotations.zep", 370); + zephir_is_iterable(converts, &_9, &_8, 0, 0, "phalcon/mvc/router/annotations.zep", 364); for ( ; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS ; zephir_hash_move_forward_ex(_9, &_8) diff --git a/ext/phalcon/mvc/router/group.zep.c b/ext/phalcon/mvc/router/group.zep.c index a15ae5de74d..4baff7d60a2 100644 --- a/ext/phalcon/mvc/router/group.zep.c +++ b/ext/phalcon/mvc/router/group.zep.c @@ -279,7 +279,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Group, add) { * * @param string pattern * @param string/array paths - * @return Phalcon\Mvc\Router\Route + * @return \Phalcon\Mvc\Router\Route */ PHP_METHOD(Phalcon_Mvc_Router_Group, addGet) { @@ -320,7 +320,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Group, addGet) { * * @param string pattern * @param string/array paths - * @return Phalcon\Mvc\Router\Route + * @return \Phalcon\Mvc\Router\Route */ PHP_METHOD(Phalcon_Mvc_Router_Group, addPost) { @@ -361,7 +361,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Group, addPost) { * * @param string pattern * @param string/array paths - * @return Phalcon\Mvc\Router\Route + * @return \Phalcon\Mvc\Router\Route */ PHP_METHOD(Phalcon_Mvc_Router_Group, addPut) { @@ -402,7 +402,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Group, addPut) { * * @param string pattern * @param string/array paths - * @return Phalcon\Mvc\Router\Route + * @return \Phalcon\Mvc\Router\Route */ PHP_METHOD(Phalcon_Mvc_Router_Group, addPatch) { @@ -443,7 +443,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Group, addPatch) { * * @param string pattern * @param string/array paths - * @return Phalcon\Mvc\Router\Route + * @return \Phalcon\Mvc\Router\Route */ PHP_METHOD(Phalcon_Mvc_Router_Group, addDelete) { @@ -484,7 +484,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Group, addDelete) { * * @param string pattern * @param string/array paths - * @return Phalcon\Mvc\Router\Route + * @return \Phalcon\Mvc\Router\Route */ PHP_METHOD(Phalcon_Mvc_Router_Group, addOptions) { @@ -525,7 +525,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Group, addOptions) { * * @param string pattern * @param string/array paths - * @return Phalcon\Mvc\Router\Route + * @return \Phalcon\Mvc\Router\Route */ PHP_METHOD(Phalcon_Mvc_Router_Group, addHead) { @@ -613,7 +613,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Group, _addRoute) { zephir_read_property_this(&defaultPaths, this_ptr, SL("_paths"), PH_NOISY_CC); if (Z_TYPE_P(defaultPaths) == IS_ARRAY) { if (Z_TYPE_P(paths) == IS_STRING) { - ZEPHIR_CALL_CE_STATIC(&processedPaths, phalcon_mvc_router_route_ce, "getroutepaths", &_0, 75, paths); + ZEPHIR_CALL_CE_STATIC(&processedPaths, phalcon_mvc_router_route_ce, "getroutepaths", &_0, 77, paths); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(processedPaths, paths); @@ -632,10 +632,10 @@ PHP_METHOD(Phalcon_Mvc_Router_Group, _addRoute) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_prefix"), PH_NOISY_CC); ZEPHIR_INIT_VAR(_2); ZEPHIR_CONCAT_VV(_2, _1, pattern); - ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 74, _2, mergedPaths, httpMethods); + ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 76, _2, mergedPaths, httpMethods); zephir_check_call_status(); zephir_update_property_array_append(this_ptr, SL("_routes"), route TSRMLS_CC); - ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 368, this_ptr); + ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 361, this_ptr); zephir_check_call_status(); RETURN_CCTOR(route); diff --git a/ext/phalcon/mvc/router/groupinterface.zep.c b/ext/phalcon/mvc/router/groupinterface.zep.c index 3851ec4faf4..fd73e8af5bf 100644 --- a/ext/phalcon/mvc/router/groupinterface.zep.c +++ b/ext/phalcon/mvc/router/groupinterface.zep.c @@ -93,7 +93,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Router_GroupInterface, getBeforeMatch); * Set common paths for all the routes in the group * * @param array paths - * @return Phalcon\Mvc\Router\Group + * @return \Phalcon\Mvc\Router\Group */ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Router_GroupInterface, setPaths); diff --git a/ext/phalcon/mvc/url.zep.c b/ext/phalcon/mvc/url.zep.c index fe1ff0a43eb..ae2de236bde 100644 --- a/ext/phalcon/mvc/url.zep.c +++ b/ext/phalcon/mvc/url.zep.c @@ -265,11 +265,11 @@ PHP_METHOD(Phalcon_Mvc_Url, getBasePath) { */ PHP_METHOD(Phalcon_Mvc_Url, get) { - unsigned char _10, _12; + unsigned char _10, _12, _15; int ZEPHIR_LAST_CALL_STATUS; - zend_bool _0, _1, _11; + zend_bool _0, _1, _11, _13, _14; zval *strUri = NULL, *_9 = NULL; - zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_13; + zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_16; ZEPHIR_MM_GROW(); zephir_fetch_params(1, 0, 4, &uri, &args, &local, &baseUri); @@ -386,19 +386,33 @@ PHP_METHOD(Phalcon_Mvc_Url, get) { _12 = ZEPHIR_STRING_OFFSET(strUri, 1); _11 = _12 != '/'; } - ZEPHIR_INIT_NVAR(uri); if (_11) { ZEPHIR_SINIT_NVAR(_4); ZVAL_LONG(&_4, 1); ZEPHIR_INIT_NVAR(_3); zephir_substr(_3, strUri, 1 , 0, ZEPHIR_SUBSTR_NO_LENGTH); + ZEPHIR_INIT_NVAR(uri); ZEPHIR_CONCAT_VV(uri, baseUri, _3); } else { - ZEPHIR_CONCAT_VV(uri, baseUri, strUri); + _13 = ZEPHIR_IS_STRING(baseUri, "/"); + if (_13) { + _13 = zephir_fast_strlen_ev(strUri) == 1; + } + _14 = _13; + if (_14) { + _15 = ZEPHIR_STRING_OFFSET(strUri, 0); + _14 = _15 == '/'; + } + if (_14) { + ZEPHIR_CPY_WRT(uri, baseUri); + } else { + ZEPHIR_INIT_NVAR(uri); + ZEPHIR_CONCAT_VV(uri, baseUri, strUri); + } } } if (zephir_is_true(args)) { - ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 369, args); + ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 362, args); zephir_check_call_status(); _0 = Z_TYPE_P(queryString) == IS_STRING; if (_0) { @@ -414,9 +428,9 @@ PHP_METHOD(Phalcon_Mvc_Url, get) { ZEPHIR_CONCAT_SV(_7, "&", queryString); zephir_concat_self(&uri, _7 TSRMLS_CC); } else { - ZEPHIR_INIT_VAR(_13); - ZEPHIR_CONCAT_SV(_13, "?", queryString); - zephir_concat_self(&uri, _13 TSRMLS_CC); + ZEPHIR_INIT_VAR(_16); + ZEPHIR_CONCAT_SV(_16, "?", queryString); + zephir_concat_self(&uri, _16 TSRMLS_CC); } } } diff --git a/ext/phalcon/mvc/view.zep.c b/ext/phalcon/mvc/view.zep.c index ccfaf7524d6..4c011694c55 100644 --- a/ext/phalcon/mvc/view.zep.c +++ b/ext/phalcon/mvc/view.zep.c @@ -164,7 +164,6 @@ PHP_METHOD(Phalcon_Mvc_View, getCurrentRenderLevel) { } /** - * @var array */ PHP_METHOD(Phalcon_Mvc_View, getRegisteredEngines) { @@ -366,7 +365,7 @@ PHP_METHOD(Phalcon_Mvc_View, setRenderLevel) { * * * @param int|array level - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ PHP_METHOD(Phalcon_Mvc_View, disableLevel) { @@ -456,7 +455,7 @@ PHP_METHOD(Phalcon_Mvc_View, getLayout) { * Sets a template before the controller layout * * @param string|array templateBefore - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ PHP_METHOD(Phalcon_Mvc_View, setTemplateBefore) { @@ -495,7 +494,7 @@ PHP_METHOD(Phalcon_Mvc_View, cleanTemplateBefore) { * Sets a "template after" controller layout * * @param string|array templateAfter - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ PHP_METHOD(Phalcon_Mvc_View, setTemplateAfter) { @@ -539,7 +538,7 @@ PHP_METHOD(Phalcon_Mvc_View, cleanTemplateAfter) { * * @param string key * @param mixed value - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ PHP_METHOD(Phalcon_Mvc_View, setParamToView) { @@ -576,7 +575,7 @@ PHP_METHOD(Phalcon_Mvc_View, setParamToView) { * * @param array params * @param boolean merge - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ PHP_METHOD(Phalcon_Mvc_View, setVars) { @@ -622,7 +621,7 @@ PHP_METHOD(Phalcon_Mvc_View, setVars) { * * @param string key * @param mixed value - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ PHP_METHOD(Phalcon_Mvc_View, setVar) { @@ -742,7 +741,7 @@ PHP_METHOD(Phalcon_Mvc_View, start) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_content"), ZEPHIR_GLOBAL(global_null) TSRMLS_CC); RETURN_THIS(); @@ -774,7 +773,7 @@ PHP_METHOD(Phalcon_Mvc_View, _loadTemplateEngines) { if (Z_TYPE_P(registeredEngines) != IS_ARRAY) { ZEPHIR_INIT_VAR(_1); object_init_ex(_1, phalcon_mvc_view_engine_php_ce); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 370, this_ptr, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 363, this_ptr, dependencyInjector); zephir_check_call_status(); zephir_array_update_string(&engines, SL(".phtml"), &_1, PH_COPY | PH_SEPARATE); } else { @@ -833,7 +832,7 @@ PHP_METHOD(Phalcon_Mvc_View, _loadTemplateEngines) { * @param string viewPath * @param boolean silence * @param boolean mustClean - * @param Phalcon\Cache\BackendInterface $cache + * @param \Phalcon\Cache\BackendInterface $cache */ PHP_METHOD(Phalcon_Mvc_View, _engineRender) { @@ -1117,7 +1116,7 @@ PHP_METHOD(Phalcon_Mvc_View, render) { zephir_update_property_this(this_ptr, SL("_currentRenderLevel"), _0 TSRMLS_CC); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_disabled"), PH_NOISY_CC); if (!ZEPHIR_IS_FALSE(_0)) { - ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 117); + ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 119); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_content"), _1 TSRMLS_CC); RETURN_MM_BOOL(0); @@ -1177,7 +1176,7 @@ PHP_METHOD(Phalcon_Mvc_View, render) { RETURN_MM_BOOL(0); } } - ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 117); + ZEPHIR_CALL_FUNCTION(&_1, "ob_get_contents", &_2, 119); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_content"), _1 TSRMLS_CC); mustClean = 1; @@ -1318,7 +1317,7 @@ PHP_METHOD(Phalcon_Mvc_View, render) { * * * @param string|array renderView - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ PHP_METHOD(Phalcon_Mvc_View, pick) { @@ -1394,11 +1393,11 @@ PHP_METHOD(Phalcon_Mvc_View, getPartial) { } - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, this_ptr, "partial", NULL, 0, partialPath, params); zephir_check_call_status(); - ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 291); + ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 284); zephir_check_call_status(); RETURN_MM(); @@ -1552,7 +1551,7 @@ PHP_METHOD(Phalcon_Mvc_View, getRender) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, view, "render", NULL, 0, controllerName, actionName); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); ZEPHIR_RETURN_CALL_METHOD(view, "getcontent", NULL, 0); zephir_check_call_status(); @@ -1569,7 +1568,7 @@ PHP_METHOD(Phalcon_Mvc_View, finish) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); RETURN_THIS(); @@ -1664,7 +1663,7 @@ PHP_METHOD(Phalcon_Mvc_View, getCache) { * * * @param boolean|array options - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ PHP_METHOD(Phalcon_Mvc_View, cache) { diff --git a/ext/phalcon/mvc/view/engine/php.zep.c b/ext/phalcon/mvc/view/engine/php.zep.c index 76c29eeae33..f1910edbe49 100644 --- a/ext/phalcon/mvc/view/engine/php.zep.c +++ b/ext/phalcon/mvc/view/engine/php.zep.c @@ -70,7 +70,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Php, render) { if (mustClean == 1) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371); + ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 364); zephir_check_call_status(); } if (Z_TYPE_P(params) == IS_ARRAY) { @@ -92,7 +92,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Php, render) { } if (mustClean == 1) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 117); + ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 119); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _4, "setcontent", NULL, 0, _5); zephir_check_call_status(); diff --git a/ext/phalcon/mvc/view/engine/volt.zep.c b/ext/phalcon/mvc/view/engine/volt.zep.c index 1c698719a4c..c97dd984f09 100644 --- a/ext/phalcon/mvc/view/engine/volt.zep.c +++ b/ext/phalcon/mvc/view/engine/volt.zep.c @@ -89,18 +89,18 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, getCompiler) { ZEPHIR_INIT_NVAR(compiler); object_init_ex(compiler, phalcon_mvc_view_engine_volt_compiler_ce); _0 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 372, _0); + ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 365, _0); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC); ZEPHIR_CPY_WRT(dependencyInjector, _1); if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) { - ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 373, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 366, dependencyInjector); zephir_check_call_status(); } ZEPHIR_OBS_VAR(options); zephir_read_property_this(&options, this_ptr, SL("_options"), PH_NOISY_CC); if (Z_TYPE_P(options) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 374, options); + ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 367, options); zephir_check_call_status(); } zephir_update_property_this(this_ptr, SL("_compiler"), compiler TSRMLS_CC); @@ -143,7 +143,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) { if (mustClean) { - ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371); + ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 364); zephir_check_call_status(); } ZEPHIR_CALL_METHOD(&compiler, this_ptr, "getcompiler", NULL, 0); @@ -171,7 +171,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) { } if (mustClean) { _4 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC); - ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 117); + ZEPHIR_CALL_FUNCTION(&_5, "ob_get_contents", NULL, 119); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, _4, "setcontent", NULL, 0, _5); zephir_check_call_status(); @@ -205,7 +205,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, length) { ZVAL_LONG(length, zephir_fast_count_int(item TSRMLS_CC)); } else { if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, item); + ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 359, item); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(length); @@ -234,7 +234,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, isIncluded) { } if (Z_TYPE_P(haystack) == IS_STRING) { if ((zephir_function_exists_ex(SS("mb_strpos") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 375, haystack, needle); + ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 368, haystack, needle); zephir_check_call_status(); RETURN_MM_BOOL(!ZEPHIR_IS_FALSE_IDENTICAL(_0)); } @@ -290,7 +290,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) { _0 = ZEPHIR_IS_STRING(to, "utf8"); } if (_0) { - ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 376, text); + ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 369, text); zephir_check_call_status(); RETURN_MM(); } @@ -299,17 +299,17 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) { _1 = ZEPHIR_IS_STRING(from, "utf8"); } if (_1) { - ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 377, text); + ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 370, text); zephir_check_call_status(); RETURN_MM(); } if ((zephir_function_exists_ex(SS("mb_convert_encoding") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, text, from, to); + ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 181, text, from, to); zephir_check_call_status(); RETURN_MM(); } if ((zephir_function_exists_ex(SS("iconv") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 378, from, to, text); + ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 371, from, to, text); zephir_check_call_status(); RETURN_MM(); } @@ -383,7 +383,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) { if (Z_TYPE_P(value) == IS_ARRAY) { ZEPHIR_SINIT_VAR(_5); ZVAL_LONG(&_5, start); - ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 379, value, &_5, length); + ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 372, value, &_5, length); zephir_check_call_status(); RETURN_MM(); } @@ -391,13 +391,13 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) { if (Z_TYPE_P(length) != IS_NULL) { ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, start); - ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5, length); + ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 373, value, &_5, length); zephir_check_call_status(); RETURN_MM(); } ZEPHIR_SINIT_NVAR(_5); ZVAL_LONG(&_5, start); - ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5); + ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 373, value, &_5); zephir_check_call_status(); RETURN_MM(); } @@ -430,7 +430,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, sort) { Z_SET_ISREF_P(value); - ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 381, value); + ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 374, value); Z_UNSET_ISREF_P(value); zephir_check_call_status(); RETURN_CTOR(value); @@ -477,7 +477,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, callMacro) { ZEPHIR_MM_RESTORE(); return; } - ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 382, macro, arguments); + ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 375, macro, arguments); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/mvc/view/engine/volt/compiler.zep.c b/ext/phalcon/mvc/view/engine/volt/compiler.zep.c index 869c971f7f4..25b96276028 100644 --- a/ext/phalcon/mvc/view/engine/volt/compiler.zep.c +++ b/ext/phalcon/mvc/view/engine/volt/compiler.zep.c @@ -320,7 +320,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, addExtension) { if (Z_TYPE_P(extension) != IS_OBJECT) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The extension is not valid", "phalcon/mvc/view/engine/volt/compiler.zep", 198); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "The extension is not valid", "phalcon/mvc/view/engine/volt/compiler.zep", 198); return; } if ((zephir_method_exists_ex(extension, SS("initialize") TSRMLS_CC) == SUCCESS)) { @@ -481,7 +481,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, getUniquePrefix) { } } if (Z_TYPE_P(prefix) != IS_STRING) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The unique compilation prefix is invalid", "phalcon/mvc/view/engine/volt/compiler.zep", 292); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "The unique compilation prefix is invalid", "phalcon/mvc/view/engine/volt/compiler.zep", 292); return; } RETURN_CCTOR(prefix); @@ -545,7 +545,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) { } } } else { - ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 383, left); + ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 376, left); zephir_check_call_status(); ZEPHIR_OBS_VAR(leftType); zephir_array_fetch_string(&leftType, left, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 339 TSRMLS_CC); @@ -567,7 +567,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) { zephir_array_fetch_string(&_7, right, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 352 TSRMLS_CC); zephir_concat_self(&exprCode, _7 TSRMLS_CC); } else { - ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 383, right); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 376, right); zephir_check_call_status(); zephir_concat_self(&exprCode, _1 TSRMLS_CC); } @@ -580,10 +580,10 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) { */ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { - zend_bool _7; + zend_bool _6; zephir_fcall_cache_entry *_0 = NULL; int ZEPHIR_LAST_CALL_STATUS; - zval *expr_param = NULL, *code = NULL, *funcArguments = NULL, *arguments = NULL, *nameExpr, *nameType, *name, *extensions, *functions, *definition, *extendedBlocks, *block, *currentBlock, *exprLevel, *escapedCode = NULL, *method = NULL, *arrayHelpers = NULL, *className, *_2 = NULL, *_3, *_4, *_5 = NULL, *_6, *_8 = NULL; + zval *expr_param = NULL, *code = NULL, *funcArguments = NULL, *arguments = NULL, *nameExpr, *nameType, *name, *extensions, *functions, *definition, *extendedBlocks, *block, *currentBlock, *exprLevel, *escapedCode = NULL, *method = NULL, *arrayHelpers = NULL, *className, *_2 = NULL, *_3, *_4, *_5, *_7 = NULL; zval *expr = NULL, *_1 = NULL; ZEPHIR_MM_GROW(); @@ -599,7 +599,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { ZVAL_NULL(funcArguments); ZEPHIR_OBS_NVAR(funcArguments); if (zephir_array_isset_string_fetch(&funcArguments, expr, SS("arguments"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 383, funcArguments); + ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 376, funcArguments); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(arguments); @@ -622,7 +622,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { zephir_array_fast_append(_1, funcArguments); ZEPHIR_INIT_VAR(_2); ZVAL_STRING(_2, "compileFunction", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _2, _1); + ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 377, _2, _1); zephir_check_temp_parameter(_2); zephir_check_call_status(); if (Z_TYPE_P(code) == IS_STRING) { @@ -650,7 +650,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { } } ZEPHIR_INIT_NVAR(_2); - object_init_ex(_2, phalcon_mvc_view_exception_ce); + object_init_ex(_2, phalcon_mvc_view_engine_volt_exception_ce); zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 427 TSRMLS_CC); zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 427 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); @@ -662,16 +662,11 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { return; } } - _6 = zephir_fetch_nproperty_this(this_ptr, SL("_macros"), PH_NOISY_CC); - if (zephir_array_isset(_6, name)) { - ZEPHIR_CONCAT_SVSVS(return_value, "$this->callMacro('", name, "', array(", arguments, "))"); - RETURN_MM(); - } - _7 = ZEPHIR_IS_STRING(name, "get_content"); - if (!(_7)) { - _7 = ZEPHIR_IS_STRING(name, "content"); + _6 = ZEPHIR_IS_STRING(name, "get_content"); + if (!(_6)) { + _6 = ZEPHIR_IS_STRING(name, "content"); } - if (_7) { + if (_6) { RETURN_MM_STRING("$this->getContent()", 1); } if (ZEPHIR_IS_STRING(name, "partial")) { @@ -689,7 +684,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { ZEPHIR_OBS_VAR(exprLevel); zephir_read_property_this(&exprLevel, this_ptr, SL("_exprLevel"), PH_NOISY_CC); if (Z_TYPE_P(block) == IS_ARRAY) { - ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 385, block); + ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 378, block); zephir_check_call_status(); if (ZEPHIR_IS_LONG(exprLevel, 1)) { ZEPHIR_CPY_WRT(escapedCode, code); @@ -716,7 +711,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { } ZEPHIR_INIT_NVAR(_2); zephir_camelize(_2, name); - ZEPHIR_CALL_FUNCTION(&method, "lcfirst", NULL, 65, _2); + ZEPHIR_CALL_FUNCTION(&method, "lcfirst", NULL, 67, _2); zephir_check_call_status(); ZEPHIR_INIT_VAR(className); ZVAL_STRING(className, "Phalcon\\Tag", 1); @@ -782,21 +777,12 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) { ZEPHIR_CONCAT_SVS(return_value, "constant(", arguments, ")"); RETURN_MM(); } - ZEPHIR_INIT_NVAR(_2); - object_init_ex(_2, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC); - zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC); - ZEPHIR_INIT_LNVAR(_5); - ZEPHIR_CONCAT_SVSVSV(_5, "Undefined function '", name, "' in ", _3, " on line ", _4); - ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _5); - zephir_check_call_status(); - zephir_throw_exception_debug(_2, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC); - ZEPHIR_MM_RESTORE(); - return; + ZEPHIR_CONCAT_SVSVS(return_value, "$this->callMacro('", name, "', array(", arguments, "))"); + RETURN_MM(); } - ZEPHIR_CALL_METHOD(&_8, this_ptr, "expression", &_0, 383, nameExpr); + ZEPHIR_CALL_METHOD(&_7, this_ptr, "expression", &_0, 376, nameExpr); zephir_check_call_status(); - ZEPHIR_CONCAT_VSVS(return_value, _8, "(", arguments, ")"); + ZEPHIR_CONCAT_VSVS(return_value, _7, "(", arguments, ")"); RETURN_MM(); } @@ -821,10 +807,10 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) { ZEPHIR_OBS_VAR(type); - zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 586 TSRMLS_CC); + zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 579 TSRMLS_CC); if (ZEPHIR_IS_LONG(type, 265)) { ZEPHIR_OBS_VAR(name); - zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 593 TSRMLS_CC); + zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 586 TSRMLS_CC); if (ZEPHIR_IS_STRING(name, "empty")) { ZEPHIR_CONCAT_SVS(return_value, "empty(", left, ")"); RETURN_MM(); @@ -852,33 +838,33 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) { } if (ZEPHIR_IS_LONG(type, 350)) { ZEPHIR_OBS_VAR(testName); - zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 644 TSRMLS_CC); + zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 637 TSRMLS_CC); ZEPHIR_OBS_NVAR(name); if (zephir_array_isset_string_fetch(&name, testName, SS("value"), 0 TSRMLS_CC)) { if (ZEPHIR_IS_STRING(name, "divisibleby")) { - zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 648 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1); + zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 641 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, _1); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "(((", left, ") % (", _0, ")) == 0)"); RETURN_MM(); } if (ZEPHIR_IS_STRING(name, "sameas")) { - zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 655 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1); + zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 648 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, _1); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "(", left, ") === (", _0, ")"); RETURN_MM(); } if (ZEPHIR_IS_STRING(name, "type")) { - zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 662 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1); + zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 655 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, _1); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "gettype(", left, ") === (", _0, ")"); RETURN_MM(); } } } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, test); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 376, test); zephir_check_call_status(); ZEPHIR_CONCAT_VSV(return_value, left, " == ", _0); RETURN_MM(); @@ -907,28 +893,28 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { ZEPHIR_INIT_VAR(code); ZVAL_NULL(code); ZEPHIR_OBS_VAR(type); - zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 681 TSRMLS_CC); + zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 674 TSRMLS_CC); if (ZEPHIR_IS_LONG(type, 265)) { ZEPHIR_OBS_VAR(name); - zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 687 TSRMLS_CC); + zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 680 TSRMLS_CC); } else { if (!ZEPHIR_IS_LONG(type, 350)) { ZEPHIR_INIT_VAR(_0); - object_init_ex(_0, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC); - zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC); + object_init_ex(_0, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 688 TSRMLS_CC); + zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 688 TSRMLS_CC); ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SVSV(_3, "Unknown filter type in ", _1, " on line ", _2); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 688 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } ZEPHIR_OBS_VAR(functionName); - zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 698 TSRMLS_CC); + zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 691 TSRMLS_CC); ZEPHIR_OBS_NVAR(name); - zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 699 TSRMLS_CC); + zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 692 TSRMLS_CC); } ZEPHIR_INIT_VAR(funcArguments); ZVAL_NULL(funcArguments); @@ -938,9 +924,9 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { if (zephir_array_isset_string_fetch(&funcArguments, filter, SS("arguments"), 0 TSRMLS_CC)) { if (!ZEPHIR_IS_STRING(name, "default")) { ZEPHIR_OBS_VAR(file); - zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC); + zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 707 TSRMLS_CC); ZEPHIR_OBS_VAR(line); - zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC); + zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 707 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); zephir_create_array(_4, 3, 0 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); @@ -953,11 +939,11 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { zephir_array_update_string(&_4, SL("file"), &file, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("line"), &line, PH_COPY | PH_SEPARATE); Z_SET_ISREF_P(funcArguments); - ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 386, funcArguments, _4); + ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 379, funcArguments, _4); Z_UNSET_ISREF_P(funcArguments); zephir_check_call_status(); } - ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 383, funcArguments); + ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 376, funcArguments); zephir_check_call_status(); } else { ZEPHIR_CPY_WRT(arguments, left); @@ -972,7 +958,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { zephir_array_fast_append(_4, funcArguments); ZEPHIR_INIT_NVAR(_0); ZVAL_STRING(_0, "compileFilter", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _0, _4); + ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 377, _0, _4); zephir_check_temp_parameter(_0); zephir_check_call_status(); if (Z_TYPE_P(code) == IS_STRING) { @@ -1000,14 +986,14 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { } } ZEPHIR_INIT_NVAR(_0); - object_init_ex(_0, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC); - zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC); + object_init_ex(_0, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 770 TSRMLS_CC); + zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 770 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVSVSV(_3, "Invalid definition for user filter '", name, "' in ", _1, " on line ", _2); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 770 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -1129,14 +1115,14 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) { RETURN_MM(); } ZEPHIR_INIT_NVAR(_0); - object_init_ex(_0, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC); - zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC); + object_init_ex(_0, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 959 TSRMLS_CC); + zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 959 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVSVSV(_3, "Unknown filter \"", name, "\" in ", _1, " on line ", _2); ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3); zephir_check_call_status(); - zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC); + zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 959 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; @@ -1173,7 +1159,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { zephir_array_fast_append(_0, expr); ZEPHIR_INIT_NVAR(_1); ZVAL_STRING(_1, "resolveExpression", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 384, _1, _0); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 377, _1, _0); zephir_check_temp_parameter(_1); zephir_check_call_status(); if (Z_TYPE_P(exprCode) == IS_STRING) { @@ -1184,22 +1170,22 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { if (!(zephir_array_isset_string_fetch(&type, expr, SS("type"), 0 TSRMLS_CC))) { ZEPHIR_INIT_NVAR(items); array_init(items); - zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1007); + zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1000); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) ) { ZEPHIR_GET_HVALUE(singleExpr, _5); - zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1000 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 383, _6); + zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 993 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 376, _6); zephir_check_call_status(); ZEPHIR_OBS_NVAR(name); if (zephir_array_isset_string_fetch(&name, singleExpr, SS("name"), 0 TSRMLS_CC)) { ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSV(_8, "'", name, "' => ", singleExprCode); - zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1002); + zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 995); } else { - zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1004); + zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 997); } } ZEPHIR_INIT_NVAR(exprCode); @@ -1213,24 +1199,24 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } ZEPHIR_OBS_NVAR(left); if (zephir_array_isset_string_fetch(&left, expr, SS("left"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 383, left); + ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 376, left); zephir_check_call_status(); } if (ZEPHIR_IS_LONG(type, 311)) { - zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1030 TSRMLS_CC); + zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1023 TSRMLS_CC); ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvetest", &_10, 0, _6, leftCode); zephir_check_call_status(); break; } if (ZEPHIR_IS_LONG(type, 124)) { - zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1038 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 387, _11, leftCode); + zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1031 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 380, _11, leftCode); zephir_check_call_status(); break; } ZEPHIR_OBS_NVAR(right); if (zephir_array_isset_string_fetch(&right, expr, SS("right"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 383, right); + ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 376, right); zephir_check_call_status(); } ZEPHIR_INIT_NVAR(exprCode); @@ -1302,17 +1288,17 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } if (ZEPHIR_IS_LONG(type, 258)) { ZEPHIR_OBS_NVAR(exprCode); - zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1105 TSRMLS_CC); + zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1098 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(type, 259)) { ZEPHIR_OBS_NVAR(exprCode); - zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1109 TSRMLS_CC); + zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1102 TSRMLS_CC); break; } if (ZEPHIR_IS_LONG(type, 260)) { ZEPHIR_INIT_NVAR(_1); - zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1113 TSRMLS_CC); + zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1106 TSRMLS_CC); ZEPHIR_SINIT_NVAR(_13); ZVAL_STRING(&_13, "'", 0); ZEPHIR_SINIT_NVAR(_14); @@ -1338,7 +1324,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { break; } if (ZEPHIR_IS_LONG(type, 265)) { - zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1129 TSRMLS_CC); + zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1122 TSRMLS_CC); ZEPHIR_INIT_NVAR(exprCode); ZEPHIR_CONCAT_SV(exprCode, "$", _11); break; @@ -1406,7 +1392,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { if (ZEPHIR_IS_LONG(type, 365)) { ZEPHIR_OBS_NVAR(start); if (zephir_array_isset_string_fetch(&start, expr, SS("start"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 383, start); + ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 376, start); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(startCode); @@ -1414,7 +1400,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } ZEPHIR_OBS_NVAR(end); if (zephir_array_isset_string_fetch(&end, expr, SS("end"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 383, end); + ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 376, end); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(endCode); @@ -1505,8 +1491,8 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { break; } if (ZEPHIR_IS_LONG(type, 366)) { - zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1268 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 383, _6); + zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1261 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 376, _6); zephir_check_call_status(); ZEPHIR_INIT_NVAR(exprCode); ZEPHIR_CONCAT_SVSVSVS(exprCode, "(", _16, " ? ", leftCode, " : ", rightCode, ")"); @@ -1524,18 +1510,18 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) { } if (ZEPHIR_IS_LONG(type, 364)) { ZEPHIR_OBS_NVAR(exprCode); - zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1280 TSRMLS_CC); + zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1273 TSRMLS_CC); break; } ZEPHIR_INIT_NVAR(_1); - object_init_ex(_1, phalcon_mvc_view_exception_ce); - zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC); - zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC); + object_init_ex(_1, phalcon_mvc_view_engine_volt_exception_ce); + zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1277 TSRMLS_CC); + zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1277 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_8); ZEPHIR_CONCAT_SVSVSV(_8, "Unknown expression ", type, " in ", _11, " on line ", _17); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_18, 9, _8); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1277 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } while(0); @@ -1572,7 +1558,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends) { } isStatementList = 1; if (!(zephir_array_isset_string(statements, SS("type")))) { - zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1324); + zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1317); for ( ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS ; zephir_hash_move_forward_ex(_1, &_0) @@ -1585,7 +1571,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends) { } } if (isStatementList == 1) { - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 388, statements); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 381, statements); zephir_check_call_status(); RETURN_MM(); } @@ -1620,7 +1606,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { if (!(zephir_array_isset_string(statement, SS("expr")))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1352); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1345); return; } ZEPHIR_INIT_VAR(compilation); @@ -1635,15 +1621,15 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { ZEPHIR_INIT_VAR(prefixLevel); ZEPHIR_CONCAT_VV(prefixLevel, prefix, level); ZEPHIR_OBS_VAR(expr); - zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1370 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr); + zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1363 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 376, expr); zephir_check_call_status(); ZEPHIR_OBS_VAR(blockStatements); - zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1376 TSRMLS_CC); + zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1369 TSRMLS_CC); ZEPHIR_INIT_NVAR(forElse); ZVAL_BOOL(forElse, 0); if (Z_TYPE_P(blockStatements) == IS_ARRAY) { - zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1402); + zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1395); for ( ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS ; zephir_hash_move_forward_ex(_2, &_1) @@ -1666,7 +1652,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { } } } - ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 381, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_OBS_VAR(loopContext); zephir_read_property_this(&loopContext, this_ptr, SL("_loopPointers"), PH_NOISY_CC); @@ -1701,7 +1687,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { ZEPHIR_CPY_WRT(iterator, exprCode); } ZEPHIR_OBS_VAR(variable); - zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1431 TSRMLS_CC); + zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1424 TSRMLS_CC); ZEPHIR_OBS_VAR(key); if (zephir_array_isset_string_fetch(&key, statement, SS("key"), 0 TSRMLS_CC)) { ZEPHIR_INIT_LNVAR(_5); @@ -1714,7 +1700,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) { } ZEPHIR_OBS_VAR(ifExpr); if (zephir_array_isset_string_fetch(&ifExpr, statement, SS("if_expr"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 383, ifExpr); + ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 376, ifExpr); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVS(_5, "if (", _12, ") { ?>"); @@ -1815,19 +1801,19 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileIf) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1522); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1515); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); - zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1528 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 388, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1521 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 381, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_INIT_VAR(compilation); ZEPHIR_CONCAT_SVSV(compilation, "", _1); ZEPHIR_OBS_VAR(blockStatements); if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("false_statements"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 381, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SV(_5, "", _4); @@ -1856,10 +1842,10 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileElseIf) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1557); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1550); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, ""); RETURN_MM(); @@ -1891,12 +1877,12 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1577); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1570); return; } - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 376, expr); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 383, expr); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 376, expr); zephir_check_call_status(); ZEPHIR_INIT_VAR(compilation); ZEPHIR_CONCAT_SVS(compilation, "di->get('viewCache'); "); @@ -1905,14 +1891,14 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) { ZEPHIR_INIT_VAR(_2); ZEPHIR_CONCAT_SVS(_2, "$_cacheKey[", exprCode, "]"); zephir_concat_self(&compilation, _2 TSRMLS_CC); - zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1587 TSRMLS_CC); + zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1580 TSRMLS_CC); if (ZEPHIR_IS_LONG(_3, 265)) { - zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1588 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1581 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", $", _4, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); } else { - zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1590 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1583 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", ", _4, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); @@ -1925,20 +1911,20 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) { ZEPHIR_INIT_LNVAR(_2); ZEPHIR_CONCAT_SVS(_2, "if ($_cacheKey[", exprCode, "] === null) { ?>"); zephir_concat_self(&compilation, _2 TSRMLS_CC); - zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1600 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 388, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1593 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 381, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_concat_self(&compilation, _6 TSRMLS_CC); ZEPHIR_OBS_NVAR(lifetime); if (zephir_array_isset_string_fetch(&lifetime, statement, SS("lifetime"), 0 TSRMLS_CC)) { - zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1606 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1599 TSRMLS_CC); if (ZEPHIR_IS_LONG(_4, 265)) { - zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1607 TSRMLS_CC); + zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1600 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, $", _7, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); } else { - zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1609 TSRMLS_CC); + zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1602 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_5); ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, ", _4, "); "); zephir_concat_self(&compilation, _5 TSRMLS_CC); @@ -1976,24 +1962,24 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileSet) { ZEPHIR_OBS_VAR(assignments); if (!(zephir_array_isset_string_fetch(&assignments, statement, SS("assignments"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1630); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1623); return; } ZEPHIR_INIT_VAR(compilation); ZVAL_STRING(compilation, ""); RETURN_MM(); @@ -2077,10 +2063,10 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileReturn) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1711); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1704); return; } - ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); ZEPHIR_CONCAT_SVS(return_value, ""); RETURN_MM(); @@ -2107,14 +2093,14 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileAutoEscape) { ZEPHIR_OBS_VAR(autoescape); if (!(zephir_array_isset_string_fetch(&autoescape, statement, SS("enable"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1731); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1724); return; } ZEPHIR_OBS_VAR(oldAutoescape); zephir_read_property_this(&oldAutoescape, this_ptr, SL("_autoescape"), PH_NOISY_CC); zephir_update_property_this(this_ptr, SL("_autoescape"), autoescape TSRMLS_CC); - zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1740 TSRMLS_CC); - ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 388, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1733 TSRMLS_CC); + ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 381, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_autoescape"), oldAutoescape TSRMLS_CC); RETURN_CCTOR(compilation); @@ -2143,17 +2129,17 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileEcho) { ZEPHIR_OBS_VAR(expr); if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1761); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1754); return; } - ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 383, expr); + ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 376, expr); zephir_check_call_status(); - zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1769 TSRMLS_CC); + zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1762 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 350)) { - zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1771 TSRMLS_CC); - zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1773 TSRMLS_CC); + zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1764 TSRMLS_CC); + zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1766 TSRMLS_CC); if (ZEPHIR_IS_LONG(_1, 265)) { - zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1778 TSRMLS_CC); + zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1771 TSRMLS_CC); if (ZEPHIR_IS_STRING(_2, "super")) { RETURN_CCTOR(exprCode); } @@ -2188,14 +2174,14 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) { ZEPHIR_OBS_VAR(pathExpr); if (!(zephir_array_isset_string_fetch(&pathExpr, statement, SS("path"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1806); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1799); return; } - zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1813 TSRMLS_CC); + zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1806 TSRMLS_CC); if (ZEPHIR_IS_LONG(_0, 260)) { if (!(zephir_array_isset_string(statement, SS("params")))) { ZEPHIR_OBS_VAR(path); - zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1823 TSRMLS_CC); + zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1816 TSRMLS_CC); ZEPHIR_OBS_VAR(view); zephir_read_property_this(&view, this_ptr, SL("_view"), PH_NOISY_CC); if (Z_TYPE_P(view) == IS_OBJECT) { @@ -2223,14 +2209,14 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) { RETURN_CCTOR(compilation); } } - ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 383, pathExpr); + ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 376, pathExpr); zephir_check_call_status(); ZEPHIR_OBS_VAR(params); if (!(zephir_array_isset_string_fetch(¶ms, statement, SS("params"), 0 TSRMLS_CC))) { ZEPHIR_CONCAT_SVS(return_value, "partial(", path, "); ?>"); RETURN_MM(); } - ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 383, params); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 376, params); zephir_check_call_status(); ZEPHIR_CONCAT_SVSVS(return_value, "partial(", path, ", ", _1, "); ?>"); RETURN_MM(); @@ -2260,18 +2246,18 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { ZEPHIR_OBS_VAR(name); if (!(zephir_array_isset_string_fetch(&name, statement, SS("name"), 0 TSRMLS_CC))) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1878); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_engine_volt_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1871); return; } _0 = zephir_fetch_nproperty_this(this_ptr, SL("_macros"), PH_NOISY_CC); if (zephir_array_isset(_0, name)) { ZEPHIR_INIT_VAR(_1); - object_init_ex(_1, phalcon_mvc_view_exception_ce); + object_init_ex(_1, phalcon_mvc_view_engine_volt_exception_ce); ZEPHIR_INIT_VAR(_2); ZEPHIR_CONCAT_SVS(_2, "Macro '", name, "' is already defined"); ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2); zephir_check_call_status(); - zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1885 TSRMLS_CC); + zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1878 TSRMLS_CC); ZEPHIR_MM_RESTORE(); return; } @@ -2289,7 +2275,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { ZEPHIR_INIT_LNVAR(_2); ZEPHIR_CONCAT_VS(_2, macroName, " = function($__p = null) { "); zephir_concat_self(&code, _2 TSRMLS_CC); - zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1923); + zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1916); for ( ; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS ; zephir_hash_move_forward_ex(_4, &_3) @@ -2297,7 +2283,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { ZEPHIR_GET_HMKEY(position, _4, _3); ZEPHIR_GET_HVALUE(parameter, _5); ZEPHIR_OBS_NVAR(variableName); - zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1907 TSRMLS_CC); + zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1900 TSRMLS_CC); ZEPHIR_INIT_LNVAR(_6); ZEPHIR_CONCAT_SVS(_6, "if (isset($__p[", position, "])) { "); zephir_concat_self(&code, _6 TSRMLS_CC); @@ -2314,7 +2300,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { zephir_concat_self_str(&code, SL(" } else { ") TSRMLS_CC); ZEPHIR_OBS_NVAR(defaultValue); if (zephir_array_isset_string_fetch(&defaultValue, parameter, SS("default"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 383, defaultValue); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 376, defaultValue); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_12); ZEPHIR_CONCAT_SVSVS(_12, "$", variableName, " = ", _10, ";"); @@ -2330,7 +2316,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) { } ZEPHIR_OBS_VAR(blockStatements); if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("block_statements"), 0 TSRMLS_CC)) { - ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 381, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_2); ZEPHIR_CONCAT_VS(_2, _10, " +#include "../../../../../php_ext.h" +#include "../../../../../ext.h" + +#include +#include +#include + +#include "kernel/main.h" + + +/** + * Phalcon\Mvc\View\Exception + * + * Class for exceptions thrown by Phalcon\Mvc\View + */ +ZEPHIR_INIT_CLASS(Phalcon_Mvc_View_Engine_Volt_Exception) { + + ZEPHIR_REGISTER_CLASS_EX(Phalcon\\Mvc\\View\\Engine\\Volt, Exception, phalcon, mvc_view_engine_volt_exception, phalcon_mvc_view_exception_ce, NULL, 0); + + return SUCCESS; + +} + diff --git a/ext/phalcon/mvc/view/engine/volt/exception.zep.h b/ext/phalcon/mvc/view/engine/volt/exception.zep.h new file mode 100644 index 00000000000..9e4a5f8c43b --- /dev/null +++ b/ext/phalcon/mvc/view/engine/volt/exception.zep.h @@ -0,0 +1,5 @@ + +extern zend_class_entry *phalcon_mvc_view_engine_volt_exception_ce; + +ZEPHIR_INIT_CLASS(Phalcon_Mvc_View_Engine_Volt_Exception); + diff --git a/ext/phalcon/mvc/view/engine/volt/parser.lemon b/ext/phalcon/mvc/view/engine/volt/parser.lemon index 1a15bfd76ba..1ae8aa196ca 100644 --- a/ext/phalcon/mvc/view/engine/volt/parser.lemon +++ b/ext/phalcon/mvc/view/engine/volt/parser.lemon @@ -330,7 +330,7 @@ static zval *phvolt_ret_extends_statement(zval *path, phvolt_scanner_state *stat array_init_size(ret, 4); add_assoc_long(ret, "type", PHVOLT_T_EXTENDS); - add_assoc_zval(ret, "path", path); + add_assoc_zval(ret, "path", path); Z_ADDREF_P(state->active_file); add_assoc_zval(ret, "file", state->active_file); diff --git a/ext/phalcon/mvc/view/simple.zep.c b/ext/phalcon/mvc/view/simple.zep.c index fcf5d1e74cc..b70601181a1 100644 --- a/ext/phalcon/mvc/view/simple.zep.c +++ b/ext/phalcon/mvc/view/simple.zep.c @@ -188,7 +188,7 @@ PHP_METHOD(Phalcon_Mvc_View_Simple, _loadTemplateEngines) { if (Z_TYPE_P(registeredEngines) != IS_ARRAY) { ZEPHIR_INIT_VAR(_0); object_init_ex(_0, phalcon_mvc_view_engine_php_ce); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 370, this_ptr, dependencyInjector); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 363, this_ptr, dependencyInjector); zephir_check_call_status(); zephir_array_update_string(&engines, SL(".phtml"), &_0, PH_COPY | PH_SEPARATE); } else { @@ -440,7 +440,7 @@ PHP_METHOD(Phalcon_Mvc_View_Simple, render) { ZEPHIR_INIT_VAR(_1); zephir_create_symbol_table(TSRMLS_C); - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); ZEPHIR_OBS_VAR(viewParams); zephir_read_property_this(&viewParams, this_ptr, SL("_viewParams"), PH_NOISY_CC); @@ -454,7 +454,7 @@ PHP_METHOD(Phalcon_Mvc_View_Simple, render) { } else { ZEPHIR_CPY_WRT(mergedParams, viewParams); } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 389, path, mergedParams); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 382, path, mergedParams); zephir_check_call_status(); if (Z_TYPE_P(cache) == IS_OBJECT) { ZEPHIR_CALL_METHOD(&_0, cache, "isstarted", NULL, 0); @@ -474,7 +474,7 @@ PHP_METHOD(Phalcon_Mvc_View_Simple, render) { zephir_check_call_status(); } } - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); RETURN_MM_MEMBER(this_ptr, "_content"); @@ -521,7 +521,7 @@ PHP_METHOD(Phalcon_Mvc_View_Simple, partial) { } - ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 116); + ZEPHIR_CALL_FUNCTION(NULL, "ob_start", NULL, 118); zephir_check_call_status(); if (Z_TYPE_P(params) == IS_ARRAY) { ZEPHIR_OBS_VAR(viewParams); @@ -538,12 +538,12 @@ PHP_METHOD(Phalcon_Mvc_View_Simple, partial) { } else { ZEPHIR_CPY_WRT(mergedParams, params); } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 389, partialPath, mergedParams); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 382, partialPath, mergedParams); zephir_check_call_status(); if (Z_TYPE_P(params) == IS_ARRAY) { zephir_update_property_this(this_ptr, SL("_viewParams"), viewParams TSRMLS_CC); } - ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118); + ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 120); zephir_check_call_status(); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_content"), PH_NOISY_CC); zend_print_zval(_1, 0); @@ -555,7 +555,7 @@ PHP_METHOD(Phalcon_Mvc_View_Simple, partial) { * Sets the cache options * * @param array options - * @return Phalcon\Mvc\View\Simple + * @return \Phalcon\Mvc\View\Simple */ PHP_METHOD(Phalcon_Mvc_View_Simple, setCacheOptions) { diff --git a/ext/phalcon/paginator/adapter/nativearray.zep.c b/ext/phalcon/paginator/adapter/nativearray.zep.c index 44f5c9d995c..c15f15377d4 100644 --- a/ext/phalcon/paginator/adapter/nativearray.zep.c +++ b/ext/phalcon/paginator/adapter/nativearray.zep.c @@ -112,7 +112,7 @@ PHP_METHOD(Phalcon_Paginator_Adapter_NativeArray, getPaginate) { number = zephir_fast_count_int(items TSRMLS_CC); ZEPHIR_SINIT_VAR(_2); ZVAL_LONG(&_2, show); - ZEPHIR_CALL_FUNCTION(&_3, "floatval", NULL, 311, &_2); + ZEPHIR_CALL_FUNCTION(&_3, "floatval", NULL, 304, &_2); zephir_check_call_status(); roundedTotal = zephir_safe_div_long_zval(number, _3 TSRMLS_CC); totalPages = (int) (roundedTotal); @@ -123,7 +123,7 @@ PHP_METHOD(Phalcon_Paginator_Adapter_NativeArray, getPaginate) { ZVAL_LONG(&_2, (show * ((pageNumber - 1)))); ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, show); - ZEPHIR_CALL_FUNCTION(&_5, "array_slice", NULL, 379, items, &_2, &_4); + ZEPHIR_CALL_FUNCTION(&_5, "array_slice", NULL, 372, items, &_2, &_4); zephir_check_call_status(); ZEPHIR_CPY_WRT(items, _5); if (pageNumber < totalPages) { diff --git a/ext/phalcon/queue/beanstalk.zep.c b/ext/phalcon/queue/beanstalk.zep.c index 5ca5af366ba..73253365a59 100644 --- a/ext/phalcon/queue/beanstalk.zep.c +++ b/ext/phalcon/queue/beanstalk.zep.c @@ -107,7 +107,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, connect) { ZEPHIR_INIT_VAR(_3); ZVAL_NULL(_3); Z_SET_ISREF_P(_2); - ZEPHIR_CALL_FUNCTION(&connection, "fsockopen", NULL, 390, _0, _1, _2, _3); + ZEPHIR_CALL_FUNCTION(&connection, "fsockopen", NULL, 383, _0, _1, _2, _3); Z_UNSET_ISREF_P(_2); zephir_check_call_status(); if (Z_TYPE_P(connection) != IS_RESOURCE) { @@ -116,7 +116,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, connect) { } ZEPHIR_SINIT_VAR(_4); ZVAL_LONG(&_4, -1); - ZEPHIR_CALL_FUNCTION(NULL, "stream_set_timeout", NULL, 391, connection, &_4, ZEPHIR_GLOBAL(global_null)); + ZEPHIR_CALL_FUNCTION(NULL, "stream_set_timeout", NULL, 384, connection, &_4, ZEPHIR_GLOBAL(global_null)); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_connection"), connection TSRMLS_CC); RETURN_CCTOR(connection); @@ -159,7 +159,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, put) { ZEPHIR_INIT_NVAR(ttr); ZVAL_LONG(ttr, 86400); } - ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 71, data); + ZEPHIR_CALL_FUNCTION(&serialized, "serialize", NULL, 73, data); zephir_check_call_status(); ZEPHIR_INIT_VAR(length); ZVAL_LONG(length, zephir_fast_strlen_ev(serialized)); @@ -169,7 +169,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, put) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", &_1, 0, serialized); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&status, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 128 TSRMLS_CC); _2 = !ZEPHIR_IS_STRING(status, "INSERTED"); @@ -208,7 +208,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, reserve) { } ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, command); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&_0, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 153 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_0, "RESERVED")) { @@ -219,9 +219,9 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, reserve) { zephir_array_fetch_long(&_3, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 163 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_2, this_ptr, "read", NULL, 0, _3); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "unserialize", NULL, 72, _2); + ZEPHIR_CALL_FUNCTION(&_4, "unserialize", NULL, 74, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 393, this_ptr, _1, _4); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 386, this_ptr, _1, _4); zephir_check_call_status(); RETURN_MM(); @@ -256,7 +256,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, choose) { ZEPHIR_CONCAT_SV(_0, "use ", tube); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 176 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "USING")) { @@ -296,7 +296,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, watch) { ZEPHIR_CONCAT_SV(_0, "watch ", tube); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 193 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "WATCHING")) { @@ -322,7 +322,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, stats) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_temp_parameter(_0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 394); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 387); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 210 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "OK")) { @@ -362,7 +362,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, statsTube) { ZEPHIR_CONCAT_SV(_0, "stats-tube ", tube); ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 394); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 387); zephir_check_call_status(); zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 227 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "OK")) { @@ -373,6 +373,32 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, statsTube) { } +/** + * Get list of a tubes. + */ +PHP_METHOD(Phalcon_Queue_Beanstalk, listTubes) { + + int ZEPHIR_LAST_CALL_STATUS; + zval *response = NULL, *_0, *_1, *_2; + + ZEPHIR_MM_GROW(); + + ZEPHIR_INIT_VAR(_0); + ZVAL_STRING(_0, "list-tubes", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); + zephir_check_temp_parameter(_0); + zephir_check_call_status(); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 387); + zephir_check_call_status(); + zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 244 TSRMLS_CC); + if (!ZEPHIR_IS_STRING(_1, "OK")) { + RETURN_MM_BOOL(0); + } + zephir_array_fetch_long(&_2, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 248 TSRMLS_CC); + RETURN_CTOR(_2); + +} + /** * Inspect the next ready job. */ @@ -388,20 +414,20 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, peekReady) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_temp_parameter(_0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); - zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 244 TSRMLS_CC); + zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 261 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "FOUND")) { RETURN_MM_BOOL(0); } object_init_ex(return_value, phalcon_queue_beanstalk_job_ce); - zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 248 TSRMLS_CC); - zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 248 TSRMLS_CC); + zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); + zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, this_ptr, "read", NULL, 0, _4); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 72, _3); + ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 74, _3); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 393, this_ptr, _2, _5); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 386, this_ptr, _2, _5); zephir_check_call_status(); RETURN_MM(); @@ -422,20 +448,20 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, peekBuried) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0); zephir_check_temp_parameter(_0); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); - zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 261 TSRMLS_CC); + zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 278 TSRMLS_CC); if (!ZEPHIR_IS_STRING(_1, "FOUND")) { RETURN_MM_BOOL(0); } object_init_ex(return_value, phalcon_queue_beanstalk_job_ce); - zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); - zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 265 TSRMLS_CC); + zephir_array_fetch_long(&_2, response, 1, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 282 TSRMLS_CC); + zephir_array_fetch_long(&_4, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 282 TSRMLS_CC); ZEPHIR_CALL_METHOD(&_3, this_ptr, "read", NULL, 0, _4); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 72, _3); + ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 74, _3); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 393, this_ptr, _2, _5); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 386, this_ptr, _2, _5); zephir_check_call_status(); RETURN_MM(); @@ -472,13 +498,13 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, readYaml) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392); + ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 385); zephir_check_call_status(); ZEPHIR_OBS_VAR(status); - zephir_array_fetch_long(&status, response, 0, PH_NOISY, "phalcon/queue/beanstalk.zep", 290 TSRMLS_CC); + zephir_array_fetch_long(&status, response, 0, PH_NOISY, "phalcon/queue/beanstalk.zep", 307 TSRMLS_CC); if (zephir_fast_count_int(response TSRMLS_CC) > 1) { ZEPHIR_OBS_VAR(numberOfBytes); - zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 293 TSRMLS_CC); + zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 310 TSRMLS_CC); ZEPHIR_CALL_METHOD(&response, this_ptr, "read", NULL, 0); zephir_check_call_status(); ZEPHIR_CALL_FUNCTION(&data, "yaml_parse", NULL, 0, response); @@ -534,13 +560,13 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, read) { } ZEPHIR_SINIT_VAR(_0); ZVAL_LONG(&_0, (length + 2)); - ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 395, connection, &_0); + ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 388, connection, &_0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 396, connection); + ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 389, connection); zephir_check_call_status(); - zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 337 TSRMLS_CC); + zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 354 TSRMLS_CC); if (zephir_is_true(_2)) { - ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 338); + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 355); return; } ZEPHIR_SINIT_NVAR(_0); @@ -552,7 +578,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, read) { ZVAL_LONG(&_0, 16384); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "\r\n", 0); - ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 397, connection, &_0, &_3); + ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 390, connection, &_0, &_3); zephir_check_call_status(); RETURN_MM(); @@ -587,7 +613,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, write) { ZEPHIR_CPY_WRT(packet, _0); ZEPHIR_SINIT_VAR(_1); ZVAL_LONG(&_1, zephir_fast_strlen_ev(packet)); - ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 398, connection, packet, &_1); + ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 391, connection, packet, &_1); zephir_check_call_status(); RETURN_MM(); diff --git a/ext/phalcon/queue/beanstalk.zep.h b/ext/phalcon/queue/beanstalk.zep.h index d7acfd60f8d..cc09a3233e6 100644 --- a/ext/phalcon/queue/beanstalk.zep.h +++ b/ext/phalcon/queue/beanstalk.zep.h @@ -11,6 +11,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, choose); PHP_METHOD(Phalcon_Queue_Beanstalk, watch); PHP_METHOD(Phalcon_Queue_Beanstalk, stats); PHP_METHOD(Phalcon_Queue_Beanstalk, statsTube); +PHP_METHOD(Phalcon_Queue_Beanstalk, listTubes); PHP_METHOD(Phalcon_Queue_Beanstalk, peekReady); PHP_METHOD(Phalcon_Queue_Beanstalk, peekBuried); PHP_METHOD(Phalcon_Queue_Beanstalk, readStatus); @@ -61,6 +62,7 @@ ZEPHIR_INIT_FUNCS(phalcon_queue_beanstalk_method_entry) { PHP_ME(Phalcon_Queue_Beanstalk, watch, arginfo_phalcon_queue_beanstalk_watch, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, stats, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, statsTube, arginfo_phalcon_queue_beanstalk_statstube, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Queue_Beanstalk, listTubes, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, peekReady, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, peekBuried, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Queue_Beanstalk, readStatus, NULL, ZEND_ACC_FINAL|ZEND_ACC_PUBLIC) diff --git a/ext/phalcon/registry.zep.c b/ext/phalcon/registry.zep.c index 06cda532de3..90a3466144e 100644 --- a/ext/phalcon/registry.zep.c +++ b/ext/phalcon/registry.zep.c @@ -244,7 +244,7 @@ PHP_METHOD(Phalcon_Registry, next) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 399, _0); + ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 392, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -263,7 +263,7 @@ PHP_METHOD(Phalcon_Registry, key) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 400, _0); + ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 393, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); RETURN_MM(); @@ -282,7 +282,7 @@ PHP_METHOD(Phalcon_Registry, rewind) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 401, _0); + ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 394, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -301,7 +301,7 @@ PHP_METHOD(Phalcon_Registry, valid) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 400, _0); + ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 393, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); RETURN_MM_BOOL(Z_TYPE_P(_1) != IS_NULL); @@ -320,7 +320,7 @@ PHP_METHOD(Phalcon_Registry, current) { _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); Z_SET_ISREF_P(_0); - ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 402, _0); + ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 395, _0); Z_UNSET_ISREF_P(_0); zephir_check_call_status(); RETURN_MM(); @@ -352,7 +352,7 @@ PHP_METHOD(Phalcon_Registry, __set) { } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 403, key, value); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 396, key, value); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -383,7 +383,7 @@ PHP_METHOD(Phalcon_Registry, __get) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 404, key); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 397, key); zephir_check_call_status(); RETURN_MM(); @@ -411,7 +411,7 @@ PHP_METHOD(Phalcon_Registry, __isset) { } - ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 405, key); + ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 398, key); zephir_check_call_status(); RETURN_MM(); @@ -439,7 +439,7 @@ PHP_METHOD(Phalcon_Registry, __unset) { } - ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 406, key); + ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 399, key); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/security.zep.c b/ext/phalcon/security.zep.c index dc0e834861e..f05e3c61971 100644 --- a/ext/phalcon/security.zep.c +++ b/ext/phalcon/security.zep.c @@ -191,9 +191,9 @@ PHP_METHOD(Phalcon_Security, getSaltBytes) { ZEPHIR_INIT_NVAR(safeBytes); ZEPHIR_INIT_NVAR(_1); ZVAL_LONG(_1, numberBytes); - ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 407, _1); + ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 400, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_4, "base64_encode", &_5, 112, _2); + ZEPHIR_CALL_FUNCTION(&_4, "base64_encode", &_5, 114, _2); zephir_check_call_status(); zephir_filter_alphanum(safeBytes, _4); if (!(zephir_is_true(safeBytes))) { @@ -286,7 +286,7 @@ PHP_METHOD(Phalcon_Security, hash) { } ZEPHIR_INIT_VAR(_3); ZEPHIR_CONCAT_SVSV(_3, "$", variant, "$", saltBytes); - ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3); + ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 401, password, _3); zephir_check_call_status(); RETURN_MM(); } @@ -309,11 +309,11 @@ PHP_METHOD(Phalcon_Security, hash) { ZVAL_STRING(&_5, "%02s", 0); ZEPHIR_SINIT_VAR(_6); ZVAL_LONG(&_6, workFactor); - ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 187, &_5, &_6); + ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 188, &_5, &_6); zephir_check_call_status(); ZEPHIR_INIT_LNVAR(_3); ZEPHIR_CONCAT_SVSVSV(_3, "$2", variant, "$", _7, "$", saltBytes); - ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3); + ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 401, password, _3); zephir_check_call_status(); RETURN_MM(); } while(0); @@ -356,7 +356,7 @@ PHP_METHOD(Phalcon_Security, checkHash) { RETURN_MM_BOOL(0); } } - ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 408, password, passwordHash); + ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 401, password, passwordHash); zephir_check_call_status(); zephir_get_strval(_2, _1); ZEPHIR_CPY_WRT(cryptedHash, _2); @@ -426,9 +426,9 @@ PHP_METHOD(Phalcon_Security, getTokenKey) { ZEPHIR_INIT_VAR(safeBytes); ZEPHIR_INIT_VAR(_1); ZVAL_LONG(_1, numberBytes); - ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 407, _1); + ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 400, _1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_3, "base64_encode", NULL, 112, _2); + ZEPHIR_CALL_FUNCTION(&_3, "base64_encode", NULL, 114, _2); zephir_check_call_status(); zephir_filter_alphanum(safeBytes, _3); ZEPHIR_INIT_NVAR(_1); @@ -471,9 +471,9 @@ PHP_METHOD(Phalcon_Security, getToken) { } ZEPHIR_INIT_VAR(_0); ZVAL_LONG(_0, numberBytes); - ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 407, _0); + ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 400, _0); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_1, "base64_encode", NULL, 112, token); + ZEPHIR_CALL_FUNCTION(&_1, "base64_encode", NULL, 114, token); zephir_check_call_status(); ZEPHIR_CPY_WRT(token, _1); ZEPHIR_INIT_NVAR(_0); @@ -661,7 +661,7 @@ PHP_METHOD(Phalcon_Security, computeHmac) { } - ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 409, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 402, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); zephir_check_call_status(); if (!(zephir_is_true(hmac))) { ZEPHIR_INIT_VAR(_0); diff --git a/ext/phalcon/security/random.zep.c b/ext/phalcon/security/random.zep.c new file mode 100644 index 00000000000..c35afbf5964 --- /dev/null +++ b/ext/phalcon/security/random.zep.c @@ -0,0 +1,467 @@ + +#ifdef HAVE_CONFIG_H +#include "../../ext_config.h" +#endif + +#include +#include "../../php_ext.h" +#include "../../ext.h" + +#include +#include +#include + +#include "kernel/main.h" +#include "kernel/object.h" +#include "kernel/memory.h" +#include "kernel/fcall.h" +#include "kernel/file.h" +#include "kernel/operators.h" +#include "kernel/string.h" +#include "kernel/exception.h" +#include "kernel/array.h" +#include "kernel/concat.h" + + +/** + * Phalcon\Security\Random + * + * Secure random number generator class. + * + * Provides secure random number generator which is suitable for generating + * session key in HTTP cookies, etc. + * + * It supports following secure random number generators: + * + * - libsodium + * - openssl + * - /dev/urandom + * + * + * $random = new \Phalcon\Security\Random(); + * + * // Random binary string + * $bytes = $random->bytes(); + * + * // Random hex string + * echo $random->hex(10); // a29f470508d5ccb8e289 + * echo $random->hex(10); // 533c2f08d5eee750e64a + * echo $random->hex(11); // f362ef96cb9ffef150c9cd + * echo $random->hex(12); // 95469d667475125208be45c4 + * echo $random->hex(13); // 05475e8af4a34f8f743ab48761 + * + * // Random base64 string + * echo $random->base64(12); // XfIN81jGGuKkcE1E + * echo $random->base64(12); // 3rcq39QzGK9fUqh8 + * echo $random->base64(); // DRcfbngL/iOo9hGGvy1TcQ== + * echo $random->base64(16); // SvdhPcIHDZFad838Bb0Swg== + * + * // Random URL-safe base64 string + * echo $random->base64Safe(); // PcV6jGbJ6vfVw7hfKIFDGA + * echo $random->base64Safe(); // GD8JojhzSTrqX7Q8J6uug + * echo $random->base64Safe(8); // mGyy0evy3ok + * echo $random->base64Safe(null, true); // DRrAgOFkS4rvRiVHFefcQ== + * + * // Random UUID + * echo $random->uuid(); // db082997-2572-4e2c-a046-5eefe97b1235 + * echo $random->uuid(); // da2aa0e2-b4d0-4e3c-99f5-f5ef62c57fe2 + * echo $random->uuid(); // 75e6b628-c562-4117-bb76-61c4153455a9 + * echo $random->uuid(); // dc446df1-0848-4d05-b501-4af3c220c13d + * + * // Random number between 0 and $len + * echo $random->number(256); // 84 + * echo $random->number(256); // 79 + * echo $random->number(100); // 29 + * echo $random->number(300); // 40 + * + * + * This class partially borrows SecureRandom library from Ruby + * + * @link http://ruby-doc.org/stdlib-2.2.2/libdoc/securerandom/rdoc/SecureRandom.html + */ +ZEPHIR_INIT_CLASS(Phalcon_Security_Random) { + + ZEPHIR_REGISTER_CLASS(Phalcon\\Security, Random, phalcon, security_random, phalcon_security_random_method_entry, 0); + + return SUCCESS; + +} + +/** + * Generates a random binary string + * + * If $len is not specified, 16 is assumed. It may be larger in future. + * The result may contain any byte: "x00" - "xFF". + * + * + * $random = new \Phalcon\Security\Random(); + * + * $bytes = $random->bytes(); + * + * + * @throws Exception If secure random number generator is not available or unexpected partial read + */ +PHP_METHOD(Phalcon_Security_Random, bytes) { + + zval *len_param = NULL, *handle = NULL, *ret = NULL, *_0 = NULL, _1, _2 = zval_used_for_init, _3; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &len_param); + + if (!len_param) { + len = 16; + } else { + len = zephir_get_intval(len_param); + } + + + if (len <= 0) { + len = 16; + } + if ((zephir_function_exists_ex(SS("\\sodium\\randombytes_buf") TSRMLS_CC) == SUCCESS)) { + ZEPHIR_INIT_VAR(_0); + ZVAL_LONG(_0, len); + ZEPHIR_RETURN_CALL_FUNCTION("\\sodium\\randombytes_buf", NULL, 0, _0); + zephir_check_call_status(); + RETURN_MM(); + } + if ((zephir_function_exists_ex(SS("openssl_random_pseudo_bytes") TSRMLS_CC) == SUCCESS)) { + ZEPHIR_INIT_NVAR(_0); + ZVAL_LONG(_0, len); + ZEPHIR_RETURN_CALL_FUNCTION("openssl_random_pseudo_bytes", NULL, 400, _0); + zephir_check_call_status(); + RETURN_MM(); + } + ZEPHIR_SINIT_VAR(_1); + ZVAL_STRING(&_1, "/dev/urandom", 0); + if ((zephir_file_exists(&_1 TSRMLS_CC) == SUCCESS)) { + ZEPHIR_SINIT_VAR(_2); + ZVAL_STRING(&_2, "/dev/urandom", 0); + ZEPHIR_SINIT_VAR(_3); + ZVAL_STRING(&_3, "rb", 0); + ZEPHIR_CALL_FUNCTION(&handle, "fopen", NULL, 285, &_2, &_3); + zephir_check_call_status(); + if (!ZEPHIR_IS_FALSE_IDENTICAL(handle)) { + ZEPHIR_SINIT_NVAR(_2); + ZVAL_LONG(&_2, 0); + ZEPHIR_CALL_FUNCTION(NULL, "stream_set_read_buffer", NULL, 403, handle, &_2); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_2); + ZVAL_LONG(&_2, len); + ZEPHIR_CALL_FUNCTION(&ret, "fread", NULL, 388, handle, &_2); + zephir_check_call_status(); + zephir_fclose(handle TSRMLS_CC); + if (zephir_fast_strlen_ev(ret) != len) { + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_security_exception_ce, "Unexpected partial read from random device", "phalcon/security/random.zep", 117); + return; + } + RETURN_CCTOR(ret); + } + } + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_security_exception_ce, "No random device", "phalcon/security/random.zep", 124); + return; + +} + +/** + * Generates a random hex string + * + * If $len is not specified, 16 is assumed. It may be larger in future. + * The length of the result string is usually greater of $len. + * + * + * $random = new \Phalcon\Security\Random(); + * + * echo $random->hex(10); // a29f470508d5ccb8e289 + * + * + * @throws Exception If secure random number generator is not available or unexpected partial read + */ +PHP_METHOD(Phalcon_Security_Random, hex) { + + zval *len_param = NULL, *_0 = NULL, *_1, _2, *_3 = NULL; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &len_param); + + if (!len_param) { + len = 0; + } else { + len = zephir_get_intval(len_param); + } + + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, len); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "bytes", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_SINIT_VAR(_2); + ZVAL_STRING(&_2, "H*", 0); + ZEPHIR_CALL_FUNCTION(&_3, "unpack", NULL, 404, &_2, _0); + zephir_check_call_status(); + Z_SET_ISREF_P(_3); + ZEPHIR_RETURN_CALL_FUNCTION("array_shift", NULL, 121, _3); + Z_UNSET_ISREF_P(_3); + zephir_check_call_status(); + RETURN_MM(); + +} + +/** + * Generates a random base64 string + * + * If $len is not specified, 16 is assumed. It may be larger in future. + * The length of the result string is usually greater of $len. + * + * + * $random = new \Phalcon\Security\Random(); + * + * echo $random->base64(12); // 3rcq39QzGK9fUqh8 + * + * + * @throws Exception If secure random number generator is not available or unexpected partial read + */ +PHP_METHOD(Phalcon_Security_Random, base64) { + + zval *len_param = NULL, *_0 = NULL, *_1; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &len_param); + + if (!len_param) { + len = 0; + } else { + len = zephir_get_intval(len_param); + } + + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, len); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "bytes", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_RETURN_CALL_FUNCTION("base64_encode", NULL, 114, _0); + zephir_check_call_status(); + RETURN_MM(); + +} + +/** + * Generates a random URL-safe base64 string + * + * If $len is not specified, 16 is assumed. It may be larger in future. + * The length of the result string is usually greater of $len. + * + * By default, padding is not generated because "=" may be used as a URL delimiter. + * The result may contain A-Z, a-z, 0-9, "-" and "_". "=" is also used if $padding is true. + * See RFC 3548 for the definition of URL-safe base64. + * + * + * $random = new \Phalcon\Security\Random(); + * + * echo $random->base64Safe(); // GD8JojhzSTrqX7Q8J6uug + * + * + * @link https://www.ietf.org/rfc/rfc3548.txt + * @throws Exception If secure random number generator is not available or unexpected partial read + */ +PHP_METHOD(Phalcon_Security_Random, base64Safe) { + + zend_bool padding; + zval *len_param = NULL, *padding_param = NULL, *s = NULL, *_0 = NULL, *_1 = NULL, *_2, _3; + int len, ZEPHIR_LAST_CALL_STATUS; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 2, &len_param, &padding_param); + + if (!len_param) { + len = 0; + } else { + len = zephir_get_intval(len_param); + } + if (!padding_param) { + padding = 0; + } else { + padding = zephir_get_boolval(padding_param); + } + + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, len); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "base64", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_INIT_NVAR(_1); + ZVAL_STRING(_1, "#[^a-z0-9_=-]+#i", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_INIT_VAR(_2); + ZVAL_STRING(_2, "", ZEPHIR_TEMP_PARAM_COPY); + ZEPHIR_CALL_FUNCTION(&s, "preg_replace", NULL, 29, _1, _2, _0); + zephir_check_temp_parameter(_1); + zephir_check_temp_parameter(_2); + zephir_check_call_status(); + if (!(padding)) { + ZEPHIR_SINIT_VAR(_3); + ZVAL_STRING(&_3, "=", 0); + zephir_fast_trim(return_value, s, &_3, ZEPHIR_TRIM_BOTH TSRMLS_CC); + RETURN_MM(); + } + RETURN_CCTOR(s); + +} + +/** + * Generates a v4 random UUID (Universally Unique IDentifier) + * + * The version 4 UUID is purely random (except the version). It doesn't contain meaningful + * information such as MAC address, time, etc. See RFC 4122 for details of UUID. + * + * This algorithm sets the version number (4 bits) as well as two reserved bits. + * All other bits (the remaining 122 bits) are set using a random or pseudorandom data source. + * Version 4 UUIDs have the form xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx where x is any hexadecimal + * digit and y is one of 8, 9, A, or B (e.g., f47ac10b-58cc-4372-a567-0e02b2c3d479). + * + * + * $random = new \Phalcon\Security\Random(); + * + * echo $random->uuid(); // 1378c906-64bb-4f81-a8d6-4ae1bfcdec22 + * + * + * @link https://www.ietf.org/rfc/rfc4122.txt + * @throws Exception If secure random number generator is not available or unexpected partial read + */ +PHP_METHOD(Phalcon_Security_Random, uuid) { + + int ZEPHIR_LAST_CALL_STATUS; + zval *ary = NULL, *_0 = NULL, *_1 = NULL, _2 = zval_used_for_init, *_3 = NULL, *_4, *_5, *_6, *_7; + + ZEPHIR_MM_GROW(); + + ZEPHIR_INIT_VAR(_1); + ZVAL_LONG(_1, 16); + ZEPHIR_CALL_METHOD(&_0, this_ptr, "bytes", NULL, 0, _1); + zephir_check_call_status(); + ZEPHIR_SINIT_VAR(_2); + ZVAL_STRING(&_2, "N1a/n1b/n1c/n1d/n1e/N1f", 0); + ZEPHIR_CALL_FUNCTION(&_3, "unpack", NULL, 404, &_2, _0); + zephir_check_call_status(); + ZEPHIR_CALL_FUNCTION(&ary, "array_values", NULL, 215, _3); + zephir_check_call_status(); + zephir_array_fetch_long(&_4, ary, 2, PH_NOISY | PH_READONLY, "phalcon/security/random.zep", 222 TSRMLS_CC); + ZEPHIR_INIT_NVAR(_1); + ZVAL_LONG(_1, ((((int) (zephir_get_numberval(_4)) & 0x0fff)) | 0x4000)); + zephir_array_update_long(&ary, 2, &_1, PH_COPY | PH_SEPARATE, "phalcon/security/random.zep", 222); + zephir_array_fetch_long(&_5, ary, 3, PH_NOISY | PH_READONLY, "phalcon/security/random.zep", 223 TSRMLS_CC); + ZEPHIR_INIT_VAR(_6); + ZVAL_LONG(_6, ((((int) (zephir_get_numberval(_5)) & 0x3fff)) | 0x8000)); + zephir_array_update_long(&ary, 3, &_6, PH_COPY | PH_SEPARATE, "phalcon/security/random.zep", 223); + ZEPHIR_INIT_VAR(_7); + ZVAL_STRING(_7, "%08x-%04x-%04x-%04x-%04x%08x", ZEPHIR_TEMP_PARAM_COPY); + Z_SET_ISREF_P(ary); + ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 379, ary, _7); + zephir_check_temp_parameter(_7); + Z_UNSET_ISREF_P(ary); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_2); + ZVAL_STRING(&_2, "sprintf", 0); + ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, &_2, ary); + zephir_check_call_status(); + RETURN_MM(); + +} + +/** + * Generates a random number between 0 and $len + * + * + * $random = new \Phalcon\Security\Random(); + * + * echo $random->number(16); // 8 + * + * @throws Exception If secure random number generator is not available, unexpected partial read or $len <= 0 + */ +PHP_METHOD(Phalcon_Security_Random, number) { + + zephir_fcall_cache_entry *_4 = NULL, *_9 = NULL, *_14 = NULL, *_18 = NULL; + zval *len_param = NULL, *hex = NULL, *bin = NULL, *mask = NULL, *rnd = NULL, *ret = NULL, *first = NULL, _0 = zval_used_for_init, *_1, _2, *_3, *_8 = NULL, _10 = zval_used_for_init, _11 = zval_used_for_init, _12 = zval_used_for_init, *_13 = NULL, _15 = zval_used_for_init, _16 = zval_used_for_init, *_17 = NULL; + int len, ZEPHIR_LAST_CALL_STATUS, _5, _6, _7; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 1, 0, &len_param); + + len = zephir_get_intval(len_param); + + + if (len > 0) { + ZEPHIR_SINIT_VAR(_0); + ZVAL_LONG(&_0, len); + ZEPHIR_CALL_FUNCTION(&hex, "dechex", NULL, 405, &_0); + zephir_check_call_status(); + if (((zephir_fast_strlen_ev(hex) & 1)) == 1) { + ZEPHIR_INIT_VAR(_1); + ZEPHIR_CONCAT_SV(_1, "0", hex); + ZEPHIR_CPY_WRT(hex, _1); + } + ZEPHIR_SINIT_NVAR(_0); + ZVAL_STRING(&_0, "H*", 0); + ZEPHIR_CALL_FUNCTION(&bin, "pack", NULL, 406, &_0, hex); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_0); + ZVAL_LONG(&_0, 0); + ZEPHIR_SINIT_VAR(_2); + ZVAL_LONG(&_2, 1); + ZEPHIR_INIT_VAR(_3); + zephir_substr(_3, bin, 0 , 1 , 0); + ZEPHIR_CALL_FUNCTION(&mask, "ord", &_4, 132, _3); + zephir_check_call_status(); + _5 = ((int) (zephir_get_numberval(mask)) | (((int) (zephir_get_numberval(mask)) >> 1))); + ZEPHIR_INIT_NVAR(mask); + ZVAL_LONG(mask, _5); + _6 = ((int) (zephir_get_numberval(mask)) | (((int) (zephir_get_numberval(mask)) >> 2))); + ZEPHIR_INIT_NVAR(mask); + ZVAL_LONG(mask, _6); + _7 = ((int) (zephir_get_numberval(mask)) | (((int) (zephir_get_numberval(mask)) >> 4))); + ZEPHIR_INIT_NVAR(mask); + ZVAL_LONG(mask, _7); + do { + ZEPHIR_INIT_NVAR(_8); + ZVAL_LONG(_8, zephir_fast_strlen_ev(bin)); + ZEPHIR_CALL_METHOD(&rnd, this_ptr, "bytes", &_9, 0, _8); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_10); + ZVAL_LONG(&_10, 0); + ZEPHIR_SINIT_NVAR(_11); + ZVAL_LONG(&_11, 1); + ZEPHIR_INIT_NVAR(_8); + zephir_substr(_8, rnd, 0 , 1 , 0); + ZEPHIR_CALL_FUNCTION(&first, "ord", &_4, 132, _8); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_12); + zephir_bitwise_and_function(&_12, first, mask TSRMLS_CC); + ZEPHIR_CALL_FUNCTION(&_13, "chr", &_14, 130, &_12); + zephir_check_call_status(); + ZEPHIR_SINIT_NVAR(_15); + ZVAL_LONG(&_15, 0); + ZEPHIR_SINIT_NVAR(_16); + ZVAL_LONG(&_16, 1); + ZEPHIR_CALL_FUNCTION(&_17, "substr_replace", &_18, 407, rnd, _13, &_15, &_16); + zephir_check_call_status(); + ZEPHIR_CPY_WRT(rnd, _17); + } while (ZEPHIR_LT(bin, rnd)); + ZEPHIR_SINIT_NVAR(_10); + ZVAL_STRING(&_10, "H*", 0); + ZEPHIR_CALL_FUNCTION(&ret, "unpack", NULL, 404, &_10, rnd); + zephir_check_call_status(); + Z_SET_ISREF_P(ret); + ZEPHIR_CALL_FUNCTION(&_13, "array_shift", NULL, 121, ret); + Z_UNSET_ISREF_P(ret); + zephir_check_call_status(); + ZEPHIR_RETURN_CALL_FUNCTION("hexdec", NULL, 408, _13); + zephir_check_call_status(); + RETURN_MM(); + } + ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_security_exception_ce, "Require a positive integer > 0", "phalcon/security/random.zep", 269); + return; + +} + diff --git a/ext/phalcon/security/random.zep.h b/ext/phalcon/security/random.zep.h new file mode 100644 index 00000000000..8e8a66e3add --- /dev/null +++ b/ext/phalcon/security/random.zep.h @@ -0,0 +1,42 @@ + +extern zend_class_entry *phalcon_security_random_ce; + +ZEPHIR_INIT_CLASS(Phalcon_Security_Random); + +PHP_METHOD(Phalcon_Security_Random, bytes); +PHP_METHOD(Phalcon_Security_Random, hex); +PHP_METHOD(Phalcon_Security_Random, base64); +PHP_METHOD(Phalcon_Security_Random, base64Safe); +PHP_METHOD(Phalcon_Security_Random, uuid); +PHP_METHOD(Phalcon_Security_Random, number); + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_bytes, 0, 0, 0) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_hex, 0, 0, 0) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_base64, 0, 0, 0) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_base64safe, 0, 0, 0) + ZEND_ARG_INFO(0, len) + ZEND_ARG_INFO(0, padding) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_security_random_number, 0, 0, 1) + ZEND_ARG_INFO(0, len) +ZEND_END_ARG_INFO() + +ZEPHIR_INIT_FUNCS(phalcon_security_random_method_entry) { + PHP_ME(Phalcon_Security_Random, bytes, arginfo_phalcon_security_random_bytes, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, hex, arginfo_phalcon_security_random_hex, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, base64, arginfo_phalcon_security_random_base64, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, base64Safe, arginfo_phalcon_security_random_base64safe, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, uuid, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Security_Random, number, arginfo_phalcon_security_random_number, ZEND_ACC_PUBLIC) + PHP_FE_END +}; diff --git a/ext/phalcon/session/adapter.zep.c b/ext/phalcon/session/adapter.zep.c index 26859e97443..6eb0661dd7a 100644 --- a/ext/phalcon/session/adapter.zep.c +++ b/ext/phalcon/session/adapter.zep.c @@ -20,6 +20,8 @@ #include "ext/spl/spl_exceptions.h" #include "kernel/exception.h" #include "kernel/concat.h" +#include "kernel/hash.h" +#include "kernel/string.h" /** @@ -84,7 +86,7 @@ PHP_METHOD(Phalcon_Session_Adapter, start) { ZEPHIR_MM_GROW(); - ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 54); + ZEPHIR_CALL_FUNCTION(&_0, "headers_sent", NULL, 55); zephir_check_call_status(); if (!(zephir_is_true(_0))) { _1 = zephir_fetch_nproperty_this(this_ptr, SL("_started"), PH_NOISY_CC); @@ -95,7 +97,7 @@ PHP_METHOD(Phalcon_Session_Adapter, start) { _2 = !ZEPHIR_IS_LONG_IDENTICAL(_3, 2); } if (_2) { - ZEPHIR_CALL_FUNCTION(NULL, "session_start", NULL, 55); + ZEPHIR_CALL_FUNCTION(NULL, "session_start", NULL, 56); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_started"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); RETURN_MM_BOOL(1); @@ -157,7 +159,7 @@ PHP_METHOD(Phalcon_Session_Adapter, setName) { zephir_get_strval(name, name_param); - ZEPHIR_CALL_FUNCTION(NULL, "session_name", NULL, 56, name); + ZEPHIR_CALL_FUNCTION(NULL, "session_name", NULL, 57, name); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -172,24 +174,48 @@ PHP_METHOD(Phalcon_Session_Adapter, getName) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("session_name", NULL, 56); + ZEPHIR_RETURN_CALL_FUNCTION("session_name", NULL, 57); zephir_check_call_status(); RETURN_MM(); } +/** + * {@inheritdoc} + */ +PHP_METHOD(Phalcon_Session_Adapter, regenerateId) { + + int ZEPHIR_LAST_CALL_STATUS; + zval *deleteOldSession_param = NULL; + zend_bool deleteOldSession; + + ZEPHIR_MM_GROW(); + zephir_fetch_params(1, 0, 1, &deleteOldSession_param); + + if (!deleteOldSession_param) { + deleteOldSession = 1; + } else { + deleteOldSession = zephir_get_boolval(deleteOldSession_param); + } + + + ZEPHIR_CALL_FUNCTION(NULL, "session_regenerate_id", NULL, 58, (deleteOldSession ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false))); + zephir_check_call_status(); + RETURN_THIS(); + +} + /** * Gets a session variable from an application context * - * @param string index - * @param mixed defaultValue - * @param boolean remove - * @return mixed + * + * $session->get('auth', 'yes'); + * */ PHP_METHOD(Phalcon_Session_Adapter, get) { zend_bool remove; - zval *index_param = NULL, *defaultValue = NULL, *remove_param = NULL, *value, *key, *_0, *_SESSION; + zval *index_param = NULL, *defaultValue = NULL, *remove_param = NULL, *value, *key = NULL, *uniqueId, *_SESSION; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -207,9 +233,13 @@ PHP_METHOD(Phalcon_Session_Adapter, get) { } - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(key); - ZEPHIR_CONCAT_VV(key, _0, index); + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(key); + ZEPHIR_CONCAT_VSV(key, uniqueId, "#", index); + } else { + ZEPHIR_CPY_WRT(key, index); + } ZEPHIR_OBS_VAR(value); if (zephir_array_isset_fetch(&value, _SESSION, key, 0 TSRMLS_CC)) { if (remove) { @@ -228,14 +258,11 @@ PHP_METHOD(Phalcon_Session_Adapter, get) { * * $session->set('auth', 'yes'); * - * - * @param string index - * @param string value */ PHP_METHOD(Phalcon_Session_Adapter, set) { - int _2; - zval *index_param = NULL, *value, *_SESSION, *_0, *_1; + int _1; + zval *index_param = NULL, *value, *uniqueId, *_SESSION, *_0; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -245,12 +272,20 @@ PHP_METHOD(Phalcon_Session_Adapter, set) { zephir_get_strval(index, index_param); - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_1); - ZEPHIR_CONCAT_VV(_1, _0, index); - _2 = zephir_maybe_separate_zval(&_SESSION); - zephir_array_update_zval(&_SESSION, _1, &value, PH_COPY | PH_SEPARATE); - if (_2) { + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + ZEPHIR_CONCAT_VSV(_0, uniqueId, "#", index); + _1 = zephir_maybe_separate_zval(&_SESSION); + zephir_array_update_zval(&_SESSION, _0, &value, PH_COPY | PH_SEPARATE); + if (_1) { + ZEND_SET_SYMBOL(&EG(symbol_table), "_SESSION", _SESSION); + } + RETURN_MM_NULL(); + } + _1 = zephir_maybe_separate_zval(&_SESSION); + zephir_array_update_zval(&_SESSION, index, &value, PH_COPY | PH_SEPARATE); + if (_1) { ZEND_SET_SYMBOL(&EG(symbol_table), "_SESSION", _SESSION); } ZEPHIR_MM_RESTORE(); @@ -266,7 +301,7 @@ PHP_METHOD(Phalcon_Session_Adapter, set) { */ PHP_METHOD(Phalcon_Session_Adapter, has) { - zval *index_param = NULL, *_SESSION, *_0, *_1; + zval *index_param = NULL, *uniqueId, *_SESSION, *_0; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -276,10 +311,13 @@ PHP_METHOD(Phalcon_Session_Adapter, has) { zephir_get_strval(index, index_param); - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_1); - ZEPHIR_CONCAT_VV(_1, _0, index); - RETURN_MM_BOOL(zephir_array_isset(_SESSION, _1)); + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + ZEPHIR_CONCAT_VSV(_0, uniqueId, "#", index); + RETURN_MM_BOOL(zephir_array_isset(_SESSION, _0)); + } + RETURN_MM_BOOL(zephir_array_isset(_SESSION, index)); } @@ -292,7 +330,7 @@ PHP_METHOD(Phalcon_Session_Adapter, has) { */ PHP_METHOD(Phalcon_Session_Adapter, remove) { - zval *index_param = NULL, *_0, *_1, *_SESSION; + zval *index_param = NULL, *uniqueId, *_0, *_SESSION; zval *index = NULL; ZEPHIR_MM_GROW(); @@ -302,10 +340,14 @@ PHP_METHOD(Phalcon_Session_Adapter, remove) { zephir_get_strval(index, index_param); - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); - ZEPHIR_INIT_VAR(_1); - ZEPHIR_CONCAT_VV(_1, _0, index); - zephir_array_unset(&_SESSION, _1, PH_SEPARATE); + uniqueId = zephir_fetch_nproperty_this(this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + ZEPHIR_CONCAT_VSV(_0, uniqueId, "#", index); + zephir_array_unset(&_SESSION, _0, PH_SEPARATE); + RETURN_MM_NULL(); + } + zephir_array_unset(&_SESSION, index, PH_SEPARATE); ZEPHIR_MM_RESTORE(); } @@ -323,7 +365,7 @@ PHP_METHOD(Phalcon_Session_Adapter, getId) { ZEPHIR_MM_GROW(); - ZEPHIR_RETURN_CALL_FUNCTION("session_id", NULL, 57); + ZEPHIR_RETURN_CALL_FUNCTION("session_id", NULL, 59); zephir_check_call_status(); RETURN_MM(); @@ -348,7 +390,7 @@ PHP_METHOD(Phalcon_Session_Adapter, setId) { zephir_get_strval(id, id_param); - ZEPHIR_CALL_FUNCTION(NULL, "session_id", NULL, 57, id); + ZEPHIR_CALL_FUNCTION(NULL, "session_id", NULL, 59, id); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -373,16 +415,53 @@ PHP_METHOD(Phalcon_Session_Adapter, isStarted) { * * * var_dump($session->destroy()); + * var_dump($session->destroy(true)); * */ PHP_METHOD(Phalcon_Session_Adapter, destroy) { int ZEPHIR_LAST_CALL_STATUS; + HashTable *_2; + HashPosition _1; + zval *removeData_param = NULL, *uniqueId, *key = NULL, *_SESSION = NULL, *_0 = NULL, **_3, *_4 = NULL; + zend_bool removeData; ZEPHIR_MM_GROW(); + zephir_get_global(&_SESSION, SS("_SESSION") TSRMLS_CC); + zephir_fetch_params(1, 0, 1, &removeData_param); + if (!removeData_param) { + removeData = 0; + } else { + removeData = zephir_get_boolval(removeData_param); + } + + + if (removeData) { + ZEPHIR_OBS_VAR(uniqueId); + zephir_read_property_this(&uniqueId, this_ptr, SL("_uniqueId"), PH_NOISY_CC); + if (!(ZEPHIR_IS_EMPTY(uniqueId))) { + ZEPHIR_INIT_VAR(_0); + zephir_is_iterable(_SESSION, &_2, &_1, 1, 0, "phalcon/session/adapter.zep", 265); + for ( + ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS + ; zephir_hash_move_forward_ex(_2, &_1) + ) { + ZEPHIR_GET_HMKEY(key, _2, _1); + ZEPHIR_GET_HVALUE(_0, _3); + ZEPHIR_INIT_LNVAR(_4); + ZEPHIR_CONCAT_VS(_4, uniqueId, "#"); + if (zephir_start_with(key, _4, NULL)) { + zephir_array_unset(&_SESSION, key, PH_SEPARATE); + } + } + } else { + ZEPHIR_INIT_NVAR(_SESSION); + array_init(_SESSION); + } + } zephir_update_property_this(this_ptr, SL("_started"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC); - ZEPHIR_RETURN_CALL_FUNCTION("session_destroy", NULL, 58); + ZEPHIR_RETURN_CALL_FUNCTION("session_destroy", NULL, 60); zephir_check_call_status(); RETURN_MM(); @@ -408,7 +487,7 @@ PHP_METHOD(Phalcon_Session_Adapter, status) { ZEPHIR_MM_GROW(); if (!(zephir_is_php_version(50300))) { - ZEPHIR_CALL_FUNCTION(&status, "session_status", NULL, 59); + ZEPHIR_CALL_FUNCTION(&status, "session_status", NULL, 61); zephir_check_call_status(); do { if (ZEPHIR_IS_LONG(status, 0)) { @@ -426,9 +505,6 @@ PHP_METHOD(Phalcon_Session_Adapter, status) { /** * Alias: Gets a session variable from an application context - * - * @param string index - * @return mixed */ PHP_METHOD(Phalcon_Session_Adapter, __get) { @@ -450,9 +526,6 @@ PHP_METHOD(Phalcon_Session_Adapter, __get) { /** * Alias: Sets a session variable in an application context - * - * @param string index - * @param string value */ PHP_METHOD(Phalcon_Session_Adapter, __set) { diff --git a/ext/phalcon/session/adapter.zep.h b/ext/phalcon/session/adapter.zep.h index 9082f9f2304..aee18de19af 100644 --- a/ext/phalcon/session/adapter.zep.h +++ b/ext/phalcon/session/adapter.zep.h @@ -9,6 +9,7 @@ PHP_METHOD(Phalcon_Session_Adapter, setOptions); PHP_METHOD(Phalcon_Session_Adapter, getOptions); PHP_METHOD(Phalcon_Session_Adapter, setName); PHP_METHOD(Phalcon_Session_Adapter, getName); +PHP_METHOD(Phalcon_Session_Adapter, regenerateId); PHP_METHOD(Phalcon_Session_Adapter, get); PHP_METHOD(Phalcon_Session_Adapter, set); PHP_METHOD(Phalcon_Session_Adapter, has); @@ -35,6 +36,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setname, 0, 0, 1) ZEND_ARG_INFO(0, name) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_regenerateid, 0, 0, 0) + ZEND_ARG_INFO(0, deleteOldSession) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_get, 0, 0, 1) ZEND_ARG_INFO(0, index) ZEND_ARG_INFO(0, defaultValue) @@ -58,6 +63,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setid, 0, 0, 1) ZEND_ARG_INFO(0, id) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_destroy, 0, 0, 0) + ZEND_ARG_INFO(0, removeData) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___get, 0, 0, 1) ZEND_ARG_INFO(0, index) ZEND_END_ARG_INFO() @@ -82,6 +91,7 @@ ZEPHIR_INIT_FUNCS(phalcon_session_adapter_method_entry) { PHP_ME(Phalcon_Session_Adapter, getOptions, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, setName, arginfo_phalcon_session_adapter_setname, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, getName, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Session_Adapter, regenerateId, arginfo_phalcon_session_adapter_regenerateid, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, get, arginfo_phalcon_session_adapter_get, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, set, arginfo_phalcon_session_adapter_set, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, has, arginfo_phalcon_session_adapter_has, ZEND_ACC_PUBLIC) @@ -89,7 +99,7 @@ ZEPHIR_INIT_FUNCS(phalcon_session_adapter_method_entry) { PHP_ME(Phalcon_Session_Adapter, getId, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, setId, arginfo_phalcon_session_adapter_setid, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, isStarted, NULL, ZEND_ACC_PUBLIC) - PHP_ME(Phalcon_Session_Adapter, destroy, NULL, ZEND_ACC_PUBLIC) + PHP_ME(Phalcon_Session_Adapter, destroy, arginfo_phalcon_session_adapter_destroy, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, status, NULL, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, __get, arginfo_phalcon_session_adapter___get, ZEND_ACC_PUBLIC) PHP_ME(Phalcon_Session_Adapter, __set, arginfo_phalcon_session_adapter___set, ZEND_ACC_PUBLIC) diff --git a/ext/phalcon/session/adapter/libmemcached.zep.c b/ext/phalcon/session/adapter/libmemcached.zep.c index 8171d74085d..5adb61408db 100644 --- a/ext/phalcon/session/adapter/libmemcached.zep.c +++ b/ext/phalcon/session/adapter/libmemcached.zep.c @@ -123,7 +123,7 @@ PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); ZEPHIR_INIT_VAR(_4); zephir_create_array(_4, 4, 0 TSRMLS_CC); @@ -131,7 +131,7 @@ PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) { zephir_array_update_string(&_4, SL("client"), &client, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("prefix"), &prefix, PH_COPY | PH_SEPARATE); zephir_array_update_string(&_4, SL("statsKey"), &statsKey, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, _4); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 312, _1, _4); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_libmemcached"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_5); @@ -170,9 +170,9 @@ PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) { ZEPHIR_INIT_NVAR(_6); ZVAL_STRING(_6, "gc", 1); zephir_array_fast_append(_11, _6); - ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _5, _7, _8, _9, _10, _11); + ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 409, _5, _7, _8, _9, _10, _11); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 411, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 410, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/session/adapter/memcache.zep.c b/ext/phalcon/session/adapter/memcache.zep.c index 3ecaa7bcaec..3cffd35f931 100644 --- a/ext/phalcon/session/adapter/memcache.zep.c +++ b/ext/phalcon/session/adapter/memcache.zep.c @@ -117,9 +117,9 @@ PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 314, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -158,9 +158,9 @@ PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) { ZEPHIR_INIT_NVAR(_5); ZVAL_STRING(_5, "gc", 1); zephir_array_fast_append(_10, _5); - ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10); + ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 409, _4, _6, _7, _8, _9, _10); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 411, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 410, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/session/adapter/redis.zep.c b/ext/phalcon/session/adapter/redis.zep.c index 693ad0d21e2..6b59b71a507 100644 --- a/ext/phalcon/session/adapter/redis.zep.c +++ b/ext/phalcon/session/adapter/redis.zep.c @@ -116,9 +116,9 @@ PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct) { ZEPHIR_OBS_VAR(_3); zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC); zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 311, _2); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 315, _1, options); zephir_check_call_status(); zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC); ZEPHIR_INIT_VAR(_4); @@ -157,9 +157,9 @@ PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct) { ZEPHIR_INIT_NVAR(_5); ZVAL_STRING(_5, "gc", 1); zephir_array_fast_append(_10, _5); - ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10); + ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 409, _4, _6, _7, _8, _9, _10); zephir_check_call_status(); - ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_redis_ce, this_ptr, "__construct", &_11, 411, options); + ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_redis_ce, this_ptr, "__construct", &_11, 410, options); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); diff --git a/ext/phalcon/session/adapterinterface.zep.c b/ext/phalcon/session/adapterinterface.zep.c index 35abc30ac77..eb4c539898a 100644 --- a/ext/phalcon/session/adapterinterface.zep.c +++ b/ext/phalcon/session/adapterinterface.zep.c @@ -42,18 +42,11 @@ ZEPHIR_DOC_METHOD(Phalcon_Session_AdapterInterface, getOptions); /** * Gets a session variable from an application context - * - * @param string index - * @param mixed defaultValue - * @return mixed */ ZEPHIR_DOC_METHOD(Phalcon_Session_AdapterInterface, get); /** * Sets a session variable in an application context - * - * @param string index - * @param string value */ ZEPHIR_DOC_METHOD(Phalcon_Session_AdapterInterface, set); @@ -82,3 +75,8 @@ ZEPHIR_DOC_METHOD(Phalcon_Session_AdapterInterface, isStarted); */ ZEPHIR_DOC_METHOD(Phalcon_Session_AdapterInterface, destroy); +/** + * Regenerate session's id + */ +ZEPHIR_DOC_METHOD(Phalcon_Session_AdapterInterface, regenerateId); + diff --git a/ext/phalcon/session/adapterinterface.zep.h b/ext/phalcon/session/adapterinterface.zep.h index 04c8e826d71..b34953782e3 100644 --- a/ext/phalcon/session/adapterinterface.zep.h +++ b/ext/phalcon/session/adapterinterface.zep.h @@ -25,6 +25,14 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_remove, 0, 0, 1) ZEND_ARG_INFO(0, index) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_destroy, 0, 0, 0) + ZEND_ARG_INFO(0, removeData) +ZEND_END_ARG_INFO() + +ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_regenerateid, 0, 0, 0) + ZEND_ARG_INFO(0, deleteOldSession) +ZEND_END_ARG_INFO() + ZEPHIR_INIT_FUNCS(phalcon_session_adapterinterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, start, NULL) PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, setOptions, arginfo_phalcon_session_adapterinterface_setoptions) @@ -35,6 +43,7 @@ ZEPHIR_INIT_FUNCS(phalcon_session_adapterinterface_method_entry) { PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, remove, arginfo_phalcon_session_adapterinterface_remove) PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getId, NULL) PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, isStarted, NULL) - PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, destroy, NULL) + PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, destroy, arginfo_phalcon_session_adapterinterface_destroy) + PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, regenerateId, arginfo_phalcon_session_adapterinterface_regenerateid) PHP_FE_END }; diff --git a/ext/phalcon/session/bag.zep.c b/ext/phalcon/session/bag.zep.c index 1f06cc53a86..04d63d9eb5e 100644 --- a/ext/phalcon/session/bag.zep.c +++ b/ext/phalcon/session/bag.zep.c @@ -31,7 +31,7 @@ * * $user = new \Phalcon\Session\Bag('user'); * $user->name = "Kimbra Johnson"; - * $user->age = 22; + * $user->age = 22; * */ ZEPHIR_INIT_CLASS(Phalcon_Session_Bag) { @@ -165,7 +165,7 @@ PHP_METHOD(Phalcon_Session_Bag, initialize) { PHP_METHOD(Phalcon_Session_Bag, destroy) { int ZEPHIR_LAST_CALL_STATUS; - zval *_0, *_1, *_2; + zval *_0, *_1, *_2, *_3; ZEPHIR_MM_GROW(); @@ -174,9 +174,12 @@ PHP_METHOD(Phalcon_Session_Bag, destroy) { ZEPHIR_CALL_METHOD(NULL, this_ptr, "initialize", NULL, 0); zephir_check_call_status(); } - _1 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _1, "remove", NULL, 0, _2); + ZEPHIR_INIT_VAR(_1); + array_init(_1); + zephir_update_property_this(this_ptr, SL("_data"), _1 TSRMLS_CC); + _2 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); + _3 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(NULL, _2, "remove", NULL, 0, _3); zephir_check_call_status(); ZEPHIR_MM_RESTORE(); @@ -188,9 +191,6 @@ PHP_METHOD(Phalcon_Session_Bag, destroy) { * * $user->set('name', 'Kimbra'); * - * - * @param string property - * @param string value */ PHP_METHOD(Phalcon_Session_Bag, set) { @@ -235,9 +235,6 @@ PHP_METHOD(Phalcon_Session_Bag, set) { * * $user->name = "Kimbra"; * - * - * @param string property - * @param string value */ PHP_METHOD(Phalcon_Session_Bag, __set) { @@ -273,10 +270,6 @@ PHP_METHOD(Phalcon_Session_Bag, __set) { * * echo $user->get('name', 'Kimbra'); * - * - * @param string property - * @param string defaultValue - * @return mixed */ PHP_METHOD(Phalcon_Session_Bag, get) { @@ -323,9 +316,6 @@ PHP_METHOD(Phalcon_Session_Bag, get) { * * echo $user->name; * - * - * @param string property - * @return mixed */ PHP_METHOD(Phalcon_Session_Bag, __get) { @@ -439,7 +429,7 @@ PHP_METHOD(Phalcon_Session_Bag, __isset) { PHP_METHOD(Phalcon_Session_Bag, remove) { int ZEPHIR_LAST_CALL_STATUS; - zval *property_param = NULL, *_0, *_1, *_2, *_3, *_4; + zval *property_param = NULL, *data, *_0, *_1; zval *property = NULL; ZEPHIR_MM_GROW(); @@ -458,15 +448,15 @@ PHP_METHOD(Phalcon_Session_Bag, remove) { } - _0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - if (zephir_array_isset(_0, property)) { - _1 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - zephir_array_unset(&_1, property, PH_SEPARATE); - _2 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); - _3 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); - _4 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, _2, "set", NULL, 0, _3, _4); + ZEPHIR_OBS_VAR(data); + zephir_read_property_this(&data, this_ptr, SL("_data"), PH_NOISY_CC); + if (zephir_array_isset(data, property)) { + zephir_array_unset(&data, property, PH_SEPARATE); + _0 = zephir_fetch_nproperty_this(this_ptr, SL("_session"), PH_NOISY_CC); + _1 = zephir_fetch_nproperty_this(this_ptr, SL("_name"), PH_NOISY_CC); + ZEPHIR_CALL_METHOD(NULL, _0, "set", NULL, 0, _1, data); zephir_check_call_status(); + zephir_update_property_this(this_ptr, SL("_data"), data TSRMLS_CC); RETURN_MM_BOOL(1); } RETURN_MM_BOOL(0); @@ -551,7 +541,7 @@ PHP_METHOD(Phalcon_Session_Bag, getIterator) { } object_init_ex(return_value, zephir_get_internal_ce(SS("arrayiterator") TSRMLS_CC)); _1 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC); - ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 412, _1); + ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 411, _1); zephir_check_call_status(); RETURN_MM(); @@ -652,7 +642,7 @@ PHP_METHOD(Phalcon_Session_Bag, offsetUnset) { } /** - * @param string property + * @param string property */ PHP_METHOD(Phalcon_Session_Bag, offsetGet) { diff --git a/ext/phalcon/tag.zep.c b/ext/phalcon/tag.zep.c index fed496f7155..63a371d2ee2 100644 --- a/ext/phalcon/tag.zep.c +++ b/ext/phalcon/tag.zep.c @@ -869,7 +869,7 @@ PHP_METHOD(Phalcon_Tag, colorField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "color", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -899,7 +899,7 @@ PHP_METHOD(Phalcon_Tag, textField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "text", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -929,7 +929,7 @@ PHP_METHOD(Phalcon_Tag, numericField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "number", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -955,7 +955,7 @@ PHP_METHOD(Phalcon_Tag, rangeField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "range", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -985,7 +985,7 @@ PHP_METHOD(Phalcon_Tag, emailField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "email", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1015,7 +1015,7 @@ PHP_METHOD(Phalcon_Tag, dateField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "date", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1041,7 +1041,7 @@ PHP_METHOD(Phalcon_Tag, dateTimeField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "datetime", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1067,7 +1067,7 @@ PHP_METHOD(Phalcon_Tag, dateTimeLocalField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "datetime-local", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1093,7 +1093,7 @@ PHP_METHOD(Phalcon_Tag, monthField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "month", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1119,7 +1119,7 @@ PHP_METHOD(Phalcon_Tag, timeField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "time", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1145,7 +1145,7 @@ PHP_METHOD(Phalcon_Tag, weekField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "week", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1175,7 +1175,7 @@ PHP_METHOD(Phalcon_Tag, passwordField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "password", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1205,7 +1205,7 @@ PHP_METHOD(Phalcon_Tag, hiddenField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "hidden", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1235,7 +1235,7 @@ PHP_METHOD(Phalcon_Tag, fileField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "file", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1261,7 +1261,7 @@ PHP_METHOD(Phalcon_Tag, searchField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "search", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1287,7 +1287,7 @@ PHP_METHOD(Phalcon_Tag, telField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "tel", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1313,7 +1313,7 @@ PHP_METHOD(Phalcon_Tag, urlField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "url", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1343,7 +1343,7 @@ PHP_METHOD(Phalcon_Tag, checkField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "checkbox", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 413, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1378,7 +1378,7 @@ PHP_METHOD(Phalcon_Tag, radioField) { ZEPHIR_INIT_VAR(_1); ZVAL_STRING(_1, "radio", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters); + ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 413, _1, parameters); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1415,7 +1415,7 @@ PHP_METHOD(Phalcon_Tag, imageInput) { ZVAL_STRING(_1, "image", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters, _2); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1452,7 +1452,7 @@ PHP_METHOD(Phalcon_Tag, submitButton) { ZVAL_STRING(_1, "submit", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_2); ZVAL_BOOL(_2, 1); - ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2); + ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 412, _1, parameters, _2); zephir_check_temp_parameter(_1); zephir_check_call_status(); RETURN_MM(); @@ -1484,7 +1484,7 @@ PHP_METHOD(Phalcon_Tag, selectStatic) { } - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 207, parameters, data); zephir_check_call_status(); RETURN_MM(); @@ -1524,7 +1524,7 @@ PHP_METHOD(Phalcon_Tag, select) { } - ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data); + ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 207, parameters, data); zephir_check_call_status(); RETURN_MM(); @@ -2173,20 +2173,20 @@ PHP_METHOD(Phalcon_Tag, friendlyTitle) { ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "iconv", 0); - ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", &_2, 126, &_0); + ZEPHIR_CALL_FUNCTION(&_1, "extension_loaded", &_2, 128, &_0); zephir_check_call_status(); if (zephir_is_true(_1)) { ZEPHIR_SINIT_NVAR(_0); ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "en_US.UTF-8", 0); - ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 415, &_0, &_3); + ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 414, &_0, &_3); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "UTF-8", 0); ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "ASCII//TRANSLIT", 0); - ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 378, &_0, &_3, text); + ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 371, &_0, &_3, text); zephir_check_call_status(); zephir_get_strval(text, _5); } @@ -2224,7 +2224,7 @@ PHP_METHOD(Phalcon_Tag, friendlyTitle) { ZVAL_STRING(_11, "/[^a-zA-Z0-9\\/_|+ -]/", ZEPHIR_TEMP_PARAM_COPY); ZEPHIR_INIT_VAR(_12); ZVAL_STRING(_12, "", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&friendly, "preg_replace", &_13, 28, _11, _12, text); + ZEPHIR_CALL_FUNCTION(&friendly, "preg_replace", &_13, 29, _11, _12, text); zephir_check_temp_parameter(_11); zephir_check_temp_parameter(_12); zephir_check_call_status(); @@ -2235,7 +2235,7 @@ PHP_METHOD(Phalcon_Tag, friendlyTitle) { } ZEPHIR_INIT_NVAR(_11); ZVAL_STRING(_11, "/[\\/_|+ -]+/", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_FUNCTION(&_5, "preg_replace", &_13, 28, _11, separator, friendly); + ZEPHIR_CALL_FUNCTION(&_5, "preg_replace", &_13, 29, _11, separator, friendly); zephir_check_temp_parameter(_11); zephir_check_call_status(); ZEPHIR_CPY_WRT(friendly, _5); @@ -2244,12 +2244,12 @@ PHP_METHOD(Phalcon_Tag, friendlyTitle) { ZEPHIR_CPY_WRT(friendly, _11); ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "iconv", 0); - ZEPHIR_CALL_FUNCTION(&_5, "extension_loaded", &_2, 126, &_3); + ZEPHIR_CALL_FUNCTION(&_5, "extension_loaded", &_2, 128, &_3); zephir_check_call_status(); if (zephir_is_true(_5)) { ZEPHIR_SINIT_NVAR(_3); ZVAL_LONG(&_3, 0); - ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 415, &_3, locale); + ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 414, &_3, locale); zephir_check_call_status(); } RETURN_CCTOR(friendly); diff --git a/ext/phalcon/tag/select.zep.c b/ext/phalcon/tag/select.zep.c index 0c2cea8b4e6..94b16581ce7 100644 --- a/ext/phalcon/tag/select.zep.c +++ b/ext/phalcon/tag/select.zep.c @@ -151,7 +151,7 @@ PHP_METHOD(Phalcon_Tag_Select, selectField) { ZEPHIR_GET_CONSTANT(_6, "PHP_EOL"); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, "", _6); - ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 416, options, using, value, _7); + ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 415, options, using, value, _7); zephir_check_call_status(); zephir_concat_self(&code, _8 TSRMLS_CC); } else { @@ -160,7 +160,7 @@ PHP_METHOD(Phalcon_Tag_Select, selectField) { ZEPHIR_GET_CONSTANT(_6, "PHP_EOL"); ZEPHIR_INIT_LNVAR(_7); ZEPHIR_CONCAT_SV(_7, "", _6); - ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 417, options, value, _7); + ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 416, options, value, _7); zephir_check_call_status(); zephir_concat_self(&code, _8 TSRMLS_CC); } else { @@ -176,7 +176,7 @@ PHP_METHOD(Phalcon_Tag_Select, selectField) { /** * Generate the OPTION tags based on a resultset * - * @param Phalcon\Mvc\Model\Resultset resultset + * @param \Phalcon\Mvc\Model\Resultset resultset * @param array using * @param mixed value * @param string closeOption @@ -313,12 +313,12 @@ PHP_METHOD(Phalcon_Tag_Select, _optionsFromArray) { ) { ZEPHIR_GET_HMKEY(optionValue, _1, _0); ZEPHIR_GET_HVALUE(optionText, _2); - ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 181, optionValue); + ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 182, optionValue); zephir_check_call_status(); if (Z_TYPE_P(optionText) == IS_ARRAY) { ZEPHIR_INIT_NVAR(_4); ZEPHIR_GET_CONSTANT(_4, "PHP_EOL"); - ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 417, optionText, value, closeOption); + ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 416, optionText, value, closeOption); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_7); ZEPHIR_GET_CONSTANT(_7, "PHP_EOL"); diff --git a/ext/phalcon/text.zep.c b/ext/phalcon/text.zep.c index 9385cabfdb2..0f341d3d8d6 100644 --- a/ext/phalcon/text.zep.c +++ b/ext/phalcon/text.zep.c @@ -86,7 +86,7 @@ PHP_METHOD(Phalcon_Text, camelize) { * Uncamelize strings which are camelized * * - * echo Phalcon\Text::camelize('CocoBongo'); //coco_bongo + * echo Phalcon\Text::uncamelize('CocoBongo'); //coco_bongo * */ PHP_METHOD(Phalcon_Text, uncamelize) { @@ -194,13 +194,13 @@ PHP_METHOD(Phalcon_Text, random) { ZVAL_STRING(&_0, "a", 0); ZEPHIR_SINIT_VAR(_1); ZVAL_STRING(&_1, "z", 0); - ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "A", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "Z", 0); - ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_INIT_VAR(pool); zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC); @@ -211,13 +211,13 @@ PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "a", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "f", 0); - ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_INIT_NVAR(pool); zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC); @@ -228,7 +228,7 @@ PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); break; } @@ -237,7 +237,7 @@ PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 1); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); break; } @@ -245,21 +245,21 @@ PHP_METHOD(Phalcon_Text, random) { ZVAL_LONG(&_0, 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_LONG(&_1, 9); - ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "a", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "z", 0); - ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "A", 0); ZEPHIR_SINIT_NVAR(_1); ZVAL_STRING(&_1, "Z", 0); - ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 418, &_0, &_1); + ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 417, &_0, &_1); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 419, _2, _4, _5); + ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 418, _2, _4, _5); zephir_check_call_status(); break; } while(0); @@ -388,7 +388,7 @@ PHP_METHOD(Phalcon_Text, lower) { if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, str, encoding); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 195, str, encoding); zephir_check_call_status(); RETURN_MM(); } @@ -443,7 +443,7 @@ PHP_METHOD(Phalcon_Text, upper) { if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, str, encoding); + ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 196, str, encoding); zephir_check_call_status(); RETURN_MM(); } @@ -476,7 +476,7 @@ PHP_METHOD(Phalcon_Text, reduceSlashes) { ZVAL_STRING(_0, "#(? * * @param int index - * @return Phalcon\Validation\Message + * @return \Phalcon\Validation\Message */ PHP_METHOD(Phalcon_Validation_Message_Group, offsetGet) { @@ -107,7 +107,7 @@ PHP_METHOD(Phalcon_Validation_Message_Group, offsetGet) { * * * @param int index - * @param Phalcon\Validation\Message message + * @param \Phalcon\Validation\Message message */ PHP_METHOD(Phalcon_Validation_Message_Group, offsetSet) { @@ -214,7 +214,7 @@ PHP_METHOD(Phalcon_Validation_Message_Group, appendMessage) { * $messages->appendMessages($messagesArray); * * - * @param Phalcon\Validation\MessageInterface[] messages + * @param \Phalcon\Validation\MessageInterface[] messages */ PHP_METHOD(Phalcon_Validation_Message_Group, appendMessages) { @@ -349,7 +349,7 @@ PHP_METHOD(Phalcon_Validation_Message_Group, rewind) { /** * Returns the current message in the iterator * - * @return Phalcon\Validation\Message + * @return \Phalcon\Validation\Message */ PHP_METHOD(Phalcon_Validation_Message_Group, current) { @@ -403,7 +403,7 @@ PHP_METHOD(Phalcon_Validation_Message_Group, valid) { * Magic __set_state helps to re-build messages variable when exporting * * @param array group - * @return Phalcon\Validation\Message\Group + * @return \Phalcon\Validation\Message\Group */ PHP_METHOD(Phalcon_Validation_Message_Group, __set_state) { diff --git a/ext/phalcon/validation/validator/alnum.zep.c b/ext/phalcon/validation/validator/alnum.zep.c index 1c63067adcf..7d65ef87eab 100644 --- a/ext/phalcon/validation/validator/alnum.zep.c +++ b/ext/phalcon/validation/validator/alnum.zep.c @@ -81,7 +81,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) { if (_2) { RETURN_MM_BOOL(1); } - ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 437, value); + ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 436, value); zephir_check_call_status(); if (!(zephir_is_true(_3))) { ZEPHIR_INIT_NVAR(_1); @@ -110,11 +110,11 @@ PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Alnum", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); diff --git a/ext/phalcon/validation/validator/alpha.zep.c b/ext/phalcon/validation/validator/alpha.zep.c index 6cdd687f104..f10124068bb 100644 --- a/ext/phalcon/validation/validator/alpha.zep.c +++ b/ext/phalcon/validation/validator/alpha.zep.c @@ -81,7 +81,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) { if (_2) { RETURN_MM_BOOL(1); } - ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 438, value); + ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 437, value); zephir_check_call_status(); if (!(zephir_is_true(_3))) { ZEPHIR_INIT_NVAR(_1); @@ -110,11 +110,11 @@ PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Alpha", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); diff --git a/ext/phalcon/validation/validator/between.zep.c b/ext/phalcon/validation/validator/between.zep.c index e0f09236a67..713ebd1169b 100644 --- a/ext/phalcon/validation/validator/between.zep.c +++ b/ext/phalcon/validation/validator/between.zep.c @@ -127,11 +127,11 @@ PHP_METHOD(Phalcon_Validation_Validator_Between, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Between", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); diff --git a/ext/phalcon/validation/validator/confirmation.zep.c b/ext/phalcon/validation/validator/confirmation.zep.c index 39800ffd200..88f8e8cc2ae 100644 --- a/ext/phalcon/validation/validator/confirmation.zep.c +++ b/ext/phalcon/validation/validator/confirmation.zep.c @@ -77,7 +77,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) { zephir_check_call_status(); ZEPHIR_CALL_METHOD(&valueWith, validation, "getvalue", NULL, 0, fieldWith); zephir_check_call_status(); - ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 439, value, valueWith); + ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 438, value, valueWith); zephir_check_call_status(); if (!(zephir_is_true(_1))) { ZEPHIR_INIT_NVAR(_0); @@ -116,11 +116,11 @@ PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZVAL_STRING(_3, "Confirmation", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _2, field, _3); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 435, _2, field, _3); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -162,12 +162,12 @@ PHP_METHOD(Phalcon_Validation_Validator_Confirmation, compare) { } ZEPHIR_SINIT_VAR(_3); ZVAL_STRING(&_3, "utf-8", 0); - ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 194, a, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 195, a, &_3); zephir_check_call_status(); zephir_get_strval(a, _4); ZEPHIR_SINIT_NVAR(_3); ZVAL_STRING(&_3, "utf-8", 0); - ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 194, b, &_3); + ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 195, b, &_3); zephir_check_call_status(); zephir_get_strval(b, _6); } diff --git a/ext/phalcon/validation/validator/digit.zep.c b/ext/phalcon/validation/validator/digit.zep.c index 6f27efe29b0..0ef489116ca 100644 --- a/ext/phalcon/validation/validator/digit.zep.c +++ b/ext/phalcon/validation/validator/digit.zep.c @@ -81,7 +81,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) { if (_2) { RETURN_MM_BOOL(1); } - ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 440, value); + ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 439, value); zephir_check_call_status(); if (!(zephir_is_true(_3))) { ZEPHIR_INIT_NVAR(_1); @@ -110,11 +110,11 @@ PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_5); ZVAL_STRING(_5, "Digit", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _4, field, _5); zephir_check_temp_parameter(_5); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); diff --git a/ext/phalcon/validation/validator/email.zep.c b/ext/phalcon/validation/validator/email.zep.c index 9f6a43b745b..46031d4d506 100644 --- a/ext/phalcon/validation/validator/email.zep.c +++ b/ext/phalcon/validation/validator/email.zep.c @@ -83,7 +83,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Email, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 274); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_1); @@ -112,11 +112,11 @@ PHP_METHOD(Phalcon_Validation_Validator_Email, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "Email", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _5, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); diff --git a/ext/phalcon/validation/validator/exclusionin.zep.c b/ext/phalcon/validation/validator/exclusionin.zep.c index 444d2732d85..5e865ae3289 100644 --- a/ext/phalcon/validation/validator/exclusionin.zep.c +++ b/ext/phalcon/validation/validator/exclusionin.zep.c @@ -122,11 +122,11 @@ PHP_METHOD(Phalcon_Validation_Validator_ExclusionIn, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_3, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_3, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_4); ZVAL_STRING(_4, "ExclusionIn", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _3, field, _4); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _3, field, _4); zephir_check_temp_parameter(_4); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); diff --git a/ext/phalcon/validation/validator/file.zep.c b/ext/phalcon/validation/validator/file.zep.c index 18bdf39ca9a..5464189ff38 100644 --- a/ext/phalcon/validation/validator/file.zep.c +++ b/ext/phalcon/validation/validator/file.zep.c @@ -132,11 +132,11 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_11); ZVAL_STRING(_11, "FileIniSize", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 436, _9, field, _11); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 435, _9, field, _11); zephir_check_temp_parameter(_11); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -176,7 +176,7 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) { _20 = _18; if (!(_20)) { zephir_array_fetch_string(&_21, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 79 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 232, _21); + ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 233, _21); zephir_check_call_status(); _20 = !zephir_is_true(_9); } @@ -198,11 +198,11 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_23); ZVAL_STRING(_23, "FileEmpty", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _22, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -235,11 +235,11 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_9, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_23); ZVAL_STRING(_23, "FileValid", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _9, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _9, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -285,7 +285,7 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) { zephir_array_fetch_long(&unit, matches, 2, PH_NOISY, "phalcon/validation/validator/file.zep", 115 TSRMLS_CC); } zephir_array_fetch_long(&_28, matches, 1, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _28); + ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 304, _28); zephir_check_call_status(); ZEPHIR_INIT_VAR(_30); zephir_array_fetch(&_31, byteUnits, unit, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC); @@ -295,9 +295,9 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) { ZEPHIR_INIT_VAR(bytes); mul_function(bytes, _22, _30 TSRMLS_CC); zephir_array_fetch_string(&_33, value, SL("size"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 120 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _33); + ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 304, _33); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 311, bytes); + ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 304, bytes); zephir_check_call_status(); if (ZEPHIR_GT(_22, _34)) { ZEPHIR_INIT_NVAR(_30); @@ -318,11 +318,11 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_30); object_init_ex(_30, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_36); ZVAL_STRING(_36, "FileSize", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 436, _35, field, _36); + ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 435, _35, field, _36); zephir_check_temp_parameter(_36); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _30); @@ -348,12 +348,12 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) { if ((zephir_function_exists_ex(SS("finfo_open") TSRMLS_CC) == SUCCESS)) { ZEPHIR_SINIT_NVAR(_32); ZVAL_LONG(&_32, 16); - ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 229, &_32); + ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 230, &_32); zephir_check_call_status(); zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 143 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, tmp, _28); + ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 231, tmp, _28); zephir_check_call_status(); - ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, tmp); + ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 232, tmp); zephir_check_call_status(); } else { ZEPHIR_OBS_NVAR(mime); @@ -380,11 +380,11 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_22, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_23); ZVAL_STRING(_23, "FileType", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _22, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -408,7 +408,7 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } if (_37) { zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 164 TSRMLS_CC); - ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 249, _28); + ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 241, _28); zephir_check_call_status(); ZEPHIR_OBS_VAR(width); zephir_array_fetch_long(&width, tmp, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 165 TSRMLS_CC); @@ -465,11 +465,11 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_11); object_init_ex(_11, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_35, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_23); ZVAL_STRING(_23, "FileMinResolution", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _35, field, _23); + ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 435, _35, field, _23); zephir_check_temp_parameter(_23); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11); @@ -521,11 +521,11 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) { } ZEPHIR_INIT_NVAR(_23); object_init_ex(_23, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_41, "strtr", &_10, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_41, "strtr", &_10, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_NVAR(_26); ZVAL_STRING(_26, "FileMaxResolution", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 436, _41, field, _26); + ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 435, _41, field, _26); zephir_check_temp_parameter(_26); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _23); diff --git a/ext/phalcon/validation/validator/identical.zep.c b/ext/phalcon/validation/validator/identical.zep.c index 26c223d9528..62bbac1a914 100644 --- a/ext/phalcon/validation/validator/identical.zep.c +++ b/ext/phalcon/validation/validator/identical.zep.c @@ -125,11 +125,11 @@ PHP_METHOD(Phalcon_Validation_Validator_Identical, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_4); ZVAL_STRING(_4, "Identical", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _4); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _2, field, _4); zephir_check_temp_parameter(_4); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); diff --git a/ext/phalcon/validation/validator/inclusionin.zep.c b/ext/phalcon/validation/validator/inclusionin.zep.c index 156ee27a7d3..57a555e8276 100644 --- a/ext/phalcon/validation/validator/inclusionin.zep.c +++ b/ext/phalcon/validation/validator/inclusionin.zep.c @@ -110,7 +110,7 @@ PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) { zephir_check_temp_parameter(_1); zephir_check_call_status(); } - ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 365, value, domain, strict); + ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 358, value, domain, strict); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_1); @@ -142,11 +142,11 @@ PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "InclusionIn", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _5, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); diff --git a/ext/phalcon/validation/validator/numericality.zep.c b/ext/phalcon/validation/validator/numericality.zep.c index a7524f4a31f..bac2f5a30e6 100644 --- a/ext/phalcon/validation/validator/numericality.zep.c +++ b/ext/phalcon/validation/validator/numericality.zep.c @@ -114,11 +114,11 @@ PHP_METHOD(Phalcon_Validation_Validator_Numericality, validate) { } ZEPHIR_INIT_NVAR(_5); object_init_ex(_5, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "Numericality", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 436, _6, field, _7); + ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 435, _6, field, _7); zephir_check_temp_parameter(_7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _5); diff --git a/ext/phalcon/validation/validator/presenceof.zep.c b/ext/phalcon/validation/validator/presenceof.zep.c index 1619501438f..035c505e3ab 100644 --- a/ext/phalcon/validation/validator/presenceof.zep.c +++ b/ext/phalcon/validation/validator/presenceof.zep.c @@ -100,11 +100,11 @@ PHP_METHOD(Phalcon_Validation_Validator_PresenceOf, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_3); ZVAL_STRING(_3, "PresenceOf", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _3); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _2, field, _3); zephir_check_temp_parameter(_3); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); diff --git a/ext/phalcon/validation/validator/regex.zep.c b/ext/phalcon/validation/validator/regex.zep.c index aa3271fb729..ac1f577b042 100644 --- a/ext/phalcon/validation/validator/regex.zep.c +++ b/ext/phalcon/validation/validator/regex.zep.c @@ -125,11 +125,11 @@ PHP_METHOD(Phalcon_Validation_Validator_Regex, validate) { } ZEPHIR_INIT_NVAR(_4); object_init_ex(_4, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "Regex", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 436, _6, field, _7); + ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 435, _6, field, _7); zephir_check_temp_parameter(_7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _4); diff --git a/ext/phalcon/validation/validator/stringlength.zep.c b/ext/phalcon/validation/validator/stringlength.zep.c index 52a9b1d59f1..19059cc3c5e 100644 --- a/ext/phalcon/validation/validator/stringlength.zep.c +++ b/ext/phalcon/validation/validator/stringlength.zep.c @@ -38,7 +38,7 @@ * 'messageMaximum' => 'We don\'t like really long names', * 'messageMinimum' => 'We want more than just their initials' *))); - * + * */ ZEPHIR_INIT_CLASS(Phalcon_Validation_Validator_StringLength) { @@ -117,7 +117,7 @@ PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) { zephir_check_call_status(); } if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) { - ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value); + ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 359, value); zephir_check_call_status(); } else { ZEPHIR_INIT_NVAR(length); @@ -148,11 +148,11 @@ PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "TooLong", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 436, _4, field, _6); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 435, _4, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); @@ -185,11 +185,11 @@ PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) { } ZEPHIR_INIT_NVAR(_6); object_init_ex(_6, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_4, "strtr", &_5, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_8); ZVAL_STRING(_8, "TooShort", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 436, _4, field, _8); + ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 435, _4, field, _8); zephir_check_temp_parameter(_8); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _6); diff --git a/ext/phalcon/validation/validator/uniqueness.zep.c b/ext/phalcon/validation/validator/uniqueness.zep.c index 8198331542e..37cdbac06d8 100644 --- a/ext/phalcon/validation/validator/uniqueness.zep.c +++ b/ext/phalcon/validation/validator/uniqueness.zep.c @@ -158,11 +158,11 @@ PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) { } ZEPHIR_INIT_NVAR(_0); object_init_ex(_0, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_6, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_7); ZVAL_STRING(_7, "Uniqueness", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _6, field, _7); + ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 435, _6, field, _7); zephir_check_temp_parameter(_7); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0); diff --git a/ext/phalcon/validation/validator/url.zep.c b/ext/phalcon/validation/validator/url.zep.c index 146817f487f..7012ec4491c 100644 --- a/ext/phalcon/validation/validator/url.zep.c +++ b/ext/phalcon/validation/validator/url.zep.c @@ -83,7 +83,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Url, validate) { } ZEPHIR_SINIT_VAR(_3); ZVAL_LONG(&_3, 273); - ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3); + ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 192, value, &_3); zephir_check_call_status(); if (!(zephir_is_true(_4))) { ZEPHIR_INIT_NVAR(_1); @@ -112,11 +112,11 @@ PHP_METHOD(Phalcon_Validation_Validator_Url, validate) { } ZEPHIR_INIT_NVAR(_1); object_init_ex(_1, phalcon_validation_message_ce); - ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 53, message, replacePairs); + ZEPHIR_CALL_FUNCTION(&_5, "strtr", NULL, 54, message, replacePairs); zephir_check_call_status(); ZEPHIR_INIT_VAR(_6); ZVAL_STRING(_6, "Url", ZEPHIR_TEMP_PARAM_COPY); - ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6); + ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 435, _5, field, _6); zephir_check_temp_parameter(_6); zephir_check_call_status(); ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1); diff --git a/ext/phalcon/version.zep.c b/ext/phalcon/version.zep.c index 71dcb4d95d5..2919c1cbe09 100644 --- a/ext/phalcon/version.zep.c +++ b/ext/phalcon/version.zep.c @@ -97,7 +97,7 @@ PHP_METHOD(Phalcon_Version, _getVersion) { ZVAL_LONG(_0, 0); zephir_array_fast_append(return_value, _0); ZEPHIR_INIT_NVAR(_0); - ZVAL_LONG(_0, 6); + ZVAL_LONG(_0, 7); zephir_array_fast_append(return_value, _0); ZEPHIR_INIT_NVAR(_0); ZVAL_LONG(_0, 4); @@ -178,7 +178,7 @@ PHP_METHOD(Phalcon_Version, get) { zephir_array_fetch_long(&specialNumber, version, 4, PH_NOISY, "phalcon/version.zep", 128 TSRMLS_CC); ZEPHIR_INIT_VAR(result); ZEPHIR_CONCAT_VSVSVS(result, major, ".", medium, ".", minor, " "); - ZEPHIR_CALL_STATIC(&suffix, "_getspecial", &_0, 441, special); + ZEPHIR_CALL_STATIC(&suffix, "_getspecial", &_0, 440, special); zephir_check_call_status(); if (!ZEPHIR_IS_STRING(suffix, "")) { ZEPHIR_INIT_VAR(_1); @@ -219,11 +219,11 @@ PHP_METHOD(Phalcon_Version, getId) { zephir_array_fetch_long(&specialNumber, version, 4, PH_NOISY, "phalcon/version.zep", 158 TSRMLS_CC); ZEPHIR_SINIT_VAR(_0); ZVAL_STRING(&_0, "%02s", 0); - ZEPHIR_CALL_FUNCTION(&_1, "sprintf", &_2, 187, &_0, medium); + ZEPHIR_CALL_FUNCTION(&_1, "sprintf", &_2, 188, &_0, medium); zephir_check_call_status(); ZEPHIR_SINIT_NVAR(_0); ZVAL_STRING(&_0, "%02s", 0); - ZEPHIR_CALL_FUNCTION(&_3, "sprintf", &_2, 187, &_0, minor); + ZEPHIR_CALL_FUNCTION(&_3, "sprintf", &_2, 188, &_0, minor); zephir_check_call_status(); ZEPHIR_CONCAT_VVVVV(return_value, major, _1, _3, special, specialNumber); RETURN_MM(); @@ -260,7 +260,7 @@ PHP_METHOD(Phalcon_Version, getPart) { } if (part == 3) { zephir_array_fetch_long(&_1, version, 3, PH_NOISY | PH_READONLY, "phalcon/version.zep", 187 TSRMLS_CC); - ZEPHIR_CALL_STATIC(&result, "_getspecial", &_0, 441, _1); + ZEPHIR_CALL_STATIC(&result, "_getspecial", &_0, 440, _1); zephir_check_call_status(); break; } diff --git a/ext/php_phalcon.h b/ext/php_phalcon.h index 6b975e6aad3..5a9097fa82e 100644 --- a/ext/php_phalcon.h +++ b/ext/php_phalcon.h @@ -11,7 +11,7 @@ #include "kernel/globals.h" #define PHP_PHALCON_NAME "phalcon" -#define PHP_PHALCON_VERSION "2.0.6" +#define PHP_PHALCON_VERSION "2.0.7" #define PHP_PHALCON_EXTNAME "phalcon" #define PHP_PHALCON_AUTHOR "Phalcon Team and contributors" #define PHP_PHALCON_ZEPVERSION "0.7.1b" @@ -34,6 +34,7 @@ typedef struct _zephir_struct_orm { zend_bool exception_on_failed_save; zend_bool enable_literals; zend_bool late_state_binding; + zend_bool enable_implicit_joins; zend_bool cast_on_hydrate; zend_bool ignore_unknown_columns; } zephir_struct_orm; diff --git a/phalcon/annotations/adapter.zep b/phalcon/annotations/adapter.zep index bc5ca706910..34e919c16f9 100644 --- a/phalcon/annotations/adapter.zep +++ b/phalcon/annotations/adapter.zep @@ -133,7 +133,7 @@ abstract class Adapter */ public function getMethod(string className, string methodName) -> { - var classAnnotations, methods, method; + var classAnnotations, methods, method, methodKey; /** * Get the full annotations from the class @@ -146,14 +146,16 @@ abstract class Adapter if typeof classAnnotations == "object" { let methods = classAnnotations->getMethodsAnnotations(); if typeof methods == "array" { - if fetch method, methods[methodName] { - return method; + for methodKey, method in methods { + if !strcasecmp(methodKey, methodName) { + return method; + } } } } /** - * Returns a collection anyways + * Returns a collection anyway */ return new Collection(); } diff --git a/phalcon/annotations/adapter/apc.zep b/phalcon/annotations/adapter/apc.zep index a9d469b23bb..ee95d2101fd 100644 --- a/phalcon/annotations/adapter/apc.zep +++ b/phalcon/annotations/adapter/apc.zep @@ -62,7 +62,7 @@ class Apc extends Adapter implements AdapterInterface * Reads parsed annotations from APC * * @param string key - * @return Phalcon\Annotations\Reflection + * @return \Phalcon\Annotations\Reflection */ public function read(string! key) -> | boolean { diff --git a/phalcon/annotations/adapter/files.zep b/phalcon/annotations/adapter/files.zep index 2ede690aea6..119ba6e24e5 100644 --- a/phalcon/annotations/adapter/files.zep +++ b/phalcon/annotations/adapter/files.zep @@ -58,7 +58,7 @@ class Files extends Adapter implements AdapterInterface * Reads parsed annotations from files * * @param string key - * @return Phalcon\Annotations\Reflection + * @return \Phalcon\Annotations\Reflection */ public function read(string key) -> | boolean | int { diff --git a/phalcon/annotations/adapter/memory.zep b/phalcon/annotations/adapter/memory.zep index c06edad9b76..e3a41719c30 100644 --- a/phalcon/annotations/adapter/memory.zep +++ b/phalcon/annotations/adapter/memory.zep @@ -40,7 +40,7 @@ class Memory extends Adapter implements AdapterInterface * Reads parsed annotations from memory * * @param string key - * @return Phalcon\Annotations\Reflection + * @return \Phalcon\Annotations\Reflection */ public function read(string! key) -> | boolean { diff --git a/phalcon/annotations/adapter/xcache.zep b/phalcon/annotations/adapter/xcache.zep index 275213f1360..176851fb96b 100644 --- a/phalcon/annotations/adapter/xcache.zep +++ b/phalcon/annotations/adapter/xcache.zep @@ -39,7 +39,7 @@ class Xcache extends Adapter implements AdapterInterface * Reads parsed annotations from XCache * * @param string key - * @return Phalcon\Annotations\Reflection + * @return \Phalcon\Annotations\Reflection */ public function read(string! key) -> | boolean { diff --git a/phalcon/annotations/adapterinterface.zep b/phalcon/annotations/adapterinterface.zep index 6f499b70baa..bb756b2d263 100644 --- a/phalcon/annotations/adapterinterface.zep +++ b/phalcon/annotations/adapterinterface.zep @@ -43,7 +43,7 @@ interface AdapterInterface * Parses or retrieves all the annotations found in a class * * @param string|object className - * @return Phalcon\Annotations\Reflection + * @return \Phalcon\Annotations\Reflection */ public function get(className); @@ -60,7 +60,7 @@ interface AdapterInterface * * @param string className * @param string methodName - * @return Phalcon\Annotations\Collection + * @return \Phalcon\Annotations\Collection */ public function getMethod(className, methodName); @@ -77,7 +77,7 @@ interface AdapterInterface * * @param string className * @param string propertyName - * @return Phalcon\Annotations\Collection + * @return \Phalcon\Annotations\Collection */ public function getProperty(className, propertyName); } diff --git a/phalcon/annotations/annotation.zep b/phalcon/annotations/annotation.zep index 7fff655f159..cc211740be4 100644 --- a/phalcon/annotations/annotation.zep +++ b/phalcon/annotations/annotation.zep @@ -193,7 +193,6 @@ class Annotation /** * Returns a named argument * - * @param string name * @return mixed */ public function getNamedArgument(string! name) @@ -207,7 +206,6 @@ class Annotation /** * Returns a named parameter * - * @param string name * @return mixed */ public function getNamedParameter(string! name) diff --git a/phalcon/annotations/collection.zep b/phalcon/annotations/collection.zep index f92b8d22d69..6449e46a451 100644 --- a/phalcon/annotations/collection.zep +++ b/phalcon/annotations/collection.zep @@ -88,7 +88,7 @@ class Collection implements \Iterator, \Countable /** * Returns the current annotation in the iterator * - * @return Phalcon\Annotations\Annotation + * @return \Phalcon\Annotations\Annotation */ public function current() -> | boolean { diff --git a/phalcon/annotations/reflection.zep b/phalcon/annotations/reflection.zep index 97c94126431..92234203dcb 100644 --- a/phalcon/annotations/reflection.zep +++ b/phalcon/annotations/reflection.zep @@ -113,7 +113,7 @@ class Reflection } /** - * Returns the annotations found in the properties' docblocks + * Returns the annotations found in the properties' docblocks */ public function getPropertiesAnnotations() -> | boolean { diff --git a/phalcon/assets/collection.zep b/phalcon/assets/collection.zep index 6c9e20ac7e6..bb11a077ef1 100644 --- a/phalcon/assets/collection.zep +++ b/phalcon/assets/collection.zep @@ -80,14 +80,10 @@ class Collection implements \Countable, \Iterator /** * Adds a CSS resource to the collection */ - public function addCss(string! path, var local = null, boolean filter = false, attributes = null) -> + public function addCss(string! path, var local = null, boolean filter = true, attributes = null) -> { var collectionLocal, collectionAttributes; - - if !filter { - let filter = true; - } - + if typeof local == "boolean" { let collectionLocal = local; } else { @@ -108,14 +104,10 @@ class Collection implements \Countable, \Iterator /** * Adds a inline CSS to the collection */ - public function addInlineCss(string content, boolean filter = false, attributes = null) -> + public function addInlineCss(string content, boolean filter = true, attributes = null) -> { var collectionAttributes; - - if !filter { - let filter = true; - } - + if typeof attributes == "array" { let collectionAttributes = attributes; } else { @@ -133,16 +125,12 @@ class Collection implements \Countable, \Iterator * @param boolean local * @param boolean filter * @param array attributes - * @return Phalcon\Assets\Collection + * @return \Phalcon\Assets\Collection */ - public function addJs(string! path, var local = null, boolean filter = false, attributes = null) -> + public function addJs(string! path, var local = null, boolean filter = true, attributes = null) -> { var collectionLocal, collectionAttributes; - if !filter { - let filter = true; - } - if typeof local == "boolean" { let collectionLocal = local; } else { @@ -163,14 +151,10 @@ class Collection implements \Countable, \Iterator /** * Adds a inline javascript to the collection */ - public function addInlineJs(string content, boolean filter = false, attributes = null) -> + public function addInlineJs(string content, boolean filter = true, attributes = null) -> { var collectionAttributes; - if !filter { - let filter = true; - } - if typeof attributes == "array" { let collectionAttributes = attributes; } else { diff --git a/phalcon/assets/manager.zep b/phalcon/assets/manager.zep index 83e9c91da28..f5fbd408390 100644 --- a/phalcon/assets/manager.zep +++ b/phalcon/assets/manager.zep @@ -286,7 +286,7 @@ class Manager /** * Traverses a collection calling the callback to generate its HTML * - * @param Phalcon\Assets\Collection collection + * @param \Phalcon\Assets\Collection collection * @param callback callback * @param string type */ @@ -697,7 +697,7 @@ class Manager /** * Traverses a collection and generate its HTML * - * @param Phalcon\Assets\Collection collection + * @param \Phalcon\Assets\Collection collection * @param string type */ public function outputInline( collection, type) diff --git a/phalcon/cache/backend.zep b/phalcon/cache/backend.zep index c7de9cfe227..b476ba957ca 100644 --- a/phalcon/cache/backend.zep +++ b/phalcon/cache/backend.zep @@ -46,8 +46,8 @@ abstract class Backend /** * Phalcon\Cache\Backend constructor * - * @param Phalcon\Cache\FrontendInterface frontend - * @param array options + * @param \Phalcon\Cache\FrontendInterface frontend + * @param array options */ public function __construct( frontend, options = null) { diff --git a/phalcon/cache/backend/mongo.zep b/phalcon/cache/backend/mongo.zep index a3b0f4a49b1..664b9f2cded 100644 --- a/phalcon/cache/backend/mongo.zep +++ b/phalcon/cache/backend/mongo.zep @@ -60,7 +60,7 @@ class Mongo extends Backend implements BackendInterface /** * Phalcon\Cache\Backend\Mongo constructor * - * @param Phalcon\Cache\FrontendInterface frontend + * @param \Phalcon\Cache\FrontendInterface frontend * @param array options */ public function __construct( frontend, options = null) diff --git a/phalcon/cache/backend/xcache.zep b/phalcon/cache/backend/xcache.zep index 6fe1a736694..0f362fe68c5 100644 --- a/phalcon/cache/backend/xcache.zep +++ b/phalcon/cache/backend/xcache.zep @@ -53,7 +53,7 @@ class Xcache extends Backend implements BackendInterface /** * Phalcon\Cache\Backend\Xcache constructor * - * @param Phalcon\Cache\FrontendInterface frontend + * @param \Phalcon\Cache\FrontendInterface frontend * @param array options */ public function __construct( frontend, options = null) diff --git a/phalcon/cache/frontend/data.zep b/phalcon/cache/frontend/data.zep index d55d38f3491..9cdd379cfdb 100644 --- a/phalcon/cache/frontend/data.zep +++ b/phalcon/cache/frontend/data.zep @@ -133,7 +133,7 @@ class Data implements FrontendInterface } /** - * Unserializes data after retrieval + * Unserializes data after retrieval */ public function afterRetrieve(var data) { diff --git a/phalcon/cache/multiple.zep b/phalcon/cache/multiple.zep index 9d1acc918a3..66f50b42df3 100644 --- a/phalcon/cache/multiple.zep +++ b/phalcon/cache/multiple.zep @@ -184,4 +184,18 @@ class Multiple return false; } + + /** + * Flush all backend(s) + */ + public function flush() -> boolean + { + var backend; + + for backend in this->_backends { + backend->flush(); + } + + return true; + } } diff --git a/phalcon/cli/router.zep b/phalcon/cli/router.zep index 29746f9c893..793e5f2a556 100644 --- a/phalcon/cli/router.zep +++ b/phalcon/cli/router.zep @@ -389,7 +389,7 @@ class Router implements \Phalcon\Di\InjectionAwareInterface * * @param string pattern * @param string/array paths - * @return Phalcon\Cli\Router\Route + * @return \Phalcon\Cli\Router\Route */ public function add(string! pattern, paths = null) -> { @@ -472,7 +472,7 @@ class Router implements \Phalcon\Di\InjectionAwareInterface * Returns a route object by its id * * @param int id - * @return Phalcon\Cli\Router\Route + * @return \Phalcon\Cli\Router\Route */ public function getRouteById(var id) -> | boolean { diff --git a/phalcon/cli/router/route.zep b/phalcon/cli/router/route.zep index d2346567ecf..969a6315dc3 100644 --- a/phalcon/cli/router/route.zep +++ b/phalcon/cli/router/route.zep @@ -449,7 +449,7 @@ class Route * If the callback returns false the route is treated as not matched * * @param callback callback - * @return Phalcon\Cli\Router\Route + * @return \Phalcon\Cli\Router\Route */ public function beforeMatch(var callback) -> { @@ -518,7 +518,7 @@ class Route * * @param string name * @param callable converter - * @return Phalcon\Cli\Router\Route + * @return \Phalcon\Cli\Router\Route */ public function convert(string! name, converter) -> { diff --git a/phalcon/config.zep b/phalcon/config.zep index c4ed84be8c5..58450bdfdaa 100644 --- a/phalcon/config.zep +++ b/phalcon/config.zep @@ -216,7 +216,7 @@ class Config implements \ArrayAccess, \Countable */ protected final function _merge( config, var instance = null) -> { - var key, value, number; + var key, value, number, localObject; if typeof instance !== "object" { let instance = this; @@ -225,15 +225,21 @@ class Config implements \ArrayAccess, \Countable let number = instance->count(); for key, value in get_object_vars(config) { - if isset(instance->{key}) && typeof value === "object" && typeof instance->{key} === "object" { - this->_merge(value, instance->{key}); - } else { - if typeof key == "integer" { - let key = strval(number); - let number++; + + if fetch localObject, instance->{key} { + if typeof localObject === "object" && typeof value === "object" { + if localObject instanceof Config && value instanceof Config { + this->_merge(value, localObject); + continue; + } } - let instance->{key} = value; } + + if typeof key == "integer" { + let key = strval(number), + number++; + } + let instance->{key} = value; } return instance; diff --git a/phalcon/db.zep b/phalcon/db.zep index 0b526094486..56fec211598 100644 --- a/phalcon/db.zep +++ b/phalcon/db.zep @@ -33,11 +33,14 @@ use \PDO as Pdo; * * Phalcon\Db is an abstract class. You only can use it with a database adapter like Phalcon\Db\Adapter\Pdo * - * + * + *use Phalcon\Db; + *use Phalcon\Db\Exception; + *use Phalcon\Db\Adapter\Pdo\Mysql as MysqlConnection; * *try { * - * $connection = new \Phalcon\Db\Adapter\Pdo\Mysql(array( + * $connection = new MysqlConnection(array( * 'host' => '192.168.0.11', * 'username' => 'sigma', * 'password' => 'secret', @@ -46,15 +49,14 @@ use \PDO as Pdo; * )); * * $result = $connection->query("SELECT * FROM robots LIMIT 5"); - * $result->setFetchMode(Phalcon\Db::FETCH_NUM); + * $result->setFetchMode(Db::FETCH_NUM); * while ($robot = $result->fetch()) { * print_r($robot); * } * - *} catch (Phalcon\Db\Exception $e) { + *} catch (Exception $e) { * echo $e->getMessage(), PHP_EOL; - *} - * + *} * */ abstract class Db diff --git a/phalcon/db/adapter.zep b/phalcon/db/adapter.zep index 6a2ecb8f3ab..7a67a0707d5 100644 --- a/phalcon/db/adapter.zep +++ b/phalcon/db/adapter.zep @@ -731,7 +731,7 @@ abstract class Adapter implements EventsAwareInterface } /** - * Creates a view + * Creates a view */ public function createView(string! viewName, array! definition, var schemaName = null) -> boolean { diff --git a/phalcon/db/adapter/pdo.zep b/phalcon/db/adapter/pdo.zep index d641e62038b..f181a2bed0e 100644 --- a/phalcon/db/adapter/pdo.zep +++ b/phalcon/db/adapter/pdo.zep @@ -242,7 +242,7 @@ abstract class Pdo extends Adapter /** * 1024 is ignore the bind type */ - if typeof castValue != "array" { + if typeof castValue != "array" { if type == Column::BIND_SKIP { statement->bindValue(parameter, castValue); } else { diff --git a/phalcon/db/adapterinterface.zep b/phalcon/db/adapterinterface.zep index 7bc432eb3f7..4b362c464b8 100644 --- a/phalcon/db/adapterinterface.zep +++ b/phalcon/db/adapterinterface.zep @@ -277,7 +277,7 @@ interface AdapterInterface /** * Sends SQL statements to the database server returning the success state. - * Use this method only when the SQL statement sent to the server doesn't return any rows + * Use this method only when the SQL statement sent to the server doesn't return any rows */ public function execute(string! sqlStatement, var placeholders = null, var dataTypes = null) -> boolean; diff --git a/phalcon/db/column.zep b/phalcon/db/column.zep index 324cbeb5305..ccf414be97c 100644 --- a/phalcon/db/column.zep +++ b/phalcon/db/column.zep @@ -514,7 +514,7 @@ class Column implements ColumnInterface } if fetch scale, data["_scale"] { - + switch definition["type"] { case self::TYPE_INTEGER: diff --git a/phalcon/db/dialect/postgresql.zep b/phalcon/db/dialect/postgresql.zep index 744d8a0f34f..217466db7c4 100644 --- a/phalcon/db/dialect/postgresql.zep +++ b/phalcon/db/dialect/postgresql.zep @@ -114,7 +114,7 @@ class Postgresql extends Dialect case Column::TYPE_BIGINTEGER: if empty columnSql { let columnSql .= "BIGINT"; - } + } if size { let columnSql .= "(" . column->getSize() . ")"; } @@ -381,7 +381,7 @@ class Postgresql extends Dialect let createLines[] = columnLine; } if !empty primaryColumns { - let createLines[] = "PRIMARY KEY (" . implode(",",primaryColumns) . ")"; + let createLines[] = "PRIMARY KEY (" . this->getColumnList(primaryColumns) . ")"; } /** diff --git a/phalcon/db/profiler.zep b/phalcon/db/profiler.zep index 552bce75c5c..b56176a7fee 100644 --- a/phalcon/db/profiler.zep +++ b/phalcon/db/profiler.zep @@ -82,7 +82,7 @@ class Profiler * Starts the profile of a SQL sentence * * @param string sqlStatement - * @return Phalcon\Db\Profiler + * @return \Phalcon\Db\Profiler */ public function startProfile(var sqlStatement, var sqlVariables = null, var sqlBindTypes = null) -> { diff --git a/phalcon/db/result/pdo.zep b/phalcon/db/result/pdo.zep index 1746df26ed1..87857c17bca 100644 --- a/phalcon/db/result/pdo.zep +++ b/phalcon/db/result/pdo.zep @@ -69,7 +69,7 @@ class Pdo implements ResultInterface /** * Phalcon\Db\Result\Pdo constructor * - * @param Phalcon\Db\AdapterInterface connection + * @param \Phalcon\Db\AdapterInterface connection * @param \PDOStatement result * @param string sqlStatement * @param array bindParams @@ -115,7 +115,7 @@ class Pdo implements ResultInterface * */ public function $fetch(var fetchStyle = null, var cursorOrientation = null, var cursorOffset = null) - { + { return this->_pdoStatement->$fetch(fetchStyle, cursorOrientation, cursorOffset); } diff --git a/phalcon/db/resultinterface.zep b/phalcon/db/resultinterface.zep index 3db8bf4f48c..256a04bec8e 100644 --- a/phalcon/db/resultinterface.zep +++ b/phalcon/db/resultinterface.zep @@ -30,7 +30,7 @@ interface ResultInterface /** * Phalcon\Db\Result\Pdo constructor * - * @param Phalcon\Db\AdapterInterface connection + * @param \Phalcon\Db\AdapterInterface connection * @param \PDOStatement result * @param string sqlStatement * @param array bindParams diff --git a/phalcon/debug.zep b/phalcon/debug.zep index 0b14739478b..94421230f17 100644 --- a/phalcon/debug.zep +++ b/phalcon/debug.zep @@ -364,7 +364,7 @@ class Debug let classReflection = new \ReflectionClass(className); /** - * Check if classes are PHP"s classes + * Check if classes are PHP's classes */ if classReflection->isInternal() { @@ -606,7 +606,7 @@ class Debug /** * CSS static sources to style the error presentation - * Use the exception info as document"s title + * Use the exception info as document's title */ let html = "" . className . ": " . escapedMessage . ""; let html .= this->getCssSources() . " "; diff --git a/phalcon/di.zep b/phalcon/di.zep index 1ba1811ab9e..e6634057097 100755 --- a/phalcon/di.zep +++ b/phalcon/di.zep @@ -31,7 +31,7 @@ use Phalcon\Di\InjectionAwareInterface; * Phalcon\Di * * Phalcon\Di is a component that implements Dependency Injection/Service Location - * of services and it"s itself a container for them. + * of services and it's itself a container for them. * * Since Phalcon is highly decoupled, Phalcon\Di is essential to integrate the different * components of the framework. The developer can also use this component to inject dependencies @@ -150,7 +150,7 @@ class Di implements DiInterface /** * Attempts to register a service in the services container - * Only is successful if a service hasn"t been registered previously + * Only is successful if a service hasn't been registered previously * with the same name */ public function attempt(string! name, definition, boolean shared = false) -> | boolean @@ -205,6 +205,7 @@ class Di implements DiInterface /** * Resolves the service based on its configuration + * @returm mixed */ public function get(string! name, parameters = null) { diff --git a/phalcon/di/factorydefault.zep b/phalcon/di/factorydefault.zep index 5d7657bb858..ae9dd4fe5d3 100644 --- a/phalcon/di/factorydefault.zep +++ b/phalcon/di/factorydefault.zep @@ -56,7 +56,7 @@ class FactoryDefault extends \Phalcon\Di "session": new Service("session", "Phalcon\\Session\\Adapter\\Files", true), "sessionBag": new Service("sessionBag", "Phalcon\\Session\\Bag"), "eventsManager": new Service("eventsManager", "Phalcon\\Events\\Manager", true), - "transactionManager": new Service("transactions", "Phalcon\\Mvc\\Model\\Transaction\\Manager", true), + "transactionManager": new Service("transactionManager", "Phalcon\\Mvc\\Model\\Transaction\\Manager", true), "assets": new Service("assets", "Phalcon\\Assets\\Manager", true) ]; } diff --git a/phalcon/di/injectable.zep b/phalcon/di/injectable.zep index 4db3735fa8b..d614297d63c 100644 --- a/phalcon/di/injectable.zep +++ b/phalcon/di/injectable.zep @@ -54,7 +54,7 @@ use Phalcon\Session\BagInterface; * @property \Phalcon\Mvc\Model\MetaData\Memory|\Phalcon\Mvc\Model\MetadataInterface $modelsMetadata * @property \Phalcon\Mvc\Model\Transaction\Manager $transactionManager * @property \Phalcon\Assets\Manager $assets - * @property \Phalcon\DI|\Phalcon\DiInterface $di + * @property \Phalcon\Di|\Phalcon\DiInterface $di * @property \Phalcon\Session\Bag $persistent * @property \Phalcon\Mvc\View|\Phalcon\Mvc\ViewInterface $view */ diff --git a/phalcon/di/service.zep b/phalcon/di/service.zep index 52cd70b39a6..9df5d8d67e1 100644 --- a/phalcon/di/service.zep +++ b/phalcon/di/service.zep @@ -120,7 +120,7 @@ class Service implements ServiceInterface * Resolves the service * * @param array parameters - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\DiInterface dependencyInjector * @return mixed */ public function resolve(parameters = null, dependencyInjector = null) @@ -157,7 +157,7 @@ class Service implements ServiceInterface let instance = create_instance(definition); } } else { - let instance = create_instance(definition); + let instance = create_instance(definition); } } else { let found = false; diff --git a/phalcon/di/service/builder.zep b/phalcon/di/service/builder.zep index 973132492ae..3a471dce1d6 100644 --- a/phalcon/di/service/builder.zep +++ b/phalcon/di/service/builder.zep @@ -19,8 +19,8 @@ namespace Phalcon\Di\Service; -use Phalcon\Di\Exception; use Phalcon\DiInterface; +use Phalcon\Di\Exception; /** * Phalcon\Di\Service\Builder @@ -33,7 +33,7 @@ class Builder /** * Resolves a constructor/call parameter * - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\DiInterface dependencyInjector * @param int position * @param array argument * @return mixed @@ -122,7 +122,7 @@ class Builder /** * Builds a service using a complex service definition * - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\DiInterface dependencyInjector * @param array definition * @param array parameters * @return mixed @@ -164,7 +164,7 @@ class Builder let instance = create_instance_params(className, this->_buildParameters(dependencyInjector, arguments)); } else { - let instance = create_instance(className); + let instance = create_instance(className); } } @@ -223,7 +223,6 @@ class Builder */ continue; } - } /** @@ -231,7 +230,6 @@ class Builder */ call_user_func(methodCall); } - } /** @@ -278,7 +276,6 @@ class Builder */ let instance->{propertyName} = this->_buildParameter(dependencyInjector, propertyPosition, propertyValue); } - } return instance; diff --git a/phalcon/di/serviceinterface.zep b/phalcon/di/serviceinterface.zep index 28d7cb0e7a8..cc94263e963 100644 --- a/phalcon/di/serviceinterface.zep +++ b/phalcon/di/serviceinterface.zep @@ -71,11 +71,16 @@ interface ServiceInterface * Resolves the service * * @param array parameters - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\DiInterface dependencyInjector * @return mixed */ public function resolve(parameters = null, <\Phalcon\DiInterface> dependencyInjector = null); + /** + * Changes a parameter in the definition without resolve the service + */ + public function setParameter(int position, array! parameter) -> ; + /** * Restore the interal state of a service */ diff --git a/phalcon/diinterface.zep b/phalcon/diinterface.zep index 1fea184fc57..587037ee137 100644 --- a/phalcon/diinterface.zep +++ b/phalcon/diinterface.zep @@ -36,7 +36,7 @@ interface DiInterface extends \ArrayAccess * @param string name * @param mixed definition * @param boolean shared - * @return Phalcon\Di\ServiceInterface + * @return \Phalcon\Di\ServiceInterface */ public function set(string! name, definition, boolean shared = false) -> ; @@ -45,7 +45,7 @@ interface DiInterface extends \ArrayAccess * * @param string name * @param mixed definition - * @return Phalcon\Di\ServiceInterface + * @return \Phalcon\Di\ServiceInterface */ public function setShared(string! name, definition) -> ; @@ -62,7 +62,7 @@ interface DiInterface extends \ArrayAccess * @param string name * @param mixed definition * @param boolean shared - * @return Phalcon\Di\ServiceInterface + * @return \Phalcon\Di\ServiceInterface */ public function attempt(string! name, definition, boolean shared = false) -> ; diff --git a/phalcon/events/manager.zep b/phalcon/events/manager.zep index ca22bf4977f..cd450cb448d 100644 --- a/phalcon/events/manager.zep +++ b/phalcon/events/manager.zep @@ -199,7 +199,7 @@ class Manager implements ManagerInterface * Internal handler to call a queue of events * * @param \SplPriorityQueue|array queue - * @param Phalcon\Events\Event event + * @param \Phalcon\Events\Event event * @return mixed */ public final function fireQueue(var queue, event) diff --git a/phalcon/forms/element.zep b/phalcon/forms/element.zep index 397c722ac38..98d2b832a1f 100755 --- a/phalcon/forms/element.zep +++ b/phalcon/forms/element.zep @@ -104,7 +104,7 @@ abstract class Element implements ElementInterface * Sets the element filters * * @param array|string filters - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function setFilters(var filters) -> { @@ -122,7 +122,7 @@ abstract class Element implements ElementInterface { var filters; let filters = this->_filters; - if typeof filters == "array" { + if typeof filters == "array" { let this->_filters[] = filter; } else { if typeof filters == "string" { @@ -147,8 +147,8 @@ abstract class Element implements ElementInterface /** * Adds a group of validators * - * @param Phalcon\Validation\ValidatorInterface[] - * @return Phalcon\Forms\ElementInterface + * @param \Phalcon\Validation\ValidatorInterface[] + * @return \Phalcon\Forms\ElementInterface */ public function addValidators(array! validators, boolean merge = true) -> { @@ -257,7 +257,7 @@ abstract class Element implements ElementInterface * * @param string attribute * @param mixed value - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function setAttribute(string attribute, value) -> { @@ -309,7 +309,7 @@ abstract class Element implements ElementInterface * * @param string option * @param mixed value - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function setUserOption(string option, value) -> { @@ -337,7 +337,7 @@ abstract class Element implements ElementInterface * Sets options for the element * * @param array options - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function setUserOptions(options) -> { @@ -419,7 +419,7 @@ abstract class Element implements ElementInterface * or there is no value available for the element in _POST * * @param mixed value - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function setDefault(value) -> { diff --git a/phalcon/forms/element/check.zep b/phalcon/forms/element/check.zep index 7a21f1739de..4a2027e58f7 100644 --- a/phalcon/forms/element/check.zep +++ b/phalcon/forms/element/check.zep @@ -19,6 +19,7 @@ namespace Phalcon\Forms\Element; +use Phalcon\Tag; use Phalcon\Forms\Element; use Phalcon\Forms\ElementInterface; @@ -38,6 +39,6 @@ class Check extends Element implements ElementInterface */ public function render(var attributes = null) -> string { - return \Phalcon\Tag::checkField(this->prepareAttributes(attributes, true)); + return Tag::checkField(this->prepareAttributes(attributes, true)); } } diff --git a/phalcon/forms/element/date.zep b/phalcon/forms/element/date.zep index 4ff00c51074..33ec4312c8b 100644 --- a/phalcon/forms/element/date.zep +++ b/phalcon/forms/element/date.zep @@ -19,6 +19,7 @@ namespace Phalcon\Forms\Element; +use Phalcon\Tag; use Phalcon\Forms\Element; use Phalcon\Forms\ElementInterface; @@ -38,6 +39,6 @@ class Date extends Element implements ElementInterface */ public function render(var attributes = null) -> string { - return \Phalcon\Tag::dateField(this->prepareAttributes(attributes)); + return Tag::dateField(this->prepareAttributes(attributes)); } -} \ No newline at end of file +} diff --git a/phalcon/forms/element/email.zep b/phalcon/forms/element/email.zep index da6494d80b7..687ececdb40 100644 --- a/phalcon/forms/element/email.zep +++ b/phalcon/forms/element/email.zep @@ -19,6 +19,7 @@ namespace Phalcon\Forms\Element; +use Phalcon\Tag; use Phalcon\Forms\Element; use Phalcon\Forms\ElementInterface; @@ -38,6 +39,6 @@ class Email extends Element implements ElementInterface */ public function render(var attributes = null) -> string { - return \Phalcon\Tag::emailField(this->prepareAttributes(attributes)); + return Tag::emailField(this->prepareAttributes(attributes)); } } diff --git a/phalcon/forms/element/file.zep b/phalcon/forms/element/file.zep index 0ceb26ba2b2..880dc232c49 100644 --- a/phalcon/forms/element/file.zep +++ b/phalcon/forms/element/file.zep @@ -19,6 +19,7 @@ namespace Phalcon\Forms\Element; +use Phalcon\Tag; use Phalcon\Forms\Element; use Phalcon\Forms\ElementInterface; @@ -38,7 +39,6 @@ class File extends Element implements ElementInterface */ public function render(attributes = null) -> string { - return \Phalcon\Tag::fileField(this->prepareAttributes(attributes)); + return Tag::fileField(this->prepareAttributes(attributes)); } - } diff --git a/phalcon/forms/element/hidden.zep b/phalcon/forms/element/hidden.zep index 415a7a78ad0..21c0838eff7 100644 --- a/phalcon/forms/element/hidden.zep +++ b/phalcon/forms/element/hidden.zep @@ -19,6 +19,7 @@ namespace Phalcon\Forms\Element; +use Phalcon\Tag; use Phalcon\Forms\Element; use Phalcon\Forms\ElementInterface; @@ -38,6 +39,6 @@ class Hidden extends Element implements ElementInterface */ public function render(attributes = null) -> string { - return \Phalcon\Tag::hiddenField(this->prepareAttributes(attributes)); + return Tag::hiddenField(this->prepareAttributes(attributes)); } -} \ No newline at end of file +} diff --git a/phalcon/forms/element/numeric.zep b/phalcon/forms/element/numeric.zep index 23ddbfe58ac..16e98d0c122 100644 --- a/phalcon/forms/element/numeric.zep +++ b/phalcon/forms/element/numeric.zep @@ -19,6 +19,7 @@ namespace Phalcon\Forms\Element; +use Phalcon\Tag; use Phalcon\Forms\Element; use Phalcon\Forms\ElementInterface; @@ -38,6 +39,6 @@ class Numeric extends Element implements ElementInterface */ public function render(attributes = null) -> string { - return \Phalcon\Tag::numericField(this->prepareAttributes(attributes)); + return Tag::numericField(this->prepareAttributes(attributes)); } } diff --git a/phalcon/forms/element/password.zep b/phalcon/forms/element/password.zep index 8a1dc482398..efe8581c768 100644 --- a/phalcon/forms/element/password.zep +++ b/phalcon/forms/element/password.zep @@ -19,6 +19,7 @@ namespace Phalcon\Forms\Element; +use Phalcon\Tag; use Phalcon\Forms\Element; use Phalcon\Forms\ElementInterface; @@ -38,6 +39,6 @@ class Password extends Element implements ElementInterface */ public function render(attributes = null) -> string { - return \Phalcon\Tag::passwordField(this->prepareAttributes(attributes)); + return Tag::passwordField(this->prepareAttributes(attributes)); } } diff --git a/phalcon/forms/element/radio.zep b/phalcon/forms/element/radio.zep index 441ecf9a427..3c0a48cd39c 100644 --- a/phalcon/forms/element/radio.zep +++ b/phalcon/forms/element/radio.zep @@ -19,6 +19,7 @@ namespace Phalcon\Forms\Element; +use Phalcon\Tag; use Phalcon\Forms\Element; use Phalcon\Forms\ElementInterface; @@ -38,6 +39,6 @@ class Radio extends Element implements ElementInterface */ public function render(attributes = null) -> string { - return \Phalcon\Tag::radioField(this->prepareAttributes(attributes, true)); + return Tag::radioField(this->prepareAttributes(attributes, true)); } } diff --git a/phalcon/forms/element/select.zep b/phalcon/forms/element/select.zep index 27b48b41e56..172d83f2eff 100644 --- a/phalcon/forms/element/select.zep +++ b/phalcon/forms/element/select.zep @@ -19,6 +19,7 @@ namespace Phalcon\Forms\Element; +use Phalcon\Tag\Select; use Phalcon\Forms\Element; use Phalcon\Forms\ElementInterface; @@ -27,7 +28,8 @@ use Phalcon\Forms\ElementInterface; * * Component SELECT (choice) for forms */ -class Select extends Element implements ElementInterface { +class Select extends Element implements ElementInterface +{ protected _optionsValues; @@ -48,7 +50,7 @@ class Select extends Element implements ElementInterface { * Set the choice's options * * @param array|object options - * @return Phalcon\Forms\Element + * @return \Phalcon\Forms\Element */ public function setOptions(var options) -> { @@ -74,7 +76,16 @@ class Select extends Element implements ElementInterface { */ public function addOption(var option) -> { - let this->_optionsValues[] = option; + var key, value; + + if typeof option == "array" { + for key, value in option { + let this->_optionsValues[key] = value; + } + } else { + let this->_optionsValues[] = option; + } + return this; } @@ -89,6 +100,6 @@ class Select extends Element implements ElementInterface { /** * Merged passed attributes with previously defined ones */ - return \Phalcon\Tag\Select::selectField(this->prepareAttributes(attributes), this->_optionsValues); + return Select::selectField(this->prepareAttributes(attributes), this->_optionsValues); } } diff --git a/phalcon/forms/element/submit.zep b/phalcon/forms/element/submit.zep index 9ebbafdc2d9..bc6273661a0 100644 --- a/phalcon/forms/element/submit.zep +++ b/phalcon/forms/element/submit.zep @@ -19,6 +19,7 @@ namespace Phalcon\Forms\Element; +use Phalcon\Tag; use Phalcon\Forms\Element; use Phalcon\Forms\ElementInterface; @@ -41,6 +42,6 @@ class Submit extends Element implements ElementInterface /** * Merged passed attributes with previously defined ones */ - return \Phalcon\Tag::submitButton(this->prepareAttributes(attributes)); + return Tag::submitButton(this->prepareAttributes(attributes)); } } diff --git a/phalcon/forms/element/text.zep b/phalcon/forms/element/text.zep index a370c25902e..a7ceb9f1a64 100644 --- a/phalcon/forms/element/text.zep +++ b/phalcon/forms/element/text.zep @@ -19,6 +19,7 @@ namespace Phalcon\Forms\Element; +use Phalcon\Tag; use Phalcon\Forms\Element; use Phalcon\Forms\ElementInterface; @@ -38,6 +39,6 @@ class Text extends Element implements ElementInterface */ public function render(attributes = null) -> string { - return \Phalcon\Tag::textField(this->prepareAttributes(attributes)); + return Tag::textField(this->prepareAttributes(attributes)); } } diff --git a/phalcon/forms/element/textarea.zep b/phalcon/forms/element/textarea.zep index 2ca0f3e984e..5c384f7f8c7 100644 --- a/phalcon/forms/element/textarea.zep +++ b/phalcon/forms/element/textarea.zep @@ -19,6 +19,7 @@ namespace Phalcon\Forms\Element; +use Phalcon\Tag; use Phalcon\Forms\Element; use Phalcon\Forms\ElementInterface; @@ -38,6 +39,6 @@ class TextArea extends Element implements ElementInterface */ public function render(attributes = null) -> string { - return \Phalcon\Tag::textArea(this->prepareAttributes(attributes)); + return Tag::textArea(this->prepareAttributes(attributes)); } } diff --git a/phalcon/forms/elementinterface.zep b/phalcon/forms/elementinterface.zep index 209b2b163b3..39bb2aec390 100644 --- a/phalcon/forms/elementinterface.zep +++ b/phalcon/forms/elementinterface.zep @@ -34,15 +34,15 @@ interface ElementInterface /** * Sets the parent form to the element * - * @param Phalcon\Forms\Form form - * @return Phalcon\Forms\ElementInterface + * @param \Phalcon\Forms\Form form + * @return \Phalcon\Forms\ElementInterface */ public function setForm(<\Phalcon\Forms\Form> form); /** * Returns the parent form to the element * - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function getForm(); @@ -50,7 +50,7 @@ interface ElementInterface * Sets the element's name * * @param string name - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function setName(string name); @@ -63,7 +63,7 @@ interface ElementInterface * Sets the element's filters * * @param array|string filters - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function setFilters(filters); @@ -71,7 +71,7 @@ interface ElementInterface * Adds a filter to current list of filters * * @param string filter - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function addFilter(filter); @@ -85,24 +85,24 @@ interface ElementInterface /** * Adds a group of validators * - * @param Phalcon\Validation\ValidatorInterface[] + * @param \Phalcon\Validation\ValidatorInterface[] * @param boolean merge - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function addValidators(array! validators, merge = true); /** * Adds a validator to the element * - * @param Phalcon\Validation\ValidatorInterface - * @return Phalcon\Forms\ElementInterface + * @param \Phalcon\Validation\ValidatorInterface + * @return \Phalcon\Forms\ElementInterface */ public function addValidator( validator); /** * Returns the validators registered for the element * - * @return Phalcon\Validation\ValidatorInterface[] + * @return \Phalcon\Validation\ValidatorInterface[] */ public function getValidators(); @@ -121,7 +121,7 @@ interface ElementInterface * * @param string attribute * @param mixed value - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function setAttribute(attribute, value); @@ -138,7 +138,7 @@ interface ElementInterface * Sets default attributes for the element * * @param array attributes - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function setAttributes(array! attributes); @@ -152,7 +152,7 @@ interface ElementInterface * * @param string option * @param mixed value - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function setUserOption(option, value); @@ -169,7 +169,7 @@ interface ElementInterface * Sets options for the element * * @param array options - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function setUserOptions(options); @@ -184,7 +184,7 @@ interface ElementInterface * Sets the element label * * @param string label - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function setLabel(label); @@ -203,7 +203,7 @@ interface ElementInterface * or there is no value available for the element in _POST * * @param mixed value - * @return Phalcon\Forms\ElementInterface + * @return \Phalcon\Forms\ElementInterface */ public function setDefault(value); @@ -225,7 +225,7 @@ interface ElementInterface * Returns the messages that belongs to the element * The element needs to be attached to a form * - * @return Phalcon\Validation\Message\Group + * @return \Phalcon\Validation\Message\Group */ public function getMessages(); @@ -237,23 +237,23 @@ interface ElementInterface /** * Sets the validation messages related to the element * - * @param Phalcon\Validation\Message\Group group - * @return Phalcon\Forms\ElementInterface + * @param \Phalcon\Validation\Message\Group group + * @return \Phalcon\Forms\ElementInterface */ public function setMessages( group); /** * Appends a message to the internal message list * - * @param Phalcon\Validation\Message message - * @return Phalcon\Forms\ElementInterface + * @param \Phalcon\Validation\Message message + * @return \Phalcon\Forms\ElementInterface */ public function appendMessage( message); /** * Clears every element in the form to its default value * - * @return Phalcon\Forms\Element + * @return \Phalcon\Forms\Element */ public function clear(); diff --git a/phalcon/forms/form.zep b/phalcon/forms/form.zep index 7840420b7d8..1f3e71231a6 100644 --- a/phalcon/forms/form.zep +++ b/phalcon/forms/form.zep @@ -86,7 +86,7 @@ class Form extends Injectable implements \Countable, \Iterator * Sets the form's action * * @param string action - * @return Phalcon\Forms\Form + * @return \Phalcon\Forms\Form */ public function setAction(var action) ->
{ @@ -107,7 +107,7 @@ class Form extends Injectable implements \Countable, \Iterator * * @param string option * @param mixed value - * @return Phalcon\Forms\Form + * @return \Phalcon\Forms\Form */ public function setUserOption(var option, var value) -> { @@ -154,7 +154,7 @@ class Form extends Injectable implements \Countable, \Iterator * Sets the entity related to the model * * @param object entity - * @return Phalcon\Forms\Form + * @return \Phalcon\Forms\Form */ public function setEntity(var entity) -> { @@ -186,7 +186,7 @@ class Form extends Injectable implements \Countable, \Iterator * @param array data * @param object entity * @param array whitelist - * @return Phalcon\Forms\Form + * @return \Phalcon\Forms\Form */ public function bind(array! data, var entity, var whitelist = null) -> { @@ -412,7 +412,7 @@ class Form extends Injectable implements \Countable, \Iterator * Returns the messages generated for a specific element * * @param string name - * @return Phalcon\Validation\Message\Group + * @return \Phalcon\Validation\Message\Group */ public function getMessagesFor(var name) -> { @@ -442,10 +442,10 @@ class Form extends Injectable implements \Countable, \Iterator /** * Adds an element to the form * - * @param Phalcon\Forms\ElementInterface element + * @param \Phalcon\Forms\ElementInterface element * @param string $postion * @param bool $type If $type is TRUE, the element wile add before $postion, else is after - * @return Phalcon\Forms\Form + * @return \Phalcon\Forms\Form */ public function add( element, string postion = null, boolean type = null) -> { @@ -666,7 +666,7 @@ class Form extends Injectable implements \Countable, \Iterator * Clears every element in the form to its default value * * @param array fields - * @return Phalcon\Forms\Form + * @return \Phalcon\Forms\Form */ public function clear(var fields = null) -> { diff --git a/phalcon/forms/manager.zep b/phalcon/forms/manager.zep index 7b32623939a..16a4cc4361d 100644 --- a/phalcon/forms/manager.zep +++ b/phalcon/forms/manager.zep @@ -31,7 +31,7 @@ class Manager * * @param string name * @param object entity - * @return Phalcon\Forms\Form + * @return \Phalcon\Forms\Form */ public function create(name = null, entity = null) -> { diff --git a/phalcon/http/cookie.zep b/phalcon/http/cookie.zep index 9586695b17e..b5cc087fdb5 100644 --- a/phalcon/http/cookie.zep +++ b/phalcon/http/cookie.zep @@ -30,7 +30,7 @@ use Phalcon\Session\AdapterInterface as SessionInterface; * * Provide OO wrappers to manage a HTTP cookie */ -class Cookie implements InjectionAwareInterface +class Cookie implements CookieInterface, InjectionAwareInterface { protected _readed = false; @@ -115,9 +115,9 @@ class Cookie implements InjectionAwareInterface * Sets the cookie's value * * @param string value - * @return Phalcon\Http\Cookie + * @return \Phalcon\Http\Cookie */ - public function setValue(value) -> + public function setValue(value) -> { let this->_value = value, this->_readed = true; @@ -201,7 +201,7 @@ class Cookie implements InjectionAwareInterface * Sends the cookie to the HTTP client * Stores the cookie definition in session */ - public function send() -> + public function send() -> { var name, value, expire, domain, path, secure, httpOnly, dependencyInjector, definition, session, crypt, encryptValue; @@ -247,7 +247,9 @@ class Cookie implements InjectionAwareInterface */ if count(definition) { let session = dependencyInjector->getShared("session"); - session->set("_PHCOOKIE_" . name, definition); + if session->isStarted() { + session->set("_PHCOOKIE_" . name, definition); + } } if this->_useEncryption { @@ -285,7 +287,7 @@ class Cookie implements InjectionAwareInterface * Reads the cookie-related info from the SESSION to restore the cookie as it was set * This method is automatically called internally so normally you don't need to call it */ - public function restore() -> + public function restore() -> { var dependencyInjector, expire, domain, path, secure, httpOnly, session, definition; @@ -297,27 +299,29 @@ class Cookie implements InjectionAwareInterface let session = dependencyInjector->getShared("session"); - let definition = session->get("_PHCOOKIE_" . this->_name); - if typeof definition == "array" { + if session->isStarted() { + let definition = session->get("_PHCOOKIE_" . this->_name); + if typeof definition == "array" { - if fetch expire, definition["expire"] { - let this->_expire = expire; - } + if fetch expire, definition["expire"] { + let this->_expire = expire; + } - if fetch domain, definition["domain"] { - let this->_domain = domain; - } + if fetch domain, definition["domain"] { + let this->_domain = domain; + } - if fetch path, definition["path"] { - let this->_path = path; - } + if fetch path, definition["path"] { + let this->_path = path; + } - if fetch secure, definition["secure"] { - let this->_secure = secure; - } + if fetch secure, definition["secure"] { + let this->_secure = secure; + } - if fetch httpOnly, definition["httpOnly"] { - let this->_httpOnly = httpOnly; + if fetch httpOnly, definition["httpOnly"] { + let this->_httpOnly = httpOnly; + } } } } @@ -344,7 +348,9 @@ class Cookie implements InjectionAwareInterface let dependencyInjector = this->_dependencyInjector; if typeof dependencyInjector != "object" { let session = dependencyInjector->getShared("session"); - session->remove("_PHCOOKIE_" . name); + if session->isStarted() { + session->remove("_PHCOOKIE_" . name); + } } let this->_value = null; @@ -354,7 +360,7 @@ class Cookie implements InjectionAwareInterface /** * Sets if the cookie must be encrypted/decrypted automatically */ - public function useEncryption(boolean useEncryption) -> + public function useEncryption(boolean useEncryption) -> { let this->_useEncryption = useEncryption; return this; @@ -371,7 +377,7 @@ class Cookie implements InjectionAwareInterface /** * Sets the cookie's expiration time */ - public function setExpiration(int expire) -> + public function setExpiration(int expire) -> { if !this->_restored { this->restore(); @@ -394,7 +400,7 @@ class Cookie implements InjectionAwareInterface /** * Sets the cookie's expiration time */ - public function setPath(string! path) -> + public function setPath(string! path) -> { if !this->_restored { this->restore(); @@ -425,7 +431,7 @@ class Cookie implements InjectionAwareInterface /** * Sets the domain that the cookie is available to */ - public function setDomain(string! domain) -> + public function setDomain(string! domain) -> { if !this->_restored { this->restore(); @@ -448,7 +454,7 @@ class Cookie implements InjectionAwareInterface /** * Sets if the cookie must only be sent when the connection is secure (HTTPS) */ - public function setSecure(boolean secure) -> + public function setSecure(boolean secure) -> { if !this->_restored { this->restore(); @@ -471,7 +477,7 @@ class Cookie implements InjectionAwareInterface /** * Sets if the cookie is accessible only through the HTTP protocol */ - public function setHttpOnly(boolean httpOnly) -> + public function setHttpOnly(boolean httpOnly) -> { if !this->_restored { this->restore(); diff --git a/phalcon/http/cookieinterface.zep b/phalcon/http/cookieinterface.zep new file mode 100644 index 00000000000..e0c6e5747d0 --- /dev/null +++ b/phalcon/http/cookieinterface.zep @@ -0,0 +1,119 @@ + +/* + +------------------------------------------------------------------------+ + | Phalcon Framework | + +------------------------------------------------------------------------+ + | Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) | + +------------------------------------------------------------------------+ + | This source file is subject to the New BSD License that is bundled | + | with this package in the file docs/LICENSE.txt. | + | | + | If you did not receive a copy of the license and are unable to | + | obtain it through the world-wide-web, please send an email | + | to license@phalconphp.com so we can send you a copy immediately. | + +------------------------------------------------------------------------+ + | Authors: Olivier Garbe ; + + /** + * Returns the cookie's value + * + * @param string|array filters + * @param string defaultValue + * @return mixed + */ + public function getValue(filters = null, defaultValue = null); + + /** + * Sends the cookie to the HTTP client + */ + public function send() -> ; + + /** + * Deletes the cookie + */ + public function delete(); + + /** + * Sets if the cookie must be encrypted/decrypted automatically + */ + public function useEncryption(boolean useEncryption) -> ; + + /** + * Check if the cookie is using implicit encryption + */ + public function isUsingEncryption() -> boolean; + + /** + * Sets the cookie's expiration time + */ + public function setExpiration(int expire) -> ; + + /** + * Returns the current expiration time + */ + public function getExpiration() -> string; + + /** + * Sets the cookie's expiration time + */ + public function setPath(string! path) -> ; + + /** + * Returns the current cookie's name + */ + public function getName() -> string; + + /** + * Returns the current cookie's path + */ + public function getPath() -> string; + + /** + * Sets the domain that the cookie is available to + */ + public function setDomain(string! domain) -> ; + + /** + * Returns the domain that the cookie is available to + */ + public function getDomain() -> string; + + /** + * Sets if the cookie must only be sent when the connection is secure (HTTPS) + */ + public function setSecure(boolean secure) -> ; + + /** + * Returns whether the cookie must only be sent when the connection is secure (HTTPS) + */ + public function getSecure() -> boolean; + + /** + * Sets if the cookie is accessible only through the HTTP protocol + */ + public function setHttpOnly(boolean httpOnly) -> ; + + /** + * Returns if the cookie is accessible only through the HTTP protocol + */ + public function getHttpOnly() -> boolean; +} diff --git a/phalcon/http/response.zep b/phalcon/http/response.zep index 989f4a34120..e859e2644f2 100644 --- a/phalcon/http/response.zep +++ b/phalcon/http/response.zep @@ -268,7 +268,7 @@ class Response implements ResponseInterface, InjectionAwareInterface /** * Returns coookies set by the user * - * @return Phalcon\Http\Response\CookiesInterface + * @return \Phalcon\Http\Response\CookiesInterface */ public function getCookies() -> { @@ -284,7 +284,7 @@ class Response implements ResponseInterface, InjectionAwareInterface * * @param string name * @param string value - * @return Phalcon\Http\Response + * @return \Phalcon\Http\Response */ public function setHeader(string name, value) -> { @@ -385,7 +385,7 @@ class Response implements ResponseInterface, InjectionAwareInterface * * @param string contentType * @param string charset - * @return Phalcon\Http\Response + * @return \Phalcon\Http\Response */ public function setContentType(string contentType, charset = null) -> { @@ -434,7 +434,7 @@ class Response implements ResponseInterface, InjectionAwareInterface * @param string|array location * @param boolean externalRedirect * @param int statusCode - * @return Phalcon\Http\Response + * @return \Phalcon\Http\Response */ public function redirect(location = null, boolean externalRedirect = false, int statusCode = 302) -> { @@ -515,7 +515,7 @@ class Response implements ResponseInterface, InjectionAwareInterface * * @param mixed content * @param int jsonOptions - * @return Phalcon\Http\Response + * @return \Phalcon\Http\Response */ public function setJsonContent(var content, jsonOptions = 0, depth = 512) -> { @@ -527,7 +527,7 @@ class Response implements ResponseInterface, InjectionAwareInterface * Appends a string to the HTTP response body * * @param string content - * @return Phalcon\Http\Response + * @return \Phalcon\Http\Response */ public function appendContent(content) -> { @@ -627,7 +627,7 @@ class Response implements ResponseInterface, InjectionAwareInterface * * @param string filePath * @param string attachmentName - * @return Phalcon\Http\Response + * @return \Phalcon\Http\Response */ public function setFileToSend(string filePath, attachmentName = null, attachment = true) -> { diff --git a/phalcon/http/response/cookies.zep b/phalcon/http/response/cookies.zep index 748c5575a59..8c24e7e5dd9 100644 --- a/phalcon/http/response/cookies.zep +++ b/phalcon/http/response/cookies.zep @@ -20,7 +20,7 @@ namespace Phalcon\Http\Response; use Phalcon\DiInterface; -use Phalcon\Http\Cookie; +use Phalcon\Http\CookieInterface; use Phalcon\Http\Response\CookiesInterface; use Phalcon\Di\InjectionAwareInterface; use Phalcon\Http\Cookie\Exception; @@ -78,17 +78,8 @@ class Cookies implements CookiesInterface, InjectionAwareInterface /** * Sets a cookie to be sent at the end of the request * This method overrides any cookie set before with the same name - * - * @param string name - * @param mixed value - * @param int expire - * @param string path - * @param boolean secure - * @param string domain - * @param boolean httpOnly - * @return Phalcon\Http\Response\Cookies */ - public function set(string! name, value = null, int expire = 0, string path = "/", secure = null, string! domain = null, httpOnly = null) -> + public function set(string! name, value = null, int expire = 0, string path = "/", boolean secure = null, string! domain = null, boolean httpOnly = null) -> { var cookie, encryption, dependencyInjector, response; @@ -98,8 +89,9 @@ class Cookies implements CookiesInterface, InjectionAwareInterface * Check if the cookie needs to be updated or */ if !fetch cookie, this->_cookies[name] { - - let cookie = new Cookie(name, value, expire, path, secure, domain, httpOnly); + let cookie = + this->_dependencyInjector->get("Phalcon\\Http\\Cookie", + [name, value, expire, path, secure, domain, httpOnly]); /** * Pass the DI to created cookies @@ -152,7 +144,7 @@ class Cookies implements CookiesInterface, InjectionAwareInterface /** * Gets a cookie from the bag */ - public function get(string! name) -> + public function get(string! name) -> { var dependencyInjector, encryption, cookie; @@ -163,7 +155,7 @@ class Cookies implements CookiesInterface, InjectionAwareInterface /** * Create the cookie if the it does not exist */ - let cookie = new Cookie(name), + let cookie = this->_dependencyInjector->get("Phalcon\\Http\\Cookie", [name]), dependencyInjector = this->_dependencyInjector; if typeof dependencyInjector == "object" { @@ -240,8 +232,10 @@ class Cookies implements CookiesInterface, InjectionAwareInterface for cookie in this->_cookies { cookie->send(); } + return true; } + return false; } diff --git a/phalcon/http/response/cookiesinterface.zep b/phalcon/http/response/cookiesinterface.zep index 7a97622483d..3445e036cbb 100644 --- a/phalcon/http/response/cookiesinterface.zep +++ b/phalcon/http/response/cookiesinterface.zep @@ -39,17 +39,8 @@ interface CookiesInterface /** * Sets a cookie to be sent at the end of the request - * - * @param string name - * @param mixed value - * @param int expire - * @param string path - * @param boolean secure - * @param string domain - * @param boolean httpOnly - * @return Phalcon\Http\Response\CookiesInterface */ - public function set(string! name, value = null, int expire = 0, string path = "/", secure = null, string! domain = null, httpOnly = null) -> ; + public function set(string! name, value = null, int expire = 0, string path = "/", boolean secure = null, string! domain = null, boolean httpOnly = null) -> ; /** * Gets a cookie from the bag diff --git a/phalcon/http/response/headers.zep b/phalcon/http/response/headers.zep index 83afaadcd15..51df6cdcefd 100644 --- a/phalcon/http/response/headers.zep +++ b/phalcon/http/response/headers.zep @@ -32,45 +32,37 @@ class Headers implements HeadersInterface /** * Sets a header to be sent at the end of the request - * - * @param string name - * @param string value */ - public function set(name, value) + public function set(string name, string value) { let this->_headers[name] = value; } /** * Gets a header value from the internal bag - * - * @param string name - * @return string */ - public function get(name) + public function get(string name) -> string | boolean { var headers, headerValue; let headers = this->_headers; + if fetch headerValue, headers[name] { return headerValue; } + return false; } /** * Sets a raw header to be sent at the end of the request - * - * @param string header */ - public function setRaw(var header) + public function setRaw(string header) { let this->_headers[header] = null; } /** * Removes a header to be sent at the end of the request - * - * @param string header Header name */ public function remove(string header) { @@ -117,7 +109,7 @@ class Headers implements HeadersInterface } /** - * Restore a Phalcon\Http\Response\Headers object + * Restore a \Phalcon\Http\Response\Headers object */ public static function __set_state(array! data) -> { diff --git a/phalcon/http/response/headersinterface.zep b/phalcon/http/response/headersinterface.zep index 249faec601a..c09bb215a05 100644 --- a/phalcon/http/response/headersinterface.zep +++ b/phalcon/http/response/headersinterface.zep @@ -29,26 +29,18 @@ interface HeadersInterface /** * Sets a header to be sent at the end of the request - * - * @param string name - * @param string value */ - public function set(name, value); + public function set(string name, string value); /** * Gets a header value from the internal bag - * - * @param string name - * @return string */ - public function get(name); + public function get(string name) -> string | boolean; /** * Sets a raw header to be sent at the end of the request - * - * @param string header */ - public function setRaw(header); + public function setRaw(string header); /** * Sends the headers to the client @@ -61,7 +53,7 @@ interface HeadersInterface public function reset(); /** - * Restore a Phalcon\Http\Response\Headers object + * Restore a \Phalcon\Http\Response\Headers object */ public static function __set_state(array! data) -> ; diff --git a/phalcon/http/responseinterface.zep b/phalcon/http/responseinterface.zep index a015471353b..44771776b25 100644 --- a/phalcon/http/responseinterface.zep +++ b/phalcon/http/responseinterface.zep @@ -44,7 +44,7 @@ interface ResponseInterface * * @param string name * @param string value - * @return Phalcon\Http\ResponseInterface + * @return \Phalcon\Http\ResponseInterface */ public function setHeader(string name, value) -> ; @@ -72,7 +72,7 @@ interface ResponseInterface * * @param string contentType * @param string charset - * @return Phalcon\Http\ResponseInterface + * @return \Phalcon\Http\ResponseInterface */ public function setContentType(string contentType, charset = null) -> ; @@ -82,7 +82,7 @@ interface ResponseInterface * @param string location * @param boolean externalRedirect * @param int statusCode - * @return Phalcon\Http\ResponseInterface + * @return \Phalcon\Http\ResponseInterface */ public function redirect(location = null, boolean externalRedirect = false, int statusCode = 302) -> ; @@ -99,7 +99,7 @@ interface ResponseInterface * * * @param string content - * @return Phalcon\Http\ResponseInterface + * @return \Phalcon\Http\ResponseInterface */ public function setJsonContent(content) -> ; @@ -107,7 +107,7 @@ interface ResponseInterface * Appends a string to the HTTP response body * * @param string content - * @return Phalcon\Http\ResponseInterface + * @return \Phalcon\Http\ResponseInterface */ public function appendContent(content) -> ; diff --git a/phalcon/image.zep b/phalcon/image.zep index c2bc23909db..c536714461e 100644 --- a/phalcon/image.zep +++ b/phalcon/image.zep @@ -21,10 +21,7 @@ namespace Phalcon; class Image { - - /* - * Resizing constraints - */ + // Resizing constraints const NONE = 1; const WIDTH = 2; const HEIGHT = 3; diff --git a/phalcon/image/adapter.zep b/phalcon/image/adapter.zep index e9373c1e017..880692826c1 100644 --- a/phalcon/image/adapter.zep +++ b/phalcon/image/adapter.zep @@ -310,14 +310,16 @@ abstract class Adapter /** * Add a text to an image with a specified opacity */ - public function text(string text, int offsetX = 0, int offsetY = 0, int opacity = 100, string color = "000000", int size = 12, string fontfile = null) -> + public function text(string text, var offsetX = false, var offsetY = false, int opacity = 100, string color = "000000", int size = 12, string fontfile = null) -> { var colors; if opacity < 0 { let opacity = 0; - } elseif opacity > 100 { - let opacity = 100; + } else { + if opacity > 100 { + let opacity = 100; + } } if strlen(color) > 1 && substr(color, 0, 1) === "#" { diff --git a/phalcon/image/adapter/gd.zep b/phalcon/image/adapter/gd.zep index 0d8bc575714..0d1ad84e20a 100644 --- a/phalcon/image/adapter/gd.zep +++ b/phalcon/image/adapter/gd.zep @@ -501,7 +501,14 @@ class Gd extends Adapter implements AdapterInterface { var ext; - let ext = strtolower(pathinfo(file, PATHINFO_EXTENSION)); + let ext = pathinfo(file, PATHINFO_EXTENSION); + + // If no extension is given, revert to the original type. + if !ext { + let ext = image_type_to_extension(this->_type, false); + } + + let ext = strtolower(ext); if strcmp(ext, "gif") == 0 { let this->_type = 1; diff --git a/phalcon/image/adapter/imagick.zep b/phalcon/image/adapter/imagick.zep index bc7d7c8d858..f476c0e7d24 100644 --- a/phalcon/image/adapter/imagick.zep +++ b/phalcon/image/adapter/imagick.zep @@ -20,8 +20,8 @@ namespace Phalcon\Image\Adapter; use Phalcon\Image\Adapter; -use Phalcon\Image\AdapterInterface; use Phalcon\Image\Exception; +use Phalcon\Image\AdapterInterface; /** * Phalcon\Image\Adapter\Imagick @@ -111,7 +111,7 @@ class Imagick extends Adapter implements AdapterInterface let this->_width = this->_image->getImageWidth(); let this->_height = this->_image->getImageHeight(); let this->_type = this->_image->getImageType(); - let this->_mime = "image/".this->_image->getImageFormat(); + let this->_mime = "image/" . this->_image->getImageFormat(); } /** @@ -376,18 +376,15 @@ class Imagick extends Adapter implements AdapterInterface /** * Execute a text */ - protected function _text(string text, int offsetX, int offsetY, int opacity, int r, int g, int b, int size, string fontfile) + protected function _text(string text, var offsetX, var offsetY, int opacity, int r, int g, int b, int size, string fontfile) { - var draw, color, pixel, gravity; - - let opacity = opacity / 100; - - let draw = new \ImagickDraw(); + var x, y, draw, color, gravity; - let color = sprintf("rgb(%d, %d, %d)", r, g, b); - let pixel = new \ImagickPixel(color); + let opacity = opacity / 100, + draw = new \ImagickDraw(), + color = sprintf("rgb(%d, %d, %d)", r, g, b); - draw->setFillColor(pixel); + draw->setFillColor(new \ImagickPixel(color)); if fontfile { draw->setFont(fontfile); @@ -401,21 +398,101 @@ class Imagick extends Adapter implements AdapterInterface draw->setfillopacity(opacity); } - if offsetX < 0 { - let offsetX = abs(offsetX); - if offsetY < 0 { - let offsetY = abs(offsetY); - let gravity = constant("Imagick::GRAVITY_SOUTHEAST"); + let gravity = null; + + if typeof offsetX == "bool" { + if typeof offsetY == "bool" { + let offsetX = 0, + offsetY = 0; + if offsetX && offsetY { + let gravity = constant("Imagick::GRAVITY_SOUTHEAST"); + } else { + if offsetX { + let gravity = constant("Imagick::GRAVITY_EAST"); + } else { + if offsetY { + let gravity = constant("Imagick::GRAVITY_SOUTH"); + } else { + let gravity = constant("Imagick::GRAVITY_CENTER"); + } + } + } } else { - let gravity = constant("Imagick::GRAVITY_NORTHEAST"); + if typeof offsetY == "int" { + let y = (int) offsetY; + if offsetX { + if y < 0 { + let offsetX = 0, + offsetY = y * -1, + gravity = constant("Imagick::GRAVITY_SOUTHEAST"); + } else { + let offsetX = 0, + gravity = constant("Imagick::GRAVITY_NORTHEAST"); + } + } else { + if y < 0 { + let offsetX = 0, + offsetY = y * -1, + gravity = constant("Imagick::GRAVITY_SOUTH"); + } else { + let offsetX = 0, + gravity = constant("Imagick::GRAVITY_NORTH"); + } + } + } } } else { - /*if y < 0 { where y comes from?? - let offsetY = abs(offsetY); - let gravity = constant("Imagick::GRAVITY_SOUTHWEST"); - } else { - let gravity = constant("Imagick::GRAVITY_NORTHWEST"); - }*/ + if typeof offsetX == "int" { + let x = (int) offsetX; + if offsetX { + if typeof offsetY == "bool" { + if offsetY { + if x < 0 { + let offsetX = x * -1, + offsetY = 0, + gravity = constant("Imagick::GRAVITY_SOUTHEAST"); + } else { + let offsetY = 0, + gravity = constant("Imagick::GRAVITY_SOUTH"); + } + } else { + if x < 0 { + let offsetX = x * -1, + offsetY = 0, + gravity = constant("Imagick::GRAVITY_EAST"); + } else { + let offsetY = 0, + gravity = constant("Imagick::GRAVITY_WEST"); + } + } + } else { + if typeof offsetY == "long" { + let x = (int) offsetX, + y = (int) offsetY; + + if x < 0 { + if y < 0 { + let offsetX = x * -1, + offsetY = y * -1, + gravity = constant("Imagick::GRAVITY_SOUTHEAST"); + } else { + let offsetX = x * -1, + gravity = constant("Imagick::GRAVITY_NORTHEAST"); + } + } else { + if y < 0 { + let offsetX = 0, + offsetY = y * -1, + gravity = constant("Imagick::GRAVITY_SOUTHWEST"); + } else { + let offsetX = 0, + gravity = constant("Imagick::GRAVITY_NORTHWEST"); + } + } + } + } + } + } } draw->setGravity(gravity); @@ -428,6 +505,7 @@ class Imagick extends Adapter implements AdapterInterface break; } } + draw->destroy(); } @@ -629,5 +707,4 @@ class Imagick extends Adapter implements AdapterInterface { this->_image->setResourceLimit(type, limit); } - } diff --git a/phalcon/loader.zep b/phalcon/loader.zep index f56979b6a7b..f96d3acb1c4 100644 --- a/phalcon/loader.zep +++ b/phalcon/loader.zep @@ -477,7 +477,7 @@ class Loader implements EventsAwareInterface } /** - * Get the path when a class was found + * Get the path when a class was found */ public function getFoundPath() -> string { diff --git a/phalcon/logger/adapter.zep b/phalcon/logger/adapter.zep index 9ba25eeab2c..ce5c860f9a1 100644 --- a/phalcon/logger/adapter.zep +++ b/phalcon/logger/adapter.zep @@ -218,7 +218,7 @@ abstract class Adapter } /** - * Logs messages to the internal logger. Appends logs to the logger + * Logs messages to the internal logger. Appends logs to the logger */ public function log(var type, var message = null, array! context = null) -> { diff --git a/phalcon/logger/adapterinterface.zep b/phalcon/logger/adapterinterface.zep index 6565cebe44c..87c38c0a538 100644 --- a/phalcon/logger/adapterinterface.zep +++ b/phalcon/logger/adapterinterface.zep @@ -32,14 +32,14 @@ interface AdapterInterface /** * Sets the message formatter * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ public function setFormatter( formatter); /** * Returns the internal formatter * - * @return Phalcon\Logger\FormatterInterface + * @return \Phalcon\Logger\FormatterInterface */ public function getFormatter(); @@ -47,7 +47,7 @@ interface AdapterInterface * Filters the logs sent to the handlers to be greater or equals than a specific level * * @param int level - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ public function setLogLevel(int level); @@ -61,28 +61,28 @@ interface AdapterInterface /** * Sends/Writes messages to the file log * - * @return Phalcon\Logger\Adapter1 + * @return \Phalcon\Logger\Adapter1 */ public function log(var type, var message = null, array! context = null); /** * Starts a transaction * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ public function begin(); /** * Commits the internal transaction * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ public function commit(); /** * Rollbacks the internal transaction * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ public function rollback(); @@ -94,49 +94,49 @@ interface AdapterInterface /** * Sends/Writes a debug message to the log * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ public function debug(string! message, array! context = null); /** * Sends/Writes an error message to the log * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ public function error(string! message, array! context = null); /** * Sends/Writes an info message to the log * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ public function info(string! message, array! context = null); /** * Sends/Writes a notice message to the log * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ public function notice(string! message, array! context = null); /** * Sends/Writes a warning message to the log * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ public function warning(string! message, array! context = null); /** * Sends/Writes an alert message to the log * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ public function alert(string! message, array! context = null); /** * Sends/Writes an emergency message to the log * - * @return Phalcon\Logger\Adapter + * @return \Phalcon\Logger\Adapter */ public function emergency(string! message, array! context = null); } diff --git a/phalcon/mvc/application.zep b/phalcon/mvc/application.zep index a4ef27d5d4a..a024f24b2f4 100644 --- a/phalcon/mvc/application.zep +++ b/phalcon/mvc/application.zep @@ -183,7 +183,7 @@ class Application extends Injectable * Handles a MVC request * * @param string uri - * @return Phalcon\Http\ResponseInterface|boolean + * @return \Phalcon\Http\ResponseInterface|boolean */ public function handle(uri = null) -> | boolean { diff --git a/phalcon/mvc/collection.zep b/phalcon/mvc/collection.zep index 300bc29730c..0ee8d1c8c67 100644 --- a/phalcon/mvc/collection.zep +++ b/phalcon/mvc/collection.zep @@ -333,7 +333,7 @@ abstract class Collection implements EntityInterface, CollectionInterface, Injec * Returns a collection resultset * * @param array params - * @param Phalcon\Mvc\Collection collection + * @param \Phalcon\Mvc\Collection collection * @param \MongoDb connection * @param boolean unique * @return array @@ -444,7 +444,7 @@ abstract class Collection implements EntityInterface, CollectionInterface, Injec * Perform a count over a resultset * * @param array params - * @param Phalcon\Mvc\Collection collection + * @param \Phalcon\Mvc\Collection collection * @param \MongoDb connection * @return int */ @@ -508,7 +508,7 @@ abstract class Collection implements EntityInterface, CollectionInterface, Injec /** * Executes internal hooks before save a document * - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\DiInterface dependencyInjector * @param boolean disableEvents * @param boolean exists * @return boolean @@ -915,7 +915,7 @@ abstract class Collection implements EntityInterface, CollectionInterface, Injec * Find a document by its id (_id) * * @param string|\MongoId id - * @return Phalcon\Mvc\Collection + * @return \Phalcon\Mvc\Collection */ public static function findById(id) -> { diff --git a/phalcon/mvc/collection/manager.zep b/phalcon/mvc/collection/manager.zep index af48da8b9e0..08d399328f2 100644 --- a/phalcon/mvc/collection/manager.zep +++ b/phalcon/mvc/collection/manager.zep @@ -106,8 +106,8 @@ class Manager implements InjectionAwareInterface, EventsAwareInterface /** * Returns a custom events manager related to a model * - * @param Phalcon\Mvc\CollectionInterface $model - * @return Phalcon\Events\ManagerInterface + * @param \Phalcon\Mvc\CollectionInterface $model + * @return \Phalcon\Events\ManagerInterface */ public function getCustomEventsManager( model) //-> <\Phalcon\Events\ManagerInterface> { @@ -209,7 +209,7 @@ class Manager implements InjectionAwareInterface, EventsAwareInterface /** * Returns the connection related to a model * - * @param Phalcon\Mvc\CollectionInterface $model + * @param \Phalcon\Mvc\CollectionInterface $model * @return \Mongo */ public function getConnection( model) diff --git a/phalcon/mvc/collectioninterface.zep b/phalcon/mvc/collectioninterface.zep index 14052edcaf3..e9e16563166 100644 --- a/phalcon/mvc/collectioninterface.zep +++ b/phalcon/mvc/collectioninterface.zep @@ -63,7 +63,7 @@ interface CollectionInterface * * @return MongoDb */ - public function getConnection(); + public function getConnection(); /** * Returns a cloned collection @@ -97,7 +97,7 @@ interface CollectionInterface public function appendMessage( message); /** - * Creates/Updates a collection based on the values in the atributes + * Creates/Updates a collection based on the values in the attributes */ public function save() -> boolean; @@ -105,7 +105,7 @@ interface CollectionInterface * Find a document by its id * * @param string id - * @return Phalcon\Mvc\Collection + * @return \Phalcon\Mvc\Collection */ public static function findById(id) -> ; diff --git a/phalcon/mvc/micro.zep b/phalcon/mvc/micro.zep index 63671757d0b..fe8622248e6 100644 --- a/phalcon/mvc/micro.zep +++ b/phalcon/mvc/micro.zep @@ -107,7 +107,7 @@ class Micro extends Injectable implements \ArrayAccess * * @param string routePattern * @param callable handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function map(string! routePattern, handler) -> { @@ -139,7 +139,7 @@ class Micro extends Injectable implements \ArrayAccess * * @param string routePattern * @param callable handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function get(string! routePattern, handler) -> { @@ -171,7 +171,7 @@ class Micro extends Injectable implements \ArrayAccess * * @param string routePattern * @param callable handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function post(string! routePattern, handler) -> { @@ -203,7 +203,7 @@ class Micro extends Injectable implements \ArrayAccess * * @param string $routePattern * @param callable $handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function put(string! routePattern, handler) -> { @@ -235,7 +235,7 @@ class Micro extends Injectable implements \ArrayAccess * * @param string $routePattern * @param callable $handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function patch(string! routePattern, handler) -> { @@ -267,7 +267,7 @@ class Micro extends Injectable implements \ArrayAccess * * @param string routePattern * @param callable handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function head(string! routePattern, handler) -> { @@ -299,7 +299,7 @@ class Micro extends Injectable implements \ArrayAccess * * @param string routePattern * @param callable handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function delete(string! routePattern, handler) -> { @@ -331,7 +331,7 @@ class Micro extends Injectable implements \ArrayAccess * * @param string routePattern * @param callable handler - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function options(string! routePattern, handler) -> { @@ -443,7 +443,7 @@ class Micro extends Injectable implements \ArrayAccess * Sets a handler that will be called when the router doesn't match any of the defined routes * * @param callable handler - * @return Phalcon\Mvc\Micro + * @return \Phalcon\Mvc\Micro */ public function notFound(var handler) -> { @@ -455,7 +455,7 @@ class Micro extends Injectable implements \ArrayAccess * Sets a handler that will be called when an exception is thrown handling the route * * @param callable handler - * @return Phalcon\Mvc\Micro + * @return \Phalcon\Mvc\Micro */ public function error(var handler) -> { @@ -500,7 +500,7 @@ class Micro extends Injectable implements \ArrayAccess * @param string serviceName * @param mixed definition * @param boolean shared - * @return Phalcon\DI\ServiceInterface + * @return \Phalcon\Di\ServiceInterface */ public function setService(string! serviceName, var definition, boolean shared = false) -> { @@ -980,7 +980,7 @@ class Micro extends Injectable implements \ArrayAccess * Appends a before middleware to be called before execute the route * * @param callable handler - * @return Phalcon\Mvc\Micro + * @return \Phalcon\Mvc\Micro */ public function before(handler) -> { @@ -992,7 +992,7 @@ class Micro extends Injectable implements \ArrayAccess * Appends an 'after' middleware to be called after execute the route * * @param callable handler - * @return Phalcon\Mvc\Micro + * @return \Phalcon\Mvc\Micro */ public function after(handler) -> { @@ -1004,7 +1004,7 @@ class Micro extends Injectable implements \ArrayAccess * Appends a 'finish' middleware to be called when the request is finished * * @param callable handler - * @return Phalcon\Mvc\Micro + * @return \Phalcon\Mvc\Micro */ public function finish(handler) -> { diff --git a/phalcon/mvc/micro/collection.zep b/phalcon/mvc/micro/collection.zep index 93da0cb7362..7958b1f872f 100644 --- a/phalcon/mvc/micro/collection.zep +++ b/phalcon/mvc/micro/collection.zep @@ -95,7 +95,7 @@ class Collection implements CollectionInterface * * @param mixed handler * @param boolean lazy - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ public function setHandler(var handler, boolean lazy = false) -> { @@ -136,7 +136,7 @@ class Collection implements CollectionInterface * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ public function map(string! routePattern, var handler, var name = null) -> { @@ -150,7 +150,7 @@ class Collection implements CollectionInterface * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ public function get(string! routePattern, handler, var name = null) -> { @@ -164,7 +164,7 @@ class Collection implements CollectionInterface * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ public function post(string! routePattern, handler, var name = null) -> { @@ -178,7 +178,7 @@ class Collection implements CollectionInterface * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ public function put(string! routePattern, var handler, var name = null) -> { @@ -192,7 +192,7 @@ class Collection implements CollectionInterface * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ public function patch(string! routePattern, var handler, var name = null) -> { @@ -206,7 +206,7 @@ class Collection implements CollectionInterface * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ public function head(string! routePattern, var handler, var name = null) -> { @@ -220,7 +220,7 @@ class Collection implements CollectionInterface * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ public function delete(string! routePattern, var handler, var name = null) -> { @@ -233,7 +233,7 @@ class Collection implements CollectionInterface * * @param string routePattern * @param callable handler - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ public function options(string! routePattern, handler, var name = null) -> { diff --git a/phalcon/mvc/micro/collectioninterface.zep b/phalcon/mvc/micro/collectioninterface.zep index 2b22675350f..57f8455d247 100644 --- a/phalcon/mvc/micro/collectioninterface.zep +++ b/phalcon/mvc/micro/collectioninterface.zep @@ -49,7 +49,7 @@ interface CollectionInterface * * @param mixed handler * @param boolean lazy - * @return Phalcon\Mvc\Micro\Collection + * @return \Phalcon\Mvc\Micro\Collection */ public function setHandler(handler, boolean lazy = false); @@ -76,7 +76,7 @@ interface CollectionInterface * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function map(string! routePattern, handler, name = null); @@ -86,7 +86,7 @@ interface CollectionInterface * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function get(string! routePattern, handler, name = null); @@ -96,7 +96,7 @@ interface CollectionInterface * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function post(string! routePattern, handler, name = null); @@ -106,7 +106,7 @@ interface CollectionInterface * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function put(string! routePattern, handler, name = null); @@ -116,7 +116,7 @@ interface CollectionInterface * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function patch(string! routePattern, handler, name = null); @@ -126,7 +126,7 @@ interface CollectionInterface * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function head(string! routePattern, handler, name = null); @@ -136,7 +136,7 @@ interface CollectionInterface * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function delete(string! routePattern, handler, name = null); @@ -146,7 +146,7 @@ interface CollectionInterface * @param string routePattern * @param callable handler * @param string name - * @return Phalcon\Mvc\Router\RouteInterface + * @return \Phalcon\Mvc\Router\RouteInterface */ public function options(string! routePattern, handler, name = null); diff --git a/phalcon/mvc/model.zep b/phalcon/mvc/model.zep index d71f8c08af2..d26c9ae12f7 100644 --- a/phalcon/mvc/model.zep +++ b/phalcon/mvc/model.zep @@ -1,19 +1,19 @@ /* +------------------------------------------------------------------------+ - | Phalcon Framework | + | Phalcon Framework | +------------------------------------------------------------------------+ - | Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) | + | Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) | +------------------------------------------------------------------------+ | This source file is subject to the New BSD License that is bundled | - | with this package in the file docs/LICENSE.txt. | - | | - | If you did not receive a copy of the license and are unable to | - | obtain it through the world-wide-web, please send an email | - | to license@phalconphp.com so we can send you a copy immediately. | + | with this package in the file docs/LICENSE.txt. | + | | + | If you did not receive a copy of the license and are unable to | + | obtain it through the world-wide-web, please send an email | + | to license@phalconphp.com so we can send you a copy immediately. | +------------------------------------------------------------------------+ - | Authors: Andres Gutierrez | - | Eduar Carvajal | + | Authors: Andres Gutierrez | + | Eduar Carvajal | +------------------------------------------------------------------------+ */ @@ -60,7 +60,6 @@ use Phalcon\Events\ManagerInterface as EventsManagerInterface; * when interacting with databases while is also easy to use. * * - * * $robot = new Robots(); * $robot->type = 'mechanical'; * $robot->name = 'Astro Boy'; @@ -68,7 +67,7 @@ use Phalcon\Events\ManagerInterface as EventsManagerInterface; * if ($robot->save() == false) { * echo "Umh, We can store robots: "; * foreach ($robot->getMessages() as $message) { - * echo message; + * echo message; * } * } else { * echo "Great, a new robot was saved successfully!"; @@ -257,14 +256,14 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface * $robot->name = 'WALL·E'; * $robot->created_at = date('Y-m-d'); * if ($robot->save() == false) { - * $transaction->rollback("Can't save robot"); + * $transaction->rollback("Can't save robot"); * } * * $robotPart = new RobotParts(); * $robotPart->setTransaction($transaction); * $robotPart->type = 'head'; * if ($robotPart->save() == false) { - * $transaction->rollback("Robot part cannot be saved"); + * $transaction->rollback("Robot part cannot be saved"); * } * * $transaction->commit(); @@ -420,7 +419,7 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface * @param array data * @param array dataColumnMap array to transform keys of data to another * @param array whiteList - * @return Phalcon\Mvc\Model + * @return \Phalcon\Mvc\Model */ public function assign(array! data, var dataColumnMap = null, var whiteList = null) -> { @@ -500,12 +499,12 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface *)); * * - * @param Phalcon\Mvc\ModelInterface|Phalcon\Mvc\Model\Row base + * @param \Phalcon\Mvc\ModelInterface|Phalcon\Mvc\Model\Row base * @param array data * @param array columnMap * @param int dirtyState * @param boolean keepSnapshots - * @return Phalcon\Mvc\Model + * @return \Phalcon\Mvc\Model */ public static function cloneResultMap(var base, array! data, var columnMap, int dirtyState = 0, boolean keepSnapshots = null) -> { @@ -678,10 +677,10 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface *)); * * - * @param Phalcon\Mvc\ModelInterface $base + * @param \Phalcon\Mvc\ModelInterface $base * @param array data * @param int dirtyState - * @return Phalcon\Mvc\ModelInterface + * @return \Phalcon\Mvc\ModelInterface */ public static function cloneResult( base, array! data, int dirtyState = 0) { @@ -827,7 +826,7 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface * * * @param string|array parameters - * @return Phalcon\Mvc\Model + * @return \Phalcon\Mvc\Model */ public static function findFirst(var parameters = null) -> { @@ -856,6 +855,7 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface * We only want the first record */ builder->limit(1); + let query = builder->getQuery(); /** @@ -924,8 +924,8 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface /** * Checks if the current record already exists or not * - * @param Phalcon\Mvc\Model\MetadataInterface metaData - * @param Phalcon\Db\AdapterInterface connection + * @param \Phalcon\Mvc\Model\MetadataInterface metaData + * @param \Phalcon\Db\AdapterInterface connection * @param string|array table * @return boolean */ @@ -1076,14 +1076,15 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface * @param string function * @param string alias * @param array parameters - * @return Phalcon\Mvc\Model\ResultsetInterface + * @return \Phalcon\Mvc\Model\ResultsetInterface */ protected static function _groupResult(string! functionName, string! alias, var parameters) -> { var params, distinctColumn, groupColumn, columns, bindParams, bindTypes, resultset, cache, firstRow, groupColumns, builder, query, dependencyInjector, manager; - let dependencyInjector = \Phalcon\Di::getDefault(); + + let dependencyInjector = Di::getDefault(); let manager = dependencyInjector->getShared("modelsManager"); if typeof parameters != "array" { @@ -1096,7 +1097,7 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface } if !fetch groupColumn, params["column"] { - let groupColumn = '*'; + let groupColumn = "*"; } /** @@ -1165,7 +1166,7 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface * echo "There are ", $number, "\n"; * * //How many mechanical robots are there? - * $number = Robots::count("type='mechanical'"); + * $number = Robots::count("type = 'mechanical'"); * echo "There are ", $number, " mechanical robots\n"; * * @@ -1194,7 +1195,7 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface * echo "The total price of robots is ", $sum, "\n"; * * //How much are mechanical robots? - * $sum = Robots::sum(array("type='mechanical'", 'column' => 'price')); + * $sum = Robots::sum(array("type = 'mechanical'", 'column' => 'price')); * echo "The total price of mechanical robots is ", $sum, "\n"; * * @@ -1427,7 +1428,7 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface } /** - * Returns all the validation messages + * Returns array of validation messages * * * $robot = new Robots(); @@ -2092,8 +2093,8 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface /** * Sends a pre-build INSERT SQL statement to the relational database system * - * @param Phalcon\Mvc\Model\MetadataInterface metaData - * @param Phalcon\Db\AdapterInterface connection + * @param \Phalcon\Mvc\Model\MetadataInterface metaData + * @param \Phalcon\Db\AdapterInterface connection * @param string|array table * @param boolean|string identityField * @return boolean @@ -2281,8 +2282,8 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface /** * Sends a pre-build UPDATE SQL statement to the relational database system * - * @param Phalcon\Mvc\Model\MetaDataInterface metaData - * @param Phalcon\Db\AdapterInterface connection + * @param \Phalcon\Mvc\Model\MetaDataInterface metaData + * @param \Phalcon\Db\AdapterInterface connection * @param string|array table * @return boolean */ @@ -2491,8 +2492,8 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface /** * Saves related records that must be stored prior to save the master record * - * @param Phalcon\Db\AdapterInterface connection - * @param Phalcon\Mvc\ModelInterface[] related + * @param \Phalcon\Db\AdapterInterface connection + * @param \Phalcon\Mvc\ModelInterface[] related * @return boolean */ protected function _preSaveRelatedRecords( connection, related) -> boolean @@ -2896,13 +2897,6 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface let this->_dirtyState = self::DIRTY_STATE_PERSISTENT; } - /** - * _postSave() makes all the validations - */ - if globals_get("orm.events") { - let success = this->_postSave(success, exists); - } - if typeof related == "array" { /** @@ -2918,6 +2912,13 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface } } + /** + * _postSave() invokes after* events if the operation was successful + */ + if globals_get("orm.events") { + let success = this->_postSave(success, exists); + } + if success === false { this->_cancelOperation(); } else { @@ -3838,7 +3839,7 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface * * @param string alias * @param array arguments - * @return Phalcon\Mvc\Model\ResultsetInterface + * @return \Phalcon\Mvc\Model\ResultsetInterface */ public function getRelated(string alias, arguments = null) -> { @@ -3953,7 +3954,7 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface * @param array arguments * @return mixed */ - public static function __callStatic(string method, arguments = null) + public static function __callStatic(string method, arguments) { var extraMethod, type, modelName, value, model, attributes, field, extraMethodFirst, metaData; @@ -4116,7 +4117,7 @@ abstract class Model implements EntityInterface, ModelInterface, ResultInterface * Magic method to get related records using the relation alias as a property * * @param string property - * @return Phalcon\Mvc\Model\Resultset|Phalcon\Mvc\Model + * @return \Phalcon\Mvc\Model\Resultset|Phalcon\Mvc\Model */ public function __get(string! property) { diff --git a/phalcon/mvc/model/behavior.zep b/phalcon/mvc/model/behavior.zep index 7018b13c795..0c276e9d855 100644 --- a/phalcon/mvc/model/behavior.zep +++ b/phalcon/mvc/model/behavior.zep @@ -79,7 +79,7 @@ abstract class Behavior /** * Acts as fallbacks when a missing method is called on the model * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @param string method * @param array arguments */ diff --git a/phalcon/mvc/model/behaviorinterface.zep b/phalcon/mvc/model/behaviorinterface.zep index 4dce06f34f7..6eedb6b2aa5 100644 --- a/phalcon/mvc/model/behaviorinterface.zep +++ b/phalcon/mvc/model/behaviorinterface.zep @@ -44,7 +44,7 @@ interface BehaviorInterface /** * Calls a method when it's missing in the model * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @param string method * @param array arguments */ diff --git a/phalcon/mvc/model/criteria.zep b/phalcon/mvc/model/criteria.zep index 4801f215111..1244b01e018 100644 --- a/phalcon/mvc/model/criteria.zep +++ b/phalcon/mvc/model/criteria.zep @@ -26,7 +26,6 @@ use Phalcon\Di\InjectionAwareInterface; use Phalcon\Mvc\Model\CriteriaInterface; use Phalcon\Mvc\Model\ResultsetInterface; - /** * Phalcon\Mvc\Model\Criteria * @@ -131,7 +130,7 @@ class Criteria implements CriteriaInterface, InjectionAwareInterface * * * @param string|array columns - * @return Phalcon\Mvc\Model\Criteria + * @return \Phalcon\Mvc\Model\Criteria */ public function columns(var columns) -> { @@ -352,12 +351,12 @@ class Criteria implements CriteriaInterface, InjectionAwareInterface /** * Minimum key with auto bind-params */ - let minimumKey = "AP" . hiddenParam; + let minimumKey = "ACP" . hiddenParam; /** * Maximum key with auto bind-params */ - let maximumKey = "AP" . nextHiddenParam; + let maximumKey = "ACP" . nextHiddenParam; /** * Create a standard BETWEEN condition with bind params @@ -391,12 +390,12 @@ class Criteria implements CriteriaInterface, InjectionAwareInterface /** * Minimum key with auto bind-params */ - let minimumKey = "AP" . hiddenParam; + let minimumKey = "ACP" . hiddenParam; /** * Maximum key with auto bind-params */ - let maximumKey = "AP" . nextHiddenParam; + let maximumKey = "ACP" . nextHiddenParam; /** * Create a standard BETWEEN condition with bind params @@ -435,7 +434,7 @@ class Criteria implements CriteriaInterface, InjectionAwareInterface /** * Key with auto bind-params */ - let key = "AP" . hiddenParam; + let key = "ACP" . hiddenParam; let queryKey = ":" . key . ":"; @@ -474,7 +473,7 @@ class Criteria implements CriteriaInterface, InjectionAwareInterface /** * Key with auto bind-params */ - let key = "AP" . hiddenParam, + let key = "ACP" . hiddenParam, bindKeys[] = ":" . key . ":", bindParams[key] = value; @@ -685,7 +684,7 @@ class Criteria implements CriteriaInterface, InjectionAwareInterface /** * Builds a Phalcon\Mvc\Model\Criteria based on an input array like _POST */ - public static function fromInput( dependencyInjector, string! modelName, array! data) -> + public static function fromInput( dependencyInjector, string! modelName, array! data, string! operator = "AND") -> { var attribute, conditions, field, value, type, metaData, model, dataTypes, bind, criteria, columnMap; @@ -736,7 +735,7 @@ class Criteria implements CriteriaInterface, InjectionAwareInterface */ let criteria = new self(); if count(conditions) { - criteria->where(join(" AND ", conditions)); + criteria->where(join(" " . operator . " ", conditions)); criteria->bind(bind); } diff --git a/phalcon/mvc/model/criteriainterface.zep b/phalcon/mvc/model/criteriainterface.zep index 9766cb707bb..3895046f152 100644 --- a/phalcon/mvc/model/criteriainterface.zep +++ b/phalcon/mvc/model/criteriainterface.zep @@ -71,7 +71,7 @@ interface CriteriaInterface * * @param int limit * @param int offset - * @return Phalcon\Mvc\Model\CriteriaInterface + * @return \Phalcon\Mvc\Model\CriteriaInterface */ public function limit(int limit, offset = null) -> ; @@ -91,7 +91,7 @@ interface CriteriaInterface * @param string conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\CriteriaInterface + * @return \Phalcon\Mvc\Model\CriteriaInterface */ public function andWhere(string! conditions, bindParams = null, bindTypes = null) -> ; @@ -101,7 +101,7 @@ interface CriteriaInterface * @param string conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\CriteriaInterface + * @return \Phalcon\Mvc\Model\CriteriaInterface */ public function orWhere(string! conditions, bindParams = null, bindTypes = null) -> ; @@ -115,7 +115,7 @@ interface CriteriaInterface * @param string expr * @param mixed minimum * @param mixed maximum - * @return Phalcon\Mvc\Model\CriteriaInterface + * @return \Phalcon\Mvc\Model\CriteriaInterface */ public function betweenWhere(string! expr, minimum, maximum) -> ; @@ -129,7 +129,7 @@ interface CriteriaInterface * @param string expr * @param mixed minimum * @param mixed maximum - * @return Phalcon\Mvc\Model\CriteriaInterface + * @return \Phalcon\Mvc\Model\CriteriaInterface */ public function notBetweenWhere(string! expr, minimum, maximum) -> ; @@ -189,11 +189,6 @@ interface CriteriaInterface */ public function getParams(); - /** - * Builds a Phalcon\Mvc\Model\Criteria based on an input array like _POST - */ - public static function fromInput( dependencyInjector, string! modelName, array! data) -> ; - /** * Executes a find using the parameters built with the criteria */ diff --git a/phalcon/mvc/model/manager.zep b/phalcon/mvc/model/manager.zep index be8f230b15d..2f45ab67356 100644 --- a/phalcon/mvc/model/manager.zep +++ b/phalcon/mvc/model/manager.zep @@ -40,13 +40,13 @@ use Phalcon\Events\ManagerInterface as EventsManagerInterface; * This components controls the initialization of models, keeping record of relations * between the different models of the application. * - * A ModelsManager is injected to a model via a Dependency Injector/Services Container such as Phalcon\DI. + * A ModelsManager is injected to a model via a Dependency Injector/Services Container such as Phalcon\Di. * * - * use Phalcon\DI; + * use Phalcon\Di; * use Phalcon\Mvc\Model\Manager as ModelsManager; * - * $di = new DI(); + * $di = new Di(); * * $di->set('modelsManager', function() { * return new ModelsManager(); @@ -684,7 +684,7 @@ class Manager implements ManagerInterface, InjectionAwareInterface, EventsAwareI } let lowerAlias = strtolower(alias); } else { - let lowerAlias = referencedEntity; + let lowerAlias = referencedEntity; } /** @@ -1114,9 +1114,6 @@ class Manager implements ManagerInterface, InjectionAwareInterface, EventsAwareI { var key, value, findParams; - //var_dump(findParamsOne); - //var_dump(findParamsTwo); - if typeof findParamsOne == "string" && typeof findParamsTwo == "string" { return ["(" . findParamsOne . ") AND " . findParamsTwo]; } @@ -1187,7 +1184,7 @@ class Manager implements ManagerInterface, InjectionAwareInterface, EventsAwareI /** * Helper method to query records based on a relation definition * - * @return Phalcon\Mvc\Model\Resultset\Simple|Phalcon\Mvc\Model\Resultset\Simple|false + * @return \Phalcon\Mvc\Model\Resultset\Simple|Phalcon\Mvc\Model\Resultset\Simple|false */ public function getRelationRecords( relation, string! method, record, var parameters = null) { diff --git a/phalcon/mvc/model/managerinterface.zep b/phalcon/mvc/model/managerinterface.zep index b9fae84116d..b0f139eea7d 100644 --- a/phalcon/mvc/model/managerinterface.zep +++ b/phalcon/mvc/model/managerinterface.zep @@ -174,9 +174,9 @@ interface ManagerInterface * @param string method * @param string modelName * @param string modelRelation - * @param Phalcon\Mvc\Model record + * @param \Phalcon\Mvc\Model record * @param array parameters - * @return Phalcon\Mvc\Model\ResultsetInterface + * @return \Phalcon\Mvc\Model\ResultsetInterface */ public function getBelongsToRecords(method, modelName, modelRelation, record, parameters = null); @@ -186,9 +186,9 @@ interface ManagerInterface * @param string method * @param string modelName * @param string modelRelation - * @param Phalcon\Mvc\Model record + * @param \Phalcon\Mvc\Model record * @param array parameters - * @return Phalcon\Mvc\Model\ResultsetInterface + * @return \Phalcon\Mvc\Model\ResultsetInterface */ public function getHasManyRecords(method, modelName, modelRelation, record, parameters = null); @@ -198,9 +198,9 @@ interface ManagerInterface * @param string method * @param string modelName * @param string modelRelation - * @param Phalcon\Mvc\Model record + * @param \Phalcon\Mvc\Model record * @param array parameters - * @return Phalcon\Mvc\Model\ResultsetInterface + * @return \Phalcon\Mvc\Model\ResultsetInterface */ public function getHasOneRecords(method, modelName, modelRelation, record, parameters = null); @@ -240,7 +240,7 @@ interface ManagerInterface * Query all the relationships defined on a model * * @param string modelName - * @return Phalcon\Mvc\Model\RelationInterface[] + * @return \Phalcon\Mvc\Model\RelationInterface[] */ public function getRelations(modelName); @@ -257,7 +257,7 @@ interface ManagerInterface * Creates a Phalcon\Mvc\Model\Query without execute it * * @param string phql - * @return Phalcon\Mvc\Model\QueryInterface + * @return \Phalcon\Mvc\Model\QueryInterface */ public function createQuery(phql); @@ -266,7 +266,7 @@ interface ManagerInterface * * @param string phql * @param array placeholders - * @return Phalcon\Mvc\Model\QueryInterface + * @return \Phalcon\Mvc\Model\QueryInterface */ public function executeQuery(phql, placeholders = null); @@ -274,7 +274,7 @@ interface ManagerInterface * Creates a Phalcon\Mvc\Model\Query\Builder * * @param string params - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ public function createBuilder(params = null); @@ -288,7 +288,7 @@ interface ManagerInterface * Notify the behaviors that are listening in the model * * @param string eventName - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model */ public function notifyEvent(eventName, model); @@ -297,7 +297,7 @@ interface ManagerInterface * This method expects that the endpoint listeners/behaviors returns true * meaning that a least one is implemented * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @param string eventName * @param array data * @return boolean @@ -307,7 +307,7 @@ interface ManagerInterface /** * Returns the last query created or executed in the models manager * - * @return Phalcon\Mvc\Model\QueryInterface + * @return \Phalcon\Mvc\Model\QueryInterface */ public function getLastQuery(); @@ -316,7 +316,7 @@ interface ManagerInterface * * @param string modelName * @param string alias - * @return Phalcon\Mvc\Model\Relation + * @return \Phalcon\Mvc\Model\Relation */ public function getRelationByAlias(string modelName, string alias); diff --git a/phalcon/mvc/model/message.zep b/phalcon/mvc/model/message.zep index 6e84406a4b7..d1ccbe91cca 100644 --- a/phalcon/mvc/model/message.zep +++ b/phalcon/mvc/model/message.zep @@ -65,7 +65,7 @@ class Message implements MessageInterface * @param string message * @param string|array field * @param string type - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model */ public function __construct(string! message, field = null, type = null, model = null) { diff --git a/phalcon/mvc/model/metadata.zep b/phalcon/mvc/model/metadata.zep index ed535b754e4..f58ba288ae4 100644 --- a/phalcon/mvc/model/metadata.zep +++ b/phalcon/mvc/model/metadata.zep @@ -121,7 +121,7 @@ abstract class MetaData implements InjectionAwareInterface } else { /** - * Get the meta-data extraction strategy + * Get the meta-data extraction strategy */ let dependencyInjector = this->_dependencyInjector, strategy = this->getStrategy(), diff --git a/phalcon/mvc/model/metadata/libmemcached.zep b/phalcon/mvc/model/metadata/libmemcached.zep index e95a2d4a920..88253808964 100644 --- a/phalcon/mvc/model/metadata/libmemcached.zep +++ b/phalcon/mvc/model/metadata/libmemcached.zep @@ -93,7 +93,7 @@ class Libmemcached extends MetaData implements MetaDataInterface public function read(string! key) -> array | null { var data; - + let data = this->_memcache->get(key); if typeof data == "array" { return data; @@ -122,7 +122,7 @@ class Libmemcached extends MetaData implements MetaDataInterface for key, _ in meta { let realKey = "meta-" . key; - + this->_memcache->delete(realKey); } } diff --git a/phalcon/mvc/model/metadata/memcache.zep b/phalcon/mvc/model/metadata/memcache.zep index 54d90969583..9d75b86389f 100644 --- a/phalcon/mvc/model/metadata/memcache.zep +++ b/phalcon/mvc/model/metadata/memcache.zep @@ -96,7 +96,7 @@ class Memcache extends MetaData implements MetaDataInterface public function read(string! key) -> array | null { var data; - + let data = this->_memcache->get(key); if typeof data == "array" { return data; @@ -125,7 +125,7 @@ class Memcache extends MetaData implements MetaDataInterface for key, _ in meta { let realKey = "meta-" . key; - + this->_memcache->delete(realKey); } } diff --git a/phalcon/mvc/model/metadata/redis.zep b/phalcon/mvc/model/metadata/redis.zep index cd9c910d181..555e67aefc3 100644 --- a/phalcon/mvc/model/metadata/redis.zep +++ b/phalcon/mvc/model/metadata/redis.zep @@ -96,7 +96,7 @@ class Redis extends MetaData implements MetaDataInterface public function read(string! key) -> array | null { var data; - + let data = this->_redis->get(key); if typeof data == "array" { return data; @@ -125,7 +125,7 @@ class Redis extends MetaData implements MetaDataInterface for key, _ in meta { let realKey = "meta-" . key; - + this->_redis->delete(realKey); } } diff --git a/phalcon/mvc/model/metadata/strategy/introspection.zep b/phalcon/mvc/model/metadata/strategy/introspection.zep index bc8fc55b004..ab42b3e9f31 100644 --- a/phalcon/mvc/model/metadata/strategy/introspection.zep +++ b/phalcon/mvc/model/metadata/strategy/introspection.zep @@ -150,7 +150,7 @@ class Introspection implements StrategyInterface let defaultValue = column->getDefault(); if defaultValue !== null || column->isNotNull() === false { if !column->isAutoIncrement() { - let defaultValues[fieldName] = defaultValue; + let defaultValues[fieldName] = defaultValue; } } } diff --git a/phalcon/mvc/model/metadata/strategyinterface.zep b/phalcon/mvc/model/metadata/strategyinterface.zep index 59751c31a56..381b319d17e 100644 --- a/phalcon/mvc/model/metadata/strategyinterface.zep +++ b/phalcon/mvc/model/metadata/strategyinterface.zep @@ -27,8 +27,8 @@ interface StrategyInterface /** * The meta-data is obtained by reading the column descriptions from the database information schema * - * @param Phalcon\Mvc\ModelInterface model - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\Mvc\ModelInterface model + * @param \Phalcon\DiInterface dependencyInjector * @return array */ public function getMetaData( model, dependencyInjector); @@ -36,8 +36,8 @@ interface StrategyInterface /** * Read the model's column map, this can't be inferred * - * @param Phalcon\Mvc\ModelInterface model - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\Mvc\ModelInterface model + * @param \Phalcon\DiInterface dependencyInjector * @return array * @todo Not implemented */ diff --git a/phalcon/mvc/model/metadatainterface.zep b/phalcon/mvc/model/metadatainterface.zep index 2ef3995defa..03f90b21c39 100644 --- a/phalcon/mvc/model/metadatainterface.zep +++ b/phalcon/mvc/model/metadatainterface.zep @@ -38,14 +38,14 @@ interface MetaDataInterface /** * Return the strategy to obtain the meta-data * - * @return Phalcon\Mvc\Model\MetaData\StrategyInterface + * @return \Phalcon\Mvc\Model\MetaData\StrategyInterface */ public function getStrategy(); /** * Reads meta-data for certain model * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ public function readMetaData( model); @@ -53,7 +53,7 @@ interface MetaDataInterface /** * Reads meta-data for certain model using a MODEL_* constant * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @param int index * @return mixed */ @@ -62,7 +62,7 @@ interface MetaDataInterface /** * Writes meta-data for certain model using a MODEL_* constant * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @param int index * @param mixed data */ @@ -71,7 +71,7 @@ interface MetaDataInterface /** * Reads the ordered/reversed column map for certain model * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ public function readColumnMap( model); @@ -79,7 +79,7 @@ interface MetaDataInterface /** * Reads column-map information for certain model using a MODEL_* constant * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @param int index */ public function readColumnMapIndex( model, index); @@ -87,7 +87,7 @@ interface MetaDataInterface /** * Returns table attributes names (fields) * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ public function getAttributes( model); @@ -95,7 +95,7 @@ interface MetaDataInterface /** * Returns an array of fields which are part of the primary key * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ public function getPrimaryKeyAttributes( model); @@ -103,7 +103,7 @@ interface MetaDataInterface /** * Returns an arrau of fields which are not part of the primary key * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ public function getNonPrimaryKeyAttributes( model); @@ -111,7 +111,7 @@ interface MetaDataInterface /** * Returns an array of not null attributes * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ public function getNotNullAttributes( model); @@ -119,7 +119,7 @@ interface MetaDataInterface /** * Returns attributes and their data types * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ public function getDataTypes( model); @@ -127,7 +127,7 @@ interface MetaDataInterface /** * Returns attributes which types are numerical * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ public function getDataTypesNumeric( model); @@ -135,7 +135,7 @@ interface MetaDataInterface /** * Returns the name of identity field (if one is present) * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return string */ public function getIdentityField( model); @@ -143,7 +143,7 @@ interface MetaDataInterface /** * Returns attributes and their bind data types * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ public function getBindTypes( model); @@ -151,7 +151,7 @@ interface MetaDataInterface /** * Returns attributes that must be ignored from the INSERT SQL generation * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ public function getAutomaticCreateAttributes( model); @@ -159,7 +159,7 @@ interface MetaDataInterface /** * Returns attributes that must be ignored from the UPDATE SQL generation * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @return array */ public function getAutomaticUpdateAttributes( model) -> array; @@ -175,7 +175,7 @@ interface MetaDataInterface public function setAutomaticUpdateAttributes( model, array attributes); /** - * Set the attributes that allow empty string values + * Set the attributes that allow empty string values */ public function setEmptyStringAttributes( model, array attributes) -> void; diff --git a/phalcon/mvc/model/query.zep b/phalcon/mvc/model/query.zep index 123c9942537..d4d015f5ee7 100644 --- a/phalcon/mvc/model/query.zep +++ b/phalcon/mvc/model/query.zep @@ -47,7 +47,7 @@ use Phalcon\Mvc\Model\RelationInterface; * WHERE b.name = :name: ORDER BY c.name"; * * $result = manager->executeQuery($phql, array( - * "name": "Lamborghini" + * "name" => "Lamborghini" * )); * * foreach ($result as $row) { @@ -98,6 +98,8 @@ class Query implements QueryInterface, InjectionAwareInterface protected _bindTypes; + protected _enableImplicitJoins; + static protected _irPhqlCache; const TYPE_SELECT = 309; @@ -112,10 +114,12 @@ class Query implements QueryInterface, InjectionAwareInterface * Phalcon\Mvc\Model\Query constructor * * @param string phql - * @param Phalcon\DiInterface dependencyInjector + * @param \Phalcon\DiInterface dependencyInjector */ - public function __construct(phql = null, dependencyInjector = null) + public function __construct(phql = null, dependencyInjector = null, options = null) { + var enableImplicitJoins; + if typeof phql != "null" { let this->_phql = phql; } @@ -123,6 +127,12 @@ class Query implements QueryInterface, InjectionAwareInterface if typeof dependencyInjector == "object" { this->setDI(dependencyInjector); } + + if typeof options == "array" && fetch enableImplicitJoins, options["enable_implicit_joins"] { + let this->_enableImplicitJoins = enableImplicitJoins == true; + } else { + let this->_enableImplicitJoins = globals_get("orm.enable_implicit_joins"); + } } /** @@ -252,7 +262,7 @@ class Query implements QueryInterface, InjectionAwareInterface for model in this->_modelsInstances { /** - * Check if the atribute belongs to the current model + * Check if the attribute belongs to the current model */ if metaData->hasAttribute(model, columnName) { let number++; @@ -414,7 +424,7 @@ class Query implements QueryInterface, InjectionAwareInterface * @param boolean quoting * @return string */ - protected final function _getExpression(expr, boolean quoting = true) -> string + protected final function _getExpression(var expr, boolean quoting = true) -> string { var exprType, exprLeft, exprRight, left = null, right = null, listItems, exprListItem, exprReturn, tempNotQuoting, value, escapedValue, exprValue, @@ -618,7 +628,7 @@ class Query implements QueryInterface, InjectionAwareInterface let exprReturn = [ "type": "placeholder", "value": ":" . name, - "rawValue": name, + "rawValue": name, "times": count(bind) ]; break; @@ -743,15 +753,12 @@ class Query implements QueryInterface, InjectionAwareInterface /** * Resolves a column from its intermediate representation into an array used to determine * if the resultset produced is simple or complex - * - * @param array column - * @return array */ - protected final function _getSelectColumn(array! column) + protected final function _getSelectColumn(array! column) -> array { var sqlColumns, columnType, sqlAliases, modelName, source, columnDomain, sqlColumnAlias, preparedAlias, sqlExprColumn, - sqlAliasesModels, sqlColumn, columnData, balias; + sqlAliasesModels, sqlColumn, columnData, balias, eager; if !fetch columnType, column["type"] { throw new Exception("Corrupted SELECT AST"); @@ -759,16 +766,30 @@ class Query implements QueryInterface, InjectionAwareInterface let sqlColumns = []; + /** + * Check if column is eager loaded + */ + fetch eager, column["eager"]; + /** * Check for select * (all) */ if columnType == PHQL_T_STARALL { for modelName, source in this->_models { - let sqlColumns[] = [ + + let sqlColumn = [ "type" : "object", "model" : modelName, - "column": source + "column": source, + "balias": lcfirst(modelName) ]; + + if eager !== null { + let sqlColumn["eager"] = eager, + sqlColumn["eagerType"] = column["eagerType"]; + } + + let sqlColumns[] = sqlColumn; } return sqlColumns; } @@ -798,31 +819,43 @@ class Query implements QueryInterface, InjectionAwareInterface */ let sqlColumnAlias = source; + fetch preparedAlias, column["balias"]; + /** * Get the real source name */ let sqlAliasesModels = this->_sqlAliasesModels, modelName = sqlAliasesModels[columnDomain]; - /** - * If the best alias is the model name we lowercase the first letter - */ - if columnDomain == modelName { - let preparedAlias = lcfirst(modelName); - } else { - let preparedAlias = columnDomain; + if typeof preparedAlias != "string" { + + /** + * If the best alias is the model name, we lowercase the first letter + */ + if columnDomain == modelName { + let preparedAlias = lcfirst(modelName); + } else { + let preparedAlias = columnDomain; + } } /** * Each item is a complex type returning a complete object */ - let sqlColumns[] = [ + let sqlColumn = [ "type": "object", "model": modelName, "column": sqlColumnAlias, "balias": preparedAlias ]; + if eager !== null { + let sqlColumn["eager"] = eager, + sqlColumn["eagerType"] = column["eagerType"]; + } + + let sqlColumns[] = sqlColumn; + return sqlColumns; } @@ -846,6 +879,11 @@ class Query implements QueryInterface, InjectionAwareInterface sqlColumn["sqlAlias"] = balias; } + if eager !== null { + let sqlColumn["eager"] = eager, + sqlColumn["eagerType"] = column["eagerType"]; + } + let sqlColumn["column"] = sqlExprColumn, sqlColumns[] = sqlColumn; @@ -858,7 +896,7 @@ class Query implements QueryInterface, InjectionAwareInterface /** * Resolves a table in a SELECT statement checking if the model exists * - * @param Phalcon\Mvc\Model\ManagerInterface manager + * @param \Phalcon\Mvc\Model\ManagerInterface manager * @param array qualifiedName * @return string */ @@ -883,18 +921,15 @@ class Query implements QueryInterface, InjectionAwareInterface /** * Resolves a JOIN clause checking if the associated models exist - * - * @param Phalcon\Mvc\Model\ManagerInterface manager - * @param array join - * @return array */ - protected final function _getJoin( manager, join) -> array + protected final function _getJoin( manager, var join) -> array { - var qualified, modelName, realModelName, nsAlias, source, model, schema; + var qualified, modelName, realModelName, nsAlias, + source, model, schema; if fetch qualified, join["qualified"] { - if qualified["type"] == 355 { + if qualified["type"] == PHQL_T_QUALIFIED { let modelName = qualified["name"]; @@ -963,7 +998,7 @@ class Query implements QueryInterface, InjectionAwareInterface * @param string joinSource * @param string modelAlias * @param string joinAlias - * @param Phalcon\Mvc\Model\RelationInterface relation + * @param \Phalcon\Mvc\Model\RelationInterface relation * @return array */ protected final function _getSingleJoin(string! joinType, joinSource, modelAlias, joinAlias, relation) -> array @@ -993,7 +1028,7 @@ class Query implements QueryInterface, InjectionAwareInterface "type" : "binary-op", "op" : "=", "left" : this->_getQualified([ - "type" : 355, + "type" : PHQL_T_QUALIFIED, "domain" : modelAlias, "name" : fields ]), @@ -1029,7 +1064,7 @@ class Query implements QueryInterface, InjectionAwareInterface "type" : "binary-op", "op" : "=", "left" : this->_getQualified([ - "type" : 355, + "type" : PHQL_T_QUALIFIED, "domain" : modelAlias, "name" : field ]), @@ -1060,7 +1095,7 @@ class Query implements QueryInterface, InjectionAwareInterface * @param string joinSource * @param string modelAlias * @param string joinAlias - * @param Phalcon\Mvc\Model\RelationInterface relation + * @param \Phalcon\Mvc\Model\RelationInterface relation * @return array */ protected final function _getMultiJoin(joinType, joinSource, modelAlias, joinAlias, relation) -> array @@ -1152,7 +1187,7 @@ class Query implements QueryInterface, InjectionAwareInterface "type" : "binary-op", "op" : "=", "left" : this->_getQualified([ - "type" : 355, + "type" : PHQL_T_QUALIFIED, "domain" : modelAlias, "name" : field ]), @@ -1183,7 +1218,7 @@ class Query implements QueryInterface, InjectionAwareInterface "type" : "binary-op", "op" : "=", "left" : this->_getQualified([ - "type" : 355, + "type" : PHQL_T_QUALIFIED, "domain" : modelAlias, "name" : fields ]), @@ -1208,7 +1243,7 @@ class Query implements QueryInterface, InjectionAwareInterface "type" : "binary-op", "op" : "=", "left" : this->_getQualified([ - "type" : 355, + "type" : PHQL_T_QUALIFIED, "domain" : intermediateModelName, "name" : intermediateReferencedFields ]), @@ -1231,14 +1266,14 @@ class Query implements QueryInterface, InjectionAwareInterface * @param array select * @return array */ - protected final function _getJoins(select) + protected final function _getJoins(var select) { var models, sqlAliases, sqlAliasesModels, sqlModelsAliases, sqlAliasesModelsInstances, modelsInstances, fromModels, sqlJoins, joinModels, joinSources, joinTypes, joinPreCondition, joinPrepared, manager, selectJoins, joinItem, joins, joinData, schema, source, model, realModelName, completeSource, joinType, aliasExpr, alias, joinAliasName, joinExpr, fromModelName, joinAlias, joinModel, joinSource, preCondition, modelNameAlias, - relation, relations, modelAlias, sqlJoin, sqlJoinItem; + relation, relations, modelAlias, sqlJoin, sqlJoinItem, selectTables, tables, tableItem; let models = this->_models, sqlAliases = this->_sqlAliases, @@ -1257,6 +1292,13 @@ class Query implements QueryInterface, InjectionAwareInterface let manager = this->_manager; + let tables = select["tables"]; + if !isset tables[0] { + let selectTables = [tables]; + } else { + let selectTables = tables; + } + let joins = select["joins"]; if !isset joins[0] { let selectJoins = [joins]; @@ -1424,10 +1466,33 @@ class Query implements QueryInterface, InjectionAwareInterface } /** - * Create join relationships dynamically + * Skip all implicit joins if the option is not enabled */ - let manager = this->_manager; + if !this->_enableImplicitJoins { + for joinAliasName, _ in joinPrepared { + let joinType = joinTypes[joinAliasName], + joinSource = joinSources[joinAliasName], + preCondition = joinPreCondition[joinAliasName], + sqlJoins[] = [ + "type": joinType, + "source": joinSource, + "conditions": [preCondition] + ]; + } + return sqlJoins; + } + /** + * Build the list of tables used in the SELECT clause + */ + let fromModels = []; + for tableItem in selectTables { + let fromModels[tableItem["qualifiedName"]["name"]] = true; + } + + /** + * Create join relationships dynamically + */ for fromModelName, _ in fromModels { for joinAlias, joinModel in joinModels { @@ -1630,7 +1695,10 @@ class Query implements QueryInterface, InjectionAwareInterface selectedModel, qualifiedName, modelName, nsAlias, realModelName, model, schema, source, completeSource, alias, joins, sqlJoins, selectColumns, sqlColumnAliases, column, sqlColumn, sqlSelect, distinct, having, where, - groupBy, order, limit; + groupBy, order, limit, tempModels, tempModelsInstances, tempSqlAliases, + tempSqlModelsAliases, tempSqlAliasesModelsInstances, tempSqlAliasesModels, + with, withs, withItem, automaticJoins, number, relation, joinAlias, + relationModel, bestAlias, eagerType; if empty ast { let ast = this->_ast; @@ -1653,37 +1721,37 @@ class Query implements QueryInterface, InjectionAwareInterface } /** - * sql_models are all the models that are using in the query + * sqlModels is an array of the models to be used in the query */ let sqlModels = []; /** - * sql_tables are all the mapped sources regarding the models in use + * sqlTables is an array of the mapped models sources to be used in the query */ let sqlTables = []; /** - * sql_aliases are the aliases as keys and the mapped sources as values + * sqlColumns is an array of every column expression */ - let sqlAliases = []; + let sqlColumns = []; /** - * sql_columns are all every column expression + * sqlAliases is a map from aliases to mapped sources */ - let sqlColumns = []; + let sqlAliases = []; /** - * sqlAliasesModels are the aliases as keys and the model names as values + * sqlAliasesModels is a map from aliases to model names */ let sqlAliasesModels = []; /** - * sqlAliasesModels are the model names as keys and the aliases as values + * sqlAliasesModels is a map from model names to aliases */ let sqlModelsAliases = []; /** - * sqlAliasesModelsInstances are the aliases as keys and the model instances as values + * sqlAliasesModelsInstances is a map from aliases to model instances */ let sqlAliasesModelsInstances = []; @@ -1693,12 +1761,20 @@ class Query implements QueryInterface, InjectionAwareInterface let models = [], modelsInstances = []; + // Convert selected models in an array if !isset tables[0] { let selectedModels = [tables]; } else { let selectedModels = tables; } + // Convert selected columns in an array + if !isset columns[0] { + let selectColumns = [columns]; + } else { + let selectColumns = columns; + } + let manager = this->_manager, metaData = this->_metaData; @@ -1710,15 +1786,16 @@ class Query implements QueryInterface, InjectionAwareInterface throw new Exception("A meta-data is required to execute the query"); } - // Processing selected columns + // Process selected models + let number = 0, + automaticJoins = []; + for selectedModel in selectedModels { let qualifiedName = selectedModel["qualifiedName"], modelName = qualifiedName["name"]; - /** - * Check if the table have a namespace alias - */ + // Check if the table has a namespace alias if memstr(modelName, ":") { let nsAlias = explode(":", modelName); let realModelName = manager->getNamespaceAlias(nsAlias[0]) . "\\" . nsAlias[1]; @@ -1726,14 +1803,10 @@ class Query implements QueryInterface, InjectionAwareInterface let realModelName = modelName; } - /** - * Load a model instance from the models manager - */ + // Load a model instance from the models manager let model = manager->load(realModelName, true); - /** - * Define a complete schema/source - */ + // Define a complete schema/source let schema = model->getSchema(), source = model->getSource(); @@ -1744,12 +1817,12 @@ class Query implements QueryInterface, InjectionAwareInterface let completeSource = source; } - // If an alias is defined for a model the model cannot be referenced in the column list + // If an alias is defined for a model then the model cannot be referenced in the column list if fetch alias, selectedModel["alias"] { - // Check that the alias hasn't been used before + // Check if the alias was used before if isset sqlAliases[alias] { - throw new Exception("Alias '" . alias . "' is already used, when preparing: " . this->_phql); + throw new Exception("Alias '" . alias . "' is used more than once, when preparing: " . this->_phql); } let sqlAliases[alias] = alias, @@ -1768,13 +1841,69 @@ class Query implements QueryInterface, InjectionAwareInterface let models[realModelName] = alias; } else { - let sqlAliases[realModelName] = source, + let alias = source, + sqlAliases[realModelName] = source, sqlAliasesModels[realModelName] = realModelName, sqlModelsAliases[realModelName] = realModelName, sqlAliasesModelsInstances[realModelName] = model, models[realModelName] = source; } + // Eager load any specified relationship(s) + if fetch with, selectedModel["with"] { + + if !isset with[0] { + let withs = [with]; + } else { + let withs = with; + } + + // Simulate the definition of inner joins + for withItem in withs { + + let joinAlias = "AA" . number, + relationModel = withItem["name"], + relation = manager->getRelationByAlias(realModelName, relationModel); + + if typeof relation == "object" { + let bestAlias = relation->getOption("alias"), + relationModel = relation->getReferencedModel(), + eagerType = relation->getType(); + } else { + let relation = manager->getRelationsBetween(realModelName, relationModel); + if typeof relation == "object" { + let bestAlias = relation->getOption("alias"), + relationModel = relation->getReferencedModel(), + eagerType = relation->getType(); + } else { + throw new Exception("Can't find a relationship between '" . realModelName . "' and '" . relationModel . "' when preparing: " . this->_phql); + } + } + + let selectColumns[] = [ + "type": PHQL_T_DOMAINALL, + "column": joinAlias, + "eager": alias, + "eagerType": eagerType, + "balias": bestAlias + ]; + + let automaticJoins[] = [ + "type": PHQL_T_INNERJOIN, + "qualified": [ + "type": PHQL_T_QUALIFIED, + "name": relationModel + ], + "alias": [ + "type": PHQL_T_QUALIFIED, + "name": joinAlias + ] + ]; + + let number++; + } + } + let sqlModels[] = realModelName, sqlTables[] = completeSource, modelsInstances[realModelName] = model; @@ -1789,6 +1918,14 @@ class Query implements QueryInterface, InjectionAwareInterface this->_sqlModelsAliases = sqlModelsAliases, this->_sqlAliasesModelsInstances = sqlAliasesModelsInstances; } else { + + let tempModels = this->_models, + tempModelsInstances = this->_modelsInstances, + tempSqlAliases = this->_sqlAliases, + tempSqlAliasesModels = this->_sqlAliasesModels, + tempSqlModelsAliases = this->_sqlModelsAliases, + tempSqlAliasesModelsInstances = this->_sqlAliasesModelsInstances; + let this->_models = array_merge(this->_models, models), this->_modelsInstances = array_merge(this->_modelsInstances, modelsInstances), this->_sqlAliases = array_merge(this->_sqlAliases, sqlAliases), @@ -1797,22 +1934,26 @@ class Query implements QueryInterface, InjectionAwareInterface this->_sqlAliasesModelsInstances = array_merge(this->_sqlAliasesModelsInstances, sqlAliasesModelsInstances); } - // Processing joins - if fetch joins, select["joins"] { - if count(joins) { - let sqlJoins = this->_getJoins(select); + fetch joins, select["joins"]; + + // Join existing JOINS with automatic Joins + if count(joins) { + if count(automaticJoins) { + if isset joins[0] { + let select["joins"] = array_merge(joins, automaticJoins); + } else { + let automaticJoins[] = joins, + select["joins"] = automaticJoins; + } + } + let sqlJoins = this->_getJoins(select); + } else { + if count(automaticJoins) { + let select["joins"] = automaticJoins, + sqlJoins = this->_getJoins(select); } else { let sqlJoins = []; } - } else { - let sqlJoins = []; - } - - // Processing selected columns - if !isset columns[0] { - let selectColumns = [columns]; - } else { - let selectColumns = columns; } // Resolve selected columns @@ -1824,7 +1965,7 @@ class Query implements QueryInterface, InjectionAwareInterface for sqlColumn in this->_getSelectColumn(column) { /** - * If "alias" is set, the user had defined a alias for the column + * If "alias" is set, the user defined an alias for the column */ if fetch alias, column["alias"] { @@ -1838,7 +1979,7 @@ class Query implements QueryInterface, InjectionAwareInterface } else { /** - * "balias" is the best alias selected for the column + * "balias" is the best alias choosen for the column */ if fetch alias, sqlColumn["balias"] { let sqlColumns[alias] = sqlColumn; @@ -1871,36 +2012,45 @@ class Query implements QueryInterface, InjectionAwareInterface let sqlSelect["joins"] = sqlJoins; } - // Process "WHERE" clause if any + // Process "WHERE" clause if set if fetch where, ast["where"] { let sqlSelect["where"] = this->_getExpression(where); } - // Process "GROUP BY" clause if any + // Process "GROUP BY" clause if set if fetch groupBy, ast["groupBy"] { let sqlSelect["group"] = this->_getGroupClause(groupBy); } - // Process "HAVING" clause if any + // Process "HAVING" clause if set if fetch having , ast["having"] { let sqlSelect["having"] = this->_getExpression(having); } - // Process "ORDER BY" clause if any + // Process "ORDER BY" clause if set if fetch order, ast["orderBy"] { let sqlSelect["order"] = this->_getOrderClause(order); } - // Process "LIMIT" clause if any + // Process "LIMIT" clause if set if fetch limit, ast["limit"] { let sqlSelect["limit"] = this->_getLimitClause(limit); } - // Process "FOR UPDATE" clause + // Process "FOR UPDATE" clause if set if isset ast["forUpdate"] { let sqlSelect["forUpdate"] = true; } + if merge { + let this->_models = tempModels, + this->_modelsInstances = tempModelsInstances, + this->_sqlAliases = tempSqlAliases, + this->_sqlAliasesModels = tempSqlAliasesModels, + this->_sqlModelsAliases = tempSqlModelsAliases, + this->_sqlAliasesModelsInstances = tempSqlAliasesModelsInstances; + } + return sqlSelect; } @@ -2113,7 +2263,6 @@ class Query implements QueryInterface, InjectionAwareInterface "type" : exprColumn["type"], "value": this->_getExpression(exprColumn, notQuoting) ]; - } let sqlUpdate = [ @@ -2156,9 +2305,11 @@ class Query implements QueryInterface, InjectionAwareInterface } /** - * We use these arrays to store info related to models, alias and its sources. With them we can rename columns later + * We use these arrays to store info related to models, alias and its sources. + * Thanks to them we can rename columns later */ - let models = [], modelsInstances = []; + let models = [], + modelsInstances = []; let sqlTables = [], sqlModels = [], @@ -2177,9 +2328,6 @@ class Query implements QueryInterface, InjectionAwareInterface let qualifiedName = table["qualifiedName"], modelName = qualifiedName["name"]; - /** - * Check if the table have a namespace alias - */ /** * Check if the table have a namespace alias */ @@ -2488,7 +2636,7 @@ class Query implements QueryInterface, InjectionAwareInterface } else { /** - * Create an alias if the column doesn"t have one + * Create an alias if the column doesn't have one */ if typeof aliasCopy == "int" { let columnAlias = [sqlColumn, null]; @@ -2603,7 +2751,7 @@ class Query implements QueryInterface, InjectionAwareInterface let resultObject = new Row(); /** - * Standard objects can"t keep snapshots + * Standard objects can't keep snapshots */ let isKeepingSnapshots = false; @@ -2662,7 +2810,7 @@ class Query implements QueryInterface, InjectionAwareInterface * @param array intermediate * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\StatusInterface + * @return \Phalcon\Mvc\Model\Query\StatusInterface */ protected final function _executeInsert(var intermediate, var bindParams, var bindTypes) -> { @@ -2797,7 +2945,7 @@ class Query implements QueryInterface, InjectionAwareInterface * @param array intermediate * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\StatusInterface + * @return \Phalcon\Mvc\Model\Query\StatusInterface */ protected final function _executeUpdate(var intermediate, var bindParams, var bindTypes) -> { @@ -2953,7 +3101,7 @@ class Query implements QueryInterface, InjectionAwareInterface * @param array intermediate * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\StatusInterface + * @return \Phalcon\Mvc\Model\Query\StatusInterface */ protected final function _executeDelete(var intermediate, var bindParams, var bindTypes) -> { @@ -3030,11 +3178,11 @@ class Query implements QueryInterface, InjectionAwareInterface /** * Query the records on which the UPDATE/DELETE operation well be done * - * @param Phalcon\Mvc\ModelInterface model + * @param \Phalcon\Mvc\ModelInterface model * @param array intermediate * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\ResultsetInterface + * @return \Phalcon\Mvc\Model\ResultsetInterface */ protected final function _getRelatedRecords( model, var intermediate, var bindParams, var bindTypes) -> @@ -3247,7 +3395,7 @@ class Query implements QueryInterface, InjectionAwareInterface * * @param array bindParams * @param array bindTypes - * @return Ṕhalcon\Mvc\ModelInterface + * @return \Phalcon\Mvc\ModelInterface */ public function getSingleResult(var bindParams = null, var bindTypes = null) { diff --git a/phalcon/mvc/model/query/builder.zep b/phalcon/mvc/model/query/builder.zep index d0a04a7737a..8015c2dfaac 100644 --- a/phalcon/mvc/model/query/builder.zep +++ b/phalcon/mvc/model/query/builder.zep @@ -24,8 +24,8 @@ use Phalcon\Db\Column; use Phalcon\DiInterface; use Phalcon\Mvc\Model\Query; use Phalcon\Mvc\Model\Exception; -use Phalcon\Mvc\Model\Query\BuilderInterface; use Phalcon\Di\InjectionAwareInterface; +use Phalcon\Mvc\Model\Query\BuilderInterface; /** * Phalcon\Mvc\Model\Query\Builder @@ -297,8 +297,10 @@ class Builder implements BuilderInterface, InjectionAwareInterface /** * Sets SELECT DISTINCT / SELECT ALL flag * - * @param bool|null distinct - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * + * $builder->distinct("status"); + * $builder->distinct(null); + * */ public function distinct(var distinct) -> { @@ -318,11 +320,10 @@ class Builder implements BuilderInterface, InjectionAwareInterface * Sets the columns to be queried * * + * $builder->columns("id, name"); * $builder->columns(array('id', 'name')); + * $builder->columns(array('name', 'number' => 'COUNT(*)')); * - * - * @param string|array columns - * @return Phalcon\Mvc\Model\Query\Builder */ public function columns(var columns) -> { @@ -346,10 +347,8 @@ class Builder implements BuilderInterface, InjectionAwareInterface * * $builder->from('Robots'); * $builder->from(array('Robots', 'RobotsParts')); + * $builder->from(array('r' => 'Robots', 'rp' => 'RobotsParts')); * - * - * @param string|array models - * @return Phalcon\Mvc\Model\Query\Builder */ public function from(var models) -> { @@ -361,14 +360,22 @@ class Builder implements BuilderInterface, InjectionAwareInterface * Add a model to take part of the query * * + * // Load data from models Robots + * $builder->addFrom('Robots'); + * + * // Load data from model 'Robots' using 'r' as alias in PHQL * $builder->addFrom('Robots', 'r'); - * * - * @param string model - * @param string alias - * @return Phalcon\Mvc\Model\Query\Builder + * // Load data from model 'Robots' using 'r' as alias in PHQL + * // and eager load model 'RobotsParts' + * $builder->addFrom('Robots', 'r', 'RobotsParts'); + * + * // Load data from model 'Robots' using 'r' as alias in PHQL + * // and eager load models 'RobotsParts' and 'Parts' + * $builder->addFrom('Robots', 'r', ['RobotsParts', 'Parts']); + * */ - public function addFrom(var model, var alias = null) -> + public function addFrom(var model, var alias = null, var with = null) -> { var models, currentModel; @@ -406,17 +413,24 @@ class Builder implements BuilderInterface, InjectionAwareInterface * Adds a INNER join to the query * * + * // Inner Join model 'Robots' with automatic conditions and alias * $builder->join('Robots'); - * $builder->join('Robots', 'r.id = RobotsParts.robots_id'); + * + * // Inner Join model 'Robots' specifing conditions + * $builder->join('Robots', 'Robots.id = RobotsParts.robots_id'); + * + * // Inner Join model 'Robots' specifing conditions and alias * $builder->join('Robots', 'r.id = RobotsParts.robots_id', 'r'); - * $builder->join('Robots', 'r.id = RobotsParts.robots_id', 'r', 'INNER'); + * + * // Left Join model 'Robots' specifing conditions, alias and type of join + * $builder->join('Robots', 'r.id = RobotsParts.robots_id', 'r', 'LEFT'); * * * @param string model * @param string conditions * @param string alias * @param string type - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function join(string! model, var conditions = null, var alias = null, var type = null) -> { @@ -428,8 +442,13 @@ class Builder implements BuilderInterface, InjectionAwareInterface * Adds a INNER join to the query * * + * // Inner Join model 'Robots' with automatic conditions and alias * $builder->innerJoin('Robots'); - * $builder->innerJoin('Robots', 'r.id = RobotsParts.robots_id'); + * + * // Inner Join model 'Robots' specifing conditions + * $builder->innerJoin('Robots', 'Robots.id = RobotsParts.robots_id'); + * + * // Inner Join model 'Robots' specifing conditions and alias * $builder->innerJoin('Robots', 'r.id = RobotsParts.robots_id', 'r'); * * @@ -437,7 +456,7 @@ class Builder implements BuilderInterface, InjectionAwareInterface * @param string conditions * @param string alias * @param string type - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function innerJoin(string! model, var conditions = null, var alias = null) -> { @@ -455,7 +474,7 @@ class Builder implements BuilderInterface, InjectionAwareInterface * @param string model * @param string conditions * @param string alias - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function leftJoin(string! model, var conditions = null, var alias = null) -> { @@ -473,7 +492,7 @@ class Builder implements BuilderInterface, InjectionAwareInterface * @param string model * @param string conditions * @param string alias - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function rightJoin(string! model, var conditions = null, var alias = null) -> { @@ -493,7 +512,7 @@ class Builder implements BuilderInterface, InjectionAwareInterface * @param mixed conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function where(var conditions, var bindParams = null, var bindTypes = null) -> { @@ -541,7 +560,7 @@ class Builder implements BuilderInterface, InjectionAwareInterface * @param string conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function andWhere(string! conditions, var bindParams = null, var bindTypes = null) -> { @@ -600,7 +619,7 @@ class Builder implements BuilderInterface, InjectionAwareInterface * @param string conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function orWhere(string! conditions, var bindParams = null, var bindTypes = null) -> { @@ -823,7 +842,7 @@ class Builder implements BuilderInterface, InjectionAwareInterface * * * @param string|array orderBy - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function orderBy(var orderBy) -> { @@ -935,7 +954,7 @@ class Builder implements BuilderInterface, InjectionAwareInterface * * * @param string|array group - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function groupBy(var group) -> { @@ -966,7 +985,7 @@ class Builder implements BuilderInterface, InjectionAwareInterface selectedModel, selectedModels, columnAlias, modelColumnAlias, joins, join, joinModel, joinConditions, joinAlias, joinType, group, groupItems, groupItem, having, order, orderItems, orderItem, - limit, number, offset, forUpdate, distinct, withModels, hiddenParam; + limit, number, offset, forUpdate, distinct; boolean noPrimary; let dependencyInjector = this->_dependencyInjector; @@ -987,6 +1006,7 @@ class Builder implements BuilderInterface, InjectionAwareInterface } let conditions = this->_conditions; + if is_numeric(conditions) { /** @@ -1067,7 +1087,11 @@ class Builder implements BuilderInterface, InjectionAwareInterface if typeof columnAlias == "integer" { let selectedColumns[] = column; } else { - let selectedColumns[] = column . " AS " . columnAlias; + if memstr(columnAlias, "[") { + let selectedColumns[] = column . " AS " . columnAlias; + } else { + let selectedColumns[] = column . " AS [" . columnAlias . "]"; + } } } @@ -1136,20 +1160,6 @@ class Builder implements BuilderInterface, InjectionAwareInterface } } - /** - * Check if there are eager loaded models - */ - let withModels = this->_with; - if typeof withModels == "array" { - - let selectedColumns = []; - for model in withModels { - let selectedColumns[] = "[" . model . "]"; - } - - let phql .= " WITH " . join(", ", selectedColumns); - } - /** * Check if joins were passed to the builders */ @@ -1317,19 +1327,15 @@ class Builder implements BuilderInterface, InjectionAwareInterface if is_numeric(number) { - let hiddenParam = this->_hiddenParamNumber, - phql .= " LIMIT :AP" . hiddenParam . ":", - this->_bindParams["AP" . hiddenParam] = intval(number, 10), - this->_bindTypes["AP" . hiddenParam] = Column::BIND_PARAM_INT; + let phql .= " LIMIT :APL0:", + this->_bindParams["APL0"] = intval(number, 10), + this->_bindTypes["APL0"] = Column::BIND_PARAM_INT; if is_numeric(offset) { - let hiddenParam++, - phql .= " OFFSET :AP" . hiddenParam . ":", - this->_bindParams["AP" . hiddenParam] = intval(offset, 10), - this->_bindTypes["AP" . hiddenParam] = Column::BIND_PARAM_INT; + let phql .= " OFFSET :APL1:", + this->_bindParams["APL1"] = intval(offset, 10), + this->_bindTypes["APL1"] = Column::BIND_PARAM_INT; } - - let this->_hiddenParamNumber = hiddenParam + 1; } } @@ -1339,7 +1345,7 @@ class Builder implements BuilderInterface, InjectionAwareInterface let phql .= " FOR UPDATE"; } } - + return phql; } diff --git a/phalcon/mvc/model/query/builderinterface.zep b/phalcon/mvc/model/query/builderinterface.zep index 336f11fbef0..9b38ec6ff56 100644 --- a/phalcon/mvc/model/query/builderinterface.zep +++ b/phalcon/mvc/model/query/builderinterface.zep @@ -38,7 +38,7 @@ interface BuilderInterface * Sets the columns to be queried * * @param string|array columns - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ public function columns(columns); @@ -53,7 +53,7 @@ interface BuilderInterface * Sets the models who makes part of the query * * @param string|array models - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ public function from(models); @@ -62,7 +62,7 @@ interface BuilderInterface * * @param string model * @param string alias - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ public function addFrom(model, alias = null); @@ -79,7 +79,7 @@ interface BuilderInterface * @param string model * @param string conditions * @param string alias - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ public function join(model, conditions = null, alias = null); @@ -90,7 +90,7 @@ interface BuilderInterface * @param string conditions * @param string alias * @param string type - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function innerJoin(model, conditions = null, alias = null); @@ -100,7 +100,7 @@ interface BuilderInterface * @param string model * @param string conditions * @param string alias - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function leftJoin(model, conditions = null, alias = null); @@ -110,7 +110,7 @@ interface BuilderInterface * @param string model * @param string conditions * @param string alias - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function rightJoin(model, conditions = null, alias = null); @@ -120,7 +120,7 @@ interface BuilderInterface * @param string conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ public function where(conditions, bindParams = null, bindTypes = null); @@ -130,7 +130,7 @@ interface BuilderInterface * @param string conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function andWhere(conditions, bindParams = null, bindTypes = null); @@ -140,7 +140,7 @@ interface BuilderInterface * @param string conditions * @param array bindParams * @param array bindTypes - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function orWhere(conditions, bindParams = null, bindTypes = null); @@ -150,7 +150,7 @@ interface BuilderInterface * @param string expr * @param mixed minimum * @param mixed maximum - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function betweenWhere(expr, minimum, maximum); @@ -160,7 +160,7 @@ interface BuilderInterface * @param string expr * @param mixed minimum * @param mixed maximum - * @return Phalcon\Mvc\Model\Query\Builder + * @return \Phalcon\Mvc\Model\Query\Builder */ public function notBetweenWhere(expr, minimum, maximum); @@ -185,7 +185,7 @@ interface BuilderInterface * Sets a ORDER BY condition clause * * @param string orderBy - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ public function orderBy(orderBy); @@ -200,7 +200,7 @@ interface BuilderInterface * Sets a HAVING condition clause * * @param string having - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ public function having(having); @@ -216,7 +216,7 @@ interface BuilderInterface * * @param int limit * @param int offset - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ public function limit(limit, offset = null); @@ -231,7 +231,7 @@ interface BuilderInterface * Sets a LIMIT clause * * @param string group - * @return Phalcon\Mvc\Model\Query\BuilderInterface + * @return \Phalcon\Mvc\Model\Query\BuilderInterface */ public function groupBy(group); @@ -252,7 +252,7 @@ interface BuilderInterface /** * Returns the query built * - * @return Phalcon\Mvc\Model\QueryInterface + * @return \Phalcon\Mvc\Model\QueryInterface */ public function getQuery(); diff --git a/phalcon/mvc/model/queryinterface.zep b/phalcon/mvc/model/queryinterface.zep index 23f7affc449..1f63991b094 100644 --- a/phalcon/mvc/model/queryinterface.zep +++ b/phalcon/mvc/model/queryinterface.zep @@ -39,7 +39,7 @@ interface QueryInterface * Sets the cache parameters of the query * * @param array cacheOptions - * @return Phalcon\Mvc\Model\Query + * @return \Phalcon\Mvc\Model\Query */ public function cache(cacheOptions); @@ -54,7 +54,7 @@ interface QueryInterface * Tells to the query if only the first row in the resultset must be returned * * @param boolean uniqueRow - * @return Phalcon\Mvc\Model\Query + * @return \Phalcon\Mvc\Model\Query */ public function setUniqueRow(boolean uniqueRow); diff --git a/phalcon/mvc/model/relation.zep b/phalcon/mvc/model/relation.zep index 21455def2fc..7b9d91b856e 100644 --- a/phalcon/mvc/model/relation.zep +++ b/phalcon/mvc/model/relation.zep @@ -139,6 +139,19 @@ class Relation implements RelationInterface return this->_options; } + /** + * Returns an option by the specified name + * If the option doesn't exist null is returned + */ + public function getOption(string! name) + { + var option; + if fetch option, this->_options[name] { + return option; + } + return null; + } + /** * Check whether the relation act as a foreign key */ @@ -171,7 +184,7 @@ class Relation implements RelationInterface } } return false; - } + } /** * Returns parameters that must be always used when the related records are obtained diff --git a/phalcon/mvc/model/resultset.zep b/phalcon/mvc/model/resultset.zep index 7850fee545b..2fe8d96fcea 100644 --- a/phalcon/mvc/model/resultset.zep +++ b/phalcon/mvc/model/resultset.zep @@ -93,8 +93,8 @@ abstract class Resultset * Phalcon\Mvc\Model\Resultset constructor * * @param array columnTypes - * @param Phalcon\Db\ResultInterface|false result - * @param Phalcon\Cache\BackendInterface cache + * @param \Phalcon\Db\ResultInterface|false result + * @param \Phalcon\Cache\BackendInterface cache */ public function __construct(result, cache = null) { @@ -289,7 +289,7 @@ abstract class Resultset * Resultsets cannot be changed. It has only been implemented to meet the definition of the ArrayAccess interface * * @param int index - * @param Phalcon\Mvc\ModelInterface value + * @param \Phalcon\Mvc\ModelInterface value */ public function offsetSet(var index, var value) { @@ -394,7 +394,7 @@ abstract class Resultset * Updates every record in the resultset * * @param array data - * @param Closure conditionCallback + * @param \Closure conditionCallback * @return boolean */ public function update(var data, <\Closure> conditionCallback = null) -> boolean @@ -532,7 +532,7 @@ abstract class Resultset * * * @param callback filter - * @return Phalcon\Mvc\Model[] + * @return \Phalcon\Mvc\Model[] */ public function filter(var filter) -> array { diff --git a/phalcon/mvc/model/resultset/complex.zep b/phalcon/mvc/model/resultset/complex.zep index be3a6228e42..d7303e8fe10 100644 --- a/phalcon/mvc/model/resultset/complex.zep +++ b/phalcon/mvc/model/resultset/complex.zep @@ -1,31 +1,31 @@ /* +------------------------------------------------------------------------+ - | Phalcon Framework | + | Phalcon Framework | +------------------------------------------------------------------------+ - | Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) | + | Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) | +------------------------------------------------------------------------+ | This source file is subject to the New BSD License that is bundled | - | with this package in the file docs/LICENSE.txt. | - | | | - | If you did not receive a copy of the license and are unable to | - | obtain it through the world-wide-web, please send an email | - | to license@phalconphp.com so we can send you a copy immediately. | + | with this package in the file docs/LICENSE.txt. | + | | + | If you did not receive a copy of the license and are unable to | + | obtain it through the world-wide-web, please send an email | + | to license@phalconphp.com so we can send you a copy immediately. | +------------------------------------------------------------------------+ - | Authors: Andres Gutierrez | - | Eduar Carvajal | + | Authors: Andres Gutierrez | + | Eduar Carvajal | +------------------------------------------------------------------------+ */ namespace Phalcon\Mvc\Model\Resultset; use Phalcon\Mvc\Model; +use Phalcon\Mvc\Model\Row; +use Phalcon\Db\ResultInterface; use Phalcon\Mvc\Model\Resultset; -use Phalcon\Mvc\Model\ResultsetInterface; use Phalcon\Mvc\Model\Exception; use Phalcon\Cache\BackendInterface; -use Phalcon\Db\ResultInterface; -use Phalcon\Mvc\Model\Row; +use Phalcon\Mvc\Model\ResultsetInterface; /** * Phalcon\Mvc\Model\Resultset\Complex @@ -46,8 +46,8 @@ class Complex extends Resultset implements ResultsetInterface * Phalcon\Mvc\Model\Resultset\Complex constructor * * @param array columnTypes - * @param Phalcon\Db\ResultInterface result - * @param Phalcon\Cache\BackendInterface cache + * @param \Phalcon\Db\ResultInterface result + * @param \Phalcon\Cache\BackendInterface cache */ public function __construct(var columnTypes, result = null, cache = null) { @@ -64,9 +64,9 @@ class Complex extends Resultset implements ResultsetInterface */ public final function current() -> | boolean { - var row, hydrateMode, - dirtyState, alias, activeRow, type, columnTypes, - column, columnValue, value, attribute, source, attributes, + var row, hydrateMode, eager, + dirtyState, alias, activeRow, type, column, columnValue, + value, attribute, source, attributes, columnMap, rowModel, keepSnapshots, sqlAlias, modelName; let activeRow = this->_activeRow; @@ -119,17 +119,15 @@ class Complex extends Resultset implements ResultsetInterface break; } - /** - * Create every record according to the column types - */ - let columnTypes = this->_columnTypes; - /** * Set records as dirty state PERSISTENT by default */ let dirtyState = 0; - for alias, column in columnTypes { + /** + * Create every record according to the column types + */ + for alias, column in this->_columnTypes { if typeof column != "array" { throw new Exception("Column type is corrupt"); @@ -224,18 +222,21 @@ class Complex extends Resultset implements ResultsetInterface } } - /** - * Assign the instance according to the hydration type - */ - switch hydrateMode { + if !fetch eager, column["eager"] { + + /** + * Assign the instance according to the hydration type + */ + switch hydrateMode { - case Resultset::HYDRATE_ARRAYS: - let activeRow[attribute] = value; - break; + case Resultset::HYDRATE_ARRAYS: + let activeRow[attribute] = value; + break; - default: - let activeRow->{attribute} = value; - break; + default: + let activeRow->{attribute} = value; + break; + } } } diff --git a/phalcon/mvc/model/resultset/simple.zep b/phalcon/mvc/model/resultset/simple.zep index d76d9b6ec69..cd4bfe32ee3 100644 --- a/phalcon/mvc/model/resultset/simple.zep +++ b/phalcon/mvc/model/resultset/simple.zep @@ -44,9 +44,9 @@ class Simple extends Resultset * Phalcon\Mvc\Model\Resultset\Simple constructor * * @param array columnMap - * @param Phalcon\Mvc\ModelInterface|Phalcon\Mvc\Model\Row model - * @param Phalcon\Db\Result\Pdo|null result - * @param Phalcon\Cache\BackendInterface cache + * @param \Phalcon\Mvc\ModelInterface|Phalcon\Mvc\Model\Row model + * @param \Phalcon\Db\Result\Pdo|null result + * @param \Phalcon\Cache\BackendInterface cache * @param boolean keepSnapshots */ public function __construct(var columnMap, var model, result, cache = null, keepSnapshots = null) diff --git a/phalcon/mvc/model/resultsetinterface.zep b/phalcon/mvc/model/resultsetinterface.zep index 3d8d2f80def..a7c459ec9b3 100644 --- a/phalcon/mvc/model/resultsetinterface.zep +++ b/phalcon/mvc/model/resultsetinterface.zep @@ -36,14 +36,14 @@ interface ResultsetInterface /** * Get first row in the resultset * - * @return Phalcon\Mvc\ModelInterface + * @return \Phalcon\Mvc\ModelInterface */ public function getFirst(); /** * Get last row in the resultset * - * @return Phalcon\Mvc\ModelInterface + * @return \Phalcon\Mvc\ModelInterface */ public function getLast(); @@ -60,7 +60,7 @@ interface ResultsetInterface /** * Returns the associated cache for the resultset * - * @return Phalcon\Cache\BackendInterface + * @return \Phalcon\Cache\BackendInterface */ public function getCache(); diff --git a/phalcon/mvc/model/row.zep b/phalcon/mvc/model/row.zep index f3d827c7c0c..4a49631997b 100644 --- a/phalcon/mvc/model/row.zep +++ b/phalcon/mvc/model/row.zep @@ -71,7 +71,7 @@ class Row implements EntityInterface, ResultInterface, \ArrayAccess * Rows cannot be changed. It has only been implemented to meet the definition of the ArrayAccess interface * * @param string|int index - * @param Phalcon\Mvc\ModelInterface value + * @param \Phalcon\Mvc\ModelInterface value */ public function offsetSet(var index, var value) { diff --git a/phalcon/mvc/model/transaction.zep b/phalcon/mvc/model/transaction.zep index 0230f9c0159..1fb652e821b 100644 --- a/phalcon/mvc/model/transaction.zep +++ b/phalcon/mvc/model/transaction.zep @@ -82,7 +82,7 @@ class Transaction implements TransactionInterface /** * Phalcon\Mvc\Model\Transaction constructor * - * @param Phalcon\DiInterface $ependencyInjector + * @param \Phalcon\DiInterface $ependencyInjector * @param boolean autoBegin * @param string service */ diff --git a/phalcon/mvc/model/validatorinterface.zep b/phalcon/mvc/model/validatorinterface.zep index 9efd54a8002..30a13109b05 100644 --- a/phalcon/mvc/model/validatorinterface.zep +++ b/phalcon/mvc/model/validatorinterface.zep @@ -39,7 +39,7 @@ interface ValidatorInterface /** * Executes the validator * - * @param Phalcon\Mvc\ModelInterface record + * @param \Phalcon\Mvc\ModelInterface record * @return boolean */ public function validate( record) -> boolean; diff --git a/phalcon/mvc/modelinterface.zep b/phalcon/mvc/modelinterface.zep index 0ddb54eb90a..c1a337153e7 100644 --- a/phalcon/mvc/modelinterface.zep +++ b/phalcon/mvc/modelinterface.zep @@ -101,32 +101,32 @@ interface ModelInterface /** * Assigns values to a model from an array * - * @param Phalcon\Mvc\Model object + * @param \Phalcon\Mvc\Model object * @param array data * @param array columnMap - * @return Phalcon\Mvc\Model + * @return \Phalcon\Mvc\Model */ public function assign(array! data, var dataColumnMap = null, var whiteList = null); /** * Assigns values to a model from an array returning a new model * - * @param Phalcon\Mvc\Model base + * @param \Phalcon\Mvc\Model base * @param array data * @param array columnMap * @param int dirtyState * @param boolean keepSnapshots - * @return Phalcon\Mvc\Model result + * @return \Phalcon\Mvc\Model result */ public static function cloneResultMap(base, array! data, var columnMap, dirtyState = 0, keepSnapshots = null); /** * Assigns values to a model from an array returning a new model * - * @param Phalcon\Mvc\ModelInterface base + * @param \Phalcon\Mvc\ModelInterface base * @param array data * @param int dirtyState - * @return Phalcon\Mvc\ModelInterface + * @return \Phalcon\Mvc\ModelInterface */ public static function cloneResult( base, array! data, dirtyState = 0); @@ -151,15 +151,15 @@ interface ModelInterface * Allows to query the first record that match the specified conditions * * @param array parameters - * @return Phalcon\Mvc\ModelInterface + * @return \Phalcon\Mvc\ModelInterface */ public static function findFirst(parameters = null); /** * Create a criteria for a especific model * - * @param Phalcon\DiInterface dependencyInjector - * @return Phalcon\Mvc\Model\CriteriaInterface + * @param \Phalcon\DiInterface dependencyInjector + * @return \Phalcon\Mvc\Model\CriteriaInterface */ public static function query( dependencyInjector = null); @@ -233,9 +233,9 @@ interface ModelInterface public function validationHasFailed(); /** - * Returns all the validation messages + * Returns array of validation messages * - * @return Phalcon\Mvc\Model\MessageInterface[] + * @return \Phalcon\Mvc\Model\MessageInterface[] */ public function getMessages(); @@ -291,14 +291,14 @@ interface ModelInterface /** * Skips the current operation forcing a success state */ - public function skipOperation(boolean skip); + public function skipOperation(boolean skip); /** * Returns related records based on defined relations * * @param string alias * @param array arguments - * @return Phalcon\Mvc\Model\ResultsetInterface + * @return \Phalcon\Mvc\Model\ResultsetInterface */ public function getRelated(alias, arguments = null); diff --git a/phalcon/mvc/router/annotations.zep b/phalcon/mvc/router/annotations.zep index 43eab374859..c25575e783a 100644 --- a/phalcon/mvc/router/annotations.zep +++ b/phalcon/mvc/router/annotations.zep @@ -230,13 +230,7 @@ class Annotations extends Router } /** - * Checks for annotations in the public methods of the controller - * - * @param string module - * @param string namespaceName - * @param string controller - * @param string action - * @param Phalcon\Annotations\Annotation annotation + * Checks for annotations in the public methods of the controller */ public function processActionAnnotation(string! module, string! namespaceName, string! controller, string! action, annotation) @@ -245,9 +239,9 @@ class Annotations extends Router route, methods, converts, param, convert, conversorParam, routeName, beforeMatch; - let isRoute = false, methods = null; - - let name = annotation->getName(); + let isRoute = false, + methods = null, + name = annotation->getName(); /** * Find if the route is for adding routes diff --git a/phalcon/mvc/router/group.zep b/phalcon/mvc/router/group.zep index c398ec79b70..db32b4bf091 100644 --- a/phalcon/mvc/router/group.zep +++ b/phalcon/mvc/router/group.zep @@ -179,7 +179,7 @@ class Group implements GroupInterface * * @param string pattern * @param string/array paths - * @return Phalcon\Mvc\Router\Route + * @return \Phalcon\Mvc\Router\Route */ public function addGet(string! pattern, var paths = null) -> { @@ -191,7 +191,7 @@ class Group implements GroupInterface * * @param string pattern * @param string/array paths - * @return Phalcon\Mvc\Router\Route + * @return \Phalcon\Mvc\Router\Route */ public function addPost(string! pattern, var paths = null) -> { @@ -203,7 +203,7 @@ class Group implements GroupInterface * * @param string pattern * @param string/array paths - * @return Phalcon\Mvc\Router\Route + * @return \Phalcon\Mvc\Router\Route */ public function addPut(string! pattern, var paths = null) -> { @@ -215,7 +215,7 @@ class Group implements GroupInterface * * @param string pattern * @param string/array paths - * @return Phalcon\Mvc\Router\Route + * @return \Phalcon\Mvc\Router\Route */ public function addPatch(string! pattern, var paths = null) -> { @@ -227,7 +227,7 @@ class Group implements GroupInterface * * @param string pattern * @param string/array paths - * @return Phalcon\Mvc\Router\Route + * @return \Phalcon\Mvc\Router\Route */ public function addDelete(string! pattern, var paths = null) -> { @@ -239,7 +239,7 @@ class Group implements GroupInterface * * @param string pattern * @param string/array paths - * @return Phalcon\Mvc\Router\Route + * @return \Phalcon\Mvc\Router\Route */ public function addOptions(string! pattern, var paths = null) -> { @@ -251,7 +251,7 @@ class Group implements GroupInterface * * @param string pattern * @param string/array paths - * @return Phalcon\Mvc\Router\Route + * @return \Phalcon\Mvc\Router\Route */ public function addHead(string! pattern, var paths = null) -> { diff --git a/phalcon/mvc/router/groupinterface.zep b/phalcon/mvc/router/groupinterface.zep index a65a196465a..f363c2bb1b1 100644 --- a/phalcon/mvc/router/groupinterface.zep +++ b/phalcon/mvc/router/groupinterface.zep @@ -98,7 +98,7 @@ interface GroupInterface * Set common paths for all the routes in the group * * @param array paths - * @return Phalcon\Mvc\Router\Group + * @return \Phalcon\Mvc\Router\Group */ public function setPaths(var paths) -> ; diff --git a/phalcon/mvc/url.zep b/phalcon/mvc/url.zep index 5c1ecf64c8e..9c81a343213 100644 --- a/phalcon/mvc/url.zep +++ b/phalcon/mvc/url.zep @@ -234,7 +234,11 @@ class Url implements UrlInterface, InjectionAwareInterface if baseUri == "/" && strlen(strUri) > 2 && strUri[0] == '/' && strUri[1] != '/' { let uri = baseUri . substr(strUri, 1); } else { - let uri = baseUri . strUri; + if baseUri == "/" && strlen(strUri) == 1 && strUri[0] == '/' { + let uri = baseUri; + } else { + let uri = baseUri . strUri; + } } } diff --git a/phalcon/mvc/view.zep b/phalcon/mvc/view.zep index 4fc4577db40..63154e0374f 100644 --- a/phalcon/mvc/view.zep +++ b/phalcon/mvc/view.zep @@ -261,7 +261,7 @@ class View extends Injectable implements ViewInterface * * * @param int|array level - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ public function disableLevel(var level) -> { @@ -320,7 +320,7 @@ class View extends Injectable implements ViewInterface * Sets a template before the controller layout * * @param string|array templateBefore - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ public function setTemplateBefore(var templateBefore) -> { @@ -345,7 +345,7 @@ class View extends Injectable implements ViewInterface * Sets a "template after" controller layout * * @param string|array templateAfter - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ public function setTemplateAfter(var templateAfter) -> { @@ -375,7 +375,7 @@ class View extends Injectable implements ViewInterface * * @param string key * @param mixed value - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ public function setParamToView(string! key, value) -> { @@ -392,7 +392,7 @@ class View extends Injectable implements ViewInterface * * @param array params * @param boolean merge - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ public function setVars(array! params, boolean merge = true) -> { @@ -421,7 +421,7 @@ class View extends Injectable implements ViewInterface * * @param string key * @param mixed value - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ public function setVar(string! key, value) -> { @@ -567,7 +567,7 @@ class View extends Injectable implements ViewInterface * @param string viewPath * @param boolean silence * @param boolean mustClean - * @param Phalcon\Cache\BackendInterface $cache + * @param \Phalcon\Cache\BackendInterface $cache */ protected function _engineRender(engines, string viewPath, boolean silence, boolean mustClean, cache = null) { @@ -971,7 +971,7 @@ class View extends Injectable implements ViewInterface * * * @param string|array renderView - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ public function pick(var renderView) -> { @@ -1222,7 +1222,7 @@ class View extends Injectable implements ViewInterface * * * @param boolean|array options - * @return Phalcon\Mvc\View + * @return \Phalcon\Mvc\View */ public function cache(var options = true) -> { diff --git a/phalcon/mvc/view/engine/volt/compiler.zep b/phalcon/mvc/view/engine/volt/compiler.zep index 71abf8a1c79..00a6e9fd077 100644 --- a/phalcon/mvc/view/engine/volt/compiler.zep +++ b/phalcon/mvc/view/engine/volt/compiler.zep @@ -22,7 +22,7 @@ namespace Phalcon\Mvc\View\Engine\Volt; use Phalcon\DiInterface; use Phalcon\Mvc\ViewBaseInterface; use Phalcon\Di\InjectionAwareInterface; -use Phalcon\Mvc\View\Exception; +use Phalcon\Mvc\View\Engine\Volt\Exception; /** * Phalcon\Mvc\View\Engine\Volt\Compiler @@ -428,13 +428,6 @@ class Compiler implements InjectionAwareInterface } } - /** - * Check if the function name is a macro - */ - if isset this->_macros[name] { - return "$this->callMacro('" . name . "', array(" . arguments . "))"; - } - /** * This function includes the previous rendering stage */ @@ -568,9 +561,9 @@ class Compiler implements InjectionAwareInterface } /** - * The function doesn't exist throw an exception + * By default it tries to call a macro */ - throw new Exception("Undefined function '" . name . "' in " . expr["file"] . " on line " . expr["line"]); + return "$this->callMacro('" . name . "', array(" . arguments . "))"; } return this->expression(nameExpr) . "(" . arguments . ")"; @@ -1461,7 +1454,7 @@ class Compiler implements InjectionAwareInterface } /** - * Update the forelse var if it"s iterated at least one time + * Update the forelse var if it's iterated at least one time */ if typeof forElse == "string" { let compilation .= ""; @@ -1832,7 +1825,7 @@ class Compiler implements InjectionAwareInterface /** * Clone the original compiler * Perform a subcompilation of the included file - * If the compilation doesn"t return anything we include the compiled path + * If the compilation doesn't return anything we include the compiled path */ let subCompiler = clone this; let compilation = subCompiler->compile(finalPath, false); @@ -2023,7 +2016,7 @@ class Compiler implements InjectionAwareInterface let type = statement["type"]; /** - * Compile the statement according to the statement"s type + * Compile the statement according to the statement's type */ switch type { @@ -2111,7 +2104,7 @@ class Compiler implements InjectionAwareInterface let tempCompilation = subCompiler->compile(finalPath, extended); /** - * If the compilation doesn"t return anything we include the compiled path + * If the compilation doesn't return anything we include the compiled path */ if typeof tempCompilation == "null" { let tempCompilation = file_get_contents(subCompiler->getCompiledTemplatePath()); diff --git a/phalcon/mvc/view/engine/volt/exception.zep b/phalcon/mvc/view/engine/volt/exception.zep new file mode 100644 index 00000000000..73b476169d8 --- /dev/null +++ b/phalcon/mvc/view/engine/volt/exception.zep @@ -0,0 +1,32 @@ + +/* + +------------------------------------------------------------------------+ + | Phalcon Framework | + +------------------------------------------------------------------------+ + | Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) | + +------------------------------------------------------------------------+ + | This source file is subject to the New BSD License that is bundled | + | with this package in the file docs/LICENSE.txt. | + | | + | If you did not receive a copy of the license and are unable to | + | obtain it through the world-wide-web, please send an email | + | to license@phalconphp.com so we can send you a copy immediately. | + +------------------------------------------------------------------------+ + | Authors: Andres Gutierrez | + | Eduar Carvajal | + +------------------------------------------------------------------------+ + */ + +namespace Phalcon\Mvc\View\Engine\Volt; + +use Phalcon\Mvc\View\Exception as BaseException; + +/** + * Phalcon\Mvc\View\Exception + * + * Class for exceptions thrown by Phalcon\Mvc\View + */ +class Exception extends BaseException +{ + +} diff --git a/phalcon/mvc/view/exception.zep b/phalcon/mvc/view/exception.zep index 9bc051c9a5c..59ebad3e71c 100644 --- a/phalcon/mvc/view/exception.zep +++ b/phalcon/mvc/view/exception.zep @@ -27,4 +27,4 @@ namespace Phalcon\Mvc\View; class Exception extends \Phalcon\Exception { -} \ No newline at end of file +} diff --git a/phalcon/mvc/view/simple.zep b/phalcon/mvc/view/simple.zep index 30724b96571..725757f58ba 100644 --- a/phalcon/mvc/view/simple.zep +++ b/phalcon/mvc/view/simple.zep @@ -448,7 +448,7 @@ class Simple extends Injectable implements ViewBaseInterface * Sets the cache options * * @param array options - * @return Phalcon\Mvc\View\Simple + * @return \Phalcon\Mvc\View\Simple */ public function setCacheOptions(options) -> { diff --git a/phalcon/mvc/viewinterface.zep b/phalcon/mvc/viewinterface.zep index c5173675bb6..33a63e3fa6d 100644 --- a/phalcon/mvc/viewinterface.zep +++ b/phalcon/mvc/viewinterface.zep @@ -142,7 +142,7 @@ interface ViewInterface extends ViewBaseInterface /** * Choose a view different to render than last-controller/last-action */ - public function pick(string! renderView); + public function pick(string! renderView); /** * Finishes the render process by stopping the output buffering diff --git a/phalcon/paginator/adapter/querybuilder.zep b/phalcon/paginator/adapter/querybuilder.zep index 8dd1a63f433..d63d32b204c 100644 --- a/phalcon/paginator/adapter/querybuilder.zep +++ b/phalcon/paginator/adapter/querybuilder.zep @@ -179,7 +179,7 @@ class QueryBuilder extends Adapter implements AdapterInterface row = result->getFirst(), rowcount = intval(row->rowcount), totalPages = intval(ceil(rowcount / limit)); - + if numberPage < totalPages { let next = numberPage + 1; } else { diff --git a/phalcon/queue/beanstalk.zep b/phalcon/queue/beanstalk.zep index 0d90bdfca5f..442afa65099 100644 --- a/phalcon/queue/beanstalk.zep +++ b/phalcon/queue/beanstalk.zep @@ -231,6 +231,23 @@ class Beanstalk return response[2]; } + /** + * Get list of a tubes. + */ + public function listTubes() -> boolean|array + { + var response; + + this->write("list-tubes"); + + let response = this->readYaml(); + if response[0] != "OK" { + return false; + } + + return response[2]; + } + /** * Inspect the next ready job. */ diff --git a/phalcon/security.zep b/phalcon/security.zep index ac56a8c87ae..4b42e3bcce8 100644 --- a/phalcon/security.zep +++ b/phalcon/security.zep @@ -201,7 +201,7 @@ class Security implements InjectionAwareInterface let saltBytes = this->getSaltBytes(8); if typeof saltBytes != "string" { throw new Exception("Unable to get random bytes for the salt"); - } + } return crypt(password, "$" . variant . "$" . saltBytes); case self::CRYPT_DEFAULT: diff --git a/phalcon/security/random.zep b/phalcon/security/random.zep new file mode 100644 index 00000000000..4f321aea6c8 --- /dev/null +++ b/phalcon/security/random.zep @@ -0,0 +1,271 @@ +/* + +------------------------------------------------------------------------+ + | Phalcon Framework | + +------------------------------------------------------------------------+ + | Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) | + +------------------------------------------------------------------------+ + | This source file is subject to the New BSD License that is bundled | + | with this package in the file docs/LICENSE.txt. | + | | + | If you did not receive a copy of the license and are unable to | + | obtain it through the world-wide-web, please send an email | + | to license@phalconphp.com so we can send you a copy immediately. | + +------------------------------------------------------------------------+ + | Authors: Serghei Iakovlev | + +------------------------------------------------------------------------+ + */ + +namespace Phalcon\Security; + +/** + * Phalcon\Security\Random + * + * Secure random number generator class. + * + * Provides secure random number generator which is suitable for generating + * session key in HTTP cookies, etc. + * + * It supports following secure random number generators: + * + * - libsodium + * - openssl + * - /dev/urandom + * + * + * $random = new \Phalcon\Security\Random(); + * + * // Random binary string + * $bytes = $random->bytes(); + * + * // Random hex string + * echo $random->hex(10); // a29f470508d5ccb8e289 + * echo $random->hex(10); // 533c2f08d5eee750e64a + * echo $random->hex(11); // f362ef96cb9ffef150c9cd + * echo $random->hex(12); // 95469d667475125208be45c4 + * echo $random->hex(13); // 05475e8af4a34f8f743ab48761 + * + * // Random base64 string + * echo $random->base64(12); // XfIN81jGGuKkcE1E + * echo $random->base64(12); // 3rcq39QzGK9fUqh8 + * echo $random->base64(); // DRcfbngL/iOo9hGGvy1TcQ== + * echo $random->base64(16); // SvdhPcIHDZFad838Bb0Swg== + * + * // Random URL-safe base64 string + * echo $random->base64Safe(); // PcV6jGbJ6vfVw7hfKIFDGA + * echo $random->base64Safe(); // GD8JojhzSTrqX7Q8J6uug + * echo $random->base64Safe(8); // mGyy0evy3ok + * echo $random->base64Safe(null, true); // DRrAgOFkS4rvRiVHFefcQ== + * + * // Random UUID + * echo $random->uuid(); // db082997-2572-4e2c-a046-5eefe97b1235 + * echo $random->uuid(); // da2aa0e2-b4d0-4e3c-99f5-f5ef62c57fe2 + * echo $random->uuid(); // 75e6b628-c562-4117-bb76-61c4153455a9 + * echo $random->uuid(); // dc446df1-0848-4d05-b501-4af3c220c13d + * + * // Random number between 0 and $len + * echo $random->number(256); // 84 + * echo $random->number(256); // 79 + * echo $random->number(100); // 29 + * echo $random->number(300); // 40 + * + * + * This class partially borrows SecureRandom library from Ruby + * + * @link http://ruby-doc.org/stdlib-2.2.2/libdoc/securerandom/rdoc/SecureRandom.html + */ +class Random +{ + /** + * Generates a random binary string + * + * If $len is not specified, 16 is assumed. It may be larger in future. + * The result may contain any byte: "x00" - "xFF". + * + * + * $random = new \Phalcon\Security\Random(); + * + * $bytes = $random->bytes(); + * + * + * @throws Exception If secure random number generator is not available or unexpected partial read + */ + public function bytes(int len = 16) -> string + { + var handle, ret; + + if len <= 0 { + let len = 16; + } + + if function_exists("\\Sodium\\randombytes_buf") { + return \\Sodium\\randombytes_buf(len); + } + + if function_exists("openssl_random_pseudo_bytes") { + return openssl_random_pseudo_bytes(len); + } + + if file_exists("/dev/urandom") { + let handle = fopen("/dev/urandom", "rb"); + + if handle !== false { + stream_set_read_buffer(handle, 0); + let ret = fread(handle, len); + fclose(handle); + + if strlen(ret) != len { + throw new Exception("Unexpected partial read from random device"); + } + + return ret; + } + } + + throw new Exception("No random device"); + } + + /** + * Generates a random hex string + * + * If $len is not specified, 16 is assumed. It may be larger in future. + * The length of the result string is usually greater of $len. + * + * + * $random = new \Phalcon\Security\Random(); + * + * echo $random->hex(10); // a29f470508d5ccb8e289 + * + * + * @throws Exception If secure random number generator is not available or unexpected partial read + */ + public function hex(int len = null) -> string + { + return array_shift(unpack("H*", this->bytes(len))); + } + + /** + * Generates a random base64 string + * + * If $len is not specified, 16 is assumed. It may be larger in future. + * The length of the result string is usually greater of $len. + * + * + * $random = new \Phalcon\Security\Random(); + * + * echo $random->base64(12); // 3rcq39QzGK9fUqh8 + * + * + * @throws Exception If secure random number generator is not available or unexpected partial read + */ + public function base64(int len = null) -> string + { + return base64_encode(this->bytes(len)); + } + + /** + * Generates a random URL-safe base64 string + * + * If $len is not specified, 16 is assumed. It may be larger in future. + * The length of the result string is usually greater of $len. + * + * By default, padding is not generated because "=" may be used as a URL delimiter. + * The result may contain A-Z, a-z, 0-9, "-" and "_". "=" is also used if $padding is true. + * See RFC 3548 for the definition of URL-safe base64. + * + * + * $random = new \Phalcon\Security\Random(); + * + * echo $random->base64Safe(); // GD8JojhzSTrqX7Q8J6uug + * + * + * @link https://www.ietf.org/rfc/rfc3548.txt + * @throws Exception If secure random number generator is not available or unexpected partial read + */ + public function base64Safe(int len = null, boolean padding = false) -> string + { + var s; + + let s = preg_replace("#[^a-z0-9_=-]+#i", "", this->base64(len)); + + if !padding { + return trim(s, "="); + } + + return s; + } + + /** + * Generates a v4 random UUID (Universally Unique IDentifier) + * + * The version 4 UUID is purely random (except the version). It doesn't contain meaningful + * information such as MAC address, time, etc. See RFC 4122 for details of UUID. + * + * This algorithm sets the version number (4 bits) as well as two reserved bits. + * All other bits (the remaining 122 bits) are set using a random or pseudorandom data source. + * Version 4 UUIDs have the form xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx where x is any hexadecimal + * digit and y is one of 8, 9, A, or B (e.g., f47ac10b-58cc-4372-a567-0e02b2c3d479). + * + * + * $random = new \Phalcon\Security\Random(); + * + * echo $random->uuid(); // 1378c906-64bb-4f81-a8d6-4ae1bfcdec22 + * + * + * @link https://www.ietf.org/rfc/rfc4122.txt + * @throws Exception If secure random number generator is not available or unexpected partial read + */ + public function uuid() -> string + { + var ary; + + let ary = array_values(unpack("N1a/n1b/n1c/n1d/n1e/N1f", this->bytes(16))); + let ary[2] = (ary[2] & 0x0fff) | 0x4000; + let ary[3] = (ary[3] & 0x3fff) | 0x8000; + + array_unshift(ary, "%08x-%04x-%04x-%04x-%04x%08x"); + + return call_user_func_array("sprintf", ary); + } + + /** + * Generates a random number between 0 and $len + * + * + * $random = new \Phalcon\Security\Random(); + * + * echo $random->number(16); // 8 + * + * @throws Exception If secure random number generator is not available, unexpected partial read or $len <= 0 + */ + public function number(int len) -> int + { + var hex, bin, mask, rnd, ret, first; + + if len > 0 { + let hex = dechex(len); + + if (strlen(hex) & 1) == 1 { + let hex = "0" . hex; + } + + let bin = pack("H*", hex); + + let mask = ord(substr(bin, 0, 1)); + let mask = mask | (mask >> 1); + let mask = mask | (mask >> 2); + let mask = mask | (mask >> 4); + + do { + let rnd = this->bytes(strlen(bin)); + let first = ord(substr(rnd, 0, 1)); + let rnd = substr_replace(rnd, chr(first & mask), 0, 1); + } while (bin < rnd); + + let ret = unpack("H*", rnd); + + return hexdec(array_shift(ret)); + } + + throw new Exception("Require a positive integer > 0"); + } +} diff --git a/phalcon/session/adapter.zep b/phalcon/session/adapter.zep index 24c5d54841f..bb8c42d5e15 100644 --- a/phalcon/session/adapter.zep +++ b/phalcon/session/adapter.zep @@ -44,7 +44,7 @@ abstract class Adapter * * @param array options */ - public function __construct(options = null) + public function __construct(var options = null) { if typeof options == "array" { this->setOptions(options); @@ -110,25 +110,40 @@ abstract class Adapter return session_name(); } + /** + * {@inheritdoc} + */ + public function regenerateId(bool deleteOldSession = true) -> + { + session_regenerate_id(deleteOldSession); + return this; + } + /** * Gets a session variable from an application context * - * @param string index - * @param mixed defaultValue - * @param boolean remove - * @return mixed + * + * $session->get('auth', 'yes'); + * */ - public function get(string index, defaultValue = null, boolean remove = false) + public function get(string index, var defaultValue = null, boolean remove = false) { - var value, key; + var value, key, uniqueId; + + let uniqueId = this->_uniqueId; + if !empty uniqueId { + let key = uniqueId . "#" . index; + } else { + let key = index; + } - let key = this->_uniqueId . index; if fetch value, _SESSION[key] { if remove { unset _SESSION[key]; } return value; } + return defaultValue; } @@ -138,13 +153,18 @@ abstract class Adapter * * $session->set('auth', 'yes'); * - * - * @param string index - * @param string value */ - public function set(string index, value) + public function set(string index, var value) { - let _SESSION[this->_uniqueId . index] = value; + var uniqueId; + + let uniqueId = this->_uniqueId; + if !empty uniqueId { + let _SESSION[uniqueId . "#" . index] = value; + return; + } + + let _SESSION[index] = value; } /** @@ -156,7 +176,14 @@ abstract class Adapter */ public function has(string index) -> boolean { - return isset _SESSION[this->_uniqueId . index]; + var uniqueId; + + let uniqueId = this->_uniqueId; + if !empty uniqueId { + return isset _SESSION[uniqueId . "#" . index]; + } + + return isset _SESSION[index]; } /** @@ -168,7 +195,15 @@ abstract class Adapter */ public function remove(string index) { - unset _SESSION[this->_uniqueId . index]; + var uniqueId; + + let uniqueId = this->_uniqueId; + if !empty uniqueId { + unset _SESSION[uniqueId . "#" . index]; + return; + } + + unset _SESSION[index]; } /** @@ -212,10 +247,26 @@ abstract class Adapter * * * var_dump($session->destroy()); + * var_dump($session->destroy(true)); * */ - public function destroy() -> boolean + public function destroy(boolean removeData = false) -> boolean { + var uniqueId, key; + + if removeData { + let uniqueId = this->_uniqueId; + if !empty uniqueId { + for key, _ in _SESSION { + if starts_with(key, uniqueId . "#") { + unset _SESSION[key]; + } + } + } else { + let _SESSION = []; + } + } + let this->_started = false; return session_destroy(); } @@ -253,9 +304,6 @@ abstract class Adapter /** * Alias: Gets a session variable from an application context - * - * @param string index - * @return mixed */ public function __get(string index) { @@ -264,11 +312,8 @@ abstract class Adapter /** * Alias: Sets a session variable in an application context - * - * @param string index - * @param string value */ - public function __set(string index, value) + public function __set(string index, var value) { return this->set(index, value); } diff --git a/phalcon/session/adapterinterface.zep b/phalcon/session/adapterinterface.zep index c799d7e89b1..ef389dcb533 100644 --- a/phalcon/session/adapterinterface.zep +++ b/phalcon/session/adapterinterface.zep @@ -44,20 +44,13 @@ interface AdapterInterface /** * Gets a session variable from an application context - * - * @param string index - * @param mixed defaultValue - * @return mixed */ - public function get(string index, defaultValue = null); + public function get(string index, var defaultValue = null); /** * Sets a session variable in an application context - * - * @param string index - * @param string value */ - public function set(string index, value); + public function set(string index, var value); /** * Check whether a session variable is set in an application context @@ -82,6 +75,10 @@ interface AdapterInterface /** * Destroys the active session */ - public function destroy() -> boolean; + public function destroy(boolean removeData = false) -> boolean; + /** + * Regenerate session's id + */ + public function regenerateId(bool deleteOldSession = true) -> ; } diff --git a/phalcon/session/bag.zep b/phalcon/session/bag.zep index b5c4e127850..73f6778f31b 100644 --- a/phalcon/session/bag.zep +++ b/phalcon/session/bag.zep @@ -32,7 +32,7 @@ use Phalcon\Di\InjectionAwareInterface; * * $user = new \Phalcon\Session\Bag('user'); * $user->name = "Kimbra Johnson"; - * $user->age = 22; + * $user->age = 22; * */ class Bag implements InjectionAwareInterface, BagInterface, \IteratorAggregate, \ArrayAccess, \Countable @@ -98,6 +98,7 @@ class Bag implements InjectionAwareInterface, BagInterface, \IteratorAggregate, if typeof data != "array" { let data = []; } + let this->_data = data; let this->_initialized = true; } @@ -114,6 +115,7 @@ class Bag implements InjectionAwareInterface, BagInterface, \IteratorAggregate, if this->_initialized === false { this->initialize(); } + let this->_data = []; this->_session->remove(this->_name); } @@ -123,15 +125,13 @@ class Bag implements InjectionAwareInterface, BagInterface, \IteratorAggregate, * * $user->set('name', 'Kimbra'); * - * - * @param string property - * @param string value */ - public function set(string! property, value) + public function set(string! property, var value) { if this->_initialized === false { this->initialize(); } + let this->_data[property] = value; this->_session->set(this->_name, this->_data); } @@ -142,11 +142,8 @@ class Bag implements InjectionAwareInterface, BagInterface, \IteratorAggregate, * * $user->name = "Kimbra"; * - * - * @param string property - * @param string value */ - public function __set(string! property, value) + public function __set(string! property, var value) { this->set(property, value); } @@ -157,12 +154,8 @@ class Bag implements InjectionAwareInterface, BagInterface, \IteratorAggregate, * * echo $user->get('name', 'Kimbra'); * - * - * @param string property - * @param string defaultValue - * @return mixed */ - public function get(string! property, defaultValue = null) + public function get(string! property, var defaultValue = null) { var value; @@ -189,9 +182,6 @@ class Bag implements InjectionAwareInterface, BagInterface, \IteratorAggregate, * * echo $user->name; * - * - * @param string property - * @return mixed */ public function __get(string! property) { @@ -235,11 +225,16 @@ class Bag implements InjectionAwareInterface, BagInterface, \IteratorAggregate, */ public function remove(string! property) -> boolean { - if isset this->_data[property] { - unset this->_data[property]; - this->_session->set(this->_name, this->_data); + var data; + + let data = this->_data; + if isset data[property] { + unset data[property]; + this->_session->set(this->_name, data); + let this->_data = data; return true; } + return false; } @@ -310,7 +305,7 @@ class Bag implements InjectionAwareInterface, BagInterface, \IteratorAggregate, } /** - * @param string property + * @param string property */ public final function offsetGet(string! property) { diff --git a/phalcon/tag/select.zep b/phalcon/tag/select.zep index d643f0462c3..52d449e53f9 100644 --- a/phalcon/tag/select.zep +++ b/phalcon/tag/select.zep @@ -147,7 +147,7 @@ abstract class Select /** * Generate the OPTION tags based on a resultset * - * @param Phalcon\Mvc\Model\Resultset resultset + * @param \Phalcon\Mvc\Model\Resultset resultset * @param array using * @param mixed value * @param string closeOption @@ -189,7 +189,7 @@ abstract class Select } /** - * If the value is equal to the option"s value we mark it as selected + * If the value is equal to the option's value we mark it as selected */ if typeof value == "array" { if in_array(optionValue, value) { diff --git a/phalcon/text.zep b/phalcon/text.zep index f764d082e8e..3496bcadffa 100644 --- a/phalcon/text.zep +++ b/phalcon/text.zep @@ -53,7 +53,7 @@ abstract class Text * Uncamelize strings which are camelized * * - * echo Phalcon\Text::camelize('CocoBongo'); //coco_bongo + * echo Phalcon\Text::uncamelize('CocoBongo'); //coco_bongo * */ public static function uncamelize(string! str) -> string @@ -255,15 +255,15 @@ abstract class Text */ public static function dynamic(string! text, string! leftDelimiter = "{", string! rightDelimiter = "}", string! separator = "|") -> string { - var ld_s, rd_s, result, pattern; + var ldS, rdS, result, pattern; if substr_count(text, leftDelimiter) !== substr_count(text, rightDelimiter) { throw new \RuntimeException("Syntax error in string \"" . text . "\""); } - let ld_s = preg_quote(leftDelimiter); - let rd_s = preg_quote(rightDelimiter); - let pattern = "/" . ld_s . "([^" . ld_s . rd_s . "]+)" . rd_s . "/"; + let ldS = preg_quote(leftDelimiter); + let rdS = preg_quote(rightDelimiter); + let pattern = "/" . ldS . "([^" . ldS . rdS . "]+)" . rdS . "/"; let result = text; while memstr(result, leftDelimiter) { diff --git a/phalcon/validation.zep b/phalcon/validation.zep index 685408e372b..7122cd89d55 100644 --- a/phalcon/validation.zep +++ b/phalcon/validation.zep @@ -72,7 +72,7 @@ class Validation extends Injectable * * @param array|object data * @param object entity - * @return Phalcon\Validation\Message\Group + * @return \Phalcon\Validation\Message\Group */ public function validate(var data = null, var entity = null) -> { @@ -180,7 +180,7 @@ class Validation extends Injectable * * @param string field * @param array|string filters - * @return Phalcon\Validation + * @return \Phalcon\Validation */ public function setFilters(string field, filters) -> { @@ -327,7 +327,7 @@ class Validation extends Injectable * * @param object entity * @param array|object data - * @return Phalcon\Validation + * @return \Phalcon\Validation */ public function bind(entity, data) -> { diff --git a/phalcon/validation/message/group.zep b/phalcon/validation/message/group.zep index d1d0c82311c..75ed253ad17 100644 --- a/phalcon/validation/message/group.zep +++ b/phalcon/validation/message/group.zep @@ -56,7 +56,7 @@ class Group implements \Countable, \ArrayAccess, \Iterator * * * @param int index - * @return Phalcon\Validation\Message + * @return \Phalcon\Validation\Message */ public function offsetGet(int! index) -> | boolean { @@ -75,7 +75,7 @@ class Group implements \Countable, \ArrayAccess, \Iterator * * * @param int index - * @param Phalcon\Validation\Message message + * @param \Phalcon\Validation\Message message */ public function offsetSet(int! index, var message) { @@ -136,7 +136,7 @@ class Group implements \Countable, \ArrayAccess, \Iterator * $messages->appendMessages($messagesArray); * * - * @param Phalcon\Validation\MessageInterface[] messages + * @param \Phalcon\Validation\MessageInterface[] messages */ public function appendMessages(messages) { @@ -221,7 +221,7 @@ class Group implements \Countable, \ArrayAccess, \Iterator /** * Returns the current message in the iterator * - * @return Phalcon\Validation\Message + * @return \Phalcon\Validation\Message */ public function current() -> | boolean { @@ -260,7 +260,7 @@ class Group implements \Countable, \ArrayAccess, \Iterator * Magic __set_state helps to re-build messages variable when exporting * * @param array group - * @return Phalcon\Validation\Message\Group + * @return \Phalcon\Validation\Message\Group */ public static function __set_state(group) -> { diff --git a/phalcon/validation/validator/stringlength.zep b/phalcon/validation/validator/stringlength.zep index acbe2b8b47e..cb6aca43fd8 100644 --- a/phalcon/validation/validator/stringlength.zep +++ b/phalcon/validation/validator/stringlength.zep @@ -40,7 +40,7 @@ use Phalcon\Validation\Message; * 'messageMaximum' => 'We don\'t like really long names', * 'messageMinimum' => 'We want more than just their initials' *))); - * + * */ class StringLength extends Validator { diff --git a/phalcon/version.zep b/phalcon/version.zep index d873f4ca093..238f368108b 100644 --- a/phalcon/version.zep +++ b/phalcon/version.zep @@ -80,7 +80,7 @@ class Version */ protected static function _getVersion() -> array { - return [2, 0, 6, 4, 0]; + return [2, 0, 7, 4, 0]; } /** diff --git a/unit-tests/FormsTest.php b/unit-tests/FormsTest.php index ec43c5b512c..8ae28907779 100644 --- a/unit-tests/FormsTest.php +++ b/unit-tests/FormsTest.php @@ -517,4 +517,20 @@ public function testIssue2045() $this->assertEquals('', $element->render()); } + + public function testCorrectlyAddOptionToSelectElementIfParameterIsAnArray() + { + $element = new Select('test-select'); + $element->addOption(array('key' => 'value')); + + $this->assertEquals('', preg_replace('/[[:cntrl:]]/', '', $element->render())); + } + + public function testCorrectlyAddOptionToSelectElementIfParameterIsAString() + { + $element = new Select('test-select'); + $element->addOption('value'); + + $this->assertEquals('', preg_replace('/[[:cntrl:]]/', '', $element->render())); + } } diff --git a/unit-tests/ModelsQueryBuilderTest.php b/unit-tests/ModelsQueryBuilderTest.php index d8fe00ea05e..41fc2d87e3d 100644 --- a/unit-tests/ModelsQueryBuilderTest.php +++ b/unit-tests/ModelsQueryBuilderTest.php @@ -254,14 +254,14 @@ public function testAction() ->from('Robots') ->limit(10) ->getPhql(); - $this->assertEquals($phql, 'SELECT [Robots].* FROM [Robots] LIMIT :AP0:'); + $this->assertEquals($phql, 'SELECT [Robots].* FROM [Robots] LIMIT :APL0:'); $builder = new Builder(); $phql = $builder->setDi($di) ->from('Robots') ->limit(10, 5) ->getPhql(); - $this->assertEquals($phql, 'SELECT [Robots].* FROM [Robots] LIMIT :AP0: OFFSET :AP1:'); + $this->assertEquals($phql, 'SELECT [Robots].* FROM [Robots] LIMIT :APL0: OFFSET :APL1:'); } public function testIssue701() @@ -386,7 +386,7 @@ public function testConstructor() $expectedPhql = "SELECT id, name, status FROM [Robots] " . "WHERE a > 5 GROUP BY [type], [source] " . "HAVING b < 5 ORDER BY [name], [created] " - . "LIMIT :AP0: OFFSET :AP1:"; + . "LIMIT :APL0: OFFSET :APL1:"; $this->assertEquals($expectedPhql, $builder->getPhql()); $this->assertEquals($di, $builder->getDI()); @@ -426,7 +426,7 @@ public function testConstructorLimit() $builderLimitWithOffset = new Builder($params); $expectedPhql = "SELECT [Robots].* FROM [Robots] " - . "LIMIT :AP0: OFFSET :AP1:"; + . "LIMIT :APL0: OFFSET :APL1:"; $this->assertEquals($expectedPhql, $builderLimitAndOffset->getPhql()); $this->assertEquals($expectedPhql, $builderLimitWithOffset->getPhql()); diff --git a/unit-tests/ViewEnginesVoltTest.php b/unit-tests/ViewEnginesVoltTest.php index 42e7c66949e..4238deccbfa 100644 --- a/unit-tests/ViewEnginesVoltTest.php +++ b/unit-tests/ViewEnginesVoltTest.php @@ -698,22 +698,6 @@ public function testVoltRuntimeError() catch (Phalcon\Mvc\View\Exception $e){ $this->assertEquals($e->getMessage(), 'Unknown filter type in eval code on line 1'); } - - try { - $volt->compileString('{{ unknown() }}'); - $this->assertTrue(false); - } - catch (Phalcon\Mvc\View\Exception $e){ - $this->assertEquals($e->getMessage(), "Undefined function 'unknown' in eval code on line 1"); - } - - try { - $volt->compileString('{{ dump(unknown()) }}'); - $this->assertTrue(false); - } - catch (Phalcon\Mvc\View\Exception $e){ - $this->assertEquals($e->getMessage(), "Undefined function 'unknown' in eval code on line 1"); - } } public function testVoltExtendsError()
Memory
Usage", _13, "