Report warning on @Synchronized on inline methods
Until KT-27310 is supported, we warn users that this has no effect. #KT-29884 Fixed
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
// !DIAGNOSTICS: -UNUSED_PARAMETER
|
||||
|
||||
<!SYNCHRONIZED_ON_INLINE!>@Synchronized<!>
|
||||
inline fun foo(f: () -> Unit): Unit = f()
|
||||
|
||||
var bar: String
|
||||
<!SYNCHRONIZED_ON_INLINE!>@Synchronized<!>
|
||||
inline get() = ""
|
||||
<!SYNCHRONIZED_ON_INLINE!>@Synchronized<!>
|
||||
inline set(value) {}
|
||||
|
||||
inline var baz: String
|
||||
<!SYNCHRONIZED_ON_INLINE!>@Synchronized<!>
|
||||
get() = ""
|
||||
<!SYNCHRONIZED_ON_INLINE!>@Synchronized<!>
|
||||
set(value) {}
|
||||
Reference in New Issue
Block a user