diff --git a/src/context.c b/src/context.c index 76ef73c..c9e4032 100644 --- a/src/context.c +++ b/src/context.c @@ -2358,38 +2358,8 @@ setup_function_for_load_inner(apfl_ctx ctx, struct apfl_string *filename) return NULL; } - struct matcher_instruction_list *milist = apfl_matcher_instructions_new(&ctx->gc); - if ( - milist == NULL - || !apfl_gc_tmproot_add(&ctx->gc, GC_OBJECT_FROM(milist, GC_TYPE_MATCHER_INSTRUCTIONS)) - ) { - return NULL; - } - if (!apfl_resizable_append( - ctx->gc.allocator, - sizeof(union matcher_instruction_or_arg), - (void **)&milist->instructions, - &milist->len, - &milist->cap, - &(union matcher_instruction_or_arg[]) { - {.instruction = MATCHER_IGNORE}, - }, - 1 - )) { - return NULL; - } - - struct matcher *matcher = apfl_matcher_new(&ctx->gc, milist); - if ( - matcher == NULL - || !apfl_gc_tmproot_add(&ctx->gc, GC_OBJECT_FROM(matcher, GC_TYPE_MATCHER)) - ) { - apfl_drop(ctx, -1); - return NULL; - } - - if (!apfl_func_add_subfunc(func_value->func, ilist, matcher)) { + if (!apfl_func_add_subfunc(func_value->func, ilist, NULL)) { apfl_drop(ctx, -1); return NULL; }