TPascalCodeGenerator.EscapeKeyWord function
Escape Pascal keyword if needed
Declaration
function EscapeKeyWord(const S: string; ForceAmpersand: Boolean=False)
: string; virtualArguments
S | String to escape |
ForceAmpersand | Force ampersand prefix instead of configured prefix/suffix |
Function result
Escaped string
Description
EscapeKeyWord escapes a string if it is a Pascal keyword by adding prefix and suffix characters.
If the string is a keyword, it adds the configured
KeywordPrefix and
KeywordSuffix or an ampersand (&) if ForceAmpersand is
True.See also
An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
