Add test for [KT-3706]
Issue is already fixed by metadata-based cinterop (cherry picked from commit fd4f5b2c07ebdc431d6243ac087f911ee30e88ca)
This commit is contained in:
committed by
TeamCityServer
parent
64129314fb
commit
ba50a8275c
@@ -0,0 +1,12 @@
|
||||
#import <objc/NSObject.h>
|
||||
|
||||
|
||||
@interface KT37067_Impl : NSObject
|
||||
|
||||
@property (nonatomic, readonly) NSObject *newValue;
|
||||
@property (nonatomic, readonly) NSObject *allocValue;
|
||||
@property (nonatomic, readonly) NSObject *copyValue;
|
||||
@property (nonatomic, readonly) NSObject *mutableCopyValue;
|
||||
|
||||
@end;
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
import kotlin.test.*
|
||||
import objcTests.*
|
||||
|
||||
/// KT-37067: attribute prefixed with "new" causes cinterop failure
|
||||
// No matter what is in the test: I only need to get it compilable with cinterop
|
||||
|
||||
@Test fun testKT37067() {
|
||||
val impl = KT37067_Impl()
|
||||
assertEquals(null, impl.newValue)
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
#include "KT37067_prefix.h"
|
||||
|
||||
@implementation KT37067_Impl : NSObject
|
||||
|
||||
/// KT-37067 is a cinterop issue, so .m implementaion is not relevant at all,
|
||||
// but I still need to make objc compilable with `-fobjc-arc` option
|
||||
- (NSObject *)newValue {
|
||||
return nil;
|
||||
}
|
||||
- (NSObject *)allocValue {
|
||||
return nil;
|
||||
}
|
||||
- (NSObject *)copyValue {
|
||||
return nil;
|
||||
}
|
||||
- (NSObject *)mutableCopyValue {
|
||||
return nil;
|
||||
}
|
||||
|
||||
@end;
|
||||
Reference in New Issue
Block a user