From 1384e5bbdf4dc1ceeeeeb1e16a90ce5d51766c07 Mon Sep 17 00:00:00 2001 From: Lewis Van Winkle Date: Thu, 21 Jan 2016 14:42:07 -0600 Subject: [PATCH] Refactored print function --- tinyexpr.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/tinyexpr.c b/tinyexpr.c index 97be41b..3c4e95d 100644 --- a/tinyexpr.c +++ b/tinyexpr.c @@ -381,10 +381,7 @@ double te_interp(const char *expression, int *error) { static void pn (const te_expr *n, int depth) { - int i; - for (i = 0; i < depth; ++i) { - printf(" "); - } + printf("%*s", depth, ""); if (n->bound) { printf("bound %p\n", n->bound);