Remove AST_ObjectComputedKeyVal
This commit is contained in:
committed by
Richard van Velzen
parent
b7bb706150
commit
7e80a979a7
@@ -1508,7 +1508,13 @@ function OutputStream(options) {
|
||||
) {
|
||||
self.print_property_name(self.key, self.quote, output);
|
||||
} else {
|
||||
self.print_property_name(self.key, self.quote, output);
|
||||
if (!(self.key instanceof AST_Node) || self.key instanceof AST_Symbol) {
|
||||
self.print_property_name(self.key, self.quote, output);
|
||||
} else {
|
||||
output.with_square(function() {
|
||||
self.key.print(output);
|
||||
});
|
||||
}
|
||||
output.colon();
|
||||
self.value.print(output);
|
||||
}
|
||||
@@ -1559,19 +1565,6 @@ function OutputStream(options) {
|
||||
}
|
||||
self.value._do_print(output, true);
|
||||
});
|
||||
DEFPRINT(AST_ObjectComputedKeyVal, function(self, output) {
|
||||
output.print("[");
|
||||
self.key.print(output);
|
||||
output.print("]:");
|
||||
output.space();
|
||||
self.value.print(output);
|
||||
if (self.default) {
|
||||
output.space();
|
||||
output.print('=');
|
||||
output.space();
|
||||
self.default.print(output);
|
||||
}
|
||||
});
|
||||
AST_Symbol.DEFMETHOD("_do_print", function(output){
|
||||
var def = this.definition();
|
||||
output.print_name(def ? def.mangled_name || def.name : this.name);
|
||||
|
||||
Reference in New Issue
Block a user