diff --git a/platform/util/src/com/intellij/openapi/util/NotNullLazyValue.java b/platform/util/src/com/intellij/openapi/util/NotNullLazyValue.java index 1b82d50fdd18..9c9390371f87 100644 --- a/platform/util/src/com/intellij/openapi/util/NotNullLazyValue.java +++ b/platform/util/src/com/intellij/openapi/util/NotNullLazyValue.java @@ -23,17 +23,15 @@ import org.jetbrains.annotations.NotNull; * @author peter */ public abstract class NotNullLazyValue { - private boolean myComputed; - @NotNull private T myValue; + private T myValue; @NotNull protected abstract T compute(); @NotNull public T getValue() { - if (!myComputed) { + if (myValue == null) { myValue = compute(); - myComputed = true; } return myValue; }