Skip to content

Odin Programming Language #3204

@gingerBill

Description

@gingerBill

Language
Odin is a general-purpose programming language with distinct typing, built for high performance, modern systems, and built-in data-oriented data types. The Odin Programming Language, the C alternative for the joy of programming. The Data-Oriented Language for Sane Software Development.

Additional resources
https://odin-lang.org/
https://odin-lang.org/docs/overview/
https://github.com/odin-lang/Odin

Syntax:

Prism.languages.odin = Prism.languages.extend('clike', {
	'string': {
		pattern: /(["'`])(?:\\[\s\S]|(?!\1)[^\\])*\1/,
		greedy: true
	},
	'keyword': /\b(?:asm|auto_cast|bit_set|break|case|cast|context|continue|defer|distinct|do|dynamic|else|enum|fallthrough|for|foreign|if|import|in|map|matrix|not_in|or_else|or_return|package|proc|return|struct|switch|transmute|typeid|union|using|when|where)\b/,
	'boolean': /\b(?:_|false|true|nil)\b/,
	'number': /(?:\b0[xh][0-9a-fA-F_]+|(?:\b0b[01_])|(?:\b0o[0-7_])|(?:\b0d[0-9_])|(?:\b0z[0-9abAB_])|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[-+]?\d+)?)[ijk]?/i,
	'operator': /[+-\/%~!=<>]=?|%%=?|---|\?|\|(?:=|\|=?)?|&(?:=|&=?|\~=?)?|>(?:>=?|=)?|<(?:<=?|=)?|:\s*=|:\s*:|\.\.[=<]?|->|[@#$]/,
	'builtin': /\b(?:abs|align_of|cap|clamp|complex|conj|expand_to_tuple|hadamard_product|imag|jmag|kmag|len|matrix_flatten|max|min|offset_of|offset_of_by_string|outer_product|quaternion|real|size_of|soa_unzip|soa_zip|swizzle|transpose|type_info_of|type_of|typeid_of|any|b(?:8|16|32|64)|bool|byte|c?string|complex(?:32|64|128)|f(?:16|32|64)(?:le|be)?|quaternion(?:64|128|256)|rawptr|rune|[ui](?:8|16|32|64|128)(?:le|be)?|u?int(?:ptr)?\b/
});
delete Prism.languages.odin['class-name'];

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions