Linking Error (WS2_32.LIB)
Walter Bright
newshound2 at digitalmars.com
Thu Nov 10 16:08:37 PST 2011
On 11/10/2011 2:50 PM, mta`chrono wrote:
> Walter, have you looked into his source. What he did was:
>
> --------- BEGIN ----------
> import std.socket;
>
> class FoobarAddress : Address
> {
>
> }
>
> void main()
> {
>
> }
> ---------- END ---------
>
> compile this with dmd -m32 main.d and you'll see exactly the same errors
> that he posted. Even tough dmd's error message are a little bit
> confusing in this case, the problem should be clear.
You're right.
And the problem is that Address is an *abstract* class, defined as:
abstract class Address
{
protected sockaddr* name();
protected int nameLen();
AddressFamily addressFamily();
override string toString();
}
This means that anyone deriving from it needs to implement those functions.
More information about the Digitalmars-d
mailing list