tricu

An interpreted language for exploring Tree Calculus
Log | Files | Refs | README | LICENSE

interaction-inspection.tri (398B)


      1 -- A materialized IO tree for read-only bundle inspection. Compiling and
      2 -- inspecting this module does not read settings.txt. Running it with --io does.
      3 !export main
      4 !export afterRead
      5 
      6 pure value = t 0 value
      7 bind action resume = t 1 (t action resume)
      8 readFile path = t 20 path
      9 io action = t "tricuIO" (t 1 action)
     10 
     11 afterRead reply = pure reply
     12 main = io (bind (readFile "settings.txt") afterRead)