Skip to content

objc: add NSArray to []objc.ID slice support in Send and SendSuper#411

Open
tmc wants to merge 1 commit intoebitengine:mainfrom
tmc:objc-nsarray-slice-support
Open

objc: add NSArray to []objc.ID slice support in Send and SendSuper#411
tmc wants to merge 1 commit intoebitengine:mainfrom
tmc:objc-nsarray-slice-support

Conversation

@tmc
Copy link
Contributor

@tmc tmc commented Feb 7, 2026

What issue is this addressing?

#410

What type of issue is this addressing?

feature

What this PR does | solves

Add NSArrayToSlice helper that iterates an NSArray via count and objectAtIndex: to produce a []objc.ID. Intercept reflect.Slice in Send[T] and SendSuper[T] to automatically convert NSArray returns, avoiding the "unsupported return kind: slice" panic from purego core.

Unsupported element types (e.g. []string) panic with a clear message.

Add NSArrayToSlice helper that iterates an NSArray via count and
objectAtIndex: to produce a []objc.ID. Intercept reflect.Slice in
Send[T] and SendSuper[T] to automatically convert NSArray returns,
avoiding the "unsupported return kind: slice" panic from purego core.

Unsupported element types (e.g. []string) panic with a clear message.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant