From dba2ae9fa1eb01d795d36b209aee6045967ba00a Mon Sep 17 00:00:00 2001 From: barras Date: Thu, 11 Mar 2010 19:08:46 +0000 Subject: introduced lazy computation of size info in the guard condition git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@12862 85f007b7-540e-0410-9357-904b9bb8a0f7 --- test-suite/complexity/guard.v | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 test-suite/complexity/guard.v (limited to 'test-suite/complexity') diff --git a/test-suite/complexity/guard.v b/test-suite/complexity/guard.v new file mode 100644 index 0000000000..f64ffc2598 --- /dev/null +++ b/test-suite/complexity/guard.v @@ -0,0 +1,17 @@ +(* Examples to check that the guard condition does not unfold + irrelevant subterms *) +(* Expected time < 1s *) +Require Import Bool. + +Fixpoint slow n := + match n with + | 0 => true + | S k => andb (slow k) (slow k) + end. + +Timeout 5 Time Fixpoint F n := + match n with + | 0 => 0 + | S k => + if slow 100 then F k else 0 + end. -- cgit v1.2.3