diff options
author | William Langford <wlangfor@gmail.com> | 2014-07-09 00:55:20 -0400 |
---|---|---|
committer | Nicolas Williams <nico@cryptonector.com> | 2014-07-22 22:51:11 -0500 |
commit | 38b939688a596c2de1b3d254491005b2754c8569 (patch) | |
tree | 5a72e591ad521c9d6085c26bfd935739929543cd /builtin.c | |
parent | 01fc8168e95bc596e22eebcb568e83660d9fe9f5 (diff) |
Added library system with -l, -L, and JQ_LIBRARY_PATH
Created util.[ch] to hold common utilities.
Diffstat (limited to 'builtin.c')
-rw-r--r-- | builtin.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -991,14 +991,14 @@ static const char* const jq_builtins[] = { static int builtins_bind_one(jq_state *jq, block* bb, const char* code) { - struct locfile src; - locfile_init(&src, jq, code, strlen(code)); + struct locfile* src; + src = locfile_init(jq, code, strlen(code)); block funcs; - int nerrors = jq_parse_library(&src, &funcs); + int nerrors = jq_parse_library(src, &funcs); if (nerrors == 0) { *bb = block_bind_referenced(funcs, *bb, OP_IS_CALL_PSEUDO); } - locfile_free(&src); + locfile_free(src); return nerrors; } |