You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Check using "super" before "this" lexically instead of using the
NodeCheckFlags
Remove "type-checking" way of checking if super is used before this.
Instead check using whether super occurs before this syntactically
Refactor the code
Dive down to get super call
Copy file name to clipboardExpand all lines: src/compiler/types.ts
+3-3Lines changed: 3 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -2068,9 +2068,8 @@ namespace ts {
2068
2068
LoopWithCapturedBlockScopedBinding=0x00010000,// Loop that contains block scoped variable captured in closure
2069
2069
CapturedBlockScopedBinding=0x00020000,// Block-scoped binding that is captured in some function
2070
2070
BlockScopedBindingInLoop=0x00040000,// Block-scoped binding with declaration nested inside iteration statement
2071
-
HasSeenSuperCall=0x00080000,// Set during the binding when encounter 'super'
2072
-
ClassWithBodyScopedClassBinding=0x00100000,// Decorated class that contains a binding to itself inside of the class body.
2073
-
BodyScopedClassBinding=0x00200000,// Binding to a decorated class inside of the class's body.
2071
+
ClassWithBodyScopedClassBinding=0x0080000,// Decorated class that contains a binding to itself inside of the class body.
2072
+
BodyScopedClassBinding=0x00100000,// Binding to a decorated class inside of the class's body.
2074
2073
}
2075
2074
2076
2075
/* @internal */
@@ -2089,6 +2088,7 @@ namespace ts {
2089
2088
importOnRightSide?: Symbol;// for import declarations - import that appear on the right side
2090
2089
jsxFlags?: JsxFlags;// flags for knowning what kind of element/attributes we're dealing with
2091
2090
resolvedJsxType?: Type;// resolved element attributes type of a JSX openinglike element
2091
+
superStatement?: ExpressionStatement;// Cached super-statement found in the constructor. Used in checking whether super is called before this-accessing
0 commit comments