[Mono-bugs] [Bug 61204][Wis] Changed - Incorrect behavior if const field and default value have different types
bugzilla-daemon@bugzilla.ximian.com
bugzilla-daemon@bugzilla.ximian.com
Tue, 6 Jul 2004 13:30:08 -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 bmaurer@users.sf.net.
http://bugzilla.ximian.com/show_bug.cgi?id=61204
--- shadow/61204 2004-07-06 12:36:35.000000000 -0400
+++ shadow/61204.tmp.14321 2004-07-06 13:30:08.000000000 -0400
@@ -1,14 +1,14 @@
Bug#: 61204
Product: Mono: Runtime
Version: unspecified
-OS:
+OS: unknown
OS Details:
Status: NEW
Resolution:
-Severity:
+Severity: Unknown
Priority: Wishlist
Component: misc
AssignedTo: mono-bugs@ximian.com
ReportedBy: bmaurer@users.sf.net
QAContact: mono-bugs@ximian.com
TargetMilestone: ---
@@ -23,6 +23,17 @@
...
And since you're working in this area: the spec says that the type of
the constant may not match the type of the field. This means that the
code was and remains incorrect: please write the test case in IL and
change the code to handle this case.
+
+------- Additional Comments From bmaurer@users.sf.net 2004-07-06 13:30 -------
+Basically what happens is that MS does a byte by byte copy.
+
+if you have .field public static literal float64 a = int8(1), you
+get "4.94065645841247E-324" when you reflect (i assume that is what
+0x000000000001 is...)
+
+We actually hande everything correctly, except when the constant type
+is wider than the field type. THen we corrupt some memory durring the
+copy.