I wouldn't expect it to compile, and it doesn't in $mode delphi: (both 3.2.2 and 3.3.1):
Free Pascal Compiler version 3.2.2 [2021/05/15] for i386
Copyright (c) 1993-2021 by Florian Klaempfl and others
Target OS: Win32 for i386
Compiling project1.lpr
project1.lpr(4,58) Fatal: Syntax error, ";" expected but "const char" found
Fatal: Compilation aborted
Error: d:\fpc\3.2.2\bin\i386-win32\ppc386.exe returned an error exitcode
So it seems to be a $mode objfpc feature or bug.