Author: martin
Date: 2005-04-12 13:47:41 -0400 (Tue, 12 Apr 2005)
New Revision: 42846
Modified:
trunk/mcs/gmcs/ChangeLog
trunk/mcs/gmcs/attribute.cs
Log:
**** Merged r40762 from MCS ****
Modified: trunk/mcs/gmcs/ChangeLog
===================================================================
--- trunk/mcs/gmcs/ChangeLog 2005-04-12 17:46:45 UTC (rev 42845)
+++ trunk/mcs/gmcs/ChangeLog 2005-04-12 17:47:41 UTC (rev 42846)
@@ -1,3 +1,8 @@
+2005-02-16 Marek Safar <[EMAIL PROTECTED]>
+
+ * attribute.cs (Attribute.Resolve): Add arguments casting for
+ when types doesn't match ctor arguments.
+
2005-02-16 Raja R Harinath <[EMAIL PROTECTED]>
Fix parts of #63202.
Modified: trunk/mcs/gmcs/attribute.cs
===================================================================
--- trunk/mcs/gmcs/attribute.cs 2005-04-12 17:46:45 UTC (rev 42845)
+++ trunk/mcs/gmcs/attribute.cs 2005-04-12 17:47:41 UTC (rev 42846)
@@ -572,6 +572,16 @@
return null;
}
+ object value = pos_values [j];
+ if (value != null && a.Type != value.GetType ()
&& a.Type.IsPrimitive) {
+ bool fail;
+ pos_values [j] = TypeManager.ChangeType
(value, a.Type, out fail);
+ if (fail) {
+ // TODO: Can failed ?
+ throw new
NotImplementedException ();
+ }
+ }
+
if (j < last_real_param)
continue;
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches