• No categories

Language Guide

This document introduces the main concepts and syntax of the Whiley language. By the end, you should have a good grasp of Whiley, and be able to write useful programs.   As a first taste of Whiley, let’s consider the simplest possible program which prints “Hello World”:

void ::main(System.Console sys):
    sys.out.println("Hello World")

This illustrates several points about Whiley’s syntax. Firstly, Whiley does not use curly-braces for statement blocks and, instead, follows Python indentation syntax. Secondly, System::main indicates main is a method attached to processes of type “System“. Finally, the effect of out.println(..) is to send the println(..) message to the process referenced by out

Table of Contents

  1. Data Types
  2. Type System
  3. Semantics
  4. Concurrency
  5. Constraints
  6. Module System

Note: You can navigate the language guide using the menu on the left sidebar.