From 59b30c1305ff6bcb63c673898893edcda19e27e4 Mon Sep 17 00:00:00 2001 From: Mitja Felicijan Date: Thu, 22 Jan 2026 12:23:25 +0100 Subject: Add Odin grammar --- tests/test.odin | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 tests/test.odin (limited to 'tests') diff --git a/tests/test.odin b/tests/test.odin new file mode 100644 index 0000000..687615b --- /dev/null +++ b/tests/test.odin @@ -0,0 +1,30 @@ +package main + +import "core:fmt" + +main :: proc() { + hello() + fmt.println(add(10, 20)) +} + +hello :: proc() { + fmt.println("Hello, Odin!") +} + +add :: proc(a, b: int) -> int { + return a + b +} + +Point :: struct { + x, y: f32, +} + +Color :: enum { + Red, + Green, + Blue, +} + +complex_proc :: proc(name: string, age: int, flags: ..bool) { + // ... +} -- cgit v1.2.3