-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Think I found a good way to handle checking for valid programs.
A number of the tokens require specific conditions (ie: tanh requires 1 token on the stack, + requires 2 tokesn on the stack), and yield a certain change (+ pops 2, pushes 1, tanh pops 1 pushes 1, a constant pushes 1). Using this, I can validate that the stack is syntactically correct, and more importantly, used all the tokens in the stack (ends with 1).
Metadata
Metadata
Assignees
Labels
No labels