mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-06-17 17:20:29 +02:00
Compile Syntax Objects to Javascript
* module/language/js-il/compile-javascript.scm (compile-const): Handle the new syntax object struct. * module/language/js-il/runtime.js(scheme.Syntax): Add Syntax Object type
This commit is contained in:
parent
c2589b5c48
commit
536d94feb3
2 changed files with 16 additions and 0 deletions
|
@ -291,6 +291,14 @@ scheme.primitives["builtin-ref"] = function (idx) {
|
|||
return scheme.builtins[idx];
|
||||
};
|
||||
|
||||
// Syntax Objects
|
||||
scheme.Syntax = function (expr, wrap, module) {
|
||||
this.expr = expr;
|
||||
this.wrap = wrap;
|
||||
this.module = module;
|
||||
return this;
|
||||
};
|
||||
|
||||
// Modules
|
||||
scheme.primitives["define!"] = function(sym, obj) {
|
||||
var b = new scheme.Box(obj);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue