[ nice-Bugs-1750297 ] [nullness] Access to field via nullable reference
"SourceForge.net" <[email protected]> Mon, 09 Jul 2007 04:23:48 -0700
| Newsgroups | gmane.comp.lang.nice.devel |
|---|---|
| Message-ID | <[email protected]> |
Bugs item #1750297, was opened at 2007-07-09 14:23
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=112788&aid=1750297&group_id=12788
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Yauheni Akhotnikau (eao197)
Assigned to: Nobody/Anonymous (nobody)
Summary: [nullness] Access to field via nullable reference
Initial Comment:
This code doesn't compiled:
class Exchanger
{
?Holder first = null;
void exchange( Holder h )
{
if( first != null )
{
h.other = first.self;
first.other = h.self;
}
}
}
class Holder
{
int self = 0;
int other = 0;
}
with error:
D:\home\eao197\tmp\nice\optional_field_bug>nicec --jar test1.jar test1
nice.lang: parsing
test1: parsing
test1: typechecking
D:\home\eao197\tmp\nice\optional_field_bug\test1\t.nice: line 9, column 23:
Arguments (?test1.Holder) do not fit:
nice.lang.int test1.Holder.self
compilation failed with 1 error
Nice version is:
D:\home\eao197\tmp\nice\optional_field_bug>nicec --version
Nice compiler version 0.9.12 (build 2006.01.26, 12:43:13 UTC)
Compiled using JDK 1.4.2_08
Copyright (C) 2003 Daniel Bonniot
Visit the Nice homepage: http://nice.sourceforge.net
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=112788&aid=1750297&group_id=12788
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/