bugDotGNU Portable.NET - Bugs: bug #10058, cscc bug with enums and the...

 
 

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

bug #10058: cscc bug with enums and the bitwise OR operator | for integral types

Submitter:  None
Submitted:  Wed 18 Aug 2004 11:26:28 PM UTC
   
 
Category:  None Severity:  3 - Normal
Item Group:  None Status:  Fixed
Privacy:  Public Assigned to:  None
Open/Closed:  Closed

Thu 09 Sep 2004 03:43:45 PM UTC, comment #2: 

Fixed in CVS 9th Sept 2004

Gopal.V <t3rmin4t0r>
Group administrator
Thu 09 Sep 2004 02:38:28 PM UTC, comment #1: 

The ECMA spec does not mention enum initializers as a special case, while Enum '|' Int is invalid in normal expressions.

Gopal.V <t3rmin4t0r>
Group administrator
Wed 18 Aug 2004 11:26:28 PM UTC, original submission:  

Compiling the following with cscc version 0.6.8 produces an error.

**** Test.cs ****
using System;

public class Test
{
public enum Foo
{
TabFocus = 0x1,
NoFocus = 0,
StrongFocus = TabFocus | ClickFocus | 0x8,
WheelFocus = StrongFocus | 0x4,
ClickFocus = 0x2
}

public static void Main (String[] args)
{
Console.WriteLine ("test");
}
}

**** Error by cscc ****

test.cs:9: invalid operands to binary `|'
test.cs:9: constant value required
test.cs:10: invalid operands to binary `|'
test.cs:10: constant value required

**** Expected result ****

Should compile without any errors.

Anonymous

 

(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-09-09 t3rmin4t0r StatusNone Fixed
    Open/ClosedOpen Closed

Back to the top

Powered by Savane 3.13-02a9.
Corresponding source code