قالب وردپرس درنا توس
Home / IOS Development / Radar: [Xcode] Enables expansion-safe API check changes generated ObjC-Header

Radar: [Xcode] Enables expansion-safe API check changes generated ObjC-Header



<! –

->

Usually, you only need "Allow app extension API only" for expansion targets to be warned if you access APIs that are not available for extensions. I had made it possible for a framework to make sure I did not call the banned API.

I found this issue at the same time as this other issue because my client complained about both issues: Do not see any documentation through Quick Help also as the generated headline unnecessarily contains internal classes. This problem was already present in Xcode 8, as evidenced by someone asking for it at Stack Overflow.

Filed as rdar: // 34790796 and on Open Radar. The mentioned sample is on my Radar Samples GitHub repo, titled InterfaceTest.

Summary

For Swift-based frames / modules, Xcode generates a Objective-C header named Module-Swift.h . Usually this includes only public classes. But if you turn on "Allow only app extension API API," then internal classes are included.

Steps to Reproduce

  1. Build Module Form in the Specified Test Application with Xcode 9
  2. Inspect Module- Swift.h contained in the Manufactured Module.
  3. You will only see public classes CustomView and AncestorView
  4. Now turn on "Allow app extension API only" in Module Target build building settings and rebuild
  5. Check the same heading as in Step 1
    .

Expected Results [19659015] The generated Objective-C header should be identical regardless of the state of this setting

Actual Results

  • ] With the setting, only public classes appear
  • With the setting on, you also see The Internal Class SwiftViewController

Version / Build

Xcode 9.0 (9A235)

Configuration [19659007] iMac or MacBo ok, with xcode 9 and macos 10.13


Categories: Error reports


Source link