[ObjCExport] Split ObjCExport into K1 and Analysis Api implementation

FL-23390
^KT-64168 Fixed
This commit is contained in:
Sebastian Sellmair
2023-12-06 18:14:00 +01:00
committed by Space Team
parent 3e57265fcb
commit e409c60780
95 changed files with 1042 additions and 383 deletions
@@ -0,0 +1,35 @@
#import <Foundation/NSArray.h>
#import <Foundation/NSDictionary.h>
#import <Foundation/NSError.h>
#import <Foundation/NSObject.h>
#import <Foundation/NSSet.h>
#import <Foundation/NSString.h>
#import <Foundation/NSValue.h>
@class Foo;
NS_ASSUME_NONNULL_BEGIN
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wunknown-warning-option"
#pragma clang diagnostic ignored "-Wincompatible-property-type"
#pragma clang diagnostic ignored "-Wnullability"
#pragma push_macro("_Nullable_result")
#if !__has_feature(nullability_nullable_result)
#undef _Nullable_result
#define _Nullable_result _Nullable
#endif
__attribute__((objc_subclassing_restricted))
@interface Foo : Base
+ (instancetype)alloc __attribute__((unavailable));
+ (instancetype)allocWithZone:(struct _NSZone *)zone __attribute__((unavailable));
+ (instancetype)foo __attribute__((swift_name("init()")));
@property (class, readonly, getter=shared) Foo *shared __attribute__((swift_name("shared")));
- (NSString *)someMethod __attribute__((swift_name("someMethod()")));
@property (readonly) int32_t someProperty __attribute__((swift_name("someProperty")));
@end
#pragma pop_macro("_Nullable_result")
#pragma clang diagnostic pop
NS_ASSUME_NONNULL_END
@@ -0,0 +1,4 @@
object Foo {
val someProperty = 42
fun someMethod() = ""
}