diff options
| author | Maxime Dénès | 2019-03-22 09:56:31 +0100 |
|---|---|---|
| committer | Maxime Dénès | 2019-03-22 09:56:31 +0100 |
| commit | 582d92dfd7a3f8fe5cb2bbf24c2f1e200a479053 (patch) | |
| tree | 3325a9a62906c081761ad147c9b2ed32efb61dc3 /test-suite | |
| parent | 96c9b16f03ef6898b575a0cc78470f0fa86fd2e4 (diff) | |
| parent | 565cefdb051339a601b9977e163ee4ffbba75274 (diff) | |
Merge PR #9602: [kernel] termination checking: backtrack on stuck case, fix, proj
Ack-by: gares
Reviewed-by: mattam82
Reviewed-by: maximedenes
Diffstat (limited to 'test-suite')
| -rw-r--r-- | test-suite/bugs/closed/bug_9598.v | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/test-suite/bugs/closed/bug_9598.v b/test-suite/bugs/closed/bug_9598.v new file mode 100644 index 0000000000..00bbfcf5d9 --- /dev/null +++ b/test-suite/bugs/closed/bug_9598.v @@ -0,0 +1,36 @@ +Module case. + + Inductive pair := K (n1 : nat) (n2 : nat). + Definition fst (p : pair) : nat := match p with K n _ => n end. + + Definition alias_K a b := K a b. + + Fixpoint rec (x : nat) : nat := fst (K 0 (rec x)). + Fixpoint rec_ko (x : nat) : nat := fst (alias_K 0 (rec_ko x)). + +End case. + +Module fixpoint. + + Inductive pair := K (n1 : nat) (n2 : nat). + Fixpoint fst (p : pair) : nat := match p with K n _ => n end. + + Definition alias_K a b := K a b. + + Fixpoint rec (x : nat) : nat := fst (K 0 (rec x)). + Fixpoint rec_ko (x : nat) : nat := fst (alias_K 0 (rec_ko x)). + +End fixpoint. + +Module primproj. + + Set Primitive Projections. + + Inductive pair := K { fst : nat; snd : nat }. + + Definition alias_K a b := K a b. + + Fixpoint rec (x : nat) : nat := fst (K 0 (rec x)). + Fixpoint rec_ko (x : nat) : nat := fst (alias_K 0 (rec_ko x)). + +End primproj. |
