The Koru Book

Learn Koru through working examples. Every lesson is a real test from the compiler's regression suite.

Tests: 1463
✓ 1151 passing
✗ 193 failing
○ 59 planned
Linear documentation and a formal language spec are coming as Koru stabilizes. For now, the suite is the book — browse by example below.

core language / basic syntax

22/24

core language / events flows

36/38

core language / literals

7/8

core language / type system

5/16

core language / control flow

31/32

module system / imports

18/24

module system / comptime mirror

20/38

module system / namespaces

2/2

module system / packages

1/1

module system / file layout

13/16

parser

8/11

compiler features / parser

138/160

compiler features / compilation

12/18

compiler features / flow checker

8/12

compiler features / codegen

1/1

compiler features / emitter

5/6

compiler features / std library

3/3

compiler features / template engine

9/9

compiler features / subflow

1/1

syntax / struct constructors

1/2

advanced features / comptime

66/83

advanced features / stdlib

49/51

advanced features / keyword

5/5

advanced features / phantom types

96/124

advanced features / obligation stress

10/22

advanced features / obligation matrix

6/6

The permutation matrix of Koru's phantom-obligation discharge system — the

advanced features / type system

9/14

advanced features / auto proc

3/3

advanced features / pattern branches

3/4

advanced features / subflows

11/16

advanced features / optional branches

10/11

advanced features / taps observers

8/10

advanced features / interceptors

0/4

advanced features / phantom types

0/1

advanced features / variants

8/15

advanced features / templating

2/4

advanced features / kernel

29/31

advanced features / testing

7/10

control flow

25/29

runtime features

98/106

runtime features / budgeted interpreter

0/7

runtime features / purity checking

8/9

runtime features / performance

0/20

runtime features / coordination

6/11

runtime features / runtime

0/37

runtime features / resource bridge

2/2

integration testing / negative tests

41/50

integration testing / negative tests / 020 parse errors

1/1

integration testing / negative tests / 034 type errors

1/1

integration testing / bug reproduction

3/4

integration testing / validation

10/10

stdlib / string

16/17

stdlib / fmt

5/6

stdlib / io

5/5

stdlib / regex

16/16

stdlib / parser

12/12

stdlib / switch

4/4

stdlib / fs

5/7

stdlib / collections

23/27

stdlib / trellis

3/5

stdlib / store

88/107

stdlib / store tree

3/3

nesting sweep

34/35

event globbing

3/10

challenges

3/3

aoc 2015

37/44

the world

7/7

examples showcase

1/1

examples showcase / language shootout

27/30

watchdog selftest

1/1