@Input and @Internal should not be apply on the same property (#9059)

Motivation:

In Gradle 7.0 apply @Input and @Internal on property is forbidden.
Before Gradle 7.0 applying both on the same property is confusing. According to the documentation:

* @Input: Attached to a task property to indicate that the property specifies some input value for the task.
* @Internal: Attached to a task property to indicate that the property is not to be taken into account for up-to-date checking
This commit is contained in:
Vincent Galloy 2021-04-14 11:02:48 +02:00 committed by GitHub
parent dbdb6c51c4
commit 9edf70e980
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -81,9 +81,8 @@ open class GenerateTask : DefaultTask() {
val outputDir = project.objects.property<String>() val outputDir = project.objects.property<String>()
@Suppress("unused") @Suppress("unused")
@get:Internal
@set:Option(option = "input", description = "The input specification.") @set:Option(option = "input", description = "The input specification.")
@Input @Internal
var input: String? = null var input: String? = null
set(value) { set(value) {
inputSpec.set(value) inputSpec.set(value)