slow.monster

STUDIO HAZE · topaz

Topaz source

Open by house policy. Topaz is our own language.

Topaz 5.20 · 56 files

compiler/crates/topaz_self_frontend/tests/fixtures/parser-declarations.tpz

Topaz · 266 B · Original file

1record Point<T> derives Eq {
2 x: T,
3 y: T = x,
4}
6enum Choice<T> derives Eq {
7 None,
8 Some(T),
9}
11newtype Id = int
12type Index<T> = Map<string, T>
14function identity<T: Eq>(value: T) -> T {
15 value
18impl Point {
19 function first(self) -> int {
20 self.x
21 }

SHA256 d59646bf01ae358d9befbe870b51ab8889a185f522dcd73bb3842c71ed8d3937