deleting interpreter now that we have compiler
This commit is contained in:
parent
60c8f74d50
commit
6f7f06b748
12 changed files with 19 additions and 1677 deletions
|
|
@ -1,10 +1,13 @@
|
|||
import type { Value } from './types';
|
||||
type LiteralValue =
|
||||
| { kind: 'int', value: number }
|
||||
| { kind: 'float', value: number }
|
||||
| { kind: 'string', value: string };
|
||||
|
||||
// Literals and Variables
|
||||
|
||||
export type Literal = {
|
||||
kind: 'literal'
|
||||
value: Value
|
||||
value: LiteralValue
|
||||
line?: number
|
||||
column?: number
|
||||
start?: number
|
||||
|
|
@ -198,8 +201,6 @@ export function prettyPrint(ast: AST, indent = 0): string {
|
|||
return `${i}${val.value}`;
|
||||
case 'string':
|
||||
return `${i}"${val.value}"`;
|
||||
default:
|
||||
return `${i}${val.kind}`;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue