diff --git a/platform/analysis-api/api-dump-unreviewed.txt b/platform/analysis-api/api-dump-unreviewed.txt index 6b0ac03136b7..09ba624d7b32 100644 --- a/platform/analysis-api/api-dump-unreviewed.txt +++ b/platform/analysis-api/api-dump-unreviewed.txt @@ -416,6 +416,8 @@ f:com.intellij.codeInsight.completion.PrioritizedLookupElement - s:withExplicitProximity(com.intellij.codeInsight.lookup.LookupElement,I):com.intellij.codeInsight.lookup.LookupElement - s:withGrouping(com.intellij.codeInsight.lookup.LookupElement,I):com.intellij.codeInsight.lookup.LookupElement - s:withPriority(com.intellij.codeInsight.lookup.LookupElement,D):com.intellij.codeInsight.lookup.LookupElement +*:com.intellij.codeInsight.completion.ml.MLRankingIgnorable +- s:wrap(com.intellij.codeInsight.lookup.LookupElement):com.intellij.codeInsight.lookup.LookupElement a:com.intellij.codeInsight.completion.util.ParenthesesInsertHandler - com.intellij.codeInsight.completion.InsertHandler - sf:NO_PARAMETERS:com.intellij.codeInsight.completion.util.ParenthesesInsertHandler diff --git a/platform/lang-api/src/com/intellij/codeInsight/completion/ml/MLRankingIgnorable.java b/platform/analysis-api/src/com/intellij/codeInsight/completion/ml/MLRankingIgnorable.java similarity index 100% rename from platform/lang-api/src/com/intellij/codeInsight/completion/ml/MLRankingIgnorable.java rename to platform/analysis-api/src/com/intellij/codeInsight/completion/ml/MLRankingIgnorable.java diff --git a/platform/lang-api/api-dump-unreviewed.txt b/platform/lang-api/api-dump-unreviewed.txt index ef9f16c4c0af..2fbc4b1a3f18 100644 --- a/platform/lang-api/api-dump-unreviewed.txt +++ b/platform/lang-api/api-dump-unreviewed.txt @@ -547,8 +547,6 @@ com.intellij.codeInsight.completion.ml.ContextFeatures - a:categoricalValue(java.lang.String):java.lang.String - a:classNameValue(java.lang.String):java.lang.String - a:floatValue(java.lang.String):java.lang.Double -*:com.intellij.codeInsight.completion.ml.MLRankingIgnorable -- s:wrap(com.intellij.codeInsight.lookup.LookupElement):com.intellij.codeInsight.lookup.LookupElement f:com.intellij.codeInsight.completion.util.CompletionStyleUtil - ():V - s:getCodeStyleSettings(com.intellij.codeInsight.completion.InsertionContext):com.intellij.psi.codeStyle.CommonCodeStyleSettings diff --git a/python/python-psi-impl/src/com/jetbrains/python/codeInsight/completion/PyLiteralTypeCompletionContributor.kt b/python/python-psi-impl/src/com/jetbrains/python/codeInsight/completion/PyLiteralTypeCompletionContributor.kt index a58be1346d95..88f7376a6880 100644 --- a/python/python-psi-impl/src/com/jetbrains/python/codeInsight/completion/PyLiteralTypeCompletionContributor.kt +++ b/python/python-psi-impl/src/com/jetbrains/python/codeInsight/completion/PyLiteralTypeCompletionContributor.kt @@ -1,6 +1,7 @@ package com.jetbrains.python.codeInsight.completion import com.intellij.codeInsight.completion.* +import com.intellij.codeInsight.completion.ml.MLRankingIgnorable import com.intellij.codeInsight.lookup.LookupElementBuilder import com.intellij.patterns.PlatformPatterns.psiElement import com.intellij.patterns.StandardPatterns.or @@ -71,11 +72,13 @@ private class PyLiteralTypeCompletionProvider : CompletionProvider() .forEach { result.addElement( - PrioritizedLookupElement.withPriority( - LookupElementBuilder - .create(lookupString(it)) - .withIcon(IconManager.getInstance().getPlatformIcon(PlatformIcons.Parameter)), - PythonCompletionWeigher.PRIORITY_WEIGHT.toDouble() + MLRankingIgnorable.wrap( + PrioritizedLookupElement.withPriority( + LookupElementBuilder + .create(lookupString(it)) + .withIcon(IconManager.getInstance().getPlatformIcon(PlatformIcons.Parameter)), + PythonCompletionWeigher.PRIORITY_WEIGHT.toDouble() + ) ) ) }