Copy Constructor MethodDefinition

28 views
Skip to first unread message

Greg Young

unread,
Jul 15, 2011, 2:48:21 PM7/15/11
to mono-...@googlegroups.com
Is there a quick and easy way to copy a MethodDefinition?

--
Le doute n'est pas une condition agréable, mais la certitude est absurde.

Gábor Kozár

unread,
Jul 16, 2011, 8:10:37 AM7/16/11
to mono-...@googlegroups.com
There is no Clone() method if that's what you're asking. You can effectively copy a MethodDefinition (or any other *Definition for that matter) by creating a new object instance, and setting the new object's properties to the same values as the original object. In case of a MethodDefinition, this involves the method name, return type, declaring type, parameters, generic parameters, HasThis, ExplicitThis, etc.

2011/7/15 Greg Young <gregor...@gmail.com>
Is there a quick and easy way to copy a MethodDefinition?

--
Le doute n'est pas une condition agréable, mais la certitude est absurde.

--
--
mono-cecil

Reply all
Reply to author
Forward
0 new messages