bolt/test.bolt
Sam Vervaeck 2b2d40c4f5 Major restructuring and update to code base
- Created a new VSCode Extension subproject
 - Created a new Bolt CLI subproject
 - Created a new Bolt Language Server subproject
 - Created a new Bolt Compiler subproject
 - Moved most existing code to the new Compiler subproject
 - Added a small language server
 - Laid the foundations for a Hindley-Milner type checker
 - Fixed some bugs and type errors in the compiler
 - Removed the unused testing infrastructure
 - Added an example parser test that should be run with Ava
2020-11-15 09:57:25 +01:00

25 lines
319 B
Text

fn (a: int) == (b: int) -> int;
fn (a: int) - (b: int) -> int;
fn (a: int) * (b: int) -> int;
fn write(data: String);
struct Point<NumT> {
x: NumT,
y: NumT,
}
trait Print {
fn print(self);
}
impl Print for Point {
fn print(self) {
write("A point!");
}
}
let p1 = Point { x: 1, y: 2 }
p1.printer();