diff --git a/packages/boringlang/src/types/context.ts b/packages/boringlang/src/types/context.ts index 0fb2717..49817fa 100644 --- a/packages/boringlang/src/types/context.ts +++ b/packages/boringlang/src/types/context.ts @@ -24,7 +24,7 @@ export interface Context { environment: Record; } -export function getAttr(ctx: Context, name: string, field: string) { +export function getAttr(ctx: Context, name: string, field: string): TypeUsage { const struct = ctx.environment[name]; if (!struct || struct.namedEntity !== "NamedType") { throw Error(`Unknown type ${name}`);