digitalmars.D - How mature is std.socket?
- lurker (5/5) Feb 14 2011 Given that large parts of Phobos are still in flux or planned for
- lurker (2/2) Feb 14 2011 Also, I wouldn't mind a small example of a server using std.socket.
- Jonathan M Davis (14/19) Feb 14 2011 I've never used std.socket and don't really know how mature it is, but i...
- Daniel Gibson (9/28) Feb 14 2011 When the new code is accepted std.socket should be really usable (it was...
- Andrej Mitrovic (5/5) Feb 14 2011 There's a broken example for D2 in the samples folder. It uses D1
- lurker (3/3) Feb 14 2011 Are you talking about listener.d? I managed to compile it with the
- Andrej Mitrovic (3/6) Feb 14 2011 You've fixed it from 2.051, right? The one released with 2.051 doesn't
- lurker (6/6) Feb 15 2011 Yes, 2.51:
Given that large parts of Phobos are still in flux or planned for replacement I'd like to ask, how mature is std.socket? I'm thinking of writing a small server app and would like to know if there are serious problems awaiting the uninitiated? Thanks
Feb 14 2011
Also, I wouldn't mind a small example of a server using std.socket. Thanks
Feb 14 2011
On Monday, February 14, 2011 17:16:33 lurker wrote:Given that large parts of Phobos are still in flux or planned for replacement I'd like to ask, how mature is std.socket? I'm thinking of writing a small server app and would like to know if there are serious problems awaiting the uninitiated?I've never used std.socket and don't really know how mature it is, but it looks like the author of that module made some improvements to it recently which haven't made it into Phobos yet: http://d.puremagic.com/issues/show_bug.cgi?id=5401 So, I suspect that other than that, very little work has been done on it recently, though I don't know how much work it needs, if any. Presumably, the updates in that enhancement request deal with the most pressing issues. Regardless, I'm unaware of any current issues for std.socket (nothing really stands out in the bugzilla from what I can see), and I'm unaware of any plans to replace it. A socket type doesn't seem like the sort of thing that would really need do be overhauled though. Presumably, it's pretty low level. Bug again, I haven't really used it or looked at it. Maybe someone else would know more. - Jonathan M Davis
Feb 14 2011
Am 15.02.2011 02:36, schrieb Jonathan M Davis:On Monday, February 14, 2011 17:16:33 lurker wrote:When the new code is accepted std.socket should be really usable (it was usable before if you didn't want to do too fancy stuff like feeding your own socket_t into std.socket.Socket or deriving from the Socket class.. but this is fixed in the new code). Better support for IPv6 (an Internet6Address class or something like that) and local connections (AF_UNIX) would be nice, though. Cheers, - DanielGiven that large parts of Phobos are still in flux or planned for replacement I'd like to ask, how mature is std.socket? I'm thinking of writing a small server app and would like to know if there are serious problems awaiting the uninitiated?I've never used std.socket and don't really know how mature it is, but it looks like the author of that module made some improvements to it recently which haven't made it into Phobos yet: http://d.puremagic.com/issues/show_bug.cgi?id=5401 So, I suspect that other than that, very little work has been done on it recently, though I don't know how much work it needs, if any. Presumably, the updates in that enhancement request deal with the most pressing issues. Regardless, I'm unaware of any current issues for std.socket (nothing really stands out in the bugzilla from what I can see), and I'm unaware of any plans to replace it. A socket type doesn't seem like the sort of thing that would really need do be overhauled though. Presumably, it's pretty low level. Bug again, I haven't really used it or looked at it. Maybe someone else would know more. - Jonathan M Davis
Feb 14 2011
There's a broken example for D2 in the samples folder. It uses D1 code, so it needs to be translated properly to D2. char[] -> string, string.find -> algorithm.find (+ algo's find is different) and some other tidbits. I'll see if I can try to fix it.
Feb 14 2011
Are you talking about listener.d? I managed to compile it with the latest DMD: http://pastie.org/1565017
Feb 14 2011
On 2/15/11, lurker <lurker mailinator.com> wrote:Are you talking about listener.d? I managed to compile it with the latest DMD: http://pastie.org/1565017You've fixed it from 2.051, right? The one released with 2.051 doesn't compile without modifications.
Feb 14 2011
Yes, 2.51: Digital Mars D Compiler v2.051 Copyright (c) 1999-2010 by Digital Mars written by Walter Bright Documentation: http://www.digitalmars.com/d/2.0/index.html Usage: ...
Feb 15 2011