Rux Language
Fast, compiled, strongly typed, multi-paradigm programming language.
Hello/Src/Main.rux
import Io::PrintLine;
// Entry point of the program
func Main() -> int {
let greetings = [
"Hello World",
"你好,世界",
"नमस्ते दुनिया",
"Hola Mundo",
"Bonjour le monde",
"مرحبا يا عالم",
"হ্যালো বিশ্ব",
"Привет мир",
"Olá Mundo",
"سلام دنیا",
"Привіт світ",
"🐯🐶🐱🐭"
];
for greeting in greetings {
PrintLine(greeting);
}
return 0;
}
Functions/Src/Main.rux
import Io::Print;
func Main() -> int {
let factorial = Factorial(10);
let quotient = Div<float>(10.0, 2.0);
let sum = Sum(1, 2, 3);
Print("Factorial: {}\n", factorial);
Print("Quotient: {}\n", quotient);
Print("Sum: {}\n", sum);
return 0;
}
Struct/Src/Main.rux
import Io::PrintLine;
func Main() -> int {
let v1 = Vector{ x: 1.0, y: 2.0, z: 3.0 };
let v2 = Vector::New(10.0, 20.0, 30.0);
let sum = v1 + v2;
let prod = v1 * v2;
PrintLine("Sum: [{}, {}, {}]", sum.x, sum.y, sum.z);
PrintLine("Length: {}", sum.Length());
PrintLine("Product: {}", prod);
return 0;
}
Mutability/Src/Main.rux
func Main() -> int {
// Compile-time constant
const Size: uint = 1024;
// Compile-time error
Size = 35;
// Immutable variable
let value = 20;
// Compile-time error
value = 25;
// Variable
var steps = 10;
// OK
steps = 15;
return 0;
}
Imports/Src/Main.rux
// Import package
import Math;
// Import a package with an alias
import Math as Calc;
// Import all items from a package
import Math::*;
// Import specific items from a package
import Math::Sin;
// Import multiple specific items from a package
import Math::{ Sin, Cos };
// Import specific item from a package with an alias
import Math::Cos as Cosine;
func Main() -> int {
return 0;
}
Why Rux
Built for people who want the speed of native code without giving up clarity.
- Native PerformanceCompiles straight to native machine code. No virtual machine, no interpreter, no garbage collector pauses.
- Instant ToolchainCompiler, linter, package manager, formatter, and test runner — one small binary, zero dependencies.
- Strong TypesNo implicit conversions, no surprises. Everything is checked at compile time and free at runtime.
- Explicit MutabilityBindings are immutable until you write var. That choice runs deep — through struct fields and pointers.
- Multi-ParadigmImperative, functional, or data-oriented — pick what fits the problem, no forced style.
- Hardware AccessInline assembly, raw pointers, and FFI. When you need the metal, Rux gets out of the way.
- Clean SyntaxReads like pseudocode, compiles like assembly. No ceremony, no boilerplate.
- Cross-PlatformBuild CLI tools, servers, and games for Linux, Windows, and macOS from the same source.
- Dive into the language
Up and Running in Seconds
One small download gives you the compiler, linter, package manager, formatter, and test runner. No SDKs to chain together, nothing else to install.
50ms
Typical compile — no LLVM, no waiting.
1
Tiny binary for the whole toolchain.
0
Dependencies, VMs, or runtimes.
100%
Native machine code, full speed.
Works With Your Editor
Syntax highlighting and language support, wherever you write code.
Missing your editor?
Rux editor support is developed in the open, one repository per editor. Add the one you use.
Contribute supportNeovimComing soon
HelixComing soon
JetBrains IDEsComing soon
Build on what the community has published
The most downloaded packages in the Rux registry over the last 30 days.
Loading popular packages
Sponsors
Rux is free, open source, and developed independently. You could be the first.