An esoteric programming language that combines Go-like semantics with Gen Z slang keywords, featuring the world's first use of Among Us
à¶ž
characters in pointer syntax.
CURSED is a statically typed, garbage-collected programming language designed to make coding more expressive and culturally relevant while maintaining practical functionality. It's self-hosting through a multi-stage bootstrap compiler written in Zig.
- Gen Z Slang Keywords: Core programming constructs use contemporary slang (
slay
for function,sus
for variable,vibe
for package,stan
for goroutine) - Among Us Pointer Syntax: First programming language to use
à¶ž
(U+0D9E) for pointer operations - Go-like Semantics: Familiar control flow and typing for experienced developers
- Built-in Concurrency: Goroutines (
stan
) and channels (dm
) for concurrent programming - Advanced Memory Management: Generational garbage collector with performance monitoring
- Comprehensive Error Handling:
yikes
/fam
/shook
error system with panic recovery
vibe main
yeet "vibez"
slay main() {
vibez.spill("Hello, World!")
}
vibe example
yeet "vibez", "stringz"
slay demo() {
sus age normie = 25 // 32-bit integer
sus name tea = "Alice" // string
sus is_cool lit = based // boolean (true)
sus height snack = 5.8 // 32-bit float
// Pointer operations with Among Us syntax
sus ptr à¶žnormie = à¶žage // pointer to age
sus value normie = *ptr // dereference
vibez.spill("Name:", name)
}
slay calculate(x normie, y normie) normie {
ready x > y {
damn x + y
} otherwise {
damn x - y
}
}
slay loop_example() {
bestie i := 0; i < 10; i++ {
ready i % 2 == 0 {
vibez.spill("Even:", i)
}
}
}
slay worker_example() {
sus ch dm<normie> // channel
// Spawn goroutine
stan {
dm_send(ch, 42)
}
// Receive from channel
result := dm_recv(ch)
vibez.spill("Received:", result)
}
slay divide(a normie, b normie) normie yikes {
ready b == 0 {
yikes "Division by zero"
}
damn a / b
}
slay safe_division() {
fam {
result := divide(10, 0) shook
vibez.spill("Result:", result)
} sus error {
vibez.spill("Error:", error.message())
}
}
Traditional | CURSED | Usage |
---|---|---|
package | vibe |
Package declaration |
import | yeet |
Import packages |
func | slay |
Function definition |
var | sus |
Variable declaration |
const | facts |
Constant declaration |
if | ready |
Conditional |
else | otherwise |
Alternative branch |
for | bestie |
Loop |
while | periodt |
While loop |
return | damn |
Return statement |
true | based |
Boolean true |
false | cringe |
Boolean false |
nil | nah |
Null value |
go | stan |
Spawn goroutine |
Type | Description |
---|---|
lit |
Boolean |
normie |
32-bit signed integer |
smol |
8-bit signed integer |
mid |
16-bit signed integer |
thicc |
64-bit signed integer |
snack |
32-bit float |
meal |
64-bit float |
tea |
String |
sip |
Character |
à¶žT |
Pointer to type T |
dm<T> |
Channel of type T |
- Zig 0.13+ (compiler implementation)
- Git
The CURSED compiler is now implemented in Zig with built-in LLVM support, eliminating external LLVM dependencies and enabling cross-platform compilation including Windows.
git clone https://github.com/ghuntley/cursed
cd cursed
zig build
# Interpret and run a CURSED program
./zig-out/bin/cursed-compiler example.💀
# Compile to native executable
./zig-out/bin/cursed-compiler --compile example.💀
# Generate LLVM IR
./zig-out/bin/cursed-compiler --emit-ir example.💀
# Debug mode
./zig-out/bin/cursed-compiler --debug --verbose example.💀
├── src-zig/ # Zig compiler implementation source
├── runtime/ # Runtime library and garbage collector
├── stdlib/ # Standard library modules
├── specs/ # Language specifications
├── test_suite/ # Comprehensive tests (including LeetCode suite)
├── tools/ # Development tools
└── build.zig # Zig build configuration
CURSED has evolved through multiple implementation phases:
- ✅ Stage 0: Environment setup and language design
- ✅ Stage 1: Zig-native compiler with LLVM backend
- 🚧 Stage 2: Advanced features and optimization
- 🔮 Stage 3: Self-hosting compiler in CURSED
Current Status: Full compiler implemented in Zig with comprehensive language support, built-in LLVM backend, and extensive test suite including 17+ LeetCode problems.
We welcome contributions! Please see:
- Language specifications in
specs/
- Open issues for good first contributions
- Development roadmap in project milestones
- Follow the language specifications in
specs/
- Add tests for new features
- Update documentation
- Use conventional commit messages
- Language Specifications - Complete language documentation
- Grammar Reference - Syntax and grammar rules
- Type System - Type system details
- Concurrency Model - Goroutines and channels
- Memory Management - GC and memory model
- Error Handling - Error patterns and recovery
The test_suite/leetcode_comprehensive_suite/
contains 17+ LeetCode problems implemented in CURSED, demonstrating:
- Complex algorithms: Binary search, dynamic programming, backtracking
- Data structures: Linked lists and trees with
à¶ž
pointers - String manipulation: Anagram detection, palindrome validation
- Array operations: Two Sum, 3Sum, Product Except Self
- Meme implementations: FizzBuzz with "Sus" and "Impostor"
// LeetCode #206: Reverse Linked List with Among Us pointers
slay reverse_list(head à¶žListNode) à¶žListNode {
sus prev à¶žListNode = nah
sus current à¶žListNode = head
periodt current != nah {
sus next_temp à¶žListNode = current.next
current.next = prev
prev = current
current = next_temp
}
damn prev
}
- Basic syntax and language features
- Concurrency patterns with goroutines and channels
- Memory management demonstrations
- Error handling patterns
This project is licensed under the MIT License - see the LICENSE file for details.
- Inspired by Go's simplicity and concurrency model
- Gen Z linguistic creativity and internet culture
- The Among Us community for the iconic
à¶ž
character
"Stay based, avoid cringe, and always handle your yikes responsibly." 💀✨