equal
deleted
inserted
replaced
11 val add_judgment_i: bstring * typ * mixfix -> theory -> theory |
11 val add_judgment_i: bstring * typ * mixfix -> theory -> theory |
12 val judgment_name: theory -> string |
12 val judgment_name: theory -> string |
13 val is_judgment: theory -> term -> bool |
13 val is_judgment: theory -> term -> bool |
14 val drop_judgment: theory -> term -> term |
14 val drop_judgment: theory -> term -> term |
15 val fixed_judgment: theory -> string -> term |
15 val fixed_judgment: theory -> string -> term |
16 val assert_propT: theory -> term -> term |
16 val ensure_propT: theory -> term -> term |
17 val declare_atomize: theory attribute |
17 val declare_atomize: theory attribute |
18 val declare_rulify: theory attribute |
18 val declare_rulify: theory attribute |
19 val atomize_term: theory -> term -> term |
19 val atomize_term: theory -> term -> term |
20 val atomize_cterm: theory -> cterm -> thm |
20 val atomize_cterm: theory -> cterm -> thm |
21 val atomize_thm: thm -> thm |
21 val atomize_thm: thm -> thm |
108 if_none (Sign.const_type thy c) (aT --> propT) |
108 if_none (Sign.const_type thy c) (aT --> propT) |
109 |> Term.map_type_tvar (fn ((x, _), S) => TFree (x, S)); |
109 |> Term.map_type_tvar (fn ((x, _), S) => TFree (x, S)); |
110 val U = Term.domain_type T handle Match => aT; |
110 val U = Term.domain_type T handle Match => aT; |
111 in Const (c, T) $ Free (x, U) end; |
111 in Const (c, T) $ Free (x, U) end; |
112 |
112 |
113 fun assert_propT thy t = |
113 fun ensure_propT thy t = |
114 let val T = Term.fastype_of t |
114 let val T = Term.fastype_of t |
115 in if T = propT then t else Const (judgment_name thy, T --> propT) $ t end; |
115 in if T = propT then t else Const (judgment_name thy, T --> propT) $ t end; |
116 |
116 |
117 |
117 |
118 |
118 |