[Mono-list] §RE: [Mono-list] Suggestion: warning "member variable notinitialized"

Gonzalo Paniagua Javier gonzalo@ximian.com
08 Jun 2003 04:23:21 +0200


El s?, 07-06-2003 a las 23:40, Jonathan Stowe escribió:
> >
> > Prints 01.01.0001 00:00:00.
> >
> 
> But try comparing that to 0 or null ;-)

Try comparing it to DateTime.MinValue :-/

What Thong meant was that the initialization of those fields is
equivalent to this stuff in C:

typedef struct {
	int field1;
	char *field2;
} X;

......
X *x = malloc (sizeof (X));
memset (x, 0, sizeof (X));
......

-Gonzalo