64-bit PChar pointer arithmetic gives range check error
Issue description:
https://stackoverflow.com/questions/78459947/64-bit-pchar-pointer-arithmetic-gives-range-check-error
This happens in 64 bit Delphi 12.0
The TdaSQLParser.Tokenize(aSQLText: TStrings; aDatabaseType: TppDatabaseType = dtOther);
does a TdaSynHighlighterSQL.Create(nil);
This repeatedly calls procedure TdaSynHighlighterSQL.DoAddKeyword(AKeyword: String; AKind: integer);
and the error occurs on the first call with AKeyword = 'absolute'
The HasKey calculation then fails as described in the StackOverflow post
How to fix this?
https://stackoverflow.com/questions/78459947/64-bit-pchar-pointer-arithmetic-gives-range-check-error
This happens in 64 bit Delphi 12.0
The TdaSQLParser.Tokenize(aSQLText: TStrings; aDatabaseType: TppDatabaseType = dtOther);
does a TdaSynHighlighterSQL.Create(nil);
This repeatedly calls procedure TdaSynHighlighterSQL.DoAddKeyword(AKeyword: String; AKind: integer);
and the error occurs on the first call with AKeyword = 'absolute'
The HasKey calculation then fails as described in the StackOverflow post
How to fix this?
Comments
The version of SynEdit used in ReportBuilder has been highly customized and was not originally intended for 64 bit applications. We have converted it to do so however occasionally an issue will arise that slipped through the cracks.
There is now a patch available for RB 22.04 that addresses this issue. Registered users with a valid software subscription can email support@digital-metaphors.com to receive the patch.
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com