From b286ea5634bb96621fa344402fbf44f9ccad3a4f Mon Sep 17 00:00:00 2001 From: Kamila Szewczyk Date: Wed, 6 Jan 2021 10:53:01 +0100 Subject: [PATCH] "golf" --- test.sh | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/test.sh b/test.sh index a738612..ca8ab7b 100755 --- a/test.sh +++ b/test.sh @@ -1,8 +1,6 @@ #!/bin/sh -TEST_JIT=0 - -[ $# -ne 0 ] && TEST_JIT=1 +TEST_JIT=$# _log() { echo -n "$(tput setaf 6)$2 $(tput setaf 5)$1$(tput sgr0) $(printf '.%.0s' $(seq 1 70))" | head -c 70 @@ -51,7 +49,7 @@ _disasm() { } _run_jit() { - [ $TEST_JIT -eq 1 ] && _interpreter "$1" "-j" "[JIT]" + [ $TEST_JIT -gt 0 ] && _interpreter "$1" "-j" "[JIT]" _interpreter "$1" "" "[RUN]" }