Skip to content
David Pearce edited this page Apr 13, 2022 · 35 revisions

The WhileyCompiler

This wiki provides a general discussion for the WhileyCompiler. The intention is to facilitate discussions around how to improve its design.

Overview

The WhileyCompiler is one component of the larger WhileyBuildTool. When you run wy build on the command line, you are running the WhileyBuildTool which, in turn, runs the WhileyCompiler (amongst other things). The goal of the WhileyCompiler is to take one or more whiley files along with zero or more wyil files (i.e. package dependencies) and produce a single wyil file. The wyil format is the Whiley Intermediate Language which, roughly speaking, provides an Abstract Syntax Tree representation of the whiley files. A key point here is that the WhileyCompiler only produces wyil files and does not, for example, generate JavaScript files or other executable formats (these are handled by other components of the build tool).

The WhileyCompiler is responsible for (amongst other things) parsing and type checking the Whiley files and will report errors if it finds them.

Stages

Intermediate Language

Clone this wiki locally