
DevotionGeo
The Odin Programming Language
The Odin programming language is designed with the intent of creating an alternative to C with the following goals:
- simplicity
- high performance
- built for modern systems
- joy of programming
Example Code
package main
import "core:fmt"
main :: proc() {
program := "+ + * đ - /";
accumulator := 0;
for token in program {
switch token {
case '+': accumulator += 1;
case '-': accumulator -= 1;
case '*': accumulator *= 2;
case '/': accumulator /= 2;
case 'đ': accumulator *= accumulator;
case: // Ignore everything else
}
}
fmt.printf("The program \"%s\" calculates the value %d\n",
program, accumulator);
}
Language Features
- Built-in types: strings, array, slices, dynamic arrays, maps, 128-bit integers, endian-specific integers
- Multiple return arguments
- Consistent value declaration syntax
- Parametric polymorphism
-
Compile time conditions (
when
statements) and stress where there is not full blown compile time execution defer
statementusing
statement- The implicit
context
system and memory allocator system - Explicit procedure overloading
(Copied from the homepage).
Most Liked

OvermindDL1
Interesting⌠How does it compare to Zig that seems to have the same goals?
3

DevotionGeo
I didnât use it yet, but the first thing I noticed is syntactical similarity to Go, the short variable declaration operator, defer keyword, absence of parenthesis around conditions in conditionals, even names of the packages and methods like fmt.printf
.
3

kokolegorille
I also thought it looked like go
How to choose between go, rust or zig?
3
Popular General Dev topics

Have you seen the new features that will be available in the upcoming C# 9 release?
C# is taking a lot of input from functional l...
New

Looking at @siddhant3030âs photo from the Do you blog? thread, do you cover your computer or phone camera as a security precaution?
Wha...
New

So, if we can reduce the likelihood, we can reduce the overall risk. Thatâs good. Itâs actually very similar to a very common idea called...
New

Great paper by Igor Kopestenski on Erlang and GRiSP: Erlang as an Enabling Technology for Resilient General-Purpose Applications on Edge ...
New

This is all going to be a bit hand-wavey and straight off the top of my head, so bear with me, but itâs a thought/debate thatâs been ratt...
New

What shell(s) do you use, why do you use them, and how do you have them configured?
Note, this is about shellâs, not terminals, terminal...
New

I am thinking about getting a fitness tracker of some kind (probably one from Garmin). Have any of you developed your own widgets, watchf...
New

Your users of the two forums are spread across the world, thus I am curious how did you solved it?
New

Amazon CodeWhisperer is an alternative to GitHub Copilot, and itâs free!
New

Hi!
I usually keep changelogs for my projects because I think they are really useful, not only to track the changes and not to be lost b...
New
Other popular topics

What chair do you have while working⌠and why?
Is there a âbestâ type of chair or working position for developers?
New

New

Thanks to @foxtrottwistâs and @Tomasâs posts in this thread: Poll: Which code editor do you use? I bought Onivim! :nerd_face:
https://on...
New

Inspired by this post from @Carter, which languages, frameworks or other tech or tools do you think is killing it right now? :upside_down...
New

I have seen the keycaps I want - they are due for a group-buy this week but wonât be delivered until October next year!!! :rofl:
The Ser...
New

In case anyone else is wondering why Ruby 3 doesnât show when you do asdf list-all ruby :man_facepalming: do this first:
asdf plugin-upd...
New

Hereâs the story how one of the worldâs first production deployments of LiveView came to be - and how trying to improve it almost caused ...
New

This is going to be a long an frequently posted thread.
While talking to a friend of mine who has taken data structure and algorithm cou...
New

Author Spotlight:
Sophie DeBenedetto
@SophieDeBenedetto
The days of the traditional request-response web application are long gone, b...
New

Curious what kind of results others are getting, I think actually prefer the 7B model to the 32B model, not only is it faster but the qua...
New
Categories:
Sub Categories:
- All
- In The News (10066)
- Dev Chat
- Questions (32)
- Resources (118)
- Blogs/Talks (26)
- Jobs (3)
- Events (15)
- Code Editors (58)
- Hardware (57)
- Reviews (4)
- Sales (15)
- Design & UX (4)
- Marketing & SEO (1)
- Industry & Culture (14)
- Ethics & Privacy (19)
- Business (4)
- Learning Methods (4)
- Content Creators (7)
- DevOps & Hosting (9)
Popular Portals
- /elixir
- /rust
- /ruby
- /wasm
- /erlang
- /phoenix
- /keyboards
- /rails
- /js
- /python
- /security
- /go
- /swift
- /vim
- /clojure
- /emacs
- /java
- /haskell
- /onivim
- /svelte
- /typescript
- /crystal
- /c-plus-plus
- /kotlin
- /tailwind
- /gleam
- /react
- /ocaml
- /flutter
- /elm
- /vscode
- /ash
- /opensuse
- /centos
- /php
- /deepseek
- /html
- /zig
- /scala
- /textmate
- /sublime-text
- /debian
- /nixos
- /lisp
- /agda
- /react-native
- /kubuntu
- /arch-linux
- /revery
- /ubuntu
- /spring
- /manjaro
- /django
- /diversity
- /nodejs
- /lua
- /slackware
- /c
- /julia
- /markdown