JS: ignore annotation on expression when its retention is SOURCE

#KT-8258
This commit is contained in:
Zalim Bashorov
2016-02-15 18:34:20 +03:00
parent 90927cfd19
commit c28b701ccf
9 changed files with 135 additions and 32 deletions
@@ -1,4 +0,0 @@
$TESTDATA_DIR$/diagnosticForUnhandledElements.kt
-no-stdlib
-output
$TEMP_DIR$/out.js
@@ -1,12 +0,0 @@
package foo
@Target(AnnotationTarget.CLASS, AnnotationTarget.FUNCTION, AnnotationTarget.VALUE_PARAMETER, AnnotationTarget.EXPRESSION)
annotation class fancy
@fancy
class Foo {
@fancy
fun baz(@fancy foo : Int) : Int {
return (@fancy 1)
}
}
@@ -1,4 +0,0 @@
compiler/testData/cli/js/diagnosticForUnhandledElements.kt:10:17: error: cannot translate (not supported yet): '@fancy 1'
return (@fancy 1)
^
COMPILATION_ERROR