Skip to content

Commit c797bd2

Browse files
authored
Skip asking for jsdoc in checkObjectLiteral for enums in TS (#53117)
1 parent a6ba2e7 commit c797bd2

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
@@ -29935,7 +29935,7 @@ export function createTypeChecker(host: TypeCheckerHost): TypeChecker {
2993529935
const inConstContext = isConstContext(node);
2993629936
const checkFlags = inConstContext ? CheckFlags.Readonly : 0;
2993729937
const isInJavascript = isInJSFile(node) && !isInJsonFile(node);
29938-
const enumTag = getJSDocEnumTag(node);
29938+
const enumTag = isInJavascript ? getJSDocEnumTag(node) : undefined;
2993929939
const isJSObjectLiteral = !contextualType && isInJavascript && !enumTag;
2994029940
let objectFlags: ObjectFlags = freshObjectLiteralFlag;
2994129941
let patternWithComputedProperties = false;

0 commit comments

Comments
 (0)