本文整理汇总了C#中System.Reflection.Emit.MethodBuilder.GetTypeBuilder方法的典型用法代码示例。如果您正苦于以下问题:C# MethodBuilder.GetTypeBuilder方法的具体用法?C# MethodBuilder.GetTypeBuilder怎么用?C# MethodBuilder.GetTypeBuilder使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.Reflection.Emit.MethodBuilder
的用法示例。
在下文中一共展示了MethodBuilder.GetTypeBuilder方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: TypeBuilder
// ctor for generic method parameter
internal TypeBuilder(string szName, int genParamPos, MethodBuilder declMeth)
{
Contract.Requires(declMeth != null);
m_declMeth = declMeth;
m_DeclaringType =m_declMeth.GetTypeBuilder();
m_module =declMeth.GetModuleBuilder();
InitAsGenericParam(szName, genParamPos);
}
示例2: ILGenerator
internal ILGenerator(MethodBuilder methodBuilder, int size)
{
if (size < defaultSize)
{
m_ILStream = new byte[defaultSize];
}
else
{
m_ILStream = new byte[size];
}
m_length=0;
m_labelCount=0;
m_fixupCount=0;
m_labelList = null;
m_fixupData = null;
m_exceptions = null;
m_exceptionCount=0;
m_currExcStack = null;
m_currExcStackCount=0;
m_RelocFixupList = new int[DefaultFixupArraySize];
m_RelocFixupCount=0;
m_RVAFixupList = new int[DefaultFixupArraySize];
m_RVAFixupCount=0;
// initialize the scope tree
m_ScopeTree = new ScopeTree();
m_LineNumberInfo = new LineNumberInfo();
m_methodBuilder = methodBuilder;
// initialize local signature
m_localCount=0;
m_localSignature = SignatureHelper.GetLocalVarSigHelper(m_methodBuilder.GetTypeBuilder().Module);
}