Skip to content

Commit 96d1573

Browse files
committed
move TypeVarDepth further up, so its declared before it's used
1 parent 10cf53b commit 96d1573

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

javascript/extractor/lib/typescript/src/type_table.ts

+7-7
Original file line numberDiff line numberDiff line change
@@ -1240,6 +1240,13 @@ export class TypeTable {
12401240
let indexOnStack = stack.length;
12411241
stack.push(id);
12421242

1243+
/** Indicates if a type contains no type variables, is a type variable, or strictly contains type variables. */
1244+
const enum TypeVarDepth {
1245+
noTypeVar = 0,
1246+
isTypeVar = 1,
1247+
containsTypeVar = 2,
1248+
}
1249+
12431250
for (let symbol of type.getProperties()) {
12441251
let propertyType = typeTable.tryGetTypeOfSymbol(symbol);
12451252
if (propertyType == null) continue;
@@ -1267,13 +1274,6 @@ export class TypeTable {
12671274

12681275
return lowlinkTable.get(id);
12691276

1270-
/** Indicates if a type contains no type variables, is a type variable, or strictly contains type variables. */
1271-
const enum TypeVarDepth {
1272-
noTypeVar = 0,
1273-
isTypeVar = 1,
1274-
containsTypeVar = 2,
1275-
}
1276-
12771277
function traverseType(type: ts.Type): TypeVarDepth {
12781278
if (isTypeVariable(type)) return TypeVarDepth.isTypeVar;
12791279
let depth = TypeVarDepth.noTypeVar;

0 commit comments

Comments
 (0)