From 5cd9e7b5e7a4f4b55814590abdf56254fb84b54e Mon Sep 17 00:00:00 2001 From: Marshall Lochbaum Date: Mon, 6 Jul 2020 13:32:18 -0400 Subject: Add dcshim to call compiler from any current directory --- dc.bqn | 2 +- dcshim.bqn | 3 +++ test/dt.js | 5 ++--- 3 files changed, 6 insertions(+), 4 deletions(-) create mode 100755 dcshim.bqn diff --git a/dc.bqn b/dc.bqn index f219b5b1..70f51ff1 100755 --- a/dc.bqn +++ b/dc.bqn @@ -1,4 +1,4 @@ -⍝ Run with spec/dzref +#! ./spec/dzref nl‿tab←•UCS 10‿9 charSet←∾charGroups←⟨ diff --git a/dcshim.bqn b/dcshim.bqn new file mode 100755 index 00000000..1762c342 --- /dev/null +++ b/dcshim.bqn @@ -0,0 +1,3 @@ +#! /usr/bin/env dbqn + +((<•path∾"dc.bqn")∾•args) •EX •path∾"spec/dzref" diff --git a/test/dt.js b/test/dt.js index 86f10357..49636a66 100755 --- a/test/dt.js +++ b/test/dt.js @@ -9,9 +9,8 @@ const t=load('cases.bqn').split('\n').filter(x=>x).map(x=>x.split(' % ')) , expt=t.map(e=>+e[0]) var compiler = execFile( - __dirname+'/../spec/dzref', - [ __dirname+'/../dc.bqn', - '{•←Compile𝕩}¨⟨'+test+'⟩' ], + __dirname+'/../dcshim.bqn', + [ '{•←Compile𝕩}¨⟨'+test+'⟩' ], function (error, stdout, stderr) { const rslt=stdout.split('\n').filter(a=>a.length) .map(a=>runWasm(a.split("‿").map(n=>+n))) -- cgit v1.2.3