• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Returning values from objc_msgSend etc
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Returning values from objc_msgSend etc


  • Subject: Re: Returning values from objc_msgSend etc
  • From: Bill Bumgarner <email@hidden>
  • Date: Sat, 1 Mar 2008 09:30:44 -0800

On Mar 1, 2008, at 5:00 AM, Greg Parker wrote:
The right way to fix this is to add new API in libobjc: given an ffi_type, return the correct objc_msgSend function pointer for that return type. I filed the feature request for that today. Until then you'll still need to handle that choice yourself. All of the required code is in libffi somewhere, but there's no way for you to call it directly. libffi is open source, so you could try digging through the implementation and copying the code you want into your program.

Both PyObjC and RubyCocoa (and F-Script Anywhere, for that matter), use FFI to call objc_msgSend(). Both have extensive unit tests and, thus, the logic seems to be correct.


Their licenses are liberal enough that you can lift the logic pretty much directly and munge for your purposes.

b.bum
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Re: Returning values from objc_msgSend etc (From: "Sherm Pendley" <email@hidden>)
 >Re: Returning values from objc_msgSend etc (From: Greg Parker <email@hidden>)

  • Prev by Date: Re: Scrollers on custom view appearing but not disappearing
  • Next by Date: Re: Scrollers on custom view appearing but not disappearing
  • Previous by thread: Re: Returning values from objc_msgSend etc
  • Next by thread: Re: Returning values from objc_msgSend etc
  • Index(es):
    • Date
    • Thread