Skip to content

Commit 2685a67

Browse files
committed
fix force lazy
1 parent a34ab40 commit 2685a67

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/compiler/checker.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2429,7 +2429,11 @@ export function createTypeChecker(host: TypeCheckerHost): TypeChecker {
24292429
}
24302430
function unionIfLazy(_paramType: Type) {
24312431
const isLazy = isLazyParameterByType(_paramType);
2432-
const paramType = isLazy ? getUnionType([_paramType, (_paramType as TypeReference).resolvedTypeArguments![0]], UnionReduction.None) : _paramType;
2432+
const paramType = isLazy
2433+
? getUnionType([_paramType, (_paramType as TypeReference).resolvedTypeArguments![0]], UnionReduction.None)
2434+
: isForceLazyParameterByType(_paramType)
2435+
? (_paramType as TypeReference).resolvedTypeArguments![0]
2436+
: _paramType;
24332437
return paramType
24342438
}
24352439
function getFluentExtension(targetType: Type, name: string): Type | undefined {

0 commit comments

Comments
 (0)