File tree Expand file tree Collapse file tree 3 files changed +5
-4
lines changed Expand file tree Collapse file tree 3 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -3301,9 +3301,7 @@ namespace ts {
33013301 let transformFlags = subtreeFlags | TransformFlags . AssertESNext ;
33023302
33033303 // Decorators, TypeScript-specific modifiers, and type annotations are TypeScript syntax.
3304- if ( node . decorators
3305- || hasModifier ( node , ModifierFlags . TypeScriptModifier )
3306- || node . type ) {
3304+ if ( some ( node . decorators ) || hasModifier ( node , ModifierFlags . TypeScriptModifier ) || node . type ) {
33073305 transformFlags |= TransformFlags . AssertTypeScript ;
33083306 }
33093307
Original file line number Diff line number Diff line change @@ -327,6 +327,8 @@ namespace ts {
327327 return undefined ;
328328
329329 case SyntaxKind . PropertyDeclaration :
330+ // Property declarations are not TypeScript syntax, but they must be visited
331+ // for the decorator transformation.
330332 return visitPropertyDeclaration ( node as PropertyDeclaration ) ;
331333 case SyntaxKind . IndexSignature :
332334 case SyntaxKind . GetAccessor :
@@ -894,7 +896,6 @@ namespace ts {
894896 * Transforms the members of a class.
895897 *
896898 * @param node The current class.
897- * @param isDerivedClass A value indicating whether the class has an extends clause that does not extend 'null'.
898899 */
899900 function transformClassMembers ( node : ClassDeclaration | ClassExpression ) {
900901 const members : ClassElement [ ] = [ ] ;
Original file line number Diff line number Diff line change @@ -254,6 +254,8 @@ namespace ts {
254254 * Adds super call and preceding prologue directives into the list of statements.
255255 *
256256 * @param ctor The constructor node.
257+ * @param result The list of statements.
258+ * @param visitor The visitor to apply to each node added to the result array.
257259 * @returns index of the statement that follows super call
258260 */
259261 export function addPrologueDirectivesAndInitialSuperCall ( ctor : ConstructorDeclaration , result : Statement [ ] , visitor : Visitor ) : number {
You can’t perform that action at this time.
0 commit comments