mitranim/jisp

A test suite

Opened this issue · 3 comments

Jisp needs a comprehensive compiler test suite. It turned out that recompiling itself is far from being a good enough test.

I would be interested in helping out with this. What about all the examples from jisp.io home page? Would that make a good test suite? Is that the kind of thing you are looking for?

I imagine we would want to test the outcome of the execution of compiled statements, not require that compilation produce a specific output.

Also how would you want to run the tests, is there a specific testing tool you would want to use?

A couple example tests would be good to get me started and I could write more tests for the rest of the language features.

This might sound counterintuitive coming from the author, but I recommend you don't spend time on jisp right now.

Lack of tests aside, as a language, jisp is inferior to the current JavaScript, which has improved greatly with ES2015/2016. S-expressions and macros don't make up for that. For actual projects, you're better served by Babel or TypeScript. It needs to be brought up to feature parity first.

The "current" compiler version is also not worth improving, a rewrite is needed. On top of that, the language needs a purge of redundancies and Ruby influences. I started that with 0.4.0 but have been on a hiatus. My apologies.

(Edit) If you just want a lisp-to-javascript to play around, then it's probably best to look at actively maintained projects, such as eslisp.

I hadn't started figuring out ES6 yet, babel looks helpful. thanks