how can I use Posix in win32 cygwin ?

2002-11-24 Thread Ahn Ki-yung
ghc 5.04.1 binary distribution for win32 does not contain Posix. How can I use the posix package in win32 cygwin platform ? thanks. -- Ahn Ki-yung ___ Glasgow-haskell-users mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo

Network Programming with Haskell ?

2002-12-01 Thread Ahn Ki-yung
No select or poll functions in Network module yet ? listenOn and accept isn't enough for network programming. IO multiplexing is needed. It was a wish list. -- Ahn Ki-yung ___ Glasgow-haskell-users mailing list [EMAIL PROTECTED]

'accept' does not seem to be thread friendly ..

2002-12-02 Thread Ahn Ki-yung
o lsock <- listenOn $ PortNumber 9000 print lsock mvar <- newMVar [] forkIO (thd_accept lsock mvar `finally` putMVar mvar []) loopcats mvar `finally` putMVar mvar [] \end{code} -- Ahn Ki-yung ___ Glasgow-haskell-users mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Concurrncy is not working well in Windows

2003-03-20 Thread Ahn Ki-yung
{- In FreeBSD ghc-5.04.2 the simple echo server below works fine. (except for broken pipe. Installing signal handler will do good.) It broadcasts "Welcome!" to all users repeatedly. But in Windows XP, cygwin, ghc-5.04.3. It gets blocked on the accept routine and wakes up for a moment when new conn

help, ghc compile boot from hc fails.

2003-03-21 Thread Ahn Ki-yung
I checked out the CVS yesterday. === gcc version is $ gcc -v Reading specs from /usr/local/lib/gcc-lib/i386-pc-solaris2.8/3.2/specs Configured with: ../configure --with-as=/usr/ccs/bin/as --with-ld=/usr/ccs/bin/l d --disable-nls Thread model: posix gcc version 3.2 == I configured with $ ./confi

Fix in CVS ndeed Posix compile problem

2003-03-25 Thread Ahn Ki-yung
t I don't how to tweak it. My file is like this. GHC implementors and porters should be awared of this. p.s. Compiling GHC project took almost whole day long :-( Bootstraping from 4.08.2 and stage1, stange 2 ... :-( -- Ahn Ki-yung ___

Re: Fix in CVS ndeed Posix compile problem

2003-03-25 Thread Ahn Ki-yung
Ahn Ki-yung wrote: >SunOS 5.8 >Reading specs from /usr/local/lib/gcc-lib/sparc-sun-solaris2.8/2.95.3/specs >gcc version 2.95.3 20010315 (release) >In the posix related libaries there are two forign call definition. > >foreign import ccall unsafe "getpwuid_r" &g

Re: Fix in CVS ndeed Posix compile problem

2003-03-26 Thread Ahn Ki-yung
t; Thanks, I'll look into this. I left out two more fucntions : getgrnam_r, getgrgid_r in have the same problem too. p.s. I think changing the configure will be the easiest way. If configure can find __posix_***_r stuff then use

How is non-blocking IO working ?

2003-04-03 Thread Ahn Ki-yung
Document says GHC uses non-blocking IO to be thread friendly. But if it continues to poll on the non blocking file descriptor. It should cost much CPU load, but actually it doesn't : for example if a server is wating an input from a connected client, say using hGetLine, until input comes in from th

FFI and Concurrency

2003-04-03 Thread Ahn Ki-yung
C call blocks the whole process, and Concurret module become meaningless. Isn't there any library or wrapper that can avoid ccall from blocking entire process ? -- Ahn Ki-yung ___ Glasgow-haskell-users mailing list [EMAIL PROTECTED]

Why is this program leaking memory ?

2003-05-29 Thread Ahn Ki-yung
eprocess e printeval ([],e',[],[]) printNpreprocess e = print e >> print e1 >> print e2 >> print e3 >> print e' >> return e' where ((ns,[]),e1) = evalST ([1..],[]) (uniqueify e) e2 = lambdalift negate e1

How to getCh on MS Windows command line?

2008-11-09 Thread Ahn, Ki Yung
n MS Windows command line. Surprisingly, it works in WinHugs. However, I cannot use WinHugs for my purpose because the interactive calculator example in the book also uses beep characters and ANSI codes which do not work in WinHugs. Thanks for any hacks or sugges

Re: [Haskell-cafe] How to getCh on MS Windows command line?

2008-11-10 Thread Ahn, Ki Yung
Matti Niemenmaa 쓴 글: Bulat Ziganshin wrote: 1. works for me in ghc: getHiddenChar = liftM (chr.fromEnum) c_getch foreign import ccall unsafe "conio.h getch" c_getch :: IO CInt Thanks to Bulat, Bayley, and Matti for suggestions and discussions. At least for my purpose of running the partic

Re: [Haskell-cafe] How to getCh on MS Windows command line?

2008-11-11 Thread Ahn, Ki Yung
tEcho functions in the System.IO module to get no buffering and no echoing the behavior. -- Ahn, Ki Yung ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Cannot escape from a black hole in ghci 6.10.1

2008-11-17 Thread Ahn, Ki Yung
#x27;t work) You can't escape from the black hole and ghci will start eating up your memory unless kill the ghci process. Now the black hole behaves like a real black hole :-) Is this a ticketed bug, or should we make a new ticket? -- Ahn, Ki Yung _

Graham Hutton's calculator example for win32

2008-12-21 Thread Ahn, Ki Yung
need Parsing.lhs from the book hompage.http://www.cs.nott.ac.uk/~gmh/Parsing.lhs -- Ahn, Ki Yung Calculator example from section 9.6 of Programming in Haskell, Graham Hutton, Cambridge University Press, 2007. Note: the definition for getCh in this example works with the Glasgow Haskell Compi

Surprised to type in (1+n) as a type index!

2009-02-02 Thread Ahn, Ki Yung
enerics.Unit (+1 GHC.Generics.Unit (+ GHC.Generics.Unit ( But, what is this GHC.Generics.Unit thing and where is this documented? Thanks, Ahn, Ki Yung ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Re: [Haskell-cafe] HPong-0.1.2 fails to compile in Debian ghc 6.10.1

2009-04-23 Thread Ahn, Ki Yung
John Goerzen wrote: Ahn, Ki Yung wrote: I don't know the exact reason but this should not fail since I have Debian packaged ghc 6.10.1 and OpenGL-2.2.1.1 on my system. I think this is because the filename of the OpenGL shared library is /usr/lib/libGL.so.1 rather than libGL.so. This i

Does this, and should this type check on GHC 6.10.x ?

2009-06-25 Thread Ahn, Ki Yung
ns used to make this code type check. And also, we welcome any discussion whether this code should or should not in principle type check. Thanks in advance, Ahn, Ki Yung FYI, I had the following error message when I tried it on ghc 6.10.3. (When I commented out the problematic line, the last e

Re: Does this, and should this type check on GHC 6.10.x ?

2009-06-26 Thread Ahn, Ki Yung
Tom Schrijvers wrote: Have you first, before you turn to GHC< considered whether this code should be well-typed in any type system? Review3.lhs:67:29: Could not deduce (Expandable (Tuple (Map ((,) t2) ys))) from the context (xs ~ t2 ::: ts2, Expandable t2) arising from a use of

Re: Does this, and should this type check on GHC 6.10.x ?

2009-06-26 Thread Ahn, Ki Yung
Ahn, Ki Yung wrote: Another problem, which I haven't mentioned, I have when I tried to make additional type family instance declarations that latest (stable) Typo: I mean type class instance declaration of course. distributions of GHC 6.10.x does not let me declare instanc

ghc --help displays obsolete URL

2009-09-05 Thread Ahn, Ki Yung
$ ghc --help ... The User's Guide has more information about GHC's *many* options. An online copy can be found here: http://www.haskell.org/ghc/documentation.html The above URL does not exist! Hope it gets fixed in