bugDotGNU Portable.NET - Bugs: bug #11432, Compiler confuses types and...

 
 

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

bug #11432: Compiler confuses types and fields, but only if there is an attribute

Submitted by:  James Michael DuPont <mdupont>
Submitted on:  Wed 29 Dec 2004 11:46:10 AM UTC  
 
Category: NoneSeverity: 3 - Normal
Item Group: NoneStatus: None
Privacy: PublicAssigned to: None
Open/Closed: Open

Fri 31 Dec 2004 01:09:22 PM UTC, comment #1:

This error occurs when compiling mono
./class/System.XML/System.Xml.Serialization/SerializationCodeGeneratorConfiguration.cs

System.Xml.Serialization/SerializationCodeGeneratorConfiguration.cs:66: `SerializationFormat' is not declared as a type in the current scope

James Michael DuPont <mdupont>
Wed 29 Dec 2004 11:46:10 AM UTC, original submission:

// the compiler thinks this a BOOM::BOO is a type an a field. gets confused
namespace FOO
{
public class Funky : Attribute
{
public Funky (object value) { }
}
public enum BOO { BAZ }

public class BAM
{
[Funky (BOO.BAZ)]
public BOO BOO2 = BOO.BAZ;

[Funky (BOO.BAZ)]
public BOO BOO3 = BOO.BAZ;
}

public class BOOF
{
public BOO BOO2 = BOO.BAZ;
public BOO BOO = BOO.BAZ;// same name -- no attribute

}
public class BOOM
{
[Funky (BOO.BAZ)]
public BOO BOO2 = BOO.BAZ;// different name // `BOO' is not declared as a type in the current scope
[Funky (BOO.BAZ)]
public BOO BOO = BOO.BAZ;// same name -- PROBLEM `BOO' is not declared as a type in the current scope

}
}

James Michael DuPont <mdupont>

 

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

CC list is empty

 

Do you think this task is very important?
If so, you can click here to add your encouragement to it.
This task has 0 encouragements so far.

Only logged-in users can vote.

 

Please enter the title of George Orwell's famous dystopian book (it's a date):

 

 

No Changes Have Been Made to This Item

Back to the top


Powered by Savane 3.1-cleanup