equal
deleted
inserted
replaced
289 "wfrec" ("\<module>wfrec?") |
289 "wfrec" ("\<module>wfrec?") |
290 attach {* |
290 attach {* |
291 fun wfrec f x = f (wfrec f) x; |
291 fun wfrec f x = f (wfrec f) x; |
292 *} |
292 *} |
293 |
293 |
294 setup {* |
|
295 CodegenPackage.add_appconst ("Wellfounded_Recursion.wfrec", CodegenPackage.appgen_wfrec) |
|
296 *} |
|
297 |
|
298 code_const wfrec |
|
299 (SML target_atom "(let fun wfrec f x = f (wfrec f) x in wfrec end)") |
|
300 (Haskell target_atom "(let wfrec f x = f (wfrec f) x in wfrec)") |
|
301 |
294 |
302 subsection{*Variants for TFL: the Recdef Package*} |
295 subsection{*Variants for TFL: the Recdef Package*} |
303 |
296 |
304 lemma tfl_wf_induct: "ALL R. wf R --> |
297 lemma tfl_wf_induct: "ALL R. wf R --> |
305 (ALL P. (ALL x. (ALL y. (y,x):R --> P y) --> P x) --> (ALL x. P x))" |
298 (ALL P. (ALL x. (ALL y. (y,x):R --> P y) --> P x) --> (ALL x. P x))" |