dotgnu-pnet-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Dotgnu-pnet-commits] CVS: pnet/engine int_proto.h, 1.69, 1.70 int_table


From: Richard Baumann <address@hidden>
Subject: [Dotgnu-pnet-commits] CVS: pnet/engine int_proto.h, 1.69, 1.70 int_table.c, 1.72, 1.73 lib_emit.c, 1.21, 1.22
Date: Wed, 23 Jul 2003 11:35:47 -0400

Update of /cvsroot/dotgnu-pnet/pnet/engine
In directory subversions:/tmp/cvs-serv24885/engine

Modified Files:
        int_proto.h int_table.c lib_emit.c 
Log Message:
Implement method body output for dynamic assemblies.


Index: int_proto.h
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/int_proto.h,v
retrieving revision 1.69
retrieving revision 1.70
diff -C2 -r1.69 -r1.70
*** int_proto.h 22 Jul 2003 13:46:48 -0000      1.69
--- int_proto.h 23 Jul 2003 15:35:45 -0000      1.70
***************
*** 376,379 ****
--- 376,380 ----
  extern ILNativeInt _IL_AssemblyBuilder_ClrAssemblyCreate(ILExecThread * 
_thread, ILString * _p1, ILInt32 _p2, ILInt32 _p3, ILInt32 _p4, ILInt32 _p5, 
ILInt32 _p6, ILNativeInt * writer);
  extern ILBool _IL_AssemblyBuilder_ClrSave(ILExecThread * _thread, ILNativeInt 
_p1, ILNativeInt _p2, ILString * _p3, ILNativeInt _p4, ILInt32 _p5);
+ extern ILInt32 _IL_AssemblyBuilder_ClrWriteMethod(ILExecThread * _thread, 
ILNativeInt _p1, ILNativeInt _p2, System_Array * _p3);
  extern ILInt32 _IL_AssemblyBuilder_ClrGetItemToken(ILExecThread * _thread, 
ILNativeInt _p1);
  extern ILNativeInt _IL_AssemblyBuilder_ClrGetItemFromToken(ILExecThread * 
_thread, ILNativeInt _p1, ILInt32 _p2);

Index: int_table.c
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/int_table.c,v
retrieving revision 1.72
retrieving revision 1.73
diff -C2 -r1.72 -r1.73
*** int_table.c 22 Jul 2003 18:01:20 -0000      1.72
--- int_table.c 23 Jul 2003 15:35:45 -0000      1.73
***************
*** 41,95 ****
  #if !defined(HAVE_LIBFFI)
  
- static void marshal_pppp(void (*fn)(), void *rvalue, void **avalue)
- {
-       *((void * *)rvalue) = (*(void * (*)(void *, void *, void *))fn)(*((void 
* *)(avalue[0])), *((void * *)(avalue[1])), *((void * *)(avalue[2])));
- }
- 
- #endif
- 
- #if !defined(HAVE_LIBFFI)
- 
- static void marshal_ppppb(void (*fn)(), void *rvalue, void **avalue)
- {
-       *((void * *)rvalue) = (*(void * (*)(void *, void *, void *, 
ILInt8))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((void * 
*)(avalue[2])), *((ILInt8 *)(avalue[3])));
- }
- 
- #endif
- 
- #if !defined(HAVE_LIBFFI)
- 
- static void marshal_pppi(void (*fn)(), void *rvalue, void **avalue)
- {
-       *((void * *)rvalue) = (*(void * (*)(void *, void *, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 
*)(avalue[2])));
- }
- 
- #endif
- 
- #if !defined(HAVE_LIBFFI)
- 
- static void marshal_pppl(void (*fn)(), void *rvalue, void **avalue)
- {
-       *((void * *)rvalue) = (*(void * (*)(void *, void *, 
ILInt64))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((ILInt64 
*)(avalue[2])));
- }
- 
- #endif
- 
- #ifndef _IL_Enum_suppressed
- 
- IL_METHOD_BEGIN(Enum_Methods)
-       IL_METHOD("GetEnumValue", "(T)oSystem.Object;", _IL_Enum_GetEnumValue, 
marshal_ppp)
-       IL_METHOD("FormatEnumWithFlags", 
"(oSystem.Type;oSystem.Object;)oSystem.String;", _IL_Enum_FormatEnumWithFlags, 
marshal_pppp)
-       IL_METHOD("GetEnumName", 
"(oSystem.Type;oSystem.Object;)oSystem.String;", _IL_Enum_GetEnumName, 
marshal_pppp)
-       IL_METHOD("GetEnumValueFromName", 
"(oSystem.Type;oSystem.String;Z)oSystem.Object;", 
_IL_Enum_GetEnumValueFromName, marshal_ppppb)
-       IL_METHOD("IsEnumValue", "(oSystem.Type;oSystem.Object;)Z", 
_IL_Enum_IsEnumValue, marshal_bppp)
-       IL_METHOD("EnumValueOr", 
"(oSystem.Object;oSystem.Object;)oSystem.Object;", _IL_Enum_EnumValueOr, 
marshal_pppp)
-       IL_METHOD("EnumIntToObject", "(oSystem.Type;i)oSystem.Object;", 
_IL_Enum_EnumIntToObject, marshal_pppi)
-       IL_METHOD("EnumLongToObject", "(oSystem.Type;l)oSystem.Object;", 
_IL_Enum_EnumLongToObject, marshal_pppl)
- IL_METHOD_END
- 
- #endif
- 
- #if !defined(HAVE_LIBFFI)
- 
  static void marshal_vppp(void (*fn)(), void *rvalue, void **avalue)
  {
--- 41,44 ----
***************
*** 151,157 ****
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_ppjiiii(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((void * *)rvalue) = (*(void * (*)(void *, ILNativeUInt, ILInt32, 
ILInt32, ILInt32, ILInt32))fn)(*((void * *)(avalue[0])), *((ILNativeUInt 
*)(avalue[1])), *((ILInt32 *)(avalue[2])), *((ILInt32 *)(avalue[3])), 
*((ILInt32 *)(avalue[4])), *((ILInt32 *)(avalue[5])));
  }
  
--- 100,106 ----
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_pppiii(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((void * *)rvalue) = (*(void * (*)(void *, void *, ILInt32, ILInt32, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 
*)(avalue[2])), *((ILInt32 *)(avalue[3])), *((ILInt32 *)(avalue[4])));
  }
  
***************
*** 160,166 ****
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_vpppiii(void (*fn)(), void *rvalue, void **avalue)
  {
!       (*(void (*)(void *, void *, void *, ILInt32, ILInt32, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((void * 
*)(avalue[2])), *((ILInt32 *)(avalue[3])), *((ILInt32 *)(avalue[4])), 
*((ILInt32 *)(avalue[5])));
  }
  
--- 109,115 ----
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_ippi(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((ILNativeInt *)rvalue) = (*(ILInt32 (*)(void *, void *, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 
*)(avalue[2])));
  }
  
***************
*** 169,175 ****
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_pppiii(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((void * *)rvalue) = (*(void * (*)(void *, void *, ILInt32, ILInt32, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 
*)(avalue[2])), *((ILInt32 *)(avalue[3])), *((ILInt32 *)(avalue[4])));
  }
  
--- 118,124 ----
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_vppii(void (*fn)(), void *rvalue, void **avalue)
  {
!       (*(void (*)(void *, void *, ILInt32, ILInt32))fn)(*((void * 
*)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 *)(avalue[2])), *((ILInt32 
*)(avalue[3])));
  }
  
***************
*** 178,184 ****
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_ippi(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((ILNativeInt *)rvalue) = (*(ILInt32 (*)(void *, void *, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 
*)(avalue[2])));
  }
  
--- 127,133 ----
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_vppipii(void (*fn)(), void *rvalue, void **avalue)
  {
!       (*(void (*)(void *, void *, ILInt32, void *, ILInt32, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 
*)(avalue[2])), *((void * *)(avalue[3])), *((ILInt32 *)(avalue[4])), *((ILInt32 
*)(avalue[5])));
  }
  
***************
*** 187,193 ****
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_vppii(void (*fn)(), void *rvalue, void **avalue)
  {
!       (*(void (*)(void *, void *, ILInt32, ILInt32))fn)(*((void * 
*)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 *)(avalue[2])), *((ILInt32 
*)(avalue[3])));
  }
  
--- 136,142 ----
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_pppi(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((void * *)rvalue) = (*(void * (*)(void *, void *, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 
*)(avalue[2])));
  }
  
***************
*** 196,202 ****
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_vppipii(void (*fn)(), void *rvalue, void **avalue)
  {
!       (*(void (*)(void *, void *, ILInt32, void *, ILInt32, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 
*)(avalue[2])), *((void * *)(avalue[3])), *((ILInt32 *)(avalue[4])), *((ILInt32 
*)(avalue[5])));
  }
  
--- 145,151 ----
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_vpppi(void (*fn)(), void *rvalue, void **avalue)
  {
!       (*(void (*)(void *, void *, void *, ILInt32))fn)(*((void * 
*)(avalue[0])), *((void * *)(avalue[1])), *((void * *)(avalue[2])), *((ILInt32 
*)(avalue[3])));
  }
  
***************
*** 205,211 ****
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_vpppi(void (*fn)(), void *rvalue, void **avalue)
  {
!       (*(void (*)(void *, void *, void *, ILInt32))fn)(*((void * 
*)(avalue[0])), *((void * *)(avalue[1])), *((void * *)(avalue[2])), *((ILInt32 
*)(avalue[3])));
  }
  
--- 154,160 ----
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_ppjiiii(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((void * *)rvalue) = (*(void * (*)(void *, ILNativeUInt, ILInt32, 
ILInt32, ILInt32, ILInt32))fn)(*((void * *)(avalue[0])), *((ILNativeUInt 
*)(avalue[1])), *((ILInt32 *)(avalue[2])), *((ILInt32 *)(avalue[3])), 
*((ILInt32 *)(avalue[4])), *((ILInt32 *)(avalue[5])));
  }
  
***************
*** 221,230 ****
  #endif
  
  #ifndef _IL_Array_suppressed
  
  IL_METHOD_BEGIN(Array_Methods)
-       IL_METHOD("Initialize", "(T)V", _IL_Array_Initialize, marshal_vpp)
-       IL_METHOD("CreateArray", "(jiiii)oSystem.Array;", 
_IL_Array_CreateArray_jiiii, marshal_ppjiiii)
-       IL_METHOD("Set", "(ToSystem.Object;iii)V", _IL_Array_Set_Objectiii, 
marshal_vpppiii)
        IL_METHOD("Get", "(Tiii)oSystem.Object;", _IL_Array_Get_iii, 
marshal_pppiii)
        IL_METHOD("GetLowerBound", "(Ti)i", _IL_Array_GetLowerBound, 
marshal_ippi)
--- 170,194 ----
  #endif
  
+ #if !defined(HAVE_LIBFFI)
+ 
+ static void marshal_pppp(void (*fn)(), void *rvalue, void **avalue)
+ {
+       *((void * *)rvalue) = (*(void * (*)(void *, void *, void *))fn)(*((void 
* *)(avalue[0])), *((void * *)(avalue[1])), *((void * *)(avalue[2])));
+ }
+ 
+ #endif
+ 
+ #if !defined(HAVE_LIBFFI)
+ 
+ static void marshal_vpppiii(void (*fn)(), void *rvalue, void **avalue)
+ {
+       (*(void (*)(void *, void *, void *, ILInt32, ILInt32, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((void * 
*)(avalue[2])), *((ILInt32 *)(avalue[3])), *((ILInt32 *)(avalue[4])), 
*((ILInt32 *)(avalue[5])));
+ }
+ 
+ #endif
+ 
  #ifndef _IL_Array_suppressed
  
  IL_METHOD_BEGIN(Array_Methods)
        IL_METHOD("Get", "(Tiii)oSystem.Object;", _IL_Array_Get_iii, 
marshal_pppiii)
        IL_METHOD("GetLowerBound", "(Ti)i", _IL_Array_GetLowerBound, 
marshal_ippi)
***************
*** 232,242 ****
--- 196,209 ----
        IL_METHOD("GetRank", "(T)i", _IL_Array_GetRank, marshal_ipp)
        IL_METHOD("Clear", "(oSystem.Array;ii)V", _IL_Array_Clear, 
marshal_vppii)
+       IL_METHOD("Initialize", "(T)V", _IL_Array_Initialize, marshal_vpp)
        IL_METHOD("InternalCopy", "(oSystem.Array;ioSystem.Array;ii)V", 
_IL_Array_InternalCopy, marshal_vppipii)
        IL_METHOD("GetRelative", "(Ti)oSystem.Object;", _IL_Array_GetRelative, 
marshal_pppi)
        IL_METHOD("SetRelative", "(ToSystem.Object;i)V", _IL_Array_SetRelative, 
marshal_vpppi)
        IL_METHOD("GetLength", "(T)i", _IL_Array_GetLength_, marshal_ipp)
+       IL_METHOD("CreateArray", "(jiiii)oSystem.Array;", 
_IL_Array_CreateArray_jiiii, marshal_ppjiiii)
        IL_METHOD("CreateArray", "(j[i[i)oSystem.Array;", 
_IL_Array_CreateArray_jaiai, marshal_ppjpp)
        IL_METHOD("Get", "(T[i)oSystem.Object;", _IL_Array_Get_ai, marshal_pppp)
        IL_METHOD("GetLength", "(Ti)i", _IL_Array_GetLength_i, marshal_ippi)
+       IL_METHOD("Set", "(ToSystem.Object;iii)V", _IL_Array_Set_Objectiii, 
marshal_vpppiii)
        IL_METHOD("Set", "(ToSystem.Object;[i)V", _IL_Array_Set_Objectai, 
marshal_vpppp)
  IL_METHOD_END
***************
*** 254,257 ****
--- 221,257 ----
  #if !defined(HAVE_LIBFFI)
  
+ static void marshal_ppppb(void (*fn)(), void *rvalue, void **avalue)
+ {
+       *((void * *)rvalue) = (*(void * (*)(void *, void *, void *, 
ILInt8))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((void * 
*)(avalue[2])), *((ILInt8 *)(avalue[3])));
+ }
+ 
+ #endif
+ 
+ #if !defined(HAVE_LIBFFI)
+ 
+ static void marshal_pppl(void (*fn)(), void *rvalue, void **avalue)
+ {
+       *((void * *)rvalue) = (*(void * (*)(void *, void *, 
ILInt64))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((ILInt64 
*)(avalue[2])));
+ }
+ 
+ #endif
+ 
+ #ifndef _IL_Enum_suppressed
+ 
+ IL_METHOD_BEGIN(Enum_Methods)
+       IL_METHOD("GetEnumValue", "(T)oSystem.Object;", _IL_Enum_GetEnumValue, 
marshal_ppp)
+       IL_METHOD("FormatEnumWithFlags", 
"(oSystem.Type;oSystem.Object;)oSystem.String;", _IL_Enum_FormatEnumWithFlags, 
marshal_pppp)
+       IL_METHOD("GetEnumName", 
"(oSystem.Type;oSystem.Object;)oSystem.String;", _IL_Enum_GetEnumName, 
marshal_pppp)
+       IL_METHOD("GetEnumValueFromName", 
"(oSystem.Type;oSystem.String;Z)oSystem.Object;", 
_IL_Enum_GetEnumValueFromName, marshal_ppppb)
+       IL_METHOD("IsEnumValue", "(oSystem.Type;oSystem.Object;)Z", 
_IL_Enum_IsEnumValue, marshal_bppp)
+       IL_METHOD("EnumValueOr", 
"(oSystem.Object;oSystem.Object;)oSystem.Object;", _IL_Enum_EnumValueOr, 
marshal_pppp)
+       IL_METHOD("EnumIntToObject", "(oSystem.Type;i)oSystem.Object;", 
_IL_Enum_EnumIntToObject, marshal_pppi)
+       IL_METHOD("EnumLongToObject", "(oSystem.Type;l)oSystem.Object;", 
_IL_Enum_EnumLongToObject, marshal_pppl)
+ IL_METHOD_END
+ 
+ #endif
+ 
+ #if !defined(HAVE_LIBFFI)
+ 
  static void marshal_bp(void (*fn)(), void *rvalue, void **avalue)
  {
***************
*** 581,587 ****
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_pppii(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((void * *)rvalue) = (*(void * (*)(void *, void *, ILInt32, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 
*)(avalue[2])), *((ILInt32 *)(avalue[3])));
  }
  
--- 581,587 ----
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_ppSi(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((void * *)rvalue) = (*(void * (*)(void *, ILUInt16, 
ILInt32))fn)(*((void * *)(avalue[0])), *((ILUInt16 *)(avalue[1])), *((ILInt32 
*)(avalue[2])));
  }
  
***************
*** 590,596 ****
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_ppSi(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((void * *)rvalue) = (*(void * (*)(void *, ILUInt16, 
ILInt32))fn)(*((void * *)(avalue[0])), *((ILUInt16 *)(avalue[1])), *((ILInt32 
*)(avalue[2])));
  }
  
--- 590,596 ----
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_Sppi(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((ILNativeUInt *)rvalue) = (*(ILUInt16 (*)(void *, void *, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 
*)(avalue[2])));
  }
  
***************
*** 599,605 ****
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_Sppi(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((ILNativeUInt *)rvalue) = (*(ILUInt16 (*)(void *, void *, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 
*)(avalue[2])));
  }
  
--- 599,605 ----
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_ippSii(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((ILNativeInt *)rvalue) = (*(ILInt32 (*)(void *, void *, ILUInt16, 
ILInt32, ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), 
*((ILUInt16 *)(avalue[2])), *((ILInt32 *)(avalue[3])), *((ILInt32 
*)(avalue[4])));
  }
  
***************
*** 617,623 ****
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_ippSii(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((ILNativeInt *)rvalue) = (*(ILInt32 (*)(void *, void *, ILUInt16, 
ILInt32, ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), 
*((ILUInt16 *)(avalue[2])), *((ILInt32 *)(avalue[3])), *((ILInt32 
*)(avalue[4])));
  }
  
--- 617,623 ----
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_ippiipiibp(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((ILNativeInt *)rvalue) = (*(ILInt32 (*)(void *, void *, ILInt32, 
ILInt32, void *, ILInt32, ILInt32, ILInt8, void *))fn)(*((void * 
*)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 *)(avalue[2])), *((ILInt32 
*)(avalue[3])), *((void * *)(avalue[4])), *((ILInt32 *)(avalue[5])), *((ILInt32 
*)(avalue[6])), *((ILInt8 *)(avalue[7])), *((void * *)(avalue[8])));
  }
  
***************
*** 626,632 ****
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_ippiipiibp(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((ILNativeInt *)rvalue) = (*(ILInt32 (*)(void *, void *, ILInt32, 
ILInt32, void *, ILInt32, ILInt32, ILInt8, void *))fn)(*((void * 
*)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 *)(avalue[2])), *((ILInt32 
*)(avalue[3])), *((void * *)(avalue[4])), *((ILInt32 *)(avalue[5])), *((ILInt32 
*)(avalue[6])), *((ILInt8 *)(avalue[7])), *((void * *)(avalue[8])));
  }
  
--- 626,632 ----
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_ppppi(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((void * *)rvalue) = (*(void * (*)(void *, void *, void *, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((void * 
*)(avalue[2])), *((ILInt32 *)(avalue[3])));
  }
  
***************
*** 635,641 ****
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_ppppi(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((void * *)rvalue) = (*(void * (*)(void *, void *, void *, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((void * 
*)(avalue[2])), *((ILInt32 *)(avalue[3])));
  }
  
--- 635,641 ----
  #if !defined(HAVE_LIBFFI)
  
! static void marshal_pppii(void (*fn)(), void *rvalue, void **avalue)
  {
!       *((void * *)rvalue) = (*(void * (*)(void *, void *, ILInt32, 
ILInt32))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), *((ILInt32 
*)(avalue[2])), *((ILInt32 *)(avalue[3])));
  }
  
***************
*** 727,740 ****
  IL_METHOD_BEGIN(String_Methods)
        IL_METHOD("Concat", "(oSystem.String;oSystem.String;)oSystem.String;", 
_IL_String_Concat_StringString, marshal_pppp)
-       IL_CONSTRUCTOR(".ctor", "(T[cii)V", 0, 0, _IL_String_ctor_acii, 
marshal_pppii)
        IL_CONSTRUCTOR(".ctor", "(Tci)V", 0, 0, _IL_String_ctor_ci, 
marshal_ppSi)
        IL_CONSTRUCTOR(".ctor", "(T[c)V", 0, 0, _IL_String_ctor_ac, marshal_ppp)
        IL_METHOD("Equals", "(oSystem.String;oSystem.String;)Z", 
_IL_String_Equals, marshal_bppp)
        IL_METHOD("GetChar", "(Ti)c", _IL_String_GetChar, marshal_Sppi)
        IL_METHOD("NewString", "(i)oSystem.String;", _IL_String_NewString, 
marshal_ppi)
        IL_METHOD("Copy", "(oSystem.String;ioSystem.String;ii)V", 
_IL_String_Copy_StringiStringii, marshal_vppipii)
-       IL_METHOD("IndexOf", "(Tcii)i", _IL_String_IndexOf, marshal_ippSii)
        IL_METHOD("InternalCompare", 
"(oSystem.String;iioSystem.String;iiZoSystem.Globalization.CultureInfo;)i", 
_IL_String_InternalCompare, marshal_ippiipiibp)
        IL_METHOD("Trim", "(T[ci)oSystem.String;", _IL_String_Trim, 
marshal_ppppi)
        IL_CONSTRUCTOR(".ctor", "(T*cii)V", 0, 0, _IL_String_ctor_pcii, 
marshal_pppii)
        IL_CONSTRUCTOR(".ctor", "(T*c)V", 0, 0, _IL_String_ctor_pc, marshal_ppp)
--- 727,740 ----
  IL_METHOD_BEGIN(String_Methods)
        IL_METHOD("Concat", "(oSystem.String;oSystem.String;)oSystem.String;", 
_IL_String_Concat_StringString, marshal_pppp)
        IL_CONSTRUCTOR(".ctor", "(Tci)V", 0, 0, _IL_String_ctor_ci, 
marshal_ppSi)
        IL_CONSTRUCTOR(".ctor", "(T[c)V", 0, 0, _IL_String_ctor_ac, marshal_ppp)
        IL_METHOD("Equals", "(oSystem.String;oSystem.String;)Z", 
_IL_String_Equals, marshal_bppp)
        IL_METHOD("GetChar", "(Ti)c", _IL_String_GetChar, marshal_Sppi)
+       IL_METHOD("IndexOf", "(Tcii)i", _IL_String_IndexOf, marshal_ippSii)
        IL_METHOD("NewString", "(i)oSystem.String;", _IL_String_NewString, 
marshal_ppi)
        IL_METHOD("Copy", "(oSystem.String;ioSystem.String;ii)V", 
_IL_String_Copy_StringiStringii, marshal_vppipii)
        IL_METHOD("InternalCompare", 
"(oSystem.String;iioSystem.String;iiZoSystem.Globalization.CultureInfo;)i", 
_IL_String_InternalCompare, marshal_ippiipiibp)
        IL_METHOD("Trim", "(T[ci)oSystem.String;", _IL_String_Trim, 
marshal_ppppi)
+       IL_CONSTRUCTOR(".ctor", "(T[cii)V", 0, 0, _IL_String_ctor_acii, 
marshal_pppii)
        IL_CONSTRUCTOR(".ctor", "(T*cii)V", 0, 0, _IL_String_ctor_pcii, 
marshal_pppii)
        IL_CONSTRUCTOR(".ctor", "(T*c)V", 0, 0, _IL_String_ctor_pc, marshal_ppp)
***************
*** 964,967 ****
--- 964,976 ----
  #if !defined(HAVE_LIBFFI)
  
+ static void marshal_pp(void (*fn)(), void *rvalue, void **avalue)
+ {
+       *((void * *)rvalue) = (*(void * (*)(void *))fn)(*((void * 
*)(avalue[0])));
+ }
+ 
+ #endif
+ 
+ #if !defined(HAVE_LIBFFI)
+ 
  static void marshal_vpi(void (*fn)(), void *rvalue, void **avalue)
  {
***************
*** 1124,1140 ****
  #endif
  
- #if !defined(HAVE_LIBFFI)
- 
- static void marshal_pp(void (*fn)(), void *rvalue, void **avalue)
- {
-       *((void * *)rvalue) = (*(void * (*)(void *))fn)(*((void * 
*)(avalue[0])));
- }
- 
- #endif
- 
  #ifndef _IL_Thread_suppressed
  
  IL_METHOD_BEGIN(Thread_Methods)
        IL_METHOD("InternalGetThreadId", "()i", _IL_Thread_InternalGetThreadId, 
marshal_ip)
        IL_METHOD("InitializeThread", "(T)V", _IL_Thread_InitializeThread, 
marshal_vpp)
        IL_METHOD("FinalizeThread", "(T)V", _IL_Thread_FinalizeThread, 
marshal_vpp)
--- 1133,1141 ----
  #endif
  
  #ifndef _IL_Thread_suppressed
  
  IL_METHOD_BEGIN(Thread_Methods)
        IL_METHOD("InternalGetThreadId", "()i", _IL_Thread_InternalGetThreadId, 
marshal_ip)
+       IL_METHOD("InternalCurrentThread", "()oSystem.Threading.Thread;", 
_IL_Thread_InternalCurrentThread, marshal_pp)
        IL_METHOD("InitializeThread", "(T)V", _IL_Thread_InitializeThread, 
marshal_vpp)
        IL_METHOD("FinalizeThread", "(T)V", _IL_Thread_FinalizeThread, 
marshal_vpp)
***************
*** 1171,1175 ****
        IL_METHOD("VolatileWrite", "(&dd)V", _IL_Thread_VolatileWrite_Rdd, 
marshal_vppd)
        IL_METHOD("VolatileWrite", "(&oSystem.Object;oSystem.Object;)V", 
_IL_Thread_VolatileWrite_RObjectObject, marshal_vppp)
-       IL_METHOD("InternalCurrentThread", "()oSystem.Threading.Thread;", 
_IL_Thread_InternalCurrentThread, marshal_pp)
        IL_METHOD("InternalGetState", "(T)vSystem.Threading.ThreadState;", 
_IL_Thread_InternalGetState, marshal_ipp)
        IL_METHOD("InternalSetBackground", "(TZ)V", 
_IL_Thread_InternalSetBackground, marshal_vppb)
--- 1172,1175 ----
***************
*** 1737,1788 ****
  #endif
  
- #if !defined(HAVE_LIBFFI)
- 
- static void marshal_ppppiipipp(void (*fn)(), void *rvalue, void **avalue)
- {
-       *((void * *)rvalue) = (*(void * (*)(void *, void *, void *, ILInt32, 
ILInt32, void *, ILInt32, void *, void *))fn)(*((void * *)(avalue[0])), *((void 
* *)(avalue[1])), *((void * *)(avalue[2])), *((ILInt32 *)(avalue[3])), 
*((ILInt32 *)(avalue[4])), *((void * *)(avalue[5])), *((ILInt32 *)(avalue[6])), 
*((void * *)(avalue[7])), *((void * *)(avalue[8])));
- }
- 
- #endif
- 
- #if !defined(HAVE_LIBFFI)
- 
- static void marshal_pppiipp(void (*fn)(), void *rvalue, void **avalue)
- {
-       *((void * *)rvalue) = (*(void * (*)(void *, void *, ILInt32, ILInt32, 
void *, void *))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), 
*((ILInt32 *)(avalue[2])), *((ILInt32 *)(avalue[3])), *((void * *)(avalue[4])), 
*((void * *)(avalue[5])));
- }
- 
- #endif
- 
- #ifndef _IL_ClrType_suppressed
- 
- IL_METHOD_BEGIN(ClrType_Methods)
-       IL_METHOD("GetClrArrayRank", "(T)i", _IL_ClrType_GetClrArrayRank, 
marshal_ipp)
-       IL_METHOD("GetAttributeFlagsImpl", 
"(T)vSystem.Reflection.TypeAttributes;", _IL_ClrType_GetAttributeFlagsImpl, 
marshal_ipp)
-       IL_METHOD("GetClrTypeCategory", 
"(T)vSystem.Reflection.ClrTypeCategory;", _IL_ClrType_GetClrTypeCategory, 
marshal_ipp)
-       IL_METHOD("GetElementType", "(T)oSystem.Type;", 
_IL_ClrType_GetElementType, marshal_ppp)
-       IL_METHOD("GetInterfaces", "(T)[oSystem.Type;", 
_IL_ClrType_GetInterfaces, marshal_ppp)
-       IL_METHOD("IsSubclassOf", "(ToSystem.Type;)Z", 
_IL_ClrType_IsSubclassOf, marshal_bppp)
-       IL_METHOD("GetClrFullName", "(T)oSystem.String;", 
_IL_ClrType_GetClrFullName, marshal_ppp)
-       IL_METHOD("GetClrAssembly", "(T)oSystem.Reflection.Assembly;", 
_IL_ClrType_GetClrAssembly, marshal_ppp)
-       IL_METHOD("GetClrBaseType", "(T)oSystem.Type;", 
_IL_ClrType_GetClrBaseType, marshal_ppp)
-       IL_METHOD("GetInterface", "(ToSystem.String;Z)oSystem.Type;", 
_IL_ClrType_GetInterface, marshal_ppppb)
-       IL_METHOD("GetMemberImpl", 
"(ToSystem.String;vSystem.Reflection.MemberTypes;vSystem.Reflection.BindingFlags;oSystem.Reflection.Binder;vSystem.Reflection.CallingConventions;[oSystem.Type;[vSystem.Reflection.ParameterModifier;)oSystem.Reflection.MemberInfo;",
 _IL_ClrType_GetMemberImpl, marshal_ppppiipipp)
-       IL_METHOD("GetMembersImpl", 
"(TvSystem.Reflection.MemberTypes;vSystem.Reflection.BindingFlags;oSystem.Type;oSystem.String;)oSystem.Object;",
 _IL_ClrType_GetMembersImpl, marshal_pppiipp)
-       IL_METHOD("IsClrNestedType", "(T)Z", _IL_ClrType_IsClrNestedType, 
marshal_bpp)
-       IL_METHOD("GetClrGUID", "(T)vSystem.Guid;", _IL_ClrType_GetClrGUID, 
marshal_vppp)
-       IL_METHOD("GetClrModule", "(T)oSystem.Reflection.Module;", 
_IL_ClrType_GetClrModule, marshal_ppp)
-       IL_METHOD("GetClrNestedDeclaringType", "(T)oSystem.Type;", 
_IL_ClrType_GetClrNestedDeclaringType, marshal_ppp)
-       IL_METHOD("GetClrName", "(T)oSystem.String;", _IL_ClrType_GetClrName, 
marshal_ppp)
-       IL_METHOD("GetClrNamespace", "(T)oSystem.String;", 
_IL_ClrType_GetClrNamespace, marshal_ppp)
-       IL_METHOD("IsGenericTypeImpl", "(T)Z", _IL_ClrType_IsGenericTypeImpl, 
marshal_bpp)
-       IL_METHOD("ArityImpl", "(T)i", _IL_ClrType_ArityImpl, marshal_ipp)
-       IL_METHOD("GetInstantiation", "(T)[oSystem.Type;", 
_IL_ClrType_GetInstantiation, marshal_ppp)
-       IL_METHOD("Instantiate", "(T[oSystem.Type;)oSystem.Type;", 
_IL_ClrType_Instantiate, marshal_pppp)
-       IL_METHOD("GetGenericType", "(T)oSystem.Type;", 
_IL_ClrType_GetGenericType, marshal_ppp)
- IL_METHOD_END
- 
- #endif
- 
  #ifndef _IL_ClrParameter_suppressed
  
--- 1737,1740 ----
***************
*** 1840,1843 ****
--- 1792,1843 ----
  #endif
  
+ #if !defined(HAVE_LIBFFI)
+ 
+ static void marshal_ppppiipipp(void (*fn)(), void *rvalue, void **avalue)
+ {
+       *((void * *)rvalue) = (*(void * (*)(void *, void *, void *, ILInt32, 
ILInt32, void *, ILInt32, void *, void *))fn)(*((void * *)(avalue[0])), *((void 
* *)(avalue[1])), *((void * *)(avalue[2])), *((ILInt32 *)(avalue[3])), 
*((ILInt32 *)(avalue[4])), *((void * *)(avalue[5])), *((ILInt32 *)(avalue[6])), 
*((void * *)(avalue[7])), *((void * *)(avalue[8])));
+ }
+ 
+ #endif
+ 
+ #if !defined(HAVE_LIBFFI)
+ 
+ static void marshal_pppiipp(void (*fn)(), void *rvalue, void **avalue)
+ {
+       *((void * *)rvalue) = (*(void * (*)(void *, void *, ILInt32, ILInt32, 
void *, void *))fn)(*((void * *)(avalue[0])), *((void * *)(avalue[1])), 
*((ILInt32 *)(avalue[2])), *((ILInt32 *)(avalue[3])), *((void * *)(avalue[4])), 
*((void * *)(avalue[5])));
+ }
+ 
+ #endif
+ 
+ #ifndef _IL_ClrType_suppressed
+ 
+ IL_METHOD_BEGIN(ClrType_Methods)
+       IL_METHOD("GetClrArrayRank", "(T)i", _IL_ClrType_GetClrArrayRank, 
marshal_ipp)
+       IL_METHOD("GetAttributeFlagsImpl", 
"(T)vSystem.Reflection.TypeAttributes;", _IL_ClrType_GetAttributeFlagsImpl, 
marshal_ipp)
+       IL_METHOD("GetClrTypeCategory", 
"(T)vSystem.Reflection.ClrTypeCategory;", _IL_ClrType_GetClrTypeCategory, 
marshal_ipp)
+       IL_METHOD("GetElementType", "(T)oSystem.Type;", 
_IL_ClrType_GetElementType, marshal_ppp)
+       IL_METHOD("GetInterfaces", "(T)[oSystem.Type;", 
_IL_ClrType_GetInterfaces, marshal_ppp)
+       IL_METHOD("IsSubclassOf", "(ToSystem.Type;)Z", 
_IL_ClrType_IsSubclassOf, marshal_bppp)
+       IL_METHOD("GetClrFullName", "(T)oSystem.String;", 
_IL_ClrType_GetClrFullName, marshal_ppp)
+       IL_METHOD("GetClrAssembly", "(T)oSystem.Reflection.Assembly;", 
_IL_ClrType_GetClrAssembly, marshal_ppp)
+       IL_METHOD("GetClrBaseType", "(T)oSystem.Type;", 
_IL_ClrType_GetClrBaseType, marshal_ppp)
+       IL_METHOD("GetInterface", "(ToSystem.String;Z)oSystem.Type;", 
_IL_ClrType_GetInterface, marshal_ppppb)
+       IL_METHOD("GetMemberImpl", 
"(ToSystem.String;vSystem.Reflection.MemberTypes;vSystem.Reflection.BindingFlags;oSystem.Reflection.Binder;vSystem.Reflection.CallingConventions;[oSystem.Type;[vSystem.Reflection.ParameterModifier;)oSystem.Reflection.MemberInfo;",
 _IL_ClrType_GetMemberImpl, marshal_ppppiipipp)
+       IL_METHOD("GetMembersImpl", 
"(TvSystem.Reflection.MemberTypes;vSystem.Reflection.BindingFlags;oSystem.Type;oSystem.String;)oSystem.Object;",
 _IL_ClrType_GetMembersImpl, marshal_pppiipp)
+       IL_METHOD("IsClrNestedType", "(T)Z", _IL_ClrType_IsClrNestedType, 
marshal_bpp)
+       IL_METHOD("GetClrGUID", "(T)vSystem.Guid;", _IL_ClrType_GetClrGUID, 
marshal_vppp)
+       IL_METHOD("GetClrModule", "(T)oSystem.Reflection.Module;", 
_IL_ClrType_GetClrModule, marshal_ppp)
+       IL_METHOD("GetClrNestedDeclaringType", "(T)oSystem.Type;", 
_IL_ClrType_GetClrNestedDeclaringType, marshal_ppp)
+       IL_METHOD("GetClrName", "(T)oSystem.String;", _IL_ClrType_GetClrName, 
marshal_ppp)
+       IL_METHOD("GetClrNamespace", "(T)oSystem.String;", 
_IL_ClrType_GetClrNamespace, marshal_ppp)
+       IL_METHOD("IsGenericTypeImpl", "(T)Z", _IL_ClrType_IsGenericTypeImpl, 
marshal_bpp)
+       IL_METHOD("ArityImpl", "(T)i", _IL_ClrType_ArityImpl, marshal_ipp)
+       IL_METHOD("GetInstantiation", "(T)[oSystem.Type;", 
_IL_ClrType_GetInstantiation, marshal_ppp)
+       IL_METHOD("Instantiate", "(T[oSystem.Type;)oSystem.Type;", 
_IL_ClrType_Instantiate, marshal_pppp)
+       IL_METHOD("GetGenericType", "(T)oSystem.Type;", 
_IL_ClrType_GetGenericType, marshal_ppp)
+ IL_METHOD_END
+ 
+ #endif
+ 
  #ifndef _IL_Module_suppressed
  
***************
*** 1871,1874 ****
--- 1871,1883 ----
  #endif
  
+ #if !defined(HAVE_LIBFFI)
+ 
+ static void marshal_ipjjp(void (*fn)(), void *rvalue, void **avalue)
+ {
+       *((ILNativeInt *)rvalue) = (*(ILInt32 (*)(void *, ILNativeUInt, 
ILNativeUInt, void *))fn)(*((void * *)(avalue[0])), *((ILNativeUInt 
*)(avalue[1])), *((ILNativeUInt *)(avalue[2])), *((void * *)(avalue[3])));
+ }
+ 
+ #endif
+ 
  #ifndef _IL_AssemblyBuilder_suppressed
  
***************
*** 1876,1879 ****
--- 1885,1889 ----
        IL_METHOD("ClrAssemblyCreate", 
"(oSystem.String;iiiivSystem.Reflection.Emit.AssemblyBuilderAccess;&j)j", 
_IL_AssemblyBuilder_ClrAssemblyCreate, marshal_jppiiiiip)
        IL_METHOD("ClrSave", 
"(jjoSystem.String;jvSystem.Reflection.Emit.PEFileKinds;)Z", 
_IL_AssemblyBuilder_ClrSave, marshal_bpjjpji)
+       IL_METHOD("ClrWriteMethod", "(jj[B)i", 
_IL_AssemblyBuilder_ClrWriteMethod, marshal_ipjjp)
        IL_METHOD("ClrGetItemToken", "(j)i", 
_IL_AssemblyBuilder_ClrGetItemToken, marshal_ipj)
        IL_METHOD("ClrGetItemFromToken", "(ji)j", 
_IL_AssemblyBuilder_ClrGetItemFromToken, marshal_jpji)
***************
*** 2383,2389 ****
  
  IL_METHOD_BEGIN(InfoMethods_Methods)
-       IL_METHOD("GetPlatformID", "()vSystem.PlatformID;", 
_IL_InfoMethods_GetPlatformID, marshal_ip)
        IL_METHOD("GetRuntimeVersion", "()oSystem.String;", 
_IL_InfoMethods_GetRuntimeVersion, marshal_pp)
        IL_METHOD("GetNetBIOSMachineName", "()oSystem.String;", 
_IL_InfoMethods_GetNetBIOSMachineName, marshal_pp)
        IL_METHOD("GetUserDomainName", "()oSystem.String;", 
_IL_InfoMethods_GetUserDomainName, marshal_pp)
        IL_METHOD("IsUserInteractive", "()Z", 
_IL_InfoMethods_IsUserInteractive, marshal_bp)
--- 2393,2399 ----
  
  IL_METHOD_BEGIN(InfoMethods_Methods)
        IL_METHOD("GetRuntimeVersion", "()oSystem.String;", 
_IL_InfoMethods_GetRuntimeVersion, marshal_pp)
        IL_METHOD("GetNetBIOSMachineName", "()oSystem.String;", 
_IL_InfoMethods_GetNetBIOSMachineName, marshal_pp)
+       IL_METHOD("GetPlatformID", "()vSystem.PlatformID;", 
_IL_InfoMethods_GetPlatformID, marshal_ip)
        IL_METHOD("GetUserDomainName", "()oSystem.String;", 
_IL_InfoMethods_GetUserDomainName, marshal_pp)
        IL_METHOD("IsUserInteractive", "()Z", 
_IL_InfoMethods_IsUserInteractive, marshal_bp)

Index: lib_emit.c
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/lib_emit.c,v
retrieving revision 1.21
retrieving revision 1.22
diff -C2 -r1.21 -r1.22
*** lib_emit.c  23 Jul 2003 04:01:45 -0000      1.21
--- lib_emit.c  23 Jul 2003 15:35:45 -0000      1.22
***************
*** 224,227 ****
--- 224,251 ----
        return (ILBool)1;
  }
+ /*
+  * private static int ClrWriteMethod(IntPtr assembly, IntPtr writer, byte[] 
code);
+  */
+ ILInt32 _IL_AssemblyBuilder_ClrWriteMethod(ILExecThread *_thread,
+                                            ILNativeInt _assembly,
+                                            ILNativeInt _writer,
+                                            System_Array *_code)
+ {
+       ILInt32 retval;
+       ILWriter *writer;
+       unsigned char *buf;
+       unsigned long len;
+ 
+       IL_METADATA_WRLOCK(_thread);
+ 
+       writer = (ILWriter *)_writer;
+       buf = (unsigned char *)ArrayToBuffer(_code);
+       len = (unsigned long)_code->length;
+       retval = (ILInt32)ILWriterGetTextRVA(writer);
+       ILWriterTextWrite(writer, buf, len);
+ 
+       IL_METADATA_UNLOCK(_thread);
+       return retval;
+ }
  
  /*
***************
*** 940,951 ****
                nameSpace = 0;
        }
!       if(!token && typeName &&
!               ((!strcmp("<Module>", typeName) && nameSpace==NULL) 
!               || (!strcmp("Object", typeName) && nameSpace && 
!                                        !strcmp("System", nameSpace)) 
!               || (attr & IL_META_TYPEDEF_INTERFACE))) 
        {
!               /* interfaces , <Module> and System.Object */
!               baseClass=NULL;
        }
        else if (!(baseClass = ILClass_FromToken(image, token)))
--- 964,974 ----
                nameSpace = 0;
        }
!       if (!token &&
!           ((!strcmp("<Module>", typeName) && !nameSpace) ||
!            (!strcmp("Object", typeName) && nameSpace && !strcmp("System", 
nameSpace)) ||
!            (attr & IL_META_TYPEDEF_INTERFACE)))
        {
!               /* interfaces, <Module>, and System.Object */
!               baseClass = NULL;
        }
        else if (!(baseClass = ILClass_FromToken(image, token)))





reply via email to

[Prev in Thread] Current Thread [Next in Thread]