equal
deleted
inserted
replaced
39 (Attrib.binding * (thm list * Args.src list) list) list -> |
39 (Attrib.binding * (thm list * Args.src list) list) list -> |
40 local_theory -> local_theory |
40 local_theory -> local_theory |
41 val theory_abbrev: Syntax.mode -> (binding * mixfix) -> term * term -> term list -> |
41 val theory_abbrev: Syntax.mode -> (binding * mixfix) -> term * term -> term list -> |
42 local_theory -> local_theory |
42 local_theory -> local_theory |
43 val theory_declaration: declaration -> local_theory -> local_theory |
43 val theory_declaration: declaration -> local_theory -> local_theory |
|
44 val theory_registration: string * morphism -> (morphism * bool) option -> morphism -> |
|
45 local_theory -> local_theory |
|
46 val locale_dependency: string -> string * morphism -> (morphism * bool) option -> morphism -> |
|
47 local_theory -> local_theory |
44 end |
48 end |
45 |
49 |
46 structure Generic_Target: GENERIC_TARGET = |
50 structure Generic_Target: GENERIC_TARGET = |
47 struct |
51 struct |
48 |
52 |
269 val rhs' = Morphism.term phi rhs; |
273 val rhs' = Morphism.term phi rhs; |
270 val same_shape = Term.aconv_untyped (rhs, rhs'); |
274 val same_shape = Term.aconv_untyped (rhs, rhs'); |
271 in generic_const same_shape prmode ((b', mx), rhs') end); |
275 in generic_const same_shape prmode ((b', mx), rhs') end); |
272 |
276 |
273 |
277 |
|
278 (* registrations and dependencies *) |
|
279 |
|
280 val theory_registration = |
|
281 Local_Theory.raw_theory o Context.theory_map ooo Locale.add_registration; |
|
282 |
|
283 fun locale_dependency locale dep_morph mixin export = |
|
284 (Local_Theory.raw_theory ooo Locale.add_dependency locale) dep_morph mixin export |
|
285 #> Local_Theory.activate_nonbrittle dep_morph mixin export; |
|
286 |
|
287 |
274 |
288 |
275 (** primitive theory operations **) |
289 (** primitive theory operations **) |
276 |
290 |
277 fun background_foundation (((b, U), mx), (b_def, rhs)) (type_params, term_params) lthy = |
291 fun background_foundation (((b, U), mx), (b_def, rhs)) (type_params, term_params) lthy = |
278 let |
292 let |