Free Pascal docs state that RawByteString
type is defined in Free Pascal but I cannot find where. One should expect that it is defined in System
unit, like in Delphi, but when I compile (using FPC 2.6.2, {$mode delphi}) a function declaration
class function FromAnsi(const S: RawByteString): ByteArray; static;
I get the compiler error
Error: Identifier not found "RawByteString"
Guess I can declare the type myself:
type
RawByteString = type AnsiString(CP_NONE);
but I would like to find the "native" FPC declaration.
Thanks for quick answers. Since I don't need to support FPC 1.x the workaround I need is:
{$IFDEF FPC}
{$IF FPC_VERSION = 2}
{$IF FPC_RELEASE <= 6}
type
RawByteString = AnsiString;
{$IFEND}
{$IFEND}
{$ENDIF}