fix possible range error

This commit is contained in:
Basile Burg 2018-09-23 18:38:53 +02:00
parent ad22a2ef47
commit 7a34a833d9
1 changed files with 2 additions and 2 deletions

View File

@ -9,7 +9,7 @@ uses
SynEdit, SynPluginSyncroEdit, SynCompletion, SynEditKeyCmds, LazSynEditText,
SynHighlighterLFM, SynEditHighlighter, SynEditMouseCmds, SynEditFoldedView,
SynEditMarks, SynEditTypes, SynHighlighterJScript, SynBeautifier, dialogs,
md5, Spin, LCLIntf, LazFileUtils, LMessages, SynHighlighterCpp,
md5, Spin, LCLIntf, LazFileUtils, LMessages, SynHighlighterCpp, math,
//SynEditMarkupFoldColoring,
Clipbrd, fpjson, jsonparser, LazUTF8, LazUTF8Classes, Buttons, StdCtrls,
ce_common, ce_writableComponent, ce_d2syn, ce_txtsyn, ce_dialogs, ce_dastworx,
@ -2624,7 +2624,7 @@ begin
fCallTipStrings.Clear;
str := LineText[1..CaretX];
x := CaretX;
i := x;
i := min(x, str.length);
if findOpenParen then while true do
begin
if i = 1 then