mac SDK: AVSampleBufferDisplayLayer is marked as 10.10+, but has been available since 10.8, and was in the 10.8 SDK

Originator:thakis
Number:rdar://33456649 Date Originated:2017 Jul 21
Status:new Resolved:
Product:macOS + SDK Product Version:
Classification:other bug Reproducible:always
 
AVSampleBufferDisplayLayer is marked as being available since macOS 10.10, and clang insists on it being used in @available(macos 10.10, *).

However, AVSampleBufferDisplayLayer has been around as public API since 10.8. The availability annotation should be fixed.

Set deployment target to 10.9, build a program that uses AVSampleBufferDisplayLayer.

Expected Results:
No diagnostic.

Observed Results:
-Wunguarded-availability gets emitted

Version:
I'm building on macOS 10.12, but that's irrelevant to this bug.

Notes:
This currently requires yucky workarounds like https://cs.chromium.org/chromium/src/ui/accelerated_widget_mac/availability_macros.h?type=cs&q=AVSampleBufferDisplayLayer&sq=package:chromium&l=5

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!