bugDotGNU Portable.NET - Bugs: bug #8207, System.IntPtr casts not compatible...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #8207: System.IntPtr casts not compatible with VS

Submitter:  Russell Stuart <rstuart>
Submitted:  Fri 19 Mar 2004 01:50:31 PM UTC
   
 
Category:  None Severity:  3 - Normal
Item Group:  None Status:  Fixed
Privacy:  Public Assigned to:  None
Open/Closed:  Closed

Tue 08 Jun 2004 02:48:37 PM UTC, comment #3: 

Fixed in CVS 8th June 2004

Gopal.V <t3rmin4t0r>
Group administrator
Sat 20 Mar 2004 02:12:17 AM UTC, comment #2: 

Unsafe was not used when compiling under VS.

I don't know whether the code "should" compile or not, according the ECMA.  I am simply saying code containing construct this does compile under VS.  I have verified this.  I have a copy of VS. Before submitting the bug I put the example given in a file called x.cs, and compiled it.  I did not pass the compiler any special switches.  As the original buig report says, VS did not give any errors or warnings.

I am reporting this because I am in the process of porting NUnit to PNet.  NUnit was obviously developed under VS.  It contains a more complex version of the code submitted.

Its not really about being technically right or wrong.  Its about being compatible with MS's implementation of C#.  I don't know if that is one of PNet's goals, but I thought I would submit it anyway.  If it is not one I PNet's goals I can always submit a patch to NUnit.

Let me know what the decision is.

Russell Stuart <rstuart>
Group Member
Fri 19 Mar 2004 04:29:33 PM UTC, comment #1: 

According to ECMA it should have been

unsafe class X {

for that to compile , IIRC ?

Gopal.V <t3rmin4t0r>
Group administrator
Fri 19 Mar 2004 01:50:31 PM UTC, original submission:  

This code compiles on VS without errors or warnings.  It does not compile under PNet.

class X {
  System.IntPtr b = (System.IntPtr)null;
  void x(System.IntPtr z) {
    x((System.IntPtr)null);
  }
}

Russell Stuart <rstuart>
Group Member

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

CC list is empty

 

There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

 

Follow 2 latest changes.

Date Changed by Updated Field Previous Value => Replaced by
2004-06-08 t3rmin4t0r StatusNone Fixed
    Open/ClosedOpen Closed

Back to the top

Powered by Savane 3.13-0329.
Corresponding source code