m5rcode (pronounced "em-five-er-code") is a modern programming language combining the best features of Python, C, Java, HolyC, Rust, and Ruby. It features gradual typing, hybrid memory management (GC + optional ownership), and a focus on developer productivity.
- Fixed else if statements - Now properly handles multi-branch conditionals
- Fixed string comparisons - Added ==, !=, <, >, <=, >= operators for strings
- Environment Variables:
env.get(),env.set(),env.has() - File System:
fs.read(),fs.write(),fs.exists(),fs.delete() - Enhanced Strings:
str.contains(),str.starts_with(),str.ends_with(),str.replace() - Enhanced Lists:
list.append(),list.contains() - Discord Bot Framework: Complete rewrite with 20+ working API functions
See CHANGELOG_v0.3.2.md for full details.
- Comprehensive Standard Library: 20+ built-in functions for math, strings, lists, and I/O
- Enhanced LSP: Semantic analysis, better diagnostics, context-aware completions
- Native Functions: Faster execution for built-in operations
- Type Introspection:
typeof(),toStr(),toInt(),toFloat(),toBool() - Better Error Messages: Runtime errors with line/column tracking
- Gradual Typing: Optional static types with Hindley-Milner inference
- Hybrid Memory Model: GC by default, ownership mode available
- Modern Syntax: Clean, expressive syntax inspired by multiple paradigms
- Fast Compilation: Rust-based compiler with LLVM backend
- Rich Tooling: REPL, IDE, formatter, linter, LSP server
- Native Performance: Compiles to native code via C or LLVM IR
yay -S m5rcode
# or
paru -S m5rcode./scripts/bootstrap.sh
./scripts/build_arch.sh --installcargo build --release
sudo cp m5rcode /usr/local/bin/
sudo cp target/release/m5r* /usr/local/bin/# hello.m5
import std.io
fn main() {
io.println("Hello, m5rcode!")
}
Run with:
m5rcode run hello.m5Or start the REPL:
m5rcode replm5rcode- Unified CLI (run, repl, compile, fmt, lint, ide)m5r- Compilerm5repl- Interactive REPLm5idle- GTK-based IDEm5fmt- Code formatterm5lint- Linterm5pkg- Package managerm5doc- Documentation generator
- Tutorial - 20-minute introduction
- API Reference - Standard library documentation
- Examples - Code examples
- Language Specification - Complete language spec
This project is dual-licensed under MIT OR Apache-2.0. See LICENSE file.
See CONTRIBUTING.md for guidelines.
Report security issues to security@m5rcode.org. See SECURITY.md.