Big Papoo
Big Papoo

Reputation: 167

Apportable - Is -objc-arc supported?

I've a project with a bunch of files tagged as "-objc-arc" but when compiling with apportable I have tons of errors like: error: cast of C pointer type 'CFStringRef' (aka 'const struct __CFString *') to Objective-C pointer type 'NSString *' requires a bridged cast which I suspect is coming from the lack of support of the "objc-arc" flag. Did I miss something?

[EDIT] I missed to tell that I'm talking about compiling code with "Apportable" SDK/Compiler

Upvotes: 2

Views: 1085

Answers (1)

Paul Beusterien
Paul Beusterien

Reputation: 29582

The clang compiler in the Apportable SDK compiles files with or without the objc-arc, just as is specified in the xcode project.

The issue is likely that you are using an older, less strict version of clang with xcode. If you add the bridged casts, your code should work now with Apportable and with upcoming versions of xcode.

See here for more about why the bridged casts are needed.

Upvotes: 6

Related Questions