SwiftCompile

API Documentation:SwiftCompile

Compiles Swift source files into object files.

Properties

PropertyDescription
compilerArgs

Additional arguments to provide to the compiler.

debuggable

Should the compiler generate debuggable code?

macros

Macros that should be defined for the compiler.

moduleFile

The location to write the Swift module file to.

moduleName

The name of the module to produce.

modules

The modules required to compile the source.

objectFileDir

The directory where object files will be generated.

optimized

Should the compiler generate optimized code?

source

The source files to be compiled.

sourceCompatibility

The Swift language level to use to compile the source files.

targetPlatform

The platform being compiled for.

toolChain

The tool chain used for compilation.

Methods

No methods

Script blocks

No script blocks

Property details

ListProperty<String> compilerArgs

Additional arguments to provide to the compiler.

Property<Boolean> debuggable

Should the compiler generate debuggable code?

Macros that should be defined for the compiler.

Macros do not have values in Swift; they are either present or absent.

The location to write the Swift module file to.

Property<String> moduleName

The name of the module to produce.

ConfigurableFileCollection modules (read-only)

The modules required to compile the source.

DirectoryProperty objectFileDir

The directory where object files will be generated.

Property<Boolean> optimized

Should the compiler generate optimized code?

ConfigurableFileCollection source (read-only)

The source files to be compiled.

Property<SwiftVersion> sourceCompatibility

The Swift language level to use to compile the source files.

Property<NativePlatform> targetPlatform

The platform being compiled for.

The tool chain used for compilation.