Created
December 10, 2022 14:57
-
-
Save lptr/bb4cfb2f31269a3211f3708532f99778 to your computer and use it in GitHub Desktop.
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
diff --git a/subprojects/configuration-cache/src/main/kotlin/org/gradle/configurationcache/serialization/codecs/CalculatedValueContainerCodec.kt b/subprojects/configuration-cache/src/main/kotlin/org/gradle/configurationcache/serialization/codecs/CalculatedValueContainerCodec.kt | |
index afa4b27e8c6..037318b834c 100644 | |
--- a/subprojects/configuration-cache/src/main/kotlin/org/gradle/configurationcache/serialization/codecs/CalculatedValueContainerCodec.kt | |
+++ b/subprojects/configuration-cache/src/main/kotlin/org/gradle/configurationcache/serialization/codecs/CalculatedValueContainerCodec.kt | |
@@ -33,7 +33,7 @@ class CalculatedValueContainerCodec( | |
) : Codec<CalculatedValueContainer<Any, ValueCalculator<Any>>> { | |
override suspend fun WriteContext.encode(value: CalculatedValueContainer<Any, ValueCalculator<Any>>) { | |
encodePreservingSharedIdentityOf(value) { | |
- val result = value.orNull | |
+ val result : Any? = value.orNull | |
if (result != null) { | |
writeBoolean(true) | |
write(result) | |
diff --git a/subprojects/core/src/main/java/org/gradle/internal/model/CalculatedValue.java b/subprojects/core/src/main/java/org/gradle/internal/model/CalculatedValue.java | |
index 841f87b2b47..1965cc37672 100644 | |
--- a/subprojects/core/src/main/java/org/gradle/internal/model/CalculatedValue.java | |
+++ b/subprojects/core/src/main/java/org/gradle/internal/model/CalculatedValue.java | |
@@ -18,6 +18,7 @@ | |
import org.gradle.internal.Try; | |
+import javax.annotation.Nullable; | |
import javax.annotation.concurrent.ThreadSafe; | |
/** | |
@@ -39,6 +40,7 @@ | |
* | |
* <p>Rethrows any exception that happened while calculating the value</p> | |
*/ | |
+ @Nullable | |
T getOrNull(); | |
/** |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment