diff --git a/platform/lang-impl/src/com/intellij/codeInsight/daemon/impl/LocalInspectionsPass.java b/platform/lang-impl/src/com/intellij/codeInsight/daemon/impl/LocalInspectionsPass.java index 3aed41568a8b..cf271064c67d 100644 --- a/platform/lang-impl/src/com/intellij/codeInsight/daemon/impl/LocalInspectionsPass.java +++ b/platform/lang-impl/src/com/intellij/codeInsight/daemon/impl/LocalInspectionsPass.java @@ -275,8 +275,10 @@ public class LocalInspectionsPass extends ProgressableTextEditorHighlightingPass LocalInspectionTool tool = wrapper.getTool(); if (!checkDumbAwareness || tool instanceof DumbAware) { map.putValue(tool, language); - for (Language dialect : lang.getDialects()) { - map.putValue(tool, dialect.getID()); + if (wrapper.applyToDialects()) { + for (Language dialect : lang.getDialects()) { + map.putValue(tool, dialect.getID()); + } } } }