Files
rea/tests/conformance/native/dispatch.m
T
Kaoru0822andClaude Opus 5.5 3e24a72465 feat(native): decode chained fixups, binds, ObjC categories and properties
inspect_native_dispatch_metadata read pointer fields as stored bytes, so
chained-fixup images (the default since Xcode 13) decoded no classes, and
superclasses from other images were always unresolved.

- Decode LC_DYLD_CHAINED_FIXUPS pointer formats 64, 64_OFFSET, ARM64E,
  ARM64E_USERLAND and ARM64E_USERLAND24 with import formats 1-3, and
  interpret LC_DYLD_INFO bind, weak-bind and lazy-bind opcode streams.
- Name external superclasses from their _OBJC_CLASS_$_ binds.
- Decode class_ro_t baseProperties and __objc_catlist category_t records
  (instance/class methods, protocols, properties) into objc_categories;
  category methods carry their category name.
- Report the fixup encoding in a pointer_fixups coverage facet.
- verify:apple-dispatch builds the fixture with dyld-info and chained
  fixups, plus arm64e on Apple silicon.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 12:18:24 +00:00

28 lines
699 B
Objective-C

#import <Foundation/Foundation.h>
@protocol ReaDispatchProtocol
- (void)performAction:(id)sender;
@optional
- (int)optionalFixtureValue;
@end
@interface ReaDispatchFixture : NSObject <ReaDispatchProtocol> {
int state;
}
@property(nonatomic, copy) NSString *fixtureName;
- (void)performAction:(id)sender;
+ (int)fixtureVersion;
@end
@implementation ReaDispatchFixture
- (void)performAction:(id)sender { state += sender == nil ? 1 : 2; }
+ (int)fixtureVersion { return 1; }
@end
@interface NSString (ReaDispatchAdditions)
- (NSUInteger)reaFixtureLength;
@end
@implementation NSString (ReaDispatchAdditions)
- (NSUInteger)reaFixtureLength { return self.length; }
@end
int main(void) { return 0; }