diff --git a/core/util.runtime/src/org/jetbrains/jet/storage/LockBasedStorageManager.java b/core/util.runtime/src/org/jetbrains/jet/storage/LockBasedStorageManager.java index c7b4ca4dc8e..d2fa481b416 100644 --- a/core/util.runtime/src/org/jetbrains/jet/storage/LockBasedStorageManager.java +++ b/core/util.runtime/src/org/jetbrains/jet/storage/LockBasedStorageManager.java @@ -188,12 +188,7 @@ public class LockBasedStorageManager implements StorageManager { _value = value; if (!(_value instanceof NotValue)) return WrappedValues.unescapeThrowable(_value); - if (_value == NotValue.COMPUTING) { - Object result = recursionDetected(); - if (result != NotValue.NOT_COMPUTED) { - return WrappedValues.unescapeThrowable(result); - } - } + if (_value == NotValue.COMPUTING) return WrappedValues.unescapeThrowable(recursionDetected()); value = NotValue.COMPUTING; try { @@ -213,7 +208,7 @@ public class LockBasedStorageManager implements StorageManager { } /** - * @return {@code NOT_COMPUTED} to proceed, a value or wrapped exception otherwise, see WrappedValues + * @return a value or wrapped exception, see WrappedValues * @throws DO NOT throw exceptions from implementations of this method, instead return WrappedValues.escapeThrowable(exception) */ @Nullable diff --git a/core/util.runtime/src/org/jetbrains/jet/storage/StorageManager.java b/core/util.runtime/src/org/jetbrains/jet/storage/StorageManager.java index 9e2ec6ea259..1453a61b356 100644 --- a/core/util.runtime/src/org/jetbrains/jet/storage/StorageManager.java +++ b/core/util.runtime/src/org/jetbrains/jet/storage/StorageManager.java @@ -46,8 +46,8 @@ public interface StorageManager { * @param onRecursiveCall is called if the computation calls itself recursively. * If this parameter is null, an exception will be thrown on a recursive call, * otherwise it should return a result of WrappedValues.escapeThrowable() method - * @param postCompute is called after the value is computed, but before any other thread sees it (the current thread may - * see it in between) + * @param postCompute is called after the value is computed, but before any other thread sees it + * (the current thread may see it in between) */ @NotNull NotNullLazyValue createLazyValueWithPostCompute(