Remove redundant syntax type.
A method declaration serves perfectly well as a function-property-assignment in an object literal. Conflicts: src/services/syntax/SyntaxGenerator.js.map
This commit is contained in:
parent
e6ada5fb81
commit
7c0eb2679b
|
@ -619,15 +619,14 @@ var TypeScript;
|
|||
SyntaxKind[SyntaxKind["TemplateClause"] = 207] = "TemplateClause";
|
||||
SyntaxKind[SyntaxKind["TypeParameter"] = 208] = "TypeParameter";
|
||||
SyntaxKind[SyntaxKind["Constraint"] = 209] = "Constraint";
|
||||
SyntaxKind[SyntaxKind["SimplePropertyAssignment"] = 210] = "SimplePropertyAssignment";
|
||||
SyntaxKind[SyntaxKind["FunctionPropertyAssignment"] = 211] = "FunctionPropertyAssignment";
|
||||
SyntaxKind[SyntaxKind["Parameter"] = 212] = "Parameter";
|
||||
SyntaxKind[SyntaxKind["EnumElement"] = 213] = "EnumElement";
|
||||
SyntaxKind[SyntaxKind["TypeAnnotation"] = 214] = "TypeAnnotation";
|
||||
SyntaxKind[SyntaxKind["ExpressionBody"] = 215] = "ExpressionBody";
|
||||
SyntaxKind[SyntaxKind["ComputedPropertyName"] = 216] = "ComputedPropertyName";
|
||||
SyntaxKind[SyntaxKind["ExternalModuleReference"] = 217] = "ExternalModuleReference";
|
||||
SyntaxKind[SyntaxKind["ModuleNameModuleReference"] = 218] = "ModuleNameModuleReference";
|
||||
SyntaxKind[SyntaxKind["Parameter"] = 210] = "Parameter";
|
||||
SyntaxKind[SyntaxKind["EnumElement"] = 211] = "EnumElement";
|
||||
SyntaxKind[SyntaxKind["TypeAnnotation"] = 212] = "TypeAnnotation";
|
||||
SyntaxKind[SyntaxKind["ExpressionBody"] = 213] = "ExpressionBody";
|
||||
SyntaxKind[SyntaxKind["ComputedPropertyName"] = 214] = "ComputedPropertyName";
|
||||
SyntaxKind[SyntaxKind["SimplePropertyAssignment"] = 215] = "SimplePropertyAssignment";
|
||||
SyntaxKind[SyntaxKind["ExternalModuleReference"] = 216] = "ExternalModuleReference";
|
||||
SyntaxKind[SyntaxKind["ModuleNameModuleReference"] = 217] = "ModuleNameModuleReference";
|
||||
SyntaxKind[SyntaxKind["FirstStandardKeyword"] = SyntaxKind.BreakKeyword] = "FirstStandardKeyword";
|
||||
SyntaxKind[SyntaxKind["LastStandardKeyword"] = SyntaxKind.WithKeyword] = "LastStandardKeyword";
|
||||
SyntaxKind[SyntaxKind["FirstFutureReservedKeyword"] = SyntaxKind.ClassKeyword] = "FirstFutureReservedKeyword";
|
||||
|
@ -1512,7 +1511,7 @@ var definitions = [
|
|||
{
|
||||
name: 'MemberFunctionDeclarationSyntax',
|
||||
baseType: 'ISyntaxNode',
|
||||
interfaces: ['IMemberDeclarationSyntax'],
|
||||
interfaces: ['IMemberDeclarationSyntax', 'IPropertyAssignmentSyntax'],
|
||||
children: [
|
||||
{ name: 'modifiers', isList: true, elementType: 'ISyntaxToken' },
|
||||
{ name: 'asterixToken', isToken: true, isOptional: true },
|
||||
|
@ -1772,18 +1771,6 @@ var definitions = [
|
|||
{ name: 'expression', type: 'IExpressionSyntax' }
|
||||
]
|
||||
},
|
||||
{
|
||||
name: 'FunctionPropertyAssignmentSyntax',
|
||||
baseType: 'ISyntaxNode',
|
||||
interfaces: ['IPropertyAssignmentSyntax'],
|
||||
children: [
|
||||
{ name: 'asyncKeyword', isToken: true, isOptional: true },
|
||||
{ name: 'asterixToken', isToken: true, isOptional: true },
|
||||
{ name: 'propertyName', type: 'IPropertyNameSyntax' },
|
||||
{ name: 'callSignature', type: 'CallSignatureSyntax' },
|
||||
{ name: 'body', type: 'BlockSyntax | ExpressionBody | ISyntaxToken', isOptional: true }
|
||||
]
|
||||
},
|
||||
{
|
||||
name: 'FunctionExpressionSyntax',
|
||||
baseType: 'ISyntaxNode',
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -3620,7 +3620,8 @@ module TypeScript.Parser {
|
|||
// 'async' might start an asynchronous property, or it might just be the name
|
||||
// of a property.
|
||||
if (peekToken(1).kind === SyntaxKind.AsteriskToken || isPropertyName(/*peekIndex:*/ 1, inErrorRecovery)) {
|
||||
return parseFunctionPropertyAssignment(eatToken(SyntaxKind.AsyncKeyword), tryEatToken(SyntaxKind.AsteriskToken), parsePropertyName());
|
||||
return parseMemberFunctionDeclaration(
|
||||
Syntax.list([eatToken(SyntaxKind.AsyncKeyword)]), tryEatToken(SyntaxKind.AsteriskToken), parsePropertyName());
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -3657,7 +3658,7 @@ module TypeScript.Parser {
|
|||
var propertyName = parsePropertyName();
|
||||
|
||||
if (asterixToken !== undefined || isCallSignature(/*peekIndex:*/ 0)) {
|
||||
return parseFunctionPropertyAssignment(undefined, asterixToken, propertyName);
|
||||
return parseMemberFunctionDeclaration([], asterixToken, propertyName);
|
||||
}
|
||||
else {
|
||||
// PropertyName[?Yield] : AssignmentExpression[In, ?Yield]
|
||||
|
@ -3761,15 +3762,6 @@ module TypeScript.Parser {
|
|||
eatToken(SyntaxKind.CloseBracketToken));
|
||||
}
|
||||
|
||||
function parseFunctionPropertyAssignment(asyncKeyword: ISyntaxToken, asteriskToken: ISyntaxToken, propertyName: IPropertyNameSyntax): FunctionPropertyAssignmentSyntax {
|
||||
return new FunctionPropertyAssignmentSyntax(contextFlags,
|
||||
asyncKeyword,
|
||||
asteriskToken,
|
||||
propertyName,
|
||||
parseCallSignature(/*requireCompleteTypeParameterList:*/ false, /*yieldAndGeneratorParameterContext:*/ !!asteriskToken, !!asyncKeyword),
|
||||
parseFunctionBody(!!asteriskToken, !!asyncKeyword));
|
||||
}
|
||||
|
||||
function parseArrayLiteralExpression(openBracketToken: ISyntaxToken): ArrayLiteralExpressionSyntax {
|
||||
// Debug.assert(currentToken().kind === SyntaxKind.OpenBracketToken);
|
||||
return new ArrayLiteralExpressionSyntax(contextFlags,
|
||||
|
|
|
@ -938,13 +938,6 @@ module TypeScript.PrettyPrinter {
|
|||
visitNodeOrToken(this, node.expression);
|
||||
}
|
||||
|
||||
public visitFunctionPropertyAssignment(node: FunctionPropertyAssignmentSyntax): void {
|
||||
visitNodeOrToken(this, node.propertyName);
|
||||
visitNodeOrToken(this, node.callSignature);
|
||||
this.ensureSpace();
|
||||
visitNodeOrToken(this, node.body);
|
||||
}
|
||||
|
||||
public visitFunctionExpression(node: FunctionExpressionSyntax): void {
|
||||
this.appendToken(node.functionKeyword);
|
||||
|
||||
|
|
|
@ -653,7 +653,7 @@ var definitions:ITypeDefinition[] = [
|
|||
<any>{
|
||||
name: 'MemberFunctionDeclarationSyntax',
|
||||
baseType: 'ISyntaxNode',
|
||||
interfaces: ['IMemberDeclarationSyntax'],
|
||||
interfaces: ['IMemberDeclarationSyntax', 'IPropertyAssignmentSyntax'],
|
||||
children: [
|
||||
<any>{ name: 'modifiers', isList: true, elementType: 'ISyntaxToken' },
|
||||
<any>{ name: 'asterixToken', isToken: true, isOptional: true },
|
||||
|
@ -913,18 +913,6 @@ var definitions:ITypeDefinition[] = [
|
|||
<any>{ name: 'expression', type: 'IExpressionSyntax' }
|
||||
]
|
||||
},
|
||||
<any> {
|
||||
name: 'FunctionPropertyAssignmentSyntax',
|
||||
baseType: 'ISyntaxNode',
|
||||
interfaces: ['IPropertyAssignmentSyntax'],
|
||||
children: [
|
||||
<any>{ name: 'asyncKeyword', isToken: true, isOptional: true },
|
||||
<any>{ name: 'asterixToken', isToken: true, isOptional: true },
|
||||
<any>{ name: 'propertyName', type: 'IPropertyNameSyntax' },
|
||||
<any>{ name: 'callSignature', type: 'CallSignatureSyntax' },
|
||||
<any>{ name: 'body', type: 'BlockSyntax | ExpressionBody | ISyntaxToken', isOptional: true }
|
||||
]
|
||||
},
|
||||
<any>{
|
||||
name: 'FunctionExpressionSyntax',
|
||||
baseType: 'ISyntaxNode',
|
||||
|
|
|
@ -149,7 +149,7 @@ module TypeScript {
|
|||
}
|
||||
export interface ExportAssignmentConstructor { new (data: number, exportKeyword: ISyntaxToken, equalsToken: ISyntaxToken, identifier: ISyntaxToken, semicolonToken: ISyntaxToken): ExportAssignmentSyntax }
|
||||
|
||||
export interface MemberFunctionDeclarationSyntax extends ISyntaxNode, IMemberDeclarationSyntax {
|
||||
export interface MemberFunctionDeclarationSyntax extends ISyntaxNode, IMemberDeclarationSyntax, IPropertyAssignmentSyntax {
|
||||
modifiers: ISyntaxToken[];
|
||||
asterixToken: ISyntaxToken;
|
||||
propertyName: IPropertyNameSyntax;
|
||||
|
@ -649,22 +649,6 @@ module TypeScript {
|
|||
}
|
||||
export interface ConstraintConstructor { new (data: number, extendsKeyword: ISyntaxToken, typeOrExpression: ISyntaxNodeOrToken): ConstraintSyntax }
|
||||
|
||||
export interface SimplePropertyAssignmentSyntax extends ISyntaxNode, IPropertyAssignmentSyntax {
|
||||
propertyName: IPropertyNameSyntax;
|
||||
colonToken: ISyntaxToken;
|
||||
expression: IExpressionSyntax;
|
||||
}
|
||||
export interface SimplePropertyAssignmentConstructor { new (data: number, propertyName: IPropertyNameSyntax, colonToken: ISyntaxToken, expression: IExpressionSyntax): SimplePropertyAssignmentSyntax }
|
||||
|
||||
export interface FunctionPropertyAssignmentSyntax extends ISyntaxNode, IPropertyAssignmentSyntax {
|
||||
asyncKeyword: ISyntaxToken;
|
||||
asterixToken: ISyntaxToken;
|
||||
propertyName: IPropertyNameSyntax;
|
||||
callSignature: CallSignatureSyntax;
|
||||
body: BlockSyntax | ExpressionBody | ISyntaxToken;
|
||||
}
|
||||
export interface FunctionPropertyAssignmentConstructor { new (data: number, asyncKeyword: ISyntaxToken, asterixToken: ISyntaxToken, propertyName: IPropertyNameSyntax, callSignature: CallSignatureSyntax, body: BlockSyntax | ExpressionBody | ISyntaxToken): FunctionPropertyAssignmentSyntax }
|
||||
|
||||
export interface ParameterSyntax extends ISyntaxNode {
|
||||
dotDotDotToken: ISyntaxToken;
|
||||
modifiers: ISyntaxToken[];
|
||||
|
@ -700,6 +684,13 @@ module TypeScript {
|
|||
}
|
||||
export interface ComputedPropertyNameConstructor { new (data: number, openBracketToken: ISyntaxToken, expression: IExpressionSyntax, closeBracketToken: ISyntaxToken): ComputedPropertyNameSyntax }
|
||||
|
||||
export interface SimplePropertyAssignmentSyntax extends ISyntaxNode, IPropertyAssignmentSyntax {
|
||||
propertyName: IPropertyNameSyntax;
|
||||
colonToken: ISyntaxToken;
|
||||
expression: IExpressionSyntax;
|
||||
}
|
||||
export interface SimplePropertyAssignmentConstructor { new (data: number, propertyName: IPropertyNameSyntax, colonToken: ISyntaxToken, expression: IExpressionSyntax): SimplePropertyAssignmentSyntax }
|
||||
|
||||
export interface ExternalModuleReferenceSyntax extends ISyntaxNode, IModuleReferenceSyntax {
|
||||
requireKeyword: ISyntaxToken;
|
||||
openParenToken: ISyntaxToken;
|
||||
|
|
|
@ -263,16 +263,13 @@ module TypeScript {
|
|||
TypeParameter,
|
||||
Constraint,
|
||||
|
||||
// Property Assignment
|
||||
SimplePropertyAssignment,
|
||||
FunctionPropertyAssignment,
|
||||
|
||||
// Misc.
|
||||
Parameter,
|
||||
EnumElement,
|
||||
TypeAnnotation,
|
||||
ExpressionBody,
|
||||
ComputedPropertyName,
|
||||
SimplePropertyAssignment,
|
||||
ExternalModuleReference,
|
||||
ModuleNameModuleReference,
|
||||
|
||||
|
|
|
@ -1769,50 +1769,6 @@ module TypeScript {
|
|||
}
|
||||
}
|
||||
|
||||
export var SimplePropertyAssignmentSyntax: SimplePropertyAssignmentConstructor = <any>function(data: number, propertyName: IPropertyNameSyntax, colonToken: ISyntaxToken, expression: IExpressionSyntax) {
|
||||
if (data) { this.__data = data; }
|
||||
this.propertyName = propertyName,
|
||||
this.colonToken = colonToken,
|
||||
this.expression = expression,
|
||||
propertyName.parent = this,
|
||||
colonToken.parent = this,
|
||||
expression.parent = this;
|
||||
};
|
||||
SimplePropertyAssignmentSyntax.prototype.kind = SyntaxKind.SimplePropertyAssignment;
|
||||
SimplePropertyAssignmentSyntax.prototype.childCount = 3;
|
||||
SimplePropertyAssignmentSyntax.prototype.childAt = function(index: number): ISyntaxElement {
|
||||
switch (index) {
|
||||
case 0: return this.propertyName;
|
||||
case 1: return this.colonToken;
|
||||
case 2: return this.expression;
|
||||
}
|
||||
}
|
||||
|
||||
export var FunctionPropertyAssignmentSyntax: FunctionPropertyAssignmentConstructor = <any>function(data: number, asyncKeyword: ISyntaxToken, asterixToken: ISyntaxToken, propertyName: IPropertyNameSyntax, callSignature: CallSignatureSyntax, body: BlockSyntax | ExpressionBody | ISyntaxToken) {
|
||||
if (data) { this.__data = data; }
|
||||
this.asyncKeyword = asyncKeyword,
|
||||
this.asterixToken = asterixToken,
|
||||
this.propertyName = propertyName,
|
||||
this.callSignature = callSignature,
|
||||
this.body = body,
|
||||
asyncKeyword && (asyncKeyword.parent = this),
|
||||
asterixToken && (asterixToken.parent = this),
|
||||
propertyName.parent = this,
|
||||
callSignature.parent = this,
|
||||
body && (body.parent = this);
|
||||
};
|
||||
FunctionPropertyAssignmentSyntax.prototype.kind = SyntaxKind.FunctionPropertyAssignment;
|
||||
FunctionPropertyAssignmentSyntax.prototype.childCount = 5;
|
||||
FunctionPropertyAssignmentSyntax.prototype.childAt = function(index: number): ISyntaxElement {
|
||||
switch (index) {
|
||||
case 0: return this.asyncKeyword;
|
||||
case 1: return this.asterixToken;
|
||||
case 2: return this.propertyName;
|
||||
case 3: return this.callSignature;
|
||||
case 4: return this.body;
|
||||
}
|
||||
}
|
||||
|
||||
export var ParameterSyntax: ParameterConstructor = <any>function(data: number, dotDotDotToken: ISyntaxToken, modifiers: ISyntaxToken[], identifier: ISyntaxToken, questionToken: ISyntaxToken, typeAnnotation: TypeAnnotationSyntax, equalsValueClause: EqualsValueClauseSyntax) {
|
||||
if (data) { this.__data = data; }
|
||||
this.dotDotDotToken = dotDotDotToken,
|
||||
|
@ -1908,6 +1864,25 @@ module TypeScript {
|
|||
}
|
||||
}
|
||||
|
||||
export var SimplePropertyAssignmentSyntax: SimplePropertyAssignmentConstructor = <any>function(data: number, propertyName: IPropertyNameSyntax, colonToken: ISyntaxToken, expression: IExpressionSyntax) {
|
||||
if (data) { this.__data = data; }
|
||||
this.propertyName = propertyName,
|
||||
this.colonToken = colonToken,
|
||||
this.expression = expression,
|
||||
propertyName.parent = this,
|
||||
colonToken.parent = this,
|
||||
expression.parent = this;
|
||||
};
|
||||
SimplePropertyAssignmentSyntax.prototype.kind = SyntaxKind.SimplePropertyAssignment;
|
||||
SimplePropertyAssignmentSyntax.prototype.childCount = 3;
|
||||
SimplePropertyAssignmentSyntax.prototype.childAt = function(index: number): ISyntaxElement {
|
||||
switch (index) {
|
||||
case 0: return this.propertyName;
|
||||
case 1: return this.colonToken;
|
||||
case 2: return this.expression;
|
||||
}
|
||||
}
|
||||
|
||||
export var ExternalModuleReferenceSyntax: ExternalModuleReferenceConstructor = <any>function(data: number, requireKeyword: ISyntaxToken, openParenToken: ISyntaxToken, stringLiteral: ISyntaxToken, closeParenToken: ISyntaxToken) {
|
||||
if (data) { this.__data = data; }
|
||||
this.requireKeyword = requireKeyword,
|
||||
|
|
|
@ -580,15 +580,43 @@ module TypeScript {
|
|||
}
|
||||
|
||||
public visitMemberFunctionDeclaration(node: MemberFunctionDeclarationSyntax): void {
|
||||
if (this.checkClassElementModifiers(node.modifiers) ||
|
||||
this.checkForDisallowedTemplatePropertyName(node.propertyName) ||
|
||||
if (node.parent && node.parent.parent &&
|
||||
node.parent.kind === SyntaxKind.List && node.parent.parent.kind === SyntaxKind.ObjectLiteralExpression) {
|
||||
|
||||
// Method in an object literal.
|
||||
if (this.checkForSemicolonInsteadOfBlock(node, node.body) ||
|
||||
this.checkForDisallowedObjectLiteralMethod(node.modifiers)) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
else {
|
||||
// Method in a class literal.
|
||||
if (this.checkClassElementModifiers(node.modifiers)) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
// Object literal or class method.
|
||||
if (this.checkForDisallowedTemplatePropertyName(node.propertyName) ||
|
||||
this.checkForAsyncGenerator(this.getAsyncModifier(node.modifiers), node.asterixToken)) {
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
super.visitMemberFunctionDeclaration(node);
|
||||
}
|
||||
|
||||
private checkForDisallowedObjectLiteralMethod(modifiers: ISyntaxToken[]): boolean {
|
||||
for (var i = 0, n = modifiers.length; i < n; i++) {
|
||||
var modifier = modifiers[i];
|
||||
if (modifier.kind !== SyntaxKind.AsyncKeyword) {
|
||||
return this.pushDiagnostic(modifier, DiagnosticCode.Modifiers_cannot_appear_here);
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
private checkGetAccessorParameter(node: GetAccessorSyntax): boolean {
|
||||
if (node.callSignature.parameterList.parameters.length !== 0) {
|
||||
this.pushDiagnostic(node.propertyName, DiagnosticCode.get_accessor_cannot_have_parameters);
|
||||
|
@ -1490,16 +1518,6 @@ module TypeScript {
|
|||
super.visitFunctionExpression(node);
|
||||
}
|
||||
|
||||
public visitFunctionPropertyAssignment(node: FunctionPropertyAssignmentSyntax): void {
|
||||
if (this.checkForDisallowedTemplatePropertyName(node.propertyName) ||
|
||||
this.checkForSemicolonInsteadOfBlock(node, node.body) ||
|
||||
this.checkForAsyncGenerator(node.asyncKeyword, node.asterixToken)) {
|
||||
return;
|
||||
}
|
||||
|
||||
super.visitFunctionPropertyAssignment(node);
|
||||
}
|
||||
|
||||
public visitVariableStatement(node: VariableStatementSyntax): void {
|
||||
if (this.checkForDisallowedDeclareModifier(node.modifiers) ||
|
||||
this.checkForDisallowedModifiers(node.modifiers) ||
|
||||
|
|
|
@ -19,7 +19,6 @@ module TypeScript {
|
|||
case SyntaxKind.FunctionExpression:
|
||||
case SyntaxKind.FunctionDeclaration:
|
||||
case SyntaxKind.MemberFunctionDeclaration:
|
||||
case SyntaxKind.FunctionPropertyAssignment:
|
||||
case SyntaxKind.ConstructorDeclaration:
|
||||
case SyntaxKind.GetAccessor:
|
||||
case SyntaxKind.SetAccessor:
|
||||
|
|
|
@ -90,13 +90,12 @@ module TypeScript {
|
|||
case SyntaxKind.TemplateClause: return visitor.visitTemplateClause(<TemplateClauseSyntax>element);
|
||||
case SyntaxKind.TypeParameter: return visitor.visitTypeParameter(<TypeParameterSyntax>element);
|
||||
case SyntaxKind.Constraint: return visitor.visitConstraint(<ConstraintSyntax>element);
|
||||
case SyntaxKind.SimplePropertyAssignment: return visitor.visitSimplePropertyAssignment(<SimplePropertyAssignmentSyntax>element);
|
||||
case SyntaxKind.FunctionPropertyAssignment: return visitor.visitFunctionPropertyAssignment(<FunctionPropertyAssignmentSyntax>element);
|
||||
case SyntaxKind.Parameter: return visitor.visitParameter(<ParameterSyntax>element);
|
||||
case SyntaxKind.EnumElement: return visitor.visitEnumElement(<EnumElementSyntax>element);
|
||||
case SyntaxKind.TypeAnnotation: return visitor.visitTypeAnnotation(<TypeAnnotationSyntax>element);
|
||||
case SyntaxKind.ExpressionBody: return visitor.visitExpressionBody(<ExpressionBody>element);
|
||||
case SyntaxKind.ComputedPropertyName: return visitor.visitComputedPropertyName(<ComputedPropertyNameSyntax>element);
|
||||
case SyntaxKind.SimplePropertyAssignment: return visitor.visitSimplePropertyAssignment(<SimplePropertyAssignmentSyntax>element);
|
||||
case SyntaxKind.ExternalModuleReference: return visitor.visitExternalModuleReference(<ExternalModuleReferenceSyntax>element);
|
||||
case SyntaxKind.ModuleNameModuleReference: return visitor.visitModuleNameModuleReference(<ModuleNameModuleReferenceSyntax>element);
|
||||
default: return visitor.visitToken(<ISyntaxToken>element);
|
||||
|
@ -191,13 +190,12 @@ module TypeScript {
|
|||
visitTemplateClause(node: TemplateClauseSyntax): any;
|
||||
visitTypeParameter(node: TypeParameterSyntax): any;
|
||||
visitConstraint(node: ConstraintSyntax): any;
|
||||
visitSimplePropertyAssignment(node: SimplePropertyAssignmentSyntax): any;
|
||||
visitFunctionPropertyAssignment(node: FunctionPropertyAssignmentSyntax): any;
|
||||
visitParameter(node: ParameterSyntax): any;
|
||||
visitEnumElement(node: EnumElementSyntax): any;
|
||||
visitTypeAnnotation(node: TypeAnnotationSyntax): any;
|
||||
visitExpressionBody(node: ExpressionBody): any;
|
||||
visitComputedPropertyName(node: ComputedPropertyNameSyntax): any;
|
||||
visitSimplePropertyAssignment(node: SimplePropertyAssignmentSyntax): any;
|
||||
visitExternalModuleReference(node: ExternalModuleReferenceSyntax): any;
|
||||
visitModuleNameModuleReference(node: ModuleNameModuleReferenceSyntax): any;
|
||||
}
|
||||
|
|
|
@ -580,20 +580,6 @@ module TypeScript {
|
|||
visitNodeOrToken(this, node.typeOrExpression);
|
||||
}
|
||||
|
||||
public visitSimplePropertyAssignment(node: SimplePropertyAssignmentSyntax): void {
|
||||
visitNodeOrToken(this, node.propertyName);
|
||||
this.visitToken(node.colonToken);
|
||||
visitNodeOrToken(this, node.expression);
|
||||
}
|
||||
|
||||
public visitFunctionPropertyAssignment(node: FunctionPropertyAssignmentSyntax): void {
|
||||
this.visitOptionalToken(node.asyncKeyword);
|
||||
this.visitOptionalToken(node.asterixToken);
|
||||
visitNodeOrToken(this, node.propertyName);
|
||||
visitNodeOrToken(this, node.callSignature);
|
||||
visitNodeOrToken(this, node.body);
|
||||
}
|
||||
|
||||
public visitParameter(node: ParameterSyntax): void {
|
||||
this.visitOptionalToken(node.dotDotDotToken);
|
||||
this.visitList(node.modifiers);
|
||||
|
@ -624,6 +610,12 @@ module TypeScript {
|
|||
this.visitToken(node.closeBracketToken);
|
||||
}
|
||||
|
||||
public visitSimplePropertyAssignment(node: SimplePropertyAssignmentSyntax): void {
|
||||
visitNodeOrToken(this, node.propertyName);
|
||||
this.visitToken(node.colonToken);
|
||||
visitNodeOrToken(this, node.expression);
|
||||
}
|
||||
|
||||
public visitExternalModuleReference(node: ExternalModuleReferenceSyntax): void {
|
||||
this.visitToken(node.requireKeyword);
|
||||
this.visitToken(node.openParenToken);
|
||||
|
|
Loading…
Reference in a new issue