[Mono-bugs] [Bug 42571][Wis] New - const/static scope

bugzilla-daemon@rocky.ximian.com bugzilla-daemon@rocky.ximian.com
Thu, 8 May 2003 03:00:32 -0400 (EDT)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by max.stekelenburg@planet.nl.

http://bugzilla.ximian.com/show_bug.cgi?id=42571

--- shadow/42571	Thu May  8 03:00:32 2003
+++ shadow/42571.tmp.21033	Thu May  8 03:00:32 2003
@@ -0,0 +1,38 @@
+Bug#: 42571
+Product: Mono/MCS
+Version: unspecified
+OS: 
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Wishlist
+Component: Misc
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: max.stekelenburg@planet.nl               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: const/static scope
+
+Please fill in this template when reporting a bug, unless you know what you
+are doing.
+Description of Problem:
+
+when compiling the following code this error is reported:
+test4.cs(10) error CS0150: A constant value is expected
+test4.cs(10) error CS0150: A constant value is expected
+when the defined classes are exchanged it compiles fine.
+(this looks like bug 31984)
+
+public class GoGump 
+{
+	public static bool OldStyle = PropsConfig.OldStyle;
+	public const int HeaderGumpID = PropsConfig.HeaderGumpID;
+}
+public class PropsConfig
+{
+	public const bool OldStyle = false;
+	public const int HeaderGumpID = OldStyle ? 0x0BBC : 0x0E14; 	
+}