Re: Raw socket TCP/IP

2012-02-05 Thread Eyyub
Use SocketType.STREAM if you want TCP. SOCK_RAW is for cases where you want a raw IP socket Yes, I want a raw IP socket, but when I sendTo my datagram(ip and tcp headers) with a raw IP socket, Wireshark say that my datagram is IPv4 type protocol:unknow(255)... In C or C++ programming

Re: Struct inheritance

2012-02-05 Thread Vidar Wahlberg
Sending this again, got an error the first time and it appears like it was not sent. On 2012-02-04 21:48, Simen Kjærås wrote: I see. There's a hint in the error message: function expected [...], not module. Struct is the name of a module, so the compiler thinks you want to access something

Re: Struct inheritance

2012-02-05 Thread Simen Kjærås
On Sun, 05 Feb 2012 11:58:40 +0100, Vidar Wahlberg cani...@exent.net wrote: Also, is this really ambiguous? Are there any cases where you can have a module name followed by a parentheses, i.e. module(? Not that I know. I cannot seem to recreate this error message. Which version of the

Function returning pointer to itself

2012-02-05 Thread Tobias Pankrath
Is there any better way to write a function that can return a pointer to itself than returning void* and cast at call site to the appropiate type?

Re: Function returning pointer to itself

2012-02-05 Thread Daniel Murphy
Return a struct containing a function pointer. Tobias Pankrath tob...@pankrath.net wrote in message news:jglvvq$7jr$1...@digitalmars.com... Is there any better way to write a function that can return a pointer to itself than returning void* and cast at call site to the appropiate type?

Re: Struct inheritance

2012-02-05 Thread Vidar Wahlberg
On 2012-02-05 14:16, Simen Kjærås wrote: On Sun, 05 Feb 2012 11:58:40 +0100, Vidar Wahlberg cani...@exent.net wrote: Also, is this really ambiguous? Are there any cases where you can have a module name followed by a parentheses, i.e. module(? Not that I know. Possibly something that could

Re: i18n

2012-02-05 Thread xancorreu
Al 05/02/12 05:26, En/na Jose Armando Garcia ha escrit: On Thu, Feb 2, 2012 at 4:48 PM, xancorreuxancor...@gmail.com wrote: Hi, Is there any way for localizate and internationalizate messages? I were shocked if D has something like Fantom [http://fantom.org/doc/docLang/Localization.html].

Re: Struct inheritance

2012-02-05 Thread Vidar Wahlberg
On 2012-02-05 15:19, Daniel Murphy wrote: The names only need to match if the compiler/build tool has to find the module itself. If you call the compiler with all modules listed: gdc bar.d Foo.d etc.d then it should be able to work it out. (This is how it works with dmd, anyway. GDC is

Re: Struct inheritance

2012-02-05 Thread Daniel Murphy
I guess you've found a bug then. :) Vidar Wahlberg cani...@exent.net wrote in message news:jgm7sh$k4u$1...@digitalmars.com... On 2012-02-05 15:19, Daniel Murphy wrote: The names only need to match if the compiler/build tool has to find the module itself. If you call the compiler with all

Re: i18n

2012-02-05 Thread Jose Armando Garcia
On Sun, Feb 5, 2012 at 1:15 PM, xancorreu xancor...@gmail.com wrote: Al 05/02/12 05:26, En/na Jose Armando Garcia ha escrit: On Thu, Feb 2, 2012 at 4:48 PM, xancorreuxancor...@gmail.com  wrote: Hi, Is there any way for localizate and internationalizate messages? I were shocked if D has

Re: i18n

2012-02-05 Thread Johannes Pfau
Am Sun, 5 Feb 2012 14:16:37 -0200 schrieb Jose Armando Garcia jsan...@gmail.com: On Sun, Feb 5, 2012 at 1:15 PM, xancorreu xancor...@gmail.com wrote: Al 05/02/12 05:26, En/na Jose Armando Garcia ha escrit: On Thu, Feb 2, 2012 at 4:48 PM, xancorreuxancor...@gmail.com  wrote: Hi,

Re: Raw socket TCP/IP

2012-02-05 Thread Eyyub
If the source code can help : http://paste.pocoo.org/show/OJK11zDw6jAaurlKLT3Z/ . Eyyub,

Re: i18n

2012-02-05 Thread xancorreu
Al 05/02/12 18:30, En/na Johannes Pfau ha escrit: Am Sun, 5 Feb 2012 14:16:37 -0200 schrieb Jose Armando Garciajsan...@gmail.com: On Sun, Feb 5, 2012 at 1:15 PM, xancorreuxancor...@gmail.com wrote: Al 05/02/12 05:26, En/na Jose Armando Garcia ha escrit: On Thu, Feb 2, 2012 at 4:48 PM,

Re: i18n

2012-02-05 Thread Kagamin
On Sunday, 5 February 2012 at 18:19:20 UTC, xancorreu wrote: So, out of my scope and probably this does not work. For this reason I ask for official solution. None, it sounds very very bad. What do you think I could do practically? It's simple: when there's no ready existing solution, you

Using the Variant (Setting it's memory location)

2012-02-05 Thread Era Scarecrow
I've been working and building a struct called 'AllTypes' which I've come to the conclusion is already available as a variant. However as I look at the documentation I don't see any methods/constructors to use where I can specify where I want the data to be access from. The data I will be

Re: i18n

2012-02-05 Thread xancorreu
Al 05/02/12 20:22, En/na Kagamin ha escrit: On Sunday, 5 February 2012 at 18:19:20 UTC, xancorreu wrote: So, out of my scope and probably this does not work. For this reason I ask for official solution. None, it sounds very very bad. What do you think I could do practically? It's simple:

Re: Using the Variant (Setting it's memory location)

2012-02-05 Thread Ali Çehreli
On 02/05/2012 12:20 PM, Era Scarecrow wrote: I've been working and building a struct called 'AllTypes' which I've come to the conclusion is already available as a variant. However as I look at the documentation I don't see any methods/constructors to use where I can specify where I want the