declare some properties in the node constructor so that they're copied in clone

This commit is contained in:
Mihai Bazon
2012-08-21 20:06:57 +03:00
parent 1b839eb35b
commit fb8c9e3a48
4 changed files with 25 additions and 20 deletions

View File

@@ -157,7 +157,7 @@ var AST_With = DEFNODE("With", "expression", {
/* -----[ scope and functions ]----- */
var AST_Scope = DEFNODE("Scope", null, {
var AST_Scope = DEFNODE("Scope", "variables functions uses_with uses_eval parent_scope enclosed cname", {
$documentation: "Base class for all statements introducing a lexical scope"
}, AST_BlockStatement);
@@ -165,7 +165,7 @@ var AST_Toplevel = DEFNODE("Toplevel", null, {
$documentation: "The toplevel scope"
}, AST_Scope);
var AST_Lambda = DEFNODE("Lambda", "name argnames", {
var AST_Lambda = DEFNODE("Lambda", "name argnames uses_arguments", {
$documentation: "Base class for functions",
_walk: function(visitor) {
return visitor._visit(this, function(){
@@ -470,10 +470,10 @@ var AST_ObjectSetter = DEFNODE("ObjectSetter", null, {
var AST_ObjectGetter = DEFNODE("ObjectGetter", null, {
}, AST_ObjectProperty);
var AST_Symbol = DEFNODE("Symbol", "scope name", {
var AST_Symbol = DEFNODE("Symbol", "scope name global undeclared", {
});
var AST_SymbolDeclaration = DEFNODE("SymbolDeclaration", null, {
var AST_SymbolDeclaration = DEFNODE("SymbolDeclaration", "references", {
}, AST_Symbol);
var AST_SymbolVar = DEFNODE("SymbolVar", null, {