diff options
| author | krasimir <krasimir@chalmers.se> | 2017-04-13 13:43:48 +0000 |
|---|---|---|
| committer | krasimir <krasimir@chalmers.se> | 2017-04-13 13:43:48 +0000 |
| commit | 2588a6f016cd1d0bc47d9ab0ab5a8b1d2f376000 (patch) | |
| tree | 7373cac6936a14f2fd13f1f01c2543a89c706970 /src/runtime/c | |
| parent | e650b9c5fc38ebb408ddf1982249479aac73836d (diff) | |
gu_string_buf -> gu_new_string_buf in libgu
Diffstat (limited to 'src/runtime/c')
| -rw-r--r-- | src/runtime/c/gu/string.c | 4 | ||||
| -rw-r--r-- | src/runtime/c/gu/string.h | 2 | ||||
| -rw-r--r-- | src/runtime/c/pgf/aligner.c | 2 | ||||
| -rw-r--r-- | src/runtime/c/pgf/expr.c | 4 | ||||
| -rw-r--r-- | src/runtime/c/pgf/linearizer.c | 4 | ||||
| -rw-r--r-- | src/runtime/c/pgf/literals.c | 4 | ||||
| -rw-r--r-- | src/runtime/c/pgf/parseval.c | 2 | ||||
| -rw-r--r-- | src/runtime/c/pgf/typechecker.c | 8 |
8 files changed, 15 insertions, 15 deletions
diff --git a/src/runtime/c/gu/string.c b/src/runtime/c/gu/string.c index 386eb7a6f..118e0cb0b 100644 --- a/src/runtime/c/gu/string.c +++ b/src/runtime/c/gu/string.c @@ -50,7 +50,7 @@ gu_string_buf_end(GuOutStream* stream, size_t sz, GuExn* err) } GuStringBuf* -gu_string_buf(GuPool* pool) +gu_new_string_buf(GuPool* pool) { GuStringBuf* sbuf = gu_new(GuStringBuf, pool); sbuf->stream.output = gu_string_buf_output; @@ -152,7 +152,7 @@ GuString gu_format_string_v(const char* fmt, va_list args, GuPool* pool) { GuPool* tmp_pool = gu_local_pool(); - GuStringBuf* sb = gu_string_buf(tmp_pool); + GuStringBuf* sb = gu_new_string_buf(tmp_pool); GuOut* out = gu_string_buf_out(sb); gu_vprintf(fmt, args, out, NULL); gu_out_flush(out, NULL); diff --git a/src/runtime/c/gu/string.h b/src/runtime/c/gu/string.h index d52c9dddb..5136b0189 100644 --- a/src/runtime/c/gu/string.h +++ b/src/runtime/c/gu/string.h @@ -25,7 +25,7 @@ gu_string_in(GuString string, GuPool* pool); typedef struct GuStringBuf GuStringBuf; GuStringBuf* -gu_string_buf(GuPool* pool); +gu_new_string_buf(GuPool* pool); GuOut* gu_string_buf_out(GuStringBuf* sb); diff --git a/src/runtime/c/pgf/aligner.c b/src/runtime/c/pgf/aligner.c index b23b3d2e9..be7034f58 100644 --- a/src/runtime/c/pgf/aligner.c +++ b/src/runtime/c/pgf/aligner.c @@ -210,7 +210,7 @@ pgf_align_words(PgfConcr* concr, PgfExpr expr, .parent_current = gu_new_buf(int, tmp_pool), .phrases = phrases, .last_phrase = NULL, - .sbuf = gu_string_buf(tmp_pool), + .sbuf = gu_new_string_buf(tmp_pool), .n_matches = 0, .err = err, .bind = true, diff --git a/src/runtime/c/pgf/expr.c b/src/runtime/c/pgf/expr.c index 4a186dabc..e967b5459 100644 --- a/src/runtime/c/pgf/expr.c +++ b/src/runtime/c/pgf/expr.c @@ -350,7 +350,7 @@ pgf_expr_parser_token(PgfExprParser* parser) case '\'': pgf_expr_parser_getc(parser); - GuStringBuf* chars = gu_string_buf(parser->tmp_pool); + GuStringBuf* chars = gu_new_string_buf(parser->tmp_pool); while (parser->ch != '\'' && parser->ch != EOF) { if (parser->ch == '\\') { pgf_expr_parser_getc(parser); @@ -366,7 +366,7 @@ pgf_expr_parser_token(PgfExprParser* parser) } break; default: { - GuStringBuf* chars = gu_string_buf(parser->tmp_pool); + GuStringBuf* chars = gu_new_string_buf(parser->tmp_pool); if (pgf_is_ident_first(parser->ch)) { do { diff --git a/src/runtime/c/pgf/linearizer.c b/src/runtime/c/pgf/linearizer.c index 629ac357f..f3b527536 100644 --- a/src/runtime/c/pgf/linearizer.c +++ b/src/runtime/c/pgf/linearizer.c @@ -460,7 +460,7 @@ pgf_cnc_resolve(PgfCnc* cnc, GuPool* tmp_pool = gu_local_pool(); GuExn* err = gu_new_exn(tmp_pool); - GuStringBuf* sbuf = gu_string_buf(tmp_pool); + GuStringBuf* sbuf = gu_new_string_buf(tmp_pool); GuOut* out = gu_string_buf_out(sbuf); gu_putc('[', out, err); @@ -1209,7 +1209,7 @@ pgf_get_tokens(PgfSymbols* syms, uint16_t sym_idx, GuPool* pool) { GuPool* tmp_pool = gu_new_pool(); GuExn* err = gu_new_exn(tmp_pool); - GuStringBuf* sbuf = gu_string_buf(tmp_pool); + GuStringBuf* sbuf = gu_new_string_buf(tmp_pool); GuOut* out = gu_string_buf_out(sbuf); PgfSimpleLin flin = { diff --git a/src/runtime/c/pgf/literals.c b/src/runtime/c/pgf/literals.c index b5332b1ec..e667b58bb 100644 --- a/src/runtime/c/pgf/literals.c +++ b/src/runtime/c/pgf/literals.c @@ -234,7 +234,7 @@ pgf_match_name_lit(PgfLiteralCallback* self, PgfConcr* concr, return NULL; GuPool* tmp_pool = gu_local_pool(); - GuStringBuf *sbuf = gu_string_buf(tmp_pool); + GuStringBuf *sbuf = gu_new_string_buf(tmp_pool); GuOut* out = gu_string_buf_out(sbuf); GuExn* err = gu_new_exn(tmp_pool); @@ -361,7 +361,7 @@ pgf_match_unknown_lit(PgfLiteralCallback* self, PgfConcr* concr, GuUCS ucs = gu_utf8_decode(&p); if (!gu_ucs_is_upper(ucs)) { GuPool* tmp_pool = gu_local_pool(); - GuStringBuf *sbuf = gu_string_buf(tmp_pool); + GuStringBuf *sbuf = gu_new_string_buf(tmp_pool); GuOut* out = gu_string_buf_out(sbuf); GuExn* err = gu_new_exn(tmp_pool); diff --git a/src/runtime/c/pgf/parseval.c b/src/runtime/c/pgf/parseval.c index 7ef41577d..c76e75a17 100644 --- a/src/runtime/c/pgf/parseval.c +++ b/src/runtime/c/pgf/parseval.c @@ -150,7 +150,7 @@ pgf_parseval(PgfConcr* concr, PgfExpr expr, PgfType* type, } GuStringBuf* sbuf = - gu_string_buf(pool); + gu_new_string_buf(pool); PgfMetricsLznState state; state.bind = true; diff --git a/src/runtime/c/pgf/typechecker.c b/src/runtime/c/pgf/typechecker.c index 3e04c3afe..ab8f80d73 100644 --- a/src/runtime/c/pgf/typechecker.c +++ b/src/runtime/c/pgf/typechecker.c @@ -101,7 +101,7 @@ pgf_tc_mk_print_context(PgfTypeChecker* checker, PgfContext* ctxt) static void pgf_tc_err_cannot_infer(PgfTypeChecker* checker, PgfContext* ctxt, PgfExpr e) { - GuStringBuf* sbuf = gu_string_buf(checker->tmp_pool); + GuStringBuf* sbuf = gu_new_string_buf(checker->tmp_pool); GuOut* out = gu_string_buf_out(sbuf); GuExn* err = gu_exn(checker->tmp_pool); @@ -117,7 +117,7 @@ static void pgf_tc_err_exp_fun_type_1(PgfTypeChecker* checker, PgfContext* ctxt, PgfExpr e, PgfType* ty) { - GuStringBuf* sbuf = gu_string_buf(checker->tmp_pool); + GuStringBuf* sbuf = gu_new_string_buf(checker->tmp_pool); GuOut* out = gu_string_buf_out(sbuf); GuExn* err = gu_exn(checker->tmp_pool); @@ -137,7 +137,7 @@ static void pgf_tc_err_exp_fun_type_2(PgfTypeChecker* checker, PgfContext* ctxt, PgfExpr e, PgfType* ty) { - GuStringBuf* sbuf = gu_string_buf(checker->tmp_pool); + GuStringBuf* sbuf = gu_new_string_buf(checker->tmp_pool); GuOut* out = gu_string_buf_out(sbuf); GuExn* err = gu_exn(checker->tmp_pool); @@ -170,7 +170,7 @@ pgf_tc_err_type_mismatch(PgfTypeChecker* checker, PgfContext* ctxt, PgfExpr e, PgfCFType ty1, PgfCFType ty2) { - GuStringBuf* sbuf = gu_string_buf(checker->tmp_pool); + GuStringBuf* sbuf = gu_new_string_buf(checker->tmp_pool); GuOut* out = gu_string_buf_out(sbuf); GuExn* err = gu_exn(checker->tmp_pool); |
