Lines Matching refs:type_mask

722 static bool zend_verify_weak_scalar_type_hint(uint32_t type_mask, zval *arg)  in zend_verify_weak_scalar_type_hint()  argument
730 if (type_mask & MAY_BE_LONG) { in zend_verify_weak_scalar_type_hint()
733 if ((type_mask & MAY_BE_DOUBLE) && Z_TYPE_P(arg) == IS_STRING) { in zend_verify_weak_scalar_type_hint()
753 if ((type_mask & MAY_BE_DOUBLE) && zend_parse_arg_double_weak(arg, &dval, 0)) { in zend_verify_weak_scalar_type_hint()
758 if ((type_mask & MAY_BE_STRING) && zend_parse_arg_str_weak(arg, &str, 0)) { in zend_verify_weak_scalar_type_hint()
762 if ((type_mask & MAY_BE_BOOL) == MAY_BE_BOOL && zend_parse_arg_bool_weak(arg, &bval, 0)) { in zend_verify_weak_scalar_type_hint()
783 static bool zend_verify_weak_scalar_type_hint_no_sideeffect(uint32_t type_mask, const zval *arg) in zend_verify_weak_scalar_type_hint_no_sideeffect() argument
791 if ((type_mask & MAY_BE_LONG) && zend_parse_arg_long_weak(arg, &lval, (uint32_t)-1)) { in zend_verify_weak_scalar_type_hint_no_sideeffect()
794 if ((type_mask & MAY_BE_DOUBLE) && zend_parse_arg_double_weak(arg, &dval, (uint32_t)-1)) { in zend_verify_weak_scalar_type_hint_no_sideeffect()
797 if ((type_mask & MAY_BE_STRING) && can_convert_to_string(arg)) { in zend_verify_weak_scalar_type_hint_no_sideeffect()
800 …if ((type_mask & MAY_BE_BOOL) == MAY_BE_BOOL && zend_parse_arg_bool_weak(arg, &bval, (uint32_t)-1)… in zend_verify_weak_scalar_type_hint_no_sideeffect()
807 ZEND_API bool zend_verify_scalar_type_hint(uint32_t type_mask, zval *arg, bool strict, bool is_inte… in zend_verify_scalar_type_hint() argument
811 if (!(type_mask & MAY_BE_DOUBLE) || Z_TYPE_P(arg) != IS_LONG) { in zend_verify_scalar_type_hint()
818 && (type_mask & (MAY_BE_TRUE|MAY_BE_FALSE|MAY_BE_LONG|MAY_BE_DOUBLE|MAY_BE_STRING)); in zend_verify_scalar_type_hint()
822 return zend_verify_weak_scalar_type_hint_no_sideeffect(type_mask, arg); in zend_verify_scalar_type_hint()
825 return zend_verify_weak_scalar_type_hint(type_mask, arg); in zend_verify_scalar_type_hint()
1005 uint32_t type_mask = ZEND_TYPE_FULL_MASK(info->type); in i_zend_check_property_type() local
1006 ZEND_ASSERT(!(type_mask & (MAY_BE_CALLABLE|MAY_BE_STATIC|MAY_BE_NEVER|MAY_BE_VOID))); in i_zend_check_property_type()
1007 return zend_verify_scalar_type_hint(type_mask, property, strict, 0); in i_zend_check_property_type()
1128 uint32_t type_mask; in zend_check_type_slow() local
1163 type_mask = ZEND_TYPE_FULL_MASK(*type); in zend_check_type_slow()
1164 if ((type_mask & MAY_BE_CALLABLE) && in zend_check_type_slow()
1168 if ((type_mask & MAY_BE_STATIC) && zend_value_instanceof_static(arg)) { in zend_check_type_slow()
1182 return zend_verify_scalar_type_hint(type_mask, arg, in zend_check_type_slow()
1315 uint32_t type_mask = zend_get_internal_func_info(fn, NULL, NULL); in zend_verify_internal_func_info() local
1316 if (!type_mask) { in zend_verify_internal_func_info()
1322 if (!(type_mask & MAY_BE_RC1)) { in zend_verify_internal_func_info()
1325 if (Z_REFCOUNT_P(retval) > 1 && !(type_mask & MAY_BE_RCN)) { in zend_verify_internal_func_info()
1331 if (!(type_mask & type)) { in zend_verify_internal_func_info()
1343 if (!(type_mask & MAY_BE_ARRAY_KEY_STRING)) { in zend_verify_internal_func_info()
1348 if (!(type_mask & MAY_BE_ARRAY_KEY_LONG)) { in zend_verify_internal_func_info()
1355 if (!(type_mask & array_type)) { in zend_verify_internal_func_info()
1494 uint32_t type_mask = ZEND_TYPE_FULL_MASK(c->type); in zend_check_class_constant_type() local
1495 ZEND_ASSERT(!(type_mask & (MAY_BE_CALLABLE|MAY_BE_NEVER|MAY_BE_VOID))); in zend_check_class_constant_type()
1496 return zend_verify_scalar_type_hint(type_mask, constant, true, false); in zend_check_class_constant_type()
3519 uint32_t type_mask; in i_zend_verify_type_assignable_zval() local
3531 type_mask = ZEND_TYPE_FULL_MASK(type); in i_zend_verify_type_assignable_zval()
3532 ZEND_ASSERT(!(type_mask & (MAY_BE_CALLABLE|MAY_BE_STATIC))); in i_zend_verify_type_assignable_zval()
3536 if ((type_mask & MAY_BE_DOUBLE) && zv_type == IS_LONG) { in i_zend_verify_type_assignable_zval()
3548 if (!(type_mask & (MAY_BE_LONG|MAY_BE_DOUBLE|MAY_BE_STRING)) in i_zend_verify_type_assignable_zval()
3549 && (type_mask & MAY_BE_BOOL) != MAY_BE_BOOL) { in i_zend_verify_type_assignable_zval()