From 9e83bf8c3656b736ba3a14d9b7b8af61b48415f4 Mon Sep 17 00:00:00 2001 From: Nicholas Noll Date: Thu, 30 Apr 2020 11:54:19 -0700 Subject: chore: move from new to make prefix of constructors --- sys/libbio/io/newick.c | 6 +++--- sys/libbio/phylo.c | 1 + sys/libbio/test.c | 2 +- 3 files changed, 5 insertions(+), 4 deletions(-) (limited to 'sys/libbio') diff --git a/sys/libbio/io/newick.c b/sys/libbio/io/newick.c index 038b41c..f9be2d2 100644 --- a/sys/libbio/io/newick.c +++ b/sys/libbio/io/newick.c @@ -229,7 +229,7 @@ parse(struct Parser *p) errorf("incorrect format: comment found in disallowed region"); goto ERROR; } - node->comment = str·new(""); + node->comment = str·make(""); while (tok.kind != tok·rbrak) { tok = lex_nospace(p->file, p->fimpl); if (tok.kind == tok·eof || tok.kind == tok·nil) { @@ -268,7 +268,7 @@ parse(struct Parser *p) errorf("parse error: attempting to set name of nil node"); goto ERROR; } - node->name = str·new(tok.lit.s); + node->name = str·make(tok.lit.s); } else { if (p->tok.kind != tok·lparen && p->tok.kind != tok·comma) { errorf("format error: misplaced identifier for leaf found"); @@ -282,7 +282,7 @@ parse(struct Parser *p) node = p->heap.alloc(p->himpl, 1, sizeof(*node)); memset(node, 0, sizeof(*node)); - node->name = str·new(tok.lit.s); + node->name = str·make(tok.lit.s); phylo·addchild(p->root, node); } diff --git a/sys/libbio/phylo.c b/sys/libbio/phylo.c index 4bb8f66..1cc5b5d 100644 --- a/sys/libbio/phylo.c +++ b/sys/libbio/phylo.c @@ -218,4 +218,5 @@ struct phylo·InferOpts error phylo·ancestralinfer(bio·Tree *tree, struct phylo·InferOpts opts) { + return 0; } diff --git a/sys/libbio/test.c b/sys/libbio/test.c index 5059ce6..8054864 100644 --- a/sys/libbio/test.c +++ b/sys/libbio/test.c @@ -99,7 +99,7 @@ test·newick() io·Peeker rdr; io·Putter wtr; - heap = mem·newarena(mem·sys, nil); + heap = mem·makearena(mem·sys, nil); rdr = (io·Peeker){.get = &io·getbyte, .unget = &io·ungetbyte}; wtr = (io·Putter){.put = &io·putbyte, .putstr = &io·putstring}; -- cgit v1.2.1