You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Reported in version: HG 2.0 Reported for operating system, platform: Mac OS X (All), x86
Comments on the original bug report:
On 2014-07-14 02:55:25 +0000, Alex Szpakowski wrote:
Created attachment 1753
Fix for including SDL_syswm.h in ObjC files which use ARC
In OS X and iOS, the SDL_SysWMinfo struct contains a struct which has an Objective-C object (an NSWindow or UIWindow for OS X or iOS respectively.)
When using Objective-C's Automatic Reference Counting mode in a file, Objective-C objects normally aren't allowed to be inside C structs or unions unless they're tagged with '__unsafe_unretained'.
The NSWindow and UIWindow objects in the SDL_SysWMinfo struct don't have that tag right now, which is a problem because an Objective-C file using ARC can include SDL_syswm.h but the compiler won't the struct be constructed in that file.
I have attached a patch which properly tags the objects in the struct with '__unsafe_unretained' when SDL_syswm.h is included in a file which uses Objective-C's ARC.
This shouldn't affect internal SDL behaviour at all, since none of its Objective-C code uses ARC (yet.)
On 2014-07-30 18:14:58 +0000, Ryan C. Gordon wrote:
This bug report was migrated from our old Bugzilla tracker.
These attachments are available in the static archive:
Reported in version: HG 2.0
Reported for operating system, platform: Mac OS X (All), x86
Comments on the original bug report:
On 2014-07-14 02:55:25 +0000, Alex Szpakowski wrote:
On 2014-07-30 18:14:58 +0000, Ryan C. Gordon wrote:
The text was updated successfully, but these errors were encountered: