SFX (Situation Framework eXchange) "Programming the way humans think, not the way computers think" SFX is a beginner-friendly, context-oriented programming language designed for the 2025 AI era. With JIT compilation, reactive observers, and mathematical honesty, SFX makes programming intuitive and powerful. Why SFX? Fix 50 years of accumulated lies in programming: The Lie The Truth (SFX) 0.1 + 0.2 โ 0.3 0.1 + 0.2 = 0.3 (arbitrary precision) List[0] is first List[1] is first (1-based indexing) Null pointer errors No null (safe defaults: 0, "", False, []) "๐จโ๐ฉโ๐งโ๐ฆ".Length = 7 "๐จโ๐ฉโ๐งโ๐ฆ".Length = 1 (grapheme clustering) Objects are static Context-oriented (Situations modify behavior) Manual cache updates Reactive observers (self-healing data) Quick Start Installation # Clone the repository git clone https://github.com/roriau0422/sfex-lang.git cd sfex-lang # Build (Rust 1.75+ required) cargo build --release # Run a script ./target/release/sfex run tests/oop/context.sfex Your First Program Story: Print "Hello, SFX!" # Mathematical honesty - no float errors! Result is 0.1 + 0.2 Print Result # 0.3 โ # 1-based indexing - List[1] is first Numbers is [10, 20, 30] First is Numbers[1] # 10 โ Print "First number: " + First Core Features 1. JIT Compilation with Cranelift Automatic JIT compilation after 100 calls delivers 2-5x performance improvement: Concept: Calculator To Add with X and Y: Return X + Y Story: Create Calculator Called Calc # First 100 calls: interpreted # Call 100: JIT compilation triggered # Calls 101+: native machine code (2-5x faster!) Repeat 1000 times: Result is Calc.Add with 10 and 20 Performance: 230M ops/sec for arithmetic, 3M Fibonacci calls/sec 2. Reactive When Observers The killer feature: self-healing data that automatically maintains consistency. Concept: Product Price, Tax, Total # Automatic observer - fires when Price changes When Price changes: Set This.Tax to This.Price * 0.1 Set This.Total to This.Price + This.Tax Print "Price updated!" Story: Cr...
First seen: 2025-12-06 18:20
Last seen: 2025-12-06 18:20