
//////////////////////////////////////////////////
//  SQLite Data Access Components
//  Copyright © 2008-2014 Devart. All right reserved.
//////////////////////////////////////////////////

{$IFNDEF CLR}

{$I LiteDac.inc}
unit LiteParserUni;
{$ENDIF}

interface

uses
  Classes, SysUtils, CRTypes, CRParser;

type
  TLiteParser = class (TSQLParser)
  protected
    procedure ToRightQuote(RightQuote: char); override;
    function IsIdentQuote(Ch: char): boolean; override;
  end;

implementation

procedure TLiteParser.ToRightQuote(RightQuote: char);
begin
  if RightQuote = '[' then
    RightQuote := ']';

  inherited;
end;

function TLiteParser.IsIdentQuote(Ch: char): boolean;
begin
  Result := False;
  case Ch of
    '`', '"', '[':
      Result := True;
  end;
end;

end.
