mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
EA-27364 - IOOBE: SegmentArray.findSegmentIndex
This commit is contained in:
+1
-1
@@ -214,7 +214,7 @@ public class BraceHighlightingHandler {
|
||||
// Try to find matched brace backwards.
|
||||
if (offset >= originalOffset || c != '\n') {
|
||||
int backwardNonWsOffset = CharArrayUtil.shiftBackward(chars, offset - 1, "\t ");
|
||||
if (backwardNonWsOffset < offset - 1 || c == ' ' || c == '\t' || c == '\n') {
|
||||
if (backwardNonWsOffset >= 0 && (backwardNonWsOffset < offset - 1 || c == ' ' || c == '\t' || c == '\n')) {
|
||||
iterator = getEditorHighlighter().createIterator(backwardNonWsOffset);
|
||||
if (BraceMatchingUtil.isLBraceToken(iterator, chars, myFileType) || BraceMatchingUtil.isRBraceToken(iterator, chars, myFileType)) {
|
||||
offset = backwardNonWsOffset;
|
||||
|
||||
Reference in New Issue
Block a user