diff --git a/README.md b/README.md index 897bdc6..010ddcb 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ The language is currently **very debuggable**. It can produce readable C code wi * More examples can be found in /examples and /modules -``` +``` odin #import "KERNEL32.core" #import "Base.core" @@ -18,12 +18,6 @@ Memory :: struct reserve: SizeU data : *U8 -ProcessHeap: HANDLE -Allocate :: (size: U64): *void - if ProcessHeap == 0 - ProcessHeap = GetProcessHeap() - return HeapAlloc(ProcessHeap, 0, size) - Reserve :: (size: SizeU): Memory // C like compound expressions with named arguments result := Memory{reserve=AlignUp(size, PAGE_SIZE)} @@ -65,6 +59,7 @@ Release :: (m: *Memory) ## Operator overload example ``` +Vec3 :: struct ;; x: F32; y: F32; z: F32 "-" :: (a: Vec3, b: Vec3): Vec3 ;; return {a.x-b.x, a.y-b.y, a.z-b.z} "-" :: (a: Vec3): Vec3 ;; return {-a.x, -a.y, -a.z } ```