expression where definition
Hi. The "Hugs for beginners" section of the manual has the example Prelude> take 10 fibs where fibs = ... and this indeed works. But I don't see this syntax in the grammar for Haskell; where clauses are appended to declarations, not to expressions. Is this a Hugs extension? Bob T.
Yes, that's right - this is a Hugs extension. At the
prompt-level, "<exp> WHERE <decls>" is recognised
as an expression.
--sigbjorn
----- Original Message -----
From:
Hi. The "Hugs for beginners" section of the manual has the example
Prelude> take 10 fibs where fibs = ...
and this indeed works. But I don't see this syntax in the grammar for Haskell; where clauses are appended to declarations, not to expressions. Is this a Hugs extension?
Bob T.
_______________________________________________ Hugs-Bugs mailing list Hugs-Bugs@haskell.org http://www.haskell.org/mailman/listinfo/hugs-bugs
participants (2)
-
rdt@cs.queensu.ca -
Sigbjorn Finne