This re-implements libprebirth in Rebirth Lisp, finally cutting the
cord. (Are these birth puns getting out of control?) We are finally purely
in Lisp land!
* build-aux/bootstrap/rebirth.scm: Define libprebith primitives when
`string->es' is available (using `cond-expand').
(prebirth->ecmascript): Do not include `libprebirth.js' in output.
This modifies each of the three lexers just to avoid confusion, even
though prebirth has no need for it. Birth does have a need, however, since
rebirth will contain newlines---despite the relevant rebirth code (next
commit) not being expanded, it still has to go through the lexer, which
otherwise errors out.
* build-aux/bootstrap/birth.scm (lex): Permit newlines in string regex.
* build-aux/bootstrap/prebirth.js (lex): Permit newlines in string regex.
* build-aux/bootstrap/rebirth.scm (lex): Permit newlines in string regex.
`cond-expand' allows moving forward with implementing features based on the
current bootstrapped state of the system---rebirth will be able to
recursively compile itself and introduce new features along the way.
`string->es' allows outputting raw ECMAScript, which gives us more control
over the code that is generated without having to hard-code it in the
compiler itself.
* build-aux/bootstrap/birth.scm
(fnmap)[cond-expand]: Always yield the empty string (do nothing).
* build-aux/bootstrap/rebirth.scm
(fnmap)[cond-expand]: Expand `string->es' only.
(fnmap)[string->es]: Add macro.
`define' can now be used to define values in addition to the procedure
short-hand.
* build-aux/bootstrap/rebirth.scm
(cdfn): New procedure. Renamed original `cdfn' to `cdfn-proc'.
(cdfn-var): New procedure.
(cdfn-proc): Renamed from `cdfn'.