doc-src/Codegen/Thy/examples/lookup.ML
author wenzelm
Tue, 05 Apr 2011 14:30:40 +0200
changeset 42225 cf48af306290
parent 30226 2f4684e2ea95
permissions -rw-r--r--
discontinued special treatment of structure Parser -- directly accessible;

structure ROOT = 
struct

structure Codegen = 
struct

fun lookup ((k, v) :: xs) l =
  (if ((k : string) = l) then SOME v else lookup xs l)
  | lookup [] l = NONE;

end; (*struct Codegen*)

end; (*struct ROOT*)