1 (**************************************************************************)
4 (* ||A|| A project by Andrea Asperti *)
6 (* ||I|| Developers: *)
7 (* ||T|| The HELM team. *)
8 (* ||A|| http://helm.cs.unibo.it *)
10 (* \ / This file is distributed under the terms of the *)
11 (* v GNU General Public License Version 2 *)
13 (**************************************************************************)
15 include "basic_2/static/aaa_lift.ma".
16 include "basic_2/static/ssta.ma".
18 (* STRATIFIED STATIC TYPE ASSIGNMENT ON TERMS *******************************)
20 (* Properties on atomic arity assignment for terms **************************)
22 lemma ssta_aaa: ∀h,g,G,L,T,A. ⦃G, L⦄ ⊢ T ⁝ A → ∀U,l. ⦃G, L⦄ ⊢ T •[h, g] ⦃l, U⦄ → ⦃G, L⦄ ⊢ U ⁝ A.
23 #h #g #G #L #T #A #H elim H -G -L -T -A
25 elim (ssta_inv_sort1 … H) -H #_ #H destruct //
26 | #I #G #L #K #V #B #i #HLK #HV #IHV #U #l #H
27 elim (ssta_inv_lref1 … H) -H * #K0 #V0 #W0 [2: #l0 ] #HLK0 #HVW0 #HU [ #H ]
28 lapply (ldrop_mono … HLK0 … HLK) -HLK0 #H0 destruct
29 lapply (ldrop_fwd_ldrop2 … HLK) -HLK #HLK
30 @(aaa_lift … HLK … HU) -HU -L // -HV /2 width=2/
31 | #a #G #L #V #T #B #A #HV #_ #_ #IHT #X #l #H
32 elim (ssta_inv_bind1 … H) -H #U #HTU #H destruct /3 width=2/
33 | #a #G #L #V #T #B #A #HV #_ #_ #IHT #X #l #H
34 elim (ssta_inv_bind1 … H) -H #U #HTU #H destruct /3 width=2/
35 | #G #L #V #T #B #A #HV #_ #_ #IHT #X #l #H
36 elim (ssta_inv_appl1 … H) -H #U #HTU #H destruct /3 width=3/
37 | #G #L #V #T #A #_ #_ #IHV #IHT #X #l #H
38 lapply (ssta_inv_cast1 … H) -H /2 width=2/