Skip to content

Interface: GvError

Defined in: errors.ts:33

Structured error contract shared by every error source.

Properties

code

ts
code: GvErrorCode;

Defined in: errors.ts:36

Stable i18n key.


expected?

ts
optional expected?: Expectation[];

Defined in: errors.ts:44

Peggy's discriminated union, passed through unmapped; SYNTAX_* only.


friendlyMessage

ts
friendlyMessage: string;

Defined in: errors.ts:40

Approachable, non-localized English (delivery).


location?

ts
optional location?: {
  column: number;
  line: number;
  offset?: number;
};

Defined in: errors.ts:42

Real error position; the highest-value field.

column

ts
column: number;

line

ts
line: number;

offset?

ts
optional offset?: number;

message

ts
message: string;

Defined in: errors.ts:38

Concise technical text we own (may diverge from C).


type

ts
type: GvErrorType;

Defined in: errors.ts:34