override NotNullLazyValue#isComputed to compare actual field (IDEA-CR-15467)
authorSergey Simonchik <sergey.simonchik@jetbrains.com>
Mon, 7 Nov 2016 12:38:43 +0000 (15:38 +0300)
committerSergey Simonchik <sergey.simonchik@jetbrains.com>
Mon, 7 Nov 2016 12:38:43 +0000 (15:38 +0300)
platform/util/src/com/intellij/openapi/util/VolatileNotNullLazyValue.java

index 083ccfe0947182097c971e29c157afe6be90ecc7..ed6df192cd1b5edb466d7801e92b9b6b8f0e0820 100644 (file)
@@ -39,6 +39,11 @@ public abstract class VolatileNotNullLazyValue<T> extends NotNullLazyValue<T> {
     return value;
   }
 
+  @Override
+  public boolean isComputed() {
+    return myValue != null;
+  }
+
   @SuppressWarnings("MethodOverridesStaticMethodOfSuperclass")
   @NotNull
   public static <T> VolatileNotNullLazyValue<T> createValue(@NotNull final NotNullFactory<T> value) {