doc-src/IsarAdvanced/Codegen/Thy/examples/lookup.ML
author wenzelm
Wed, 29 Nov 2006 15:44:59 +0100
changeset 21592 8831206d7f41
parent 21452 f825e0b4d566
child 21993 4b802a9e0738
permissions -rw-r--r--
renamed SIMPLE_METHOD' to SIMPLE_METHOD''; added simple version of SIMPLE_METHOD';

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*)