#include "mono/metadata/gc-internals.h"
#include "mono/metadata/mono-endian.h"
#include "mono/metadata/object-internals.h"
-#include "mono/metadata/reflection-cache.h"
#include "mono/metadata/custom-attrs-internals.h"
#include "mono/metadata/sre-internals.h"
#include "mono/metadata/reflection-internals.h"
* Find the property index in the metadata Property table.
*/
static guint32
-find_property_index (MonoClass *klass, MonoProperty *property) {
+find_property_index (MonoClass *klass, MonoProperty *property)
+{
int i;
- MonoClassExt *ext = mono_class_get_ext (klass);
+ MonoClassPropertyInfo *info = mono_class_get_property_info (klass);
- for (i = 0; i < ext->property.count; ++i) {
- if (property == &ext->properties [i])
- return ext->property.first + 1 + i;
+ for (i = 0; i < info->count; ++i) {
+ if (property == &info->properties [i])
+ return info->first + 1 + i;
}
return 0;
}
* Find the event index in the metadata Event table.
*/
static guint32
-find_event_index (MonoClass *klass, MonoEvent *event) {
+find_event_index (MonoClass *klass, MonoEvent *event)
+{
int i;
- MonoClassExt *ext = mono_class_get_ext (klass);
+ MonoClassEventInfo *info = mono_class_get_event_info (klass);
- for (i = 0; i < ext->event.count; ++i) {
- if (event == &ext->events [i])
- return ext->event.first + 1 + i;
+ for (i = 0; i < info->count; ++i) {
+ if (event == &info->events [i])
+ return info->first + 1 + i;
}
return 0;
}