https://bugzilla.novell.com/show_bug.cgi?id=485706
Summary: catch clauses with generic types produces unverifiable
IL
Classification: Mono
Product: Mono: Compilers
Version: SVN
Platform: Other
OS/Version: Other
Status: NEW
Severity: Normal
Priority: P5 - None
Component: C#
AssignedTo: [email protected]
ReportedBy: [email protected]
QAContact: [email protected]
Found By: ---
Test case:
class C {
void M<T> () where T : System.Exception {
try {
} catch (T ex) {
}
}
}
for the catch clause gmcs generates:
L_0005: stloc.0
L_0006: leave L_000b
and peverify complains:
[IL]: Error: [Y:\test\unverifiable\test.dll : C::M[T]][offset 0x00000005][found
ref (boxed) 'T'][expected (unboxed) 'T'] Unexpected type on the stack.
csc generates:
L_0005: unbox.any !!T
L_000a: stloc.0
L_000b: nop
L_000c: nop
L_000d: leave.s L_000f
(and peverify does not complain).
--
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.
_______________________________________________
mono-bugs maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-bugs