Aquesta és una versió anterior. La versió actual és la dev-2026-10. Odin Programming Language dev-2026-10 · Data de publicació:
Fitxers d’instal·lació dev-2024-04
| Arquitectura | Tipus | Àmbit | Mida del fitxer | Baixa | SHA256 |
|---|---|---|---|---|---|
| 64 bits | ZIP → Portable | — | — | github.com | VirusTotal |
L’enllaç i l’SHA256 provenen del manifest comunitari del Gestor de paquets del Windows. Convé comparar el hash del fitxer baixat abans d’executar-lo.
Notes de la versió
New Language Features
- `bit_field` type
```
Foo :: bit_field u16 { // backing type must be an integer or array of integers
x: i32 | 3, // signed integers will be signed extended on use
y: u16 | 2 + 3, // general expressions
z: My_Enum | foo.SOME_CONSTANT, // ability to define the bit-width elsewhere
w: bool | foo.SOME_CONSTANT > 10 ? 2 : 1,
}
```
```
Handle :: bit_field u32 {
slot: u32 | 16,
generation: u32 | 15,
in_use: bool | 1,
}
```
- `name: type | bit_width`
- `name: type | bit_width "field_tag"` (similar to a struct field with a tag)
Compiler Improvements
- Improved Error Reporting System
- Sorted printing based on error position
- Ability to export error list to json `-json-errors`
- `-terse-errors` are only a single line now
- Error message suggestions for people making common C mistakes
- Aiding newcomers from C/C++ to Odin
- Loads of debug info refactors and improvements
- Add Haiku OS support by @avanspector in https://github.com/odin-lang/Odin/pull/3230
- Respect "smart linker" approaches
- Respect `-lld` on non-Windows machines
- Remove entry point when compiled with no-entry-point as shared library
- Numerous fixes to wasm targets
- Numerous fixes to ARM64 ABI on Darwin
- Numerous fixes to SysV AMD64 ABI on Darwin and Linux
- Speed up `path_to_fullpath` on Linux/macOS
- Numerous compiler fixes and error messages
New Packages
- Moved `vendor:darwin/Foundation` to `core:sys/darwin/Foundation`
Package Improvements
- Improvements to `core:crypto`
- Make raylib and stb_rect_pack be free of libc
- Numerous improvements to `core:encoding/json`
- Support writing enum value names
- Support for `using _: T` fields
- Fixes to `core:math/big`
- Fixes to `core:math/linalg`
- Fixes to `core:slice`
- Fixes to `core:odin/parser`
- General fixes to `base:runtime`
- `vendor:x11` fixes
- Allow for the new futex API on darwin platforms if it is available
- Fix `os.read_entire_file` for pipes and console
CI Improvements
- Update LLVM to 17 for the CI/Releases
Full Changelog: https://github.com/odin-lang/Odin/compare/dev-2024-03...dev-2024-04