Ejemplo n.º 1
0
 internal void GenerateCall(ConstructorStructure constructor)
 {
     Generator.Emit(OpCodes.Call, constructor.GainConstructor());
 }
Ejemplo n.º 2
0
 internal ConstructorInfo RenewConstructor(ConstructorStructure constructor)
 {
     if (Info.GetType().Name == "TypeBuilderInstantiation")
     {
         return TypeBuilder.GetConstructor(Info, constructor.GainConstructor());
     }
     else
     {
         var c = constructor.GainConstructor();
         var types = Info.RenewTypes(c.GetParameters().ToTypes());
         var ret = Info.GetConstructor(types);
         if (ret == null)
         {
             throw new InvalidOperationException();
         }
         return ret;
     }
 }
Ejemplo n.º 3
0
 internal void GenerateNew(ConstructorStructure constructor)
 {
     Generator.Emit(OpCodes.Newobj, constructor.GainConstructor());
 }