@@ -929,7 +929,7 @@ let add_axiom_or_variable api id ty local_bkind options state =
929
929
| None -> begin
930
930
Dumpglob. dump_definition name false " ax" ;
931
931
comAssumption_declare_axiom Vernacexpr. NoCoercion ~local: Locality. ImportDefaultBehavior ~kind (EConstr. to_constr sigma ty)
932
- ~univs ~impargs ~inline: options.inline ~name
932
+ ~univs ~impargs ~inline: options.inline ~name: id
933
933
end
934
934
in
935
935
let ucsts = match univs with UState. Monomorphic_entry x , _ -> x | _ -> Univ.ContextSet. empty in
@@ -2363,14 +2363,15 @@ denote the same x as before.|};
2363
2363
MLCode(Pred("coq.env.primitive-projection?" ,
2364
2364
InOut(B. ioarg projection , "Projection" ,
2365
2365
InOut(B. ioarg constant , "Compatibility constant" ,
2366
- Read(global , "Relates a primitive projection to its compatibility constant." ))),
2367
- (fun p c ~depth coq_context _ _ ->
2366
+ Out(int , "Index" ,
2367
+ Read(global , "Relates a primitive projection to its compatibility constant and its index in the record." )))),
2368
+ (fun p c _ ~depth coq_context _ _ ->
2368
2369
match p , c with
2369
2370
| _ , Data (Variable c ) -> raise No_clause
2370
2371
| Data p , Data (Constant c ) ->
2371
- if Constant. equal (Projection. constant p ) c then ?: None +? None else raise No_clause
2372
+ if Constant. equal (Projection. constant p ) c then ?: None +? None +! Names.Projection. ( arg p + npars p ) else raise No_clause
2372
2373
| NoData, NoData -> U. type_error "coq.env.primitive-projection?: got no input data"
2373
- | Data p , NoData -> ?: None +! (Constant (Projection. constant p ))
2374
+ | Data p , NoData -> ?: None +! (Constant (Projection. constant p )) +! Names.Projection. ( arg p + npars p )
2374
2375
| NoData, Data (Constant c ) ->
2375
2376
(match Environ. constant_opt_value_in coq_context .env (UVars. in_punivs c ) with
2376
2377
| None -> raise No_clause
@@ -2381,7 +2382,9 @@ denote the same x as before.|};
2381
2382
| App (hd , _ ) -> get_proj hd
2382
2383
| Proj (p , _ , _ ) -> p
2383
2384
| _ -> raise No_clause
2384
- in !: (get_proj p ) +? None))),
2385
+ in
2386
+ let p = get_proj p in
2387
+ !: p +? None +! Names.Projection. (arg p + npars p )))),
2385
2388
DocAbove);
2386
2389
2387
2390
LPDoc "-- Sorts (and their universe level, if applicable) ----------------" ;
0 commit comments