Allow to suppress warnings at file level

This commit is contained in:
Nikolay Krasko
2015-12-07 21:11:26 +03:00
committed by Nikolay Krasko
parent 712d2bdec0
commit aff83087a3
24 changed files with 192 additions and 22 deletions
@@ -0,0 +1,3 @@
// "Suppress 'REDUNDANT_NULLABLE' for file ${file}" "true"
public fun foo(): String?<caret>? = null
@@ -0,0 +1,5 @@
@file:Suppress("REDUNDANT_NULLABLE")
// "Suppress 'REDUNDANT_NULLABLE' for file ${file}" "true"
public fun foo(): String?<caret>? = null
@@ -0,0 +1,8 @@
// "Suppress 'REDUNDANT_NULLABLE' for file ${file}" "true"
// ERROR: This annotation is not applicable to target 'file' and use site target '@file'
@file:Deprecated("Some")
package test
public fun foo(): String?<caret>? = null
@@ -0,0 +1,9 @@
// "Suppress 'REDUNDANT_NULLABLE' for file ${file}" "true"
// ERROR: This annotation is not applicable to target 'file' and use site target '@file'
@file:Deprecated("Some")
@file:Suppress("REDUNDANT_NULLABLE")
package test
public fun foo(): String?<caret>? = null
@@ -0,0 +1,6 @@
// "Suppress 'REDUNDANT_NULLABLE' for file ${file}" "true"
/** Some Comment **/
package test
public fun foo(): String?<caret>? = null
@@ -0,0 +1,8 @@
// "Suppress 'REDUNDANT_NULLABLE' for file ${file}" "true"
/** Some Comment **/
@file:Suppress("REDUNDANT_NULLABLE")
package test
public fun foo(): String?<caret>? = null
@@ -0,0 +1,4 @@
// "Suppress 'REDUNDANT_NULLABLE' for file ${file}" "true"
@file:Suppress("unused")
public fun foo(): String?<caret>? = null
@@ -0,0 +1,4 @@
// "Suppress 'REDUNDANT_NULLABLE' for file ${file}" "true"
@file:Suppress("unused", "REDUNDANT_NULLABLE")
public fun foo(): String?<caret>? = null