Titanium JIRA Archive
Appcelerator Community (AC)

[AC-2288] ARC plugin compilation fails with 'error: overriding method has mismatched ns_returns_not_retained attributes'

GitHub Issuen/a
TypeBug
Priorityn/a
StatusClosed
ResolutionFixed
Resolution Date2013-04-28T15:53:38.000+0000
Affected Version/sn/a
Fix Version/sn/a
ComponentsTitanium SDK & CLI
Labelsbug
ReporterPeter Steinberger
AssigneeShak Hossain
Created2013-03-07T18:23:37.000+0000
Updated2016-03-08T07:41:17.000+0000

Description

Compilation of my plugin fails here. This is a regression from 3.0.0, where everything worked. In file included from /Users/steipete/Documents/Projects/PSPDFKit/Titanium/Classes/TIPSPDFViewControllerProxy.m:8: In file included from /Users/steipete/Documents/Projects/PSPDFKit/Titanium/Classes/TIPSPDFViewControllerProxy.h:9: In file included from /Users/steipete/Library/Application Support/Titanium/mobilesdk/osx/3.0.2.GA/iphone/include/TiModule.h:8: In file included from /Users/steipete/Library/Application Support/Titanium/mobilesdk/osx/3.0.2.GA/iphone/include/TiUtils.h:26: /Users/steipete/Library/Application Support/Titanium/mobilesdk/osx/3.0.2.GA/iphone/include/TiBuffer.h:28:1: error: overriding method has mismatched ns_returns_not_retained attributes -(NSNumber*)copy:(id)args NS_RETURNS_NOT_RETAINED; ^ /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIResponder.h:50:1: note: method declared here - (void)copy:(id)sender NS_AVAILABLE_IOS(3_0); ^ 1 error generated. I suggest changing the custom copy: to something prefixed, or removing the NS_RETURNS_NOT_RETAINED to fix this issue.

Comments

  1. Peter Steinberger 2013-03-07

    The PSPDFKit Titanium plugin uses ARC, seems I'm pretty much the first one to use ARC so I run into all kinds of problems :/
  2. Peter Steinberger 2013-03-07

    Removing the NS_RETURNS_NOT_RETAINED works and I'm able to compile again - but it doesn't seem like a good idea. Please properly fix this. (I can provide you with the PSPDFKit sources to test this if you keep them private)
  3. Michael Browne 2013-03-07

    Any idea when this issue will be resolved. Been having problems compiling modules with this error. Stuck using older versions of the SDK and having to do several different work arounds.
  4. Jamie Buckley 2013-04-03

    We do not currently support ARC.
  5. Peter Steinberger 2013-04-04

  6. Pedro Enrique 2013-04-04

  7. Neeraj Gupta 2013-04-28

    This issue has been resolved with 3.1.0 release.
  8. Shak Hossain 2014-01-03

JSON Source