summaryrefslogtreecommitdiff
path: root/test-suite/success/refine.v
diff options
context:
space:
mode:
Diffstat (limited to 'test-suite/success/refine.v')
-rw-r--r--test-suite/success/refine.v30
1 files changed, 30 insertions, 0 deletions
diff --git a/test-suite/success/refine.v b/test-suite/success/refine.v
index 4346ce9a..4b636618 100644
--- a/test-suite/success/refine.v
+++ b/test-suite/success/refine.v
@@ -87,3 +87,33 @@ refine
| exist _ _ => _
end).
Abort.
+
+
+(* Use to fail because sigma was not propagated to get_type_of *)
+(* Revealed by r9310, fixed in r9359 *)
+
+Goal
+ forall f : forall a (H:a=a), Prop,
+ (forall a (H:a = a :> nat), f a H -> True /\ True) ->
+ True.
+intros.
+refine (@proj1 _ _ (H 0 _ _)).
+Abort.
+
+(* Use to fail because let-in with metas in the body where rejected
+ because a priori considered as dependent *)
+
+Require Import Peano_dec.
+
+Definition fact_F :
+ forall (n:nat),
+ (forall m, m<n -> nat) ->
+ nat.
+refine
+ (fun n fact_rec =>
+ if eq_nat_dec n 0 then
+ 1
+ else
+ let fn := fact_rec (n-1) _ in
+ n * fn).
+Abort.