diff --git a/platform/core-api/src/com/intellij/openapi/project/Project.java b/platform/core-api/src/com/intellij/openapi/project/Project.java
index 499915a673c7..dc29ab9d0fd0 100644
--- a/platform/core-api/src/com/intellij/openapi/project/Project.java
+++ b/platform/core-api/src/com/intellij/openapi/project/Project.java
@@ -1,4 +1,4 @@
-// Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
+// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.openapi.project;
import com.intellij.openapi.components.ComponentManager;
@@ -76,13 +76,12 @@ public interface Project extends ComponentManager, AreaInstance {
/**
* Returns presentable project path:
* {@linkplain #getProjectFilePath()} for file-based projects, {@linkplain #getBasePath()} for directory-based ones.
- * * Returns {@code null} for default project.
+ * Returns {@code null} for default project.
* Note: the word "presentable" here implies file system presentation, not a UI one.
- *
- * @return presentable project path
*/
@Nullable
- default @SystemDependent String getPresentableUrl() {
+ @SystemDependent
+ default String getPresentableUrl() {
return null;
}
diff --git a/platform/platform-impl/src/com/intellij/ide/RecentProjectsManagerBase.kt b/platform/platform-impl/src/com/intellij/ide/RecentProjectsManagerBase.kt
index 562874e969ce..535eafd6c21c 100644
--- a/platform/platform-impl/src/com/intellij/ide/RecentProjectsManagerBase.kt
+++ b/platform/platform-impl/src/com/intellij/ide/RecentProjectsManagerBase.kt
@@ -263,7 +263,7 @@ open class RecentProjectsManagerBase : RecentProjectsManager(), PersistentStateC
protected open fun getRecentProjectMetadata(path: String, project: Project): String? = null
open fun getProjectPath(project: Project): String? {
- return PathUtil.toSystemIndependentName(project.presentableUrl)
+ return FileUtilRt.toSystemIndependentName(project.presentableUrl ?: return null)
}
// open for Rider
diff --git a/platform/projectModel-api/src/com/intellij/openapi/components/BaseState.kt b/platform/projectModel-api/src/com/intellij/openapi/components/BaseState.kt
index 8e7fbfccd092..59c8f82cb622 100644
--- a/platform/projectModel-api/src/com/intellij/openapi/components/BaseState.kt
+++ b/platform/projectModel-api/src/com/intellij/openapi/components/BaseState.kt
@@ -1,4 +1,4 @@
-// Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
+// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.openapi.components
import com.intellij.openapi.diagnostic.logger
@@ -121,6 +121,7 @@ abstract class BaseState : SerializationFilter, ModificationTracker {
intIncrementModificationCount()
}
+ @ApiStatus.Internal
fun intIncrementModificationCount() {
MOD_COUNT_UPDATER.incrementAndGet(this)
}