Compile page of Visual Studio project properties (Synergy .NET)

Use the Compile page of project properties in Visual Studio to specify compile settings for a Synergy .NET project.

To access this page, select a project node in Solution Explorer, select Project > Properties from the Visual Studio menu, and then select the Compile tab.

Compiler command line

This non-editable area of the page displays Synergy .NET compiler options that correspond to settings selected on this page.

Compiler settings

Use alternate form of IF

Select this option to use the alternate, non-ANS DIBOL form of the IF statement, which specifies that the THEN is optional and the ELSE belongs to the last IF statement. (The ANS DIBOL form of the IF statement specifies that each ELSE belongs to the most recent THEN in the same lexical level.) For more information, see IF-THEN-ELSE.

This option sets the internal Synergy .NET compiler option -qaltif.

Enable device licensing (requires SynergyDeviceLicenseAttibute attribute in code)

Set this to enforce licensing from the device license service instead of using traditional Synergy licensing. For more information, see Device Licensing (Windows).

This option sets the internal Synergy .NET compiler option -device.

Generate code compatible with the Mono runtime

Do not set this option. Mono development is not supported.

This option instructs the compiler to generate errors for code that is not compatible with Mono (e.g., calls to Toolkit routines, low-level windowing routines, and the Windows printing API). This option sets the internal Synergy .NET compiler option -mono.

Generate errors for all compiler warnings

Select this to change compiler warnings into errors.

This option sets the internal Synergy .NET compiler option -qerrwarn.

Generate warnings instead of errors for duplicate structures and enumerations

Set this to instruct the compiler to generate a level 3 warning if the name of a global structure, common, data section, or enumeration is used in more than one assembly, which could lead to ambiguity in Interop projects.

This option sets the internal Synergy .NET compiler option -qrelaxed:allowdup.

Allow passing a non-CLS structure to a non-CLS structure parameter with the same size

Allow passing a non-CLS structure (without objects) to a parameter whose type is another non-CLS structure of the same size, but not the same name.

This option sets the internal Synergy .NET compiler option -qrelaxed:paramst.

Allow passing type a to an input or unspecified direction d

Allow passing type a to an input d or unspecified direction d. (For decimal type only, not implied-decimal.)

This option sets the internal Synergy .NET compiler option -qrelaxed:paramad.

Set the warning level

Select this option and select one of the following to control warnings:

0 Don’t generate any warning messages.
1 Display severe warnings.
2 Display level 1 warnings plus certain less severe warnings, such as warnings about hiding class members.
3 Display level 2 warnings plus certain less severe warnings, such as warnings about expressions that always evaluate to true or false. (default)
4 Display all level 3 warnings plus informational warnings.

If the “Set the warning level” check box is cleared, the default (3) is used.

Compiler warning levels are specified in error topics (e.g., the ARGMSMCH topic lists the warning level for ARGMSMCH).

This option sets the internal Synergy .NET compiler option -W#, where # is one of the settings for this option (e.g., -W4).

Default behavior of unqualified record statements

Use this to set the default for unqualified RECORD statements (i.e., RECORD statements that don’t specify STACK, STATIC, LOCAL, CONST, or READONLY). See RECORD-ENDRECORD for more information.

Stack Makes the contents of a record unique for each activation of the routine.
Static Makes the contents of a record persist throughout the life of the program.
Local Makes the contents of a record persist throughout the life of the program.
None No default for unqualified RECORD statements.

If this option is set to Stack, Static, or Local, it sets one of the following internal Synergy .NET compiler options: -qstack, -qstatic, or -qlocal.

Define alternate compile-time ^VARIANT

To define the ^VARIANT data reference operation, select this option and enter a value in the field. The default value is 0.

This option sets the internal Synergy .NET compiler option -qvariant:value.

Stack size (in bytes)

Use this to set the stack size in bytes for an application. This is available for executable assemblies (e.g., when “Output type” on the Application page of project properties is set to “Console Application” or “Windows Application”).

This option sets the internal Synergy .NET compiler option -qstack:value.

Generate warning when stack size exceeds # bytes

Use this to specify the maximum size (in bytes) for total stack data used by a routine. If this size is exceeded, the compiler will generate a STKSIZ warning. The default is 65536 bytes.

This option sets the internal Synergy .NET compiler option -qwarnstacksize:value.

Disable specified warnings

To disable warnings, select this option and specify the error numbers for warnings you want to disable. To specify multiple error numbers, separate numbers with commas.

This option sets the internal Synergy .NET compiler option -WD:error#[,error#,...].

Convert specified warnings to errors

To have the compiler report some warnings as errors, select this option and specify the numbers for the warnings in this field. To specify multiple warnings, separate numbers with commas. Note that warnings specified in the “Disable specified warnings” field will not be reported as errors or warnings.

This option sets the internal Synergy .NET compiler option -WE:error#[,error#,...].

Set compile-time defines

To define one or more identifiers and assign a replacement value to each, use the following syntax in this field:

identifier=replacement

Replacement can be a number or a quoted string. And you can specify multiple identifier=replacement pairs by separating them with commas:

ident_1=value_1,ident_2=value_2

Quotation marks that are to be part of replacement must be escaped by prefixing them with the backslash character. For example:

val="\"hello\""

Note that this is similar to using .DEFINE in code, but settings here apply to the entire compilation unit (not just a routine).

This option sets the internal Synergy .NET compiler option -qdefine:identifier=replacement[,identifier=replacement,...].

Other options

Enter additional compiler options you want set. See Synergy .NET compiler options for information on options you can specify in this field. If you specify more than one option in this field, separate options with a space.