Last active
July 7, 2016 07:47
-
-
Save shiraji/ce20ede803d6e3e850026efa1438e76f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Fancy(annotation = FooAnno()) | |
fun foo() { | |
@Fancy(annotation = @FooAnno()) | |
foo() | |
@Fancy2(annotation = arrayOf(FooAnno())) | |
foo() | |
@Fancy2(annotation = arrayOf(@FooAnno())) | |
foo() | |
} | |
} | |
@Target(AnnotationTarget.CLASS, AnnotationTarget.FUNCTION, | |
AnnotationTarget.VALUE_PARAMETER, AnnotationTarget.EXPRESSION) | |
@Retention(AnnotationRetention.SOURCE) | |
annotation class Fancy(val annotation: FooAnno) | |
@Target(AnnotationTarget.CLASS, AnnotationTarget.FUNCTION, | |
AnnotationTarget.VALUE_PARAMETER, AnnotationTarget.EXPRESSION) | |
@Retention(AnnotationRetention.SOURCE) | |
annotation class Fancy2(val annotation: Array<FooAnno>) | |
@Target(AnnotationTarget.CLASS, AnnotationTarget.FUNCTION, | |
AnnotationTarget.VALUE_PARAMETER, AnnotationTarget.EXPRESSION) | |
@Retention(AnnotationRetention.SOURCE) | |
annotation class FooAnno |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Target(AnnotationTarget.EXPRESSION) | |
@kotlin.annotation.Retention | |
annotation class Foo(val value: String, val foo: String) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
テストなどのコミット。参考にする。
shiraji/kotlin@8e5481b