This error message means there is an error in a compiler directive or in a command line option. Here are some possible error situations:
(*$Description Copyright CodeGear 2007*) (*<-- Error here*) program Produce; (*$AppType Console*) (*<-- Error here*) begin (*$If O+*) (*<-- Error here*) Writeln('Optimizations are ON'); (*$Else*) (*<-- Error here*) Writeln('Optimizations are OFF'); (*$Endif*) (*<-- Error here*) Writeln('Hello world!'); end.
The example shows three typical error situations, and the last two errors are caused by the compiler not having recognized $If.
(*$Description 'Copyright CodeGear 2007'*) (*Need string*) program Solve; (*$AppType Console*) (*AppType*) begin (*$IfOpt O+*) (*IfOpt*) Writeln('Optimizations are ON'); (*$Else*) (*Now fine*) Writeln('Optimizations are OFF'); (*$Endif*) (*Now fine*) Writeln('Hello world!'); end.
So $Description needs a quoted string, we need to spell $AppType right, and checking options is done with $IfOpt. With these changes, the example compiles fine.
Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
|
What do you think about this topic? Send feedback!
|