Skip to content

Commit

Permalink
Revert PR 56161 (#57853)
Browse files Browse the repository at this point in the history
  • Loading branch information
jakebailey committed Mar 19, 2024
1 parent cc460dc commit 309fd3d
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 31 deletions.
2 changes: 1 addition & 1 deletion src/compiler/checker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45689,7 +45689,7 @@ export function createTypeChecker(host: TypeCheckerHost): TypeChecker {
}
else {
const text = getTextOfPropertyName(member.name);
if (isNumericLiteralName(text)) {
if (isNumericLiteralName(text) && !isInfinityOrNaNString(text)) {
error(member.name, Diagnostics.An_enum_member_cannot_have_a_numeric_name);
}
}
Expand Down
10 changes: 0 additions & 10 deletions tests/baselines/reference/enumWithInfinityProperty.errors.txt

This file was deleted.

10 changes: 0 additions & 10 deletions tests/baselines/reference/enumWithNaNProperty.errors.txt

This file was deleted.

This file was deleted.

0 comments on commit 309fd3d

Please sign in to comment.