1
0
mirror of https://github.com/sehugg/8bitworkshop.git synced 2026-03-14 17:16:35 +00:00

moved SourceLocated to workertypes

This commit is contained in:
Steven Hugg
2022-01-29 13:07:21 -06:00
parent 9b6f797451
commit ce21eb29e5
4 changed files with 38 additions and 35 deletions

View File

@@ -1,4 +1,4 @@
import { WorkerError, CodeListingMap, SourceLocation, SourceLine } from "../workertypes";
import { WorkerError, CodeListingMap, SourceLocation, SourceLine, SourceLocated, SourceLineLocated } from "../workertypes";
export interface BASICOptions {
dialectName : string; // use this to select the dialect
@@ -50,15 +50,6 @@ export interface BASICOptions {
maxArrayElements? : number; // max array elements (all dimensions)
}
// objects that have source code position info
export interface SourceLocated {
$loc?: SourceLocation;
}
// statements also have the 'offset' (pc) field from SourceLine
export interface SourceLineLocated {
$loc?: SourceLine;
}
export class CompileError extends Error {
$loc : SourceLocation;
constructor(msg: string, loc: SourceLocation) {