On Sun, 2009-04-12 at 21:05 -0300, Andre Nathan wrote:
> If I simplify the rule above to
>
> "forall"; "("; gen = expr; ")"; var = ipatt; ".";
> e1 = expr; impl = OPT "=>"; e2 = OPT expr ->
>
> then everything after the dot is bound to e1, even when there's a "=>".
For the archives, this ha
Hello
I'm adding support for property testing in OSpec. Currently you can
write a specification like
forall (list_of int) (fun l -> (List.rev (List.rev l)) should = l)
and it's also possible to add a constraint as in
forall (list_of int) ~given:(fun l -> List.length l > 0)
(fun l -
Oops, missing code : http://bluestorm.info/camlp4/pa_holes.ml.html
___
Caml-list mailing list. Subscription management:
http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list
Archives: http://caml.inria.fr
Beginner's list: http://groups.yahoo.com/group
On 3/21/09, Andre Nathan wrote:
> I think I understand, although I thought the "x = expr" rule in the sum
> form definition meant that before "plus" any expression would be
> allowed.
What you wanted is let a = b in (a plus b). The expression is not
before plus, plus is inside the expression. Y
Hi
On Sat, 2009-03-21 at 16:26 +0100, blue storm wrote:
> This is not a camlp4-specific problem : the grammar you described
> apparently do not conform to what you have in mind.
I think I understand, although I thought the "x = expr" rule in the sum
form definition meant that before "plus" any ex
This is not a camlp4-specific problem : the grammar you described
apparently do not conform to what you have in mind.
According to your definition, the "sum do ... done" can only contain
"sum" forms, not an arbitrary expression. The only valid way to parse
"sum do let a = b in a plus c done" is th
Hello
I'm just beginning with camlp4 here, and I'm stuck with what I think is
a precedence issue. I have the following syntax extension:
open Camlp4.PreCast
open Syntax
let sum = Gram.Entry.mk "sum"
EXTEND Gram
expr: LEVEL "top"
[ [ "sum"; "do"; seq = LIST1 sum; "done" ->
<:expr<