On Fri, 17 Feb 2006 17:26:08 +
Jon Fairbairn [EMAIL PROTECTED] wrote:
On 2006-02-17 at 09:22PST Jared Updike wrote:
Yep. change one line to:
entry - if isdir name /= . name /= ..
and it does in fact work.
Only if no-one has been tricky with symbolic links.
And how can
J. Scott Thayer, M.D. wrote:
Haskell wants
libreadline 4 while I have libreadline 5.
I'm not sure about SUSE, but Fedora has libreadline_compat packages.
HTH,
Jim
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
On 2/18/06, asker [EMAIL PROTECTED] wrote:
Hi,
I'm trying to make three haskell classes and an instance this way:
--
class (Eq a) = Graph a where
vert :: [a]
ady :: a - [a]
class (Graph a) = Paths a where
gps
Quoth Barbier de Reuille Pierre [EMAIL PROTECTED]:
| On Fri, 17 Feb 2006 17:26:08 +
| Jon Fairbairn [EMAIL PROTECTED] wrote:
|
| On 2006-02-17 at 09:22PST Jared Updike wrote:
| Yep. change one line to:
|
| entry - if isdir name /= . name /= ..
|
| and it does in fact work.
|
Barbier de Reuille Pierre wrote:
And how can you, in Haskell, detect symbolic links ?
One can use System.Posix.Files.isSymbolicLink function for that purpose.
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
Barbier de Reuille Pierre [EMAIL PROTECTED] writes:
(snip)
And how can you, in Haskell, detect symbolic links ?
I use System.Posix.Files.
getSymbolicLinkStatus is like lstat(2) under Unix.
It returns a value to which you can apply the
isSymbolicLink predicate.
Of course, you can't be sure the
My thanks for the responses received off-list.
Dimitrios pointed out that a 'successor' class solution would require the
typechecking to depend somehow on whether the lists were empty or not.
Probably a clue that I was on the wrong track.
Both Cale and Dimitrios suggested better solutions
Hi everybody,
I have written some code for several shapes, and i get a compiling error:
parse error on input `:'
though I can't find where the error is...
data Shape = Ellipse Radius Radius
| Polygon [Vertex]
deriving Show
type Radius = Float
type Vertex =
Hi,
Am Sonntag, 19. Februar 2006 22:57 schrieb Chatzianastassiou Achilleas:
Hi everybody,
I have written some code for several shapes, and i get a compiling error:
parse error on input `:'
though I can't find where the error is...
[snip code]
ever heard of the layout-rule?
You must
Watch how deeply things are indented. The definitions for polyArea
should be indented to the same level as its type signature. Currently,
they're indented a little more, so the first line of polyArea's
definition is being treated as part of the type signature, which is
why you're getting the
Thanks everybody,
I think it was the layout thing that I misstyped plus the
area (RtTriangle s1 s1) = s1 *s2 /2
(silly me!)
Skag55
_
Dont just search. Find. Check out the new MSN Search!
What version of GHC are you using?
Your code works for me in rxvt in Cygwin, with GHC 6.4.1. But I remember having
that same problem earlier (in some earlier GHC version, so it may be fixed by now).
The solution was to run hFlush after each putStr, like so:
import System.IO (hFlush, stdout)
12 matches
Mail list logo