-
Notifications
You must be signed in to change notification settings - Fork 5.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Propagate all annotations during creating simple functional types
^KT-44563 Fixed
- Loading branch information
Showing
14 changed files
with
112 additions
and
15 deletions.
There are no files selected for viewing
5 changes: 5 additions & 0 deletions
5
...ysis-tests/tests-gen/org/jetbrains/kotlin/fir/FirOldFrontendDiagnosticsTestGenerated.java
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains 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
This file contains 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
This file contains 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
This file contains 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
12 changes: 12 additions & 0 deletions
12
...iler/testData/diagnostics/tests/annotations/functionalTypes/propagteAnyAnnotations.fir.kt
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
// !DIAGNOSTICS: -UNUSED_PARAMETER | ||
|
||
@Target(AnnotationTarget.FUNCTION, AnnotationTarget.TYPE) | ||
annotation class Composable | ||
|
||
fun bar(p: @Composable ()->Unit) {} | ||
|
||
@Composable fun foo() {} | ||
|
||
fun main() { | ||
bar(if(true) { { foo() } } else { { } }) | ||
} |
12 changes: 12 additions & 0 deletions
12
compiler/testData/diagnostics/tests/annotations/functionalTypes/propagteAnyAnnotations.kt
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
// !DIAGNOSTICS: -UNUSED_PARAMETER | ||
|
||
@Target(AnnotationTarget.FUNCTION, AnnotationTarget.TYPE) | ||
annotation class Composable | ||
|
||
fun bar(p: @Composable ()->Unit) {} | ||
|
||
@Composable fun foo() {} | ||
|
||
fun main() { | ||
bar(<!DEBUG_INFO_EXPRESSION_TYPE("@Composable() () -> kotlin.Unit")!>if(true) { { foo() } } else { { } }<!>) | ||
} |
12 changes: 12 additions & 0 deletions
12
compiler/testData/diagnostics/tests/annotations/functionalTypes/propagteAnyAnnotations.txt
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package | ||
|
||
public fun bar(/*0*/ p: @Composable() () -> kotlin.Unit): kotlin.Unit | ||
@Composable public fun foo(): kotlin.Unit | ||
public fun main(): kotlin.Unit | ||
|
||
@kotlin.annotation.Target(allowedTargets = {AnnotationTarget.FUNCTION, AnnotationTarget.TYPE}) public final annotation class Composable : kotlin.Annotation { | ||
public constructor Composable() | ||
public open override /*1*/ /*fake_override*/ fun equals(/*0*/ other: kotlin.Any?): kotlin.Boolean | ||
public open override /*1*/ /*fake_override*/ fun hashCode(): kotlin.Int | ||
public open override /*1*/ /*fake_override*/ fun toString(): kotlin.String | ||
} |
5 changes: 5 additions & 0 deletions
5
compiler/tests-gen/org/jetbrains/kotlin/checkers/DiagnosticsTestGenerated.java
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
5 changes: 5 additions & 0 deletions
5
...ler/tests-gen/org/jetbrains/kotlin/checkers/javac/DiagnosticsUsingJavacTestGenerated.java
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains 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
This file contains 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
This file contains 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
This file contains 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