diff --git a/src/builtins/sysfn.c b/src/builtins/sysfn.c index 15247737..ba66aa37 100644 --- a/src/builtins/sysfn.c +++ b/src/builtins/sysfn.c @@ -100,7 +100,7 @@ B repr_c1(B t, B x) { #if FORMATTER return bqn_repr(x); #else - thrM("•Repr: Cannot represent non-numbers without FORMATTER defined"); + thrM("•Repr: Cannot represent non-numbers with -DFORMATTER=0"); #endif } } @@ -109,7 +109,7 @@ B fmt_c1(B t, B x) { #if FORMATTER return bqn_fmt(x); #else - thrM("•Fmt isn't supported without FORMATTER defined"); + thrM("•Fmt isn't supported with -DFORMATTER=0"); #endif } diff --git a/src/core/stuff.c b/src/core/stuff.c index 148ddc4c..af8e91f0 100644 --- a/src/core/stuff.c +++ b/src/core/stuff.c @@ -822,11 +822,13 @@ void g_pst(void) { vm_pstLive(); fflush(stdout); fflush(stderr); } #else #define ONLY_ALWAYS #endif + extern bool cbqn_initialized; static void warn_ln(B x) { if (isArr(x)) fprint_fmt(stderr, "%s items, %S, shape=%H\n", IA(x), eltype_repr(TI(x,elType)), x); else { fprintf(stderr, "atom: "); - fprintsB(stderr, x = bqn_fmt(inc(x))); dec(x); + if (cbqn_initialized && FORMATTER) { fprintsB(stderr, x = bqn_fmt(inc(x))); dec(x); } + else fprintI(stderr, x); fputc('\n', stderr); } } diff --git a/src/main.c b/src/main.c index 97a52e7a..c53f1dfd 100644 --- a/src/main.c +++ b/src/main.c @@ -789,8 +789,10 @@ int main(int argc, char* argv[]) { } case 'L': { repl_init(); break; } // just initialize. mostly for perf testing case 'p': { repl_init(); REQARG(p); - B r = bqn_fmt(gsc_exec_inline(utf8Decode0(argv[i++]), m_c8vec_0("(-p)"), emptySVec())); - printsB(r); dec(r); + B r = gsc_exec_inline(utf8Decode0(argv[i++]), m_c8vec_0("(-p)"), emptySVec()); + if (FORMATTER) { r = bqn_fmt(r); printsB(r); } + else { printI(r); } + dec(r); printf("\n"); break; }