mirror of
https://github.com/ProgramSnail/Lama.git
synced 2025-12-24 07:38:46 +00:00
Pre-parsing
This commit is contained in:
commit
b8fb21720c
1 changed files with 1 additions and 2 deletions
|
|
@ -44,7 +44,7 @@ let rec eval ((stack, ((st, i, o) as c)) as conf) = function
|
|||
Takes an input stream, a program, and returns an output stream this program calculates
|
||||
*)
|
||||
let run p i = let (_, (_, _, o)) = eval ([], (Expr.empty, i, [])) p in o
|
||||
|
||||
|
||||
(* Stack machine compiler
|
||||
|
||||
val compile : Language.Stmt.t -> prg
|
||||
|
|
@ -52,7 +52,6 @@ let run p i = let (_, (_, _, o)) = eval ([], (Expr.empty, i, [])) p in o
|
|||
Takes a program in the source language and returns an equivalent program for the
|
||||
stack machine
|
||||
*)
|
||||
|
||||
let rec compile =
|
||||
let rec expr = function
|
||||
| Expr.Var x -> [LD x]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue