anchor.diff:  type
     TATEditorGetTokenKind = function(Ed: TATSynEdit; AX, AY: integer): TATTokenKind of object;
   
  +function EditorBracket_GetPairForOpeningBracketOrQuote(ch: char): char;
   function EditorBracket_GetPairForClosingBracketOrQuote(ch: char): char;
  +
   procedure EditorBracket_ClearHilite(Ed: TATSynEdit);
   procedure EditorBracket_FindBoth(Ed: TATSynEdit;
     var PosX, PosY: integer;
  
positive.code:   //makes no sense to auto-close brackets in overwrite mode
    if Ed.ModeOverwrite then exit;
  
    if CharBegin='(' then CharEnd:= ')' else
     if CharBegin='[' then CharEnd:= ']' else
      if CharBegin='{' then CharEnd:= '}' else
       if CharBegin='"' then CharEnd:= '"' else
        if CharBegin='''' then CharEnd:= '''' else
         if CharBegin='`' then CharEnd:= '`' else
          if CharBegin='~' then CharEnd:= '~' else
           if CharBegin='*' then CharEnd:= '*' else
            if CharBegin='#' then CharEnd:= '#' else
             if CharBegin='<' then CharEnd:= '>' else
              exit;
  
    //cancel vertical selection
    Ed.DoSelect_ClearColumnBlock;
  
negative.code:   iCaret: integer;
  begin
    Result:= false;
  
    CharOpening:= EditorBracket_GetPairForClosingBracketOrQuote(CharClosing);
    if CharOpening=#0 then exit;
    if Pos(CharOpening, Ed.OptAutoCloseBrackets)=0 then exit;
  
    for iCaret:= Ed.Carets.Count-1 downto 0 do
    begin
      Caret:= Ed.Carets[iCaret];
  