[Mono-list] Suggestion: warning member variable not initialized

2003-06-07 Thread Maurizio Colucci
Hi, Currently the Microsoft C# compiler gives an error if you forget to initialize a readonly member variable (this can be done either in the contructor or in the declaration itself.) I already posted a wish for mcs about that, but: What about extending this behavior to non-readonly

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

2003-06-07 Thread Gonzalo Paniagua Javier
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 {

RE: [Mono-list] Suggestion: warning member variable not initialized

2003-06-07 Thread Thong (Tum) Nguyen
Members are implicitly initialized to 0 or null so they do have a meaning even if you don't explicitly initialize them... ^Tum -Original Message- From: [EMAIL PROTECTED] [mailto:mono-list- [EMAIL PROTECTED] On Behalf Of Maurizio Colucci Sent: Sunday, 8 June 2003 12:50 a.m. To:

Re: [Mono-list] Suggestion: warning member variable not initialized

2003-06-07 Thread Maurizio Colucci
On Saturday 07 June 2003 16:03, Thong (Tum) Nguyen wrote: Members are implicitly initialized to 0 or null so they do have a meaning even if you don't explicitly initialize them... ^Tum I see. :-P So the semantics of readonly members is members which are not implicitly initialized, and must be

[Mono-list] Problems with the latest version of Mono...

2003-06-07 Thread Giuseppe Greco
Hi all, I've just checked out the very last version of Mono from CVS and compiled successfully... but as I run any Mono app (e.g. mono myApp.exe) nothing happens, or more precisely, the application does nothing and never returns. Also mcs -v never returns... My previous Mono distribution was 2

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

2003-06-07 Thread Brian Deacon
On Sat, 2003-06-07 at 07:03, Thong (Tum) Nguyen wrote: Members are implicitly initialized to 0 or null so they do have a meaning even if you don't explicitly initialize them... ^Tum Umm... no. Some [ValueType] types don't even have an equivalent to 0 or null. e.g., System.DateTime, IIRC.

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

2003-06-07 Thread Arild Fines
[EMAIL PROTECTED] wrote: notinitialized On Sat, 2003-06-07 at 07:03, Thong (Tum) Nguyen wrote: Members are implicitly initialized to 0 or null so they do have a meaning even if you don't explicitly initialize them... Umm... no. Some [ValueType] types don't even have an equivalent to 0

Re: [Mono-list] Suggestion: warning member variable not initialized

2003-06-07 Thread Marcus
On the contrary, structs should be designed to consider the default initialization a valid state. In particular, the default initialization sets all value type fields to their default value and all reference type fields to null. In the particular case of System.DateTime, a default-initialized

[Mono-list] classes

2003-06-07 Thread Hector Galarza
are dotgnu and mono classes compatibles? if so why don't both of your create another project to implement them? ___ Mono-list maillist - [EMAIL PROTECTED] http://lists.ximian.com/mailman/listinfo/mono-list

RE: [Mono-list] Suggestion: warning member variable not initialized

2003-06-07 Thread Thong (Tum) Nguyen
Hi Maurizio, Readonly members are implicitly initialized (all memory is zeroed before it is used) but since readonly members can't be set anywhere except for in the initializer or constructor a warning is given. The compiler will actually give an warning if you never initialize a field but it

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

2003-06-07 Thread Jonathan Stowe
On Sat, 7 Jun 2003, Arild Fines wrote: [EMAIL PROTECTED] wrote: notinitialized On Sat, 2003-06-07 at 07:03, Thong (Tum) Nguyen wrote: Members are implicitly initialized to 0 or null so they do have a meaning even if you don't explicitly initialize them... Umm... no. Some