types.ml 424 B

1234567891011121314151617
  1. type ins =
  2. | Basic of char (* a *)
  3. | Terminate (* ! *)
  4. | Ptest of char (* +a *)
  5. | Ntest of char (* -a *)
  6. | Jump of int (* #1 *)
  7. | Concat of ins list (* a;b *)
  8. | Repeat of ins * int (* a2 : execute a twice *)
  9. | Loop of ins (* a* : repeat a infinitely *)
  10. | Program of char (* X *)
  11. | Empty
  12. type program = ins list
  13. exception FatalError of string