New Features
- Indexed and ranged fields for array compound literals:
[?]int {0 = 123, 5..9 = 54, 10..<16 = 72}
- Constant compound literals declarations
FOO :: [5]int{1, 2, 3, 4, 5};
#partial switch- Implement the previous
#complete switchas the default behaviour
- Implement the previous
- Enumerated Arrays:
[Enum_Type]Value#partial [Enum_Type]Value
- SOA Arrays, Slices, and Dynamic Arrays
#soa[N]T#soa[]T#soa[dynamic]T
- New
#simdtype syntax#simd[N]T
- Add
@(private="file")and@(private="package") - Make
stringtype elements immutable, akin tochar const *in C - Allow
#no_bounds_checkon an expression - Deprecate
using import - Full System V ABI support
- Remove requirement for vcvarsall.bat for Windows. Windows SDK and Binaries are found automatically
- Add
-helpwhich prints information about the compiler flags - Add
x y z wfields to quaternion types - Add
r g b afields to array typeslen(array) <= 4alongsidex y z wfields
Library Improvements
- Improve
package math - Add
package math/linalg - Improve runtime/default_allocators.odin
- Make default
context.temp_allocatorthread safe - Add
strings.unsafe_string_to_cstring - Add
strings.ptr_from_string - Support
package threadon unix
Bug Fixes
- Fix string reversal
- Fix linux build
- Fix System V bitcast/transmute bug
- Fix os.write on darwin
- Fix transmute of
uintptrto/fromproc - Fix
fmt.string_to_enum_value - Fix mem.Arena
- Fix using on array in struct
- Fix -no-crt on Windows
- Fix loadsatypos