il2cpp-mapping.h 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. #pragma once
  2. #include "il2cpp-metadata.h"
  3. struct MonoMethodInfoMetadata
  4. {
  5. int64_t hash;
  6. int32_t invoker_index;
  7. int32_t method_pointer_index;
  8. };
  9. struct MonoRGCTXDefinition
  10. {
  11. Il2CppRGCTXDataType type;
  12. AssemblyIndex assemblyIndex;
  13. int32_t token;
  14. int32_t generic_parameter_index;
  15. };
  16. struct RuntimeGenericContextInfo
  17. {
  18. uint64_t hash;
  19. int32_t rgctxStart;
  20. int32_t rgctxCount;
  21. };
  22. struct MonoMetadataToken
  23. {
  24. AssemblyIndex assemblyIndex;
  25. int32_t token;
  26. };
  27. #pragma pack(push, p1,4)
  28. struct MonoMethodMetadata
  29. {
  30. MonoMetadataToken metadataToken;
  31. MethodIndex reversePInvokeWrapperIndex;
  32. uint64_t hash;
  33. };
  34. #pragma pack(pop, p1)
  35. #pragma pack(push, p1,4)
  36. struct MonoClassMetadata
  37. {
  38. MonoMetadataToken metadataToken;
  39. int32_t genericParametersOffset;
  40. int32_t genericParametersCount;
  41. int32_t isPointer;
  42. int32_t rank; //if rank == 0, the token is for a non-array type, otherwise the rank is valid and the token represents the element type of the array
  43. int32_t elementTypeIndex;
  44. };
  45. #pragma pack(pop, p1)
  46. struct MonoFieldMetadata
  47. {
  48. TypeIndex parentTypeIndex;
  49. int32_t token;
  50. };
  51. struct MonoGenericInstMetadata
  52. {
  53. uint32_t type_argc;
  54. const TypeIndex *type_argv_indices;
  55. };