From a4cdee52203040f555fe064774ccaa2268c1535b Mon Sep 17 00:00:00 2001 From: Dmitry Avdeev Date: Thu, 16 Oct 2014 14:36:50 +0400 Subject: [PATCH] cleanup --- .../codeInsight/generation/CommentByBlockCommentHandler.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform/lang-impl/src/com/intellij/codeInsight/generation/CommentByBlockCommentHandler.java b/platform/lang-impl/src/com/intellij/codeInsight/generation/CommentByBlockCommentHandler.java index 3704425eb54d..4fa6dd1a3b27 100644 --- a/platform/lang-impl/src/com/intellij/codeInsight/generation/CommentByBlockCommentHandler.java +++ b/platform/lang-impl/src/com/intellij/codeInsight/generation/CommentByBlockCommentHandler.java @@ -535,7 +535,7 @@ public class CommentByBlockCommentHandler extends MultiCaretCodeInsightActionHan final int offset = range.getStartOffset(); final IntArrayList toReplaceWithComments = new IntArrayList(); final IntArrayList prefixes = new IntArrayList(); - if (range.getLength() < 0) return; // TODO: reproduce and fix this case + final String text = document.getCharsSequence().subSequence(range.getStartOffset(), range.getEndOffset()).toString(); final String commentedPrefix = commenter.getCommentedBlockCommentPrefix(); final String commentedSuffix = commenter.getCommentedBlockCommentSuffix();