Closed sander closed 10 years ago
Such feature has being added and you can use it if you run wisp from master, once next version is released on npm it will be available from npm installation as well.
Following should should do what you expect:
echo "(print :hi)" | ./bin/wisp.js --print expansion
Nice, thanks! I’m on commit a144d1bbf94c7b9d4ca390924f52857c31918831 (2014-05-23) from master. I’ve run npm install
and tried your command, but I get:
sanderbook:wisp sander$ echo "(print :hi)" | ./bin/wisp.js --print expansion
nilsanderbook:wisp sander$
Also other options for --print
seem to result in nil
. When running wisp.js --print
without a value, I do get error: option
--print
Is this a different issue or am I just doing it wrong? :-)
It would be nice to have a command like
wisp --show-macro-expansion
that shows me the LISP code after the macros are expanded, and before it is compiled to JS. Or does such a flag already exist?