Compile Switches
I strongly recommend you to use /m /n /w /es2 when developing Clipper applications. Well, I know it should be very tough when you just migrated to Clipper 5.x, because it won't forgive you for doing minor error, i.e. typing mistakes in variable/field name, not declaring variables or fields, etc.
Switch | Description |
---|---|
/m | Compile current module only, therefore you should use Make program such as RMake, MS Make, MakForce, etc |
/n | Suppress automatic procedure definition (with the same name as the PRG file), which enables you to utilize file-wide Static variables; but you are forced to declare the procedure or function explicitly |
/w | Allow Clipper to display warnings on ambiguous variables references |
/es2 | Ask Clipper not to generate .OBJ file and set DOS errorlevel upon exit, if any warnings or errors are encountered during compilation |
Of course, you can use additional Clipper switches, i.e. if you use some manifest constants like this code fragment:
// Compile switch clipper Test /m /n /w /es2 /dSIXCDX // In the source code (Test.prg) #ifdef ADS #include "ADS.ch" #else #include "SIxCDX.ch" #endif function Test() use Invoice index on Invoice->InvNo tag InvNo return nil