Vasili Galchin writes:
>
> Two questions:
>
> 1) Where are the Berkeley Sockets Library functions actually
> defined? I.e in which file?? Can Hugs use this??
Hi,
I'm not sure if this is what you're asking for, but GHC comes with a
BSD networking module/interface (called BSD in the "misc" syslib). It
is implemented using GHC's ccall extension, so the code is not useable
under Hugs. I'd be momentarily surprised if someone hasn't implemented
similar support for programming sockets under Hugs though.
>
> 2) In the above 1), obviously this uses green card for foreign
> language calls?????
>
>
No, afraid not. The networking library was implemented by Darren
Moffat quite some time before Green Card saw the light of day. It is
on our GHC ToDo lists to convert GHC's various libraries to use Green
Card, but this won't happen before we've got a working&stable IDL
compiler. (Green Card 3 (aka H/Direct) will use IDL to interface to
external libs instead of the homegrown language used by Green Card 2.)
hope that helps,
--sigbjorn