Skip to content

Commit dbf0362

Browse files
committed
Include SymbolFlags.Function in couldContainTypeVariables check
1 parent 5ea8466 commit dbf0362

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/compiler/checker.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10239,7 +10239,7 @@ namespace ts {
1023910239
const objectFlags = getObjectFlags(type);
1024010240
return !!(type.flags & TypeFlags.TypeVariable ||
1024110241
objectFlags & ObjectFlags.Reference && forEach((<TypeReference>type).typeArguments, couldContainTypeVariables) ||
10242-
objectFlags & ObjectFlags.Anonymous && type.symbol && type.symbol.flags & (SymbolFlags.Method | SymbolFlags.TypeLiteral | SymbolFlags.Class) ||
10242+
objectFlags & ObjectFlags.Anonymous && type.symbol && type.symbol.flags & (SymbolFlags.Function | SymbolFlags.Method | SymbolFlags.TypeLiteral | SymbolFlags.Class) ||
1024310243
objectFlags & ObjectFlags.Mapped ||
1024410244
type.flags & TypeFlags.UnionOrIntersection && couldUnionOrIntersectionContainTypeVariables(<UnionOrIntersectionType>type));
1024510245
}

0 commit comments

Comments
 (0)