From 219142140c256c9d6fb277d5d9f3be32666adbca Mon Sep 17 00:00:00 2001 From: Chris Wanstrath Date: Sun, 26 Oct 2025 22:32:07 -0700 Subject: [PATCH] compile dot number too --- src/compiler/utils.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/compiler/utils.ts b/src/compiler/utils.ts index cbdd1bc..bcf0587 100644 --- a/src/compiler/utils.ts +++ b/src/compiler/utils.ts @@ -219,9 +219,9 @@ export const getDotGetParts = (node: SyntaxNode, input: string) => { ) } - if (property.type.id !== terms.Identifier) { + if (property.type.id !== terms.Identifier && property.type.id !== terms.Number) { throw new CompilerError( - `DotGet property must be an Identifier, got ${property.type.name}`, + `DotGet property must be an Identifier or Number, got ${property.type.name}`, property.from, property.to )