doc-src/IsarAdvanced/Codegen/Thy/examples/lookup.ML
author wenzelm
Fri, 19 Jan 2007 22:10:35 +0100
changeset 22124 27b674312b2f
parent 21994 dfa5133dbe73
permissions -rw-r--r--
renamed Isar/isar_output.ML to Thy/thy_output.ML; tuned messages; Antiquote.scan_arguments (moved from here); moved ML context stuff to from Context to ML_Context;

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