Lines Matching refs:FFI_G

1086 	if (!FFI_G(callbacks)) {  in zend_ffi_create_callback()
1087 FFI_G(callbacks) = emalloc(sizeof(HashTable)); in zend_ffi_create_callback()
1088 zend_hash_init(FFI_G(callbacks), 0, NULL, zend_ffi_callback_hash_dtor, 0); in zend_ffi_create_callback()
1090 zend_hash_next_index_insert_ptr(FFI_G(callbacks), callback_data); in zend_ffi_create_callback()
2948 if (EXPECTED(FFI_G(restriction) > ZEND_FFI_ENABLED)) { in zend_ffi_validate_api_restriction()
2949 ZEND_ASSERT(FFI_G(restriction) == ZEND_FFI_PRELOAD); in zend_ffi_validate_api_restriction()
2950 if (FFI_G(is_cli) in zend_ffi_validate_api_restriction()
2956 } else if (EXPECTED(FFI_G(restriction) == ZEND_FFI_ENABLED)) { in zend_ffi_validate_api_restriction()
3010 FFI_G(symbols) = NULL; in ZEND_METHOD()
3011 FFI_G(tags) = NULL; in ZEND_METHOD()
3015 FFI_G(default_type_attr) = ZEND_FFI_ATTR_STORED; in ZEND_METHOD()
3018 if (FFI_G(symbols)) { in ZEND_METHOD()
3019 zend_hash_destroy(FFI_G(symbols)); in ZEND_METHOD()
3020 efree(FFI_G(symbols)); in ZEND_METHOD()
3021 FFI_G(symbols) = NULL; in ZEND_METHOD()
3023 if (FFI_G(tags)) { in ZEND_METHOD()
3024 zend_hash_destroy(FFI_G(tags)); in ZEND_METHOD()
3025 efree(FFI_G(tags)); in ZEND_METHOD()
3026 FFI_G(tags) = NULL; in ZEND_METHOD()
3031 if (FFI_G(symbols)) { in ZEND_METHOD()
3035 ZEND_HASH_MAP_FOREACH_STR_KEY_PTR(FFI_G(symbols), name, sym) { in ZEND_METHOD()
3060 ffi->symbols = FFI_G(symbols); in ZEND_METHOD()
3061 ffi->tags = FFI_G(tags); in ZEND_METHOD()
3063 FFI_G(symbols) = NULL; in ZEND_METHOD()
3064 FFI_G(tags) = NULL; in ZEND_METHOD()
3225 if (FFI_G(symbols)) { in zend_ffi_cleanup_type()
3226 ZEND_HASH_MAP_FOREACH_PTR(FFI_G(symbols), sym) { in zend_ffi_cleanup_type()
3230 if (FFI_G(tags)) { in zend_ffi_cleanup_type()
3231 ZEND_HASH_MAP_FOREACH_PTR(FFI_G(tags), tag) { in zend_ffi_cleanup_type()
3240 if (!FFI_G(weak_types)) { in zend_ffi_remember_type()
3241 FFI_G(weak_types) = emalloc(sizeof(HashTable)); in zend_ffi_remember_type()
3242 zend_hash_init(FFI_G(weak_types), 0, NULL, zend_ffi_type_hash_dtor, 0); in zend_ffi_remember_type()
3246 zend_hash_next_index_insert_ptr(FFI_G(weak_types), ZEND_FFI_TYPE_MAKE_OWNED(type)); in zend_ffi_remember_type()
3303 FFI_G(symbols) = NULL; in zend_ffi_load()
3304 FFI_G(tags) = NULL; in zend_ffi_load()
3305 FFI_G(persistent) = preload; in zend_ffi_load()
3306 FFI_G(default_type_attr) = preload ? in zend_ffi_load()
3316 FFI_G(persistent) = 0; in zend_ffi_load()
3363 if (FFI_G(scopes)) { in zend_ffi_load()
3364 scope = zend_hash_str_find_ptr(FFI_G(scopes), scope_name, scope_name_len); in zend_ffi_load()
3368 if (FFI_G(symbols)) { in zend_ffi_load()
3369 ZEND_HASH_MAP_FOREACH_STR_KEY_PTR(FFI_G(symbols), name, sym) { in zend_ffi_load()
3426 if (scope && scope->tags && FFI_G(tags)) { in zend_ffi_load()
3427 ZEND_HASH_MAP_FOREACH_STR_KEY_PTR(FFI_G(tags), name, tag) { in zend_ffi_load()
3451 scope->symbols = FFI_G(symbols); in zend_ffi_load()
3452 scope->tags = FFI_G(tags); in zend_ffi_load()
3454 if (!FFI_G(scopes)) { in zend_ffi_load()
3455 FFI_G(scopes) = malloc(sizeof(HashTable)); in zend_ffi_load()
3456 zend_hash_init(FFI_G(scopes), 0, NULL, zend_ffi_scope_hash_dtor, 1); in zend_ffi_load()
3459 zend_hash_str_add_ptr(FFI_G(scopes), scope_name, scope_name_len, scope); in zend_ffi_load()
3461 if (FFI_G(symbols)) { in zend_ffi_load()
3463 scope->symbols = FFI_G(symbols); in zend_ffi_load()
3464 FFI_G(symbols) = NULL; in zend_ffi_load()
3466 ZEND_HASH_MAP_FOREACH_STR_KEY_PTR(FFI_G(symbols), name, sym) { in zend_ffi_load()
3472 FFI_G(symbols)->pDestructor = NULL; in zend_ffi_load()
3473 zend_hash_destroy(FFI_G(symbols)); in zend_ffi_load()
3476 if (FFI_G(tags)) { in zend_ffi_load()
3478 scope->tags = FFI_G(tags); in zend_ffi_load()
3479 FFI_G(tags) = NULL; in zend_ffi_load()
3481 ZEND_HASH_MAP_FOREACH_STR_KEY_PTR(FFI_G(tags), name, tag) { in zend_ffi_load()
3487 FFI_G(tags)->pDestructor = NULL; in zend_ffi_load()
3488 zend_hash_destroy(FFI_G(tags)); in zend_ffi_load()
3504 ffi->symbols = FFI_G(symbols); in zend_ffi_load()
3505 ffi->tags = FFI_G(tags); in zend_ffi_load()
3509 FFI_G(symbols) = NULL; in zend_ffi_load()
3510 FFI_G(tags) = NULL; in zend_ffi_load()
3511 FFI_G(persistent) = 0; in zend_ffi_load()
3517 if (FFI_G(symbols)) { in zend_ffi_load()
3518 zend_hash_destroy(FFI_G(symbols)); in zend_ffi_load()
3519 pefree(FFI_G(symbols), preload); in zend_ffi_load()
3520 FFI_G(symbols) = NULL; in zend_ffi_load()
3522 if (FFI_G(tags)) { in zend_ffi_load()
3523 zend_hash_destroy(FFI_G(tags)); in zend_ffi_load()
3524 pefree(FFI_G(tags), preload); in zend_ffi_load()
3525 FFI_G(tags) = NULL; in zend_ffi_load()
3527 FFI_G(persistent) = 0; in zend_ffi_load()
3566 if (FFI_G(scopes)) { in ZEND_METHOD()
3567 scope = zend_hash_find_ptr(FFI_G(scopes), scope_name); in ZEND_METHOD()
3615 if (!FFI_G(allow_vla) && (type->attr & ZEND_FFI_ATTR_VLA)) { in zend_ffi_validate_vla()
3616 …ser_error("\"[*]\" is not allowed in other than function prototype scope at line %d", FFI_G(line)); in zend_ffi_validate_vla()
3626 if (FFI_G(tags)) { in zend_ffi_validate_incomplete_type()
3630 ZEND_HASH_MAP_FOREACH_STR_KEY_PTR(FFI_G(tags), key, tag) { in zend_ffi_validate_incomplete_type()
3633 zend_ffi_throw_parser_error("Incomplete enum \"%s\" at line %d", ZSTR_VAL(key), FFI_G(line)); in zend_ffi_validate_incomplete_type()
3635 zend_ffi_throw_parser_error("Incomplete union \"%s\" at line %d", ZSTR_VAL(key), FFI_G(line)); in zend_ffi_validate_incomplete_type()
3637 … zend_ffi_throw_parser_error("Incomplete struct \"%s\" at line %d", ZSTR_VAL(key), FFI_G(line)); in zend_ffi_validate_incomplete_type()
3643 if (FFI_G(symbols)) { in zend_ffi_validate_incomplete_type()
3647 ZEND_HASH_MAP_FOREACH_STR_KEY_PTR(FFI_G(symbols), key, sym) { in zend_ffi_validate_incomplete_type()
3649 zend_ffi_throw_parser_error("Incomplete C type %s at line %d", ZSTR_VAL(key), FFI_G(line)); in zend_ffi_validate_incomplete_type()
3654 zend_ffi_throw_parser_error("Incomplete type at line %d", FFI_G(line)); in zend_ffi_validate_incomplete_type()
3657 zend_ffi_throw_parser_error("\"[]\" is not allowed at line %d", FFI_G(line)); in zend_ffi_validate_incomplete_type()
3659 } else if (!FFI_G(allow_vla) && (type->attr & ZEND_FFI_ATTR_VLA)) { in zend_ffi_validate_incomplete_type()
3660 …ser_error("\"[*]\" is not allowed in other than function prototype scope at line %d", FFI_G(line)); in zend_ffi_validate_incomplete_type()
3670 zend_ffi_throw_parser_error("void type is not allowed at line %d", FFI_G(line)); in zend_ffi_validate_type()
3680 zend_ffi_throw_parser_error("function type is not allowed at line %d", FFI_G(line)); in zend_ffi_validate_var_type()
3692 LONGJMP(FFI_G(bailout), FAILURE); in zend_ffi_validate_type_name()
3742 ZEND_HASH_MAP_FOREACH_PTR(FFI_G(tags), tag) { in zend_ffi_tags_cleanup()
3749 zend_hash_destroy(FFI_G(tags)); in zend_ffi_tags_cleanup()
3750 efree(FFI_G(tags)); in zend_ffi_tags_cleanup()
3795 FFI_G(symbols) = ffi->symbols; in ZEND_METHOD()
3796 FFI_G(tags) = ffi->tags; in ZEND_METHOD()
3798 FFI_G(symbols) = NULL; in ZEND_METHOD()
3799 FFI_G(tags) = NULL; in ZEND_METHOD()
3801 bool clean_symbols = FFI_G(symbols) == NULL; in ZEND_METHOD()
3802 bool clean_tags = FFI_G(tags) == NULL; in ZEND_METHOD()
3804 FFI_G(default_type_attr) = 0; in ZEND_METHOD()
3808 if (clean_tags && FFI_G(tags)) { in ZEND_METHOD()
3809 zend_hash_destroy(FFI_G(tags)); in ZEND_METHOD()
3810 efree(FFI_G(tags)); in ZEND_METHOD()
3811 FFI_G(tags) = NULL; in ZEND_METHOD()
3813 if (clean_symbols && FFI_G(symbols)) { in ZEND_METHOD()
3814 zend_hash_destroy(FFI_G(symbols)); in ZEND_METHOD()
3815 efree(FFI_G(symbols)); in ZEND_METHOD()
3816 FFI_G(symbols) = NULL; in ZEND_METHOD()
3826 if (clean_tags && FFI_G(tags)) { in ZEND_METHOD()
3829 if (clean_symbols && FFI_G(symbols)) { in ZEND_METHOD()
3830 zend_hash_destroy(FFI_G(symbols)); in ZEND_METHOD()
3831 efree(FFI_G(symbols)); in ZEND_METHOD()
3832 FFI_G(symbols) = NULL; in ZEND_METHOD()
3834 FFI_G(symbols) = NULL; in ZEND_METHOD()
3835 FFI_G(tags) = NULL; in ZEND_METHOD()
3945 FFI_G(symbols) = ffi->symbols; in ZEND_METHOD()
3946 FFI_G(tags) = ffi->tags; in ZEND_METHOD()
3948 FFI_G(symbols) = NULL; in ZEND_METHOD()
3949 FFI_G(tags) = NULL; in ZEND_METHOD()
3951 bool clean_symbols = FFI_G(symbols) == NULL; in ZEND_METHOD()
3952 bool clean_tags = FFI_G(tags) == NULL; in ZEND_METHOD()
3954 FFI_G(default_type_attr) = 0; in ZEND_METHOD()
3958 if (clean_tags && FFI_G(tags)) { in ZEND_METHOD()
3959 zend_hash_destroy(FFI_G(tags)); in ZEND_METHOD()
3960 efree(FFI_G(tags)); in ZEND_METHOD()
3961 FFI_G(tags) = NULL; in ZEND_METHOD()
3963 if (clean_symbols && FFI_G(symbols)) { in ZEND_METHOD()
3964 zend_hash_destroy(FFI_G(symbols)); in ZEND_METHOD()
3965 efree(FFI_G(symbols)); in ZEND_METHOD()
3966 FFI_G(symbols) = NULL; in ZEND_METHOD()
3976 if (clean_tags && FFI_G(tags)) { in ZEND_METHOD()
3979 if (clean_symbols && FFI_G(symbols)) { in ZEND_METHOD()
3980 zend_hash_destroy(FFI_G(symbols)); in ZEND_METHOD()
3981 efree(FFI_G(symbols)); in ZEND_METHOD()
3982 FFI_G(symbols) = NULL; in ZEND_METHOD()
3984 FFI_G(symbols) = NULL; in ZEND_METHOD()
3985 FFI_G(tags) = NULL; in ZEND_METHOD()
4117 FFI_G(symbols) = ffi->symbols; in ZEND_METHOD()
4118 FFI_G(tags) = ffi->tags; in ZEND_METHOD()
4120 FFI_G(symbols) = NULL; in ZEND_METHOD()
4121 FFI_G(tags) = NULL; in ZEND_METHOD()
4123 bool clean_symbols = FFI_G(symbols) == NULL; in ZEND_METHOD()
4124 bool clean_tags = FFI_G(tags) == NULL; in ZEND_METHOD()
4126 FFI_G(default_type_attr) = 0; in ZEND_METHOD()
4130 if (clean_tags && FFI_G(tags)) { in ZEND_METHOD()
4131 zend_hash_destroy(FFI_G(tags)); in ZEND_METHOD()
4132 efree(FFI_G(tags)); in ZEND_METHOD()
4133 FFI_G(tags) = NULL; in ZEND_METHOD()
4135 if (clean_symbols && FFI_G(symbols)) { in ZEND_METHOD()
4136 zend_hash_destroy(FFI_G(symbols)); in ZEND_METHOD()
4137 efree(FFI_G(symbols)); in ZEND_METHOD()
4138 FFI_G(symbols) = NULL; in ZEND_METHOD()
4143 if (clean_tags && FFI_G(tags)) { in ZEND_METHOD()
4146 if (clean_symbols && FFI_G(symbols)) { in ZEND_METHOD()
4147 zend_hash_destroy(FFI_G(symbols)); in ZEND_METHOD()
4148 efree(FFI_G(symbols)); in ZEND_METHOD()
4149 FFI_G(symbols) = NULL; in ZEND_METHOD()
4151 FFI_G(symbols) = NULL; in ZEND_METHOD()
4152 FFI_G(tags) = NULL; in ZEND_METHOD()
5251 FFI_G(restriction) = ZEND_FFI_PRELOAD; in ZEND_INI_MH()
5253 FFI_G(restriction) = (zend_ffi_api_restriction)zend_ini_parse_bool(new_value); in ZEND_INI_MH()
5261 if (FFI_G(restriction) == ZEND_FFI_PRELOAD) { in ZEND_INI_DISP()
5263 } else if (FFI_G(restriction) == ZEND_FFI_ENABLED) { in ZEND_INI_DISP()
5405 FFI_G(is_cli) = strcmp(sapi_module.name, "cli") == 0;
5548 if (FFI_G(preload)) {
5549 return zend_ffi_preload(FFI_G(preload));
5559 if (FFI_G(callbacks)) {
5560 zend_hash_destroy(FFI_G(callbacks));
5561 efree(FFI_G(callbacks));
5562 FFI_G(callbacks) = NULL;
5564 if (FFI_G(weak_types)) {
5566 fprintf(stderr, "WeakTypes: %d\n", zend_hash_num_elements(FFI_G(weak_types)));
5568 zend_hash_destroy(FFI_G(weak_types));
5569 efree(FFI_G(weak_types));
5570 FFI_G(weak_types) = NULL;
5722 LONGJMP(FFI_G(bailout), FAILURE);
5806 zend_ffi_parser_error("Unsupported type _Complex at line %d", FFI_G(line));
5809 zend_ffi_parser_error("Unsupported type specifier combination at line %d", FFI_G(line));
5823 if (FFI_G(symbols)) {
5824 sym = zend_hash_str_find_ptr(FFI_G(symbols), name, name_len);
5829 type = zend_hash_str_find_ptr(&FFI_G(types), name, name_len);
5842 if (FFI_G(symbols)) {
5843 sym = zend_hash_str_find_ptr(FFI_G(symbols), name, name_len);
5852 type = zend_hash_str_find_ptr(&FFI_G(types), name, name_len);
5857 zend_ffi_parser_error("Undefined C type \"%.*s\" at line %d", name_len, name, FFI_G(line));
5865 if (UNEXPECTED(FFI_G(attribute_parsing))) {
5870 } else if (FFI_G(symbols)) {
5871 sym = zend_hash_str_find_ptr(FFI_G(symbols), name, name_len);
5903 zend_ffi_type *type = pemalloc(sizeof(zend_ffi_type), FFI_G(persistent));
5905 type->attr = FFI_G(default_type_attr) | (dcl->attr & ZEND_FFI_ENUM_ATTRS);
5971 …rser_error("Enumerator value \"%.*s\" must be an integer at line %d", name_len, name, FFI_G(line));
5976 …zend_ffi_parser_error("Overflow in enumeration values \"%.*s\" at line %d", name_len, name, FFI_G(…
6014 if (!FFI_G(symbols)) {
6015 FFI_G(symbols) = pemalloc(sizeof(HashTable), FFI_G(persistent));
6016 …zend_hash_init(FFI_G(symbols), 0, NULL, FFI_G(persistent) ? zend_ffi_symbol_hash_persistent_dtor :…
6018 sym = zend_hash_str_find_ptr(FFI_G(symbols), name, name_len);
6020 zend_ffi_parser_error("Redeclaration of \"%.*s\" at line %d", name_len, name, FFI_G(line));
6022 sym = pemalloc(sizeof(zend_ffi_symbol), FFI_G(persistent));
6026 zend_hash_str_add_new_ptr(FFI_G(symbols), name, name_len, sym);
6033 zend_ffi_type *type = pemalloc(sizeof(zend_ffi_type), FFI_G(persistent));
6035 type->attr = FFI_G(default_type_attr) | (dcl->attr & ZEND_FFI_STRUCT_ATTRS);
6043 …(&type->record.fields, 0, NULL, FFI_G(persistent) ? zend_ffi_field_hash_persistent_dtor :zend_ffi_…
6058 … zend_ffi_throw_parser_error("Flexible array member not at end of struct at line %d", FFI_G(line));
6069 …zend_ffi_throw_parser_error("Struct/union can't contain an instance of itself at line %d", FFI_G(l…
6075 zend_ffi_throw_parser_error("Flexible array member in union at line %d", FFI_G(line));
6094 LONGJMP(FFI_G(bailout), FAILURE);
6097 field = pemalloc(sizeof(zend_ffi_field), FFI_G(persistent));
6121 pefree(field, FFI_G(persistent));
6122 zend_ffi_parser_error("Duplicate field name \"%.*s\" at line %d", name_len, name, FFI_G(line));
6139 zend_ffi_parser_error("Declaration does not declare anything at line %d", FFI_G(line));
6149 LONGJMP(FFI_G(bailout), FAILURE);
6158 zend_ffi_field *new_field = pemalloc(sizeof(zend_ffi_field), FFI_G(persistent));
6175 pefree(new_field, FFI_G(persistent));
6176 zend_ffi_parser_error("Duplicate field name \"%s\" at line %d", ZSTR_VAL(key), FFI_G(line));
6206 LONGJMP(FFI_G(bailout), FAILURE);
6211 … at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
6217 … at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
6221 … at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
6226 … at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
6232 … at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
6237 … at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
6241 … at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
6244 field = pemalloc(sizeof(zend_ffi_field), FFI_G(persistent));
6288 pefree(field, FFI_G(persistent));
6289 zend_ffi_parser_error("Duplicate field name \"%.*s\" at line %d", name_len, name, FFI_G(line));
6314 zend_ffi_type *type = pemalloc(sizeof(zend_ffi_type), FFI_G(persistent));
6316 type->attr = FFI_G(default_type_attr) | (dcl->attr & ZEND_FFI_POINTER_ATTRS);
6322 LONGJMP(FFI_G(bailout), FAILURE);
6335 zend_ffi_throw_parser_error("Array of functions is not allowed at line %d", FFI_G(line));
6338 …zend_ffi_throw_parser_error("Only the leftmost array can be undimensioned at line %d", FFI_G(line)…
6364 zend_ffi_parser_error("Unsupported array index type at line %d", FFI_G(line));
6369 zend_ffi_parser_error("Negative array index at line %d", FFI_G(line));
6375 LONGJMP(FFI_G(bailout), FAILURE);
6378 type = pemalloc(sizeof(zend_ffi_type), FFI_G(persistent));
6380 type->attr = FFI_G(default_type_attr) | (dcl->attr & ZEND_FFI_ARRAY_ATTRS);
6395 zend_ffi_throw_parser_error("Function returning function is not allowed at line %d", FFI_G(line));
6398 zend_ffi_throw_parser_error("Function returning array is not allowed at line %d", FFI_G(line));
6424 pefree(args, FFI_G(persistent));
6425 zend_ffi_parser_error("void type is not allowed at line %d", FFI_G(line));
6434 pefree(args, FFI_G(persistent));
6454 pefree(args, FFI_G(persistent));
6455 …ble is not allowed at position " ZEND_ULONG_FMT " with __vectorcall at line %d", i+1, FFI_G(line));
6467 pefree(args, FFI_G(persistent));
6469 LONGJMP(FFI_G(bailout), FAILURE);
6472 type = pemalloc(sizeof(zend_ffi_type), FFI_G(persistent));
6474 type->attr = FFI_G(default_type_attr) | (dcl->attr & ZEND_FFI_FUNC_ATTRS);
6528 pefree(args, FFI_G(persistent));
6532 zend_ffi_parser_error("Unsupported calling convention line %d", FFI_G(line));
6548 *args = pemalloc(sizeof(HashTable), FFI_G(persistent));
6549 zend_hash_init(*args, 0, NULL, zend_ffi_type_hash_dtor, FFI_G(persistent));
6558 zend_ffi_type *new_type = pemalloc(sizeof(zend_ffi_type), FFI_G(persistent));
6560 new_type->attr = FFI_G(default_type_attr) | (type->attr & ZEND_FFI_POINTER_ATTRS);
6567 zend_ffi_type *new_type = pemalloc(sizeof(zend_ffi_type), FFI_G(persistent));
6569 new_type->attr = FFI_G(default_type_attr);
6578 pefree(*args, FFI_G(persistent));
6580 LONGJMP(FFI_G(bailout), FAILURE);
6590 if (!FFI_G(symbols)) {
6591 FFI_G(symbols) = pemalloc(sizeof(HashTable), FFI_G(persistent));
6592 …zend_hash_init(FFI_G(symbols), 0, NULL, FFI_G(persistent) ? zend_ffi_symbol_hash_persistent_dtor :…
6595 sym = zend_hash_str_find_ptr(FFI_G(symbols), name, name_len);
6625 zend_ffi_parser_error("Redeclaration of \"%.*s\" at line %d", name_len, name, FFI_G(line));
6630 LONGJMP(FFI_G(bailout), FAILURE);
6636 zend_ffi_type *type = pemalloc(sizeof(zend_ffi_type), FFI_G(persistent));
6639 type->attr |= FFI_G(default_type_attr);
6644 sym = pemalloc(sizeof(zend_ffi_symbol), FFI_G(persistent));
6649 zend_hash_str_add_new_ptr(FFI_G(symbols), name, name_len, sym);
6656 LONGJMP(FFI_G(bailout), FAILURE);
6660 sym = pemalloc(sizeof(zend_ffi_symbol), FFI_G(persistent));
6665 zend_hash_str_add_new_ptr(FFI_G(symbols), name, name_len, sym);
6680 if (!FFI_G(tags)) {
6681 FFI_G(tags) = pemalloc(sizeof(HashTable), FFI_G(persistent));
6682 …zend_hash_init(FFI_G(tags), 0, NULL, FFI_G(persistent) ? zend_ffi_tag_hash_persistent_dtor : zend_…
6684 tag = zend_hash_str_find_ptr(FFI_G(tags), name, name_len);
6690 …zend_ffi_parser_error("\"%.*s\" defined as wrong kind of tag at line %d", name_len, name, FFI_G(li…
6693 … zend_ffi_parser_error("Redefinition of \"struct %.*s\" at line %d", name_len, name, FFI_G(line));
6698 …zend_ffi_parser_error("\"%.*s\" defined as wrong kind of tag at line %d", name_len, name, FFI_G(li…
6701 zend_ffi_parser_error("Redefinition of \"union %.*s\" at line %d", name_len, name, FFI_G(line));
6706 …zend_ffi_parser_error("\"%.*s\" defined as wrong kind of tag at line %d", name_len, name, FFI_G(li…
6709 zend_ffi_parser_error("Redefinition of \"enum %.*s\" at line %d", name_len, name, FFI_G(line));
6721 zend_ffi_tag *tag = pemalloc(sizeof(zend_ffi_tag), FFI_G(persistent));
6722 zend_string *tag_name = zend_string_init(name, name_len, FFI_G(persistent));
6747 zend_hash_add_new_ptr(FFI_G(tags), tag_name, tag);
6756 zend_ffi_parser_error("Multiple calling convention specifiers at line %d", FFI_G(line));
6852 zend_ffi_parser_error("Unsupported attribute \"%.*s\" at line %d", name_len, name, FFI_G(line));
6907 zend_ffi_parser_error("Incorrect \"regparam\" value at line %d", FFI_G(line));
6916 zend_ffi_parser_error("Incorrect \"alignment\" value at line %d", FFI_G(line));
6973 zend_ffi_parser_error("Unsupported \"mode\" value at line %d", FFI_G(line));
6976 zend_ffi_parser_error("Unsupported attribute \"%.*s\" at line %d", name_len, name, FFI_G(line));
6992 zend_ffi_parser_error("Incorrect \"alignment\" value at line %d", FFI_G(line));
7053 LONGJMP(FFI_G(bailout), FAILURE);