Libbinder APIs are guarded
The following API was added for the API level 30 and beyond. Currently, its existence is tested using the null check which is done regardless of the min sdk version of the compilation unit. (which in turn required us to mark the API symbol weak regardless of the min sdk version.) API 30: * AStatus_getDescription * AIBinder_Class_setHandleShellCommand API 31: * AParcel_getDataSize * AParcel_reset * AParcel_appendFrom Now, we have a better way of testing the API availability; __builtin_available. The null check is replaced with the call to the compiler-provided macro which determines if the code is running in a version of OS where the API is known to exist. Also, this change removes __ANDROID_API__ guards in favor of __INTRODUCED_IN macros. Bug: 150860940 Bug: 134795810 Test: m Change-Id: I78d2fdc0bf60bd8c5a82ec58884422dc534e752f
Loading
Please register or sign in to comment