r/VibeCodedLanguages • • Aug 05 '26

What tools are you using?

Thumbnail
reddit.com
0 Upvotes

r/VibeCodedLanguages • • Aug 05 '26

Tyre

Thumbnail
reddit.com
0 Upvotes

r/VibeCodedLanguages • • May 28 '26

I wanted to make a Unity game but didn't want to write C#, so I built a whole language instead

3 Upvotes

Here it is: https://github.com/antonsynd/sharpy

You can also try the transpiler to C# in the browser without installing anything: Try Sharpy Online (Blazor WASM playground).

Why Sharpy?

I'm one of those people who wants to work on something, and then ends up building something to work on that something, which is completely unproductive. In this case, I wanted to make a game in Unity, but I didn't want to use C# 'cause reasons. I figured, why not create a Pythonic language that transpiles to C#? The object model and memory models are similar enough. (I had an earlier attempt to do the same but targeting C++ for a separate reason, but I quickly ran into hard decisions about wrapping everything in shared_ptr's and things looking kind of awful).

I'm aware that Boo was a thing, but one of the things that irked me about it was the retention of PascalCase access to .NET APIs. For a Pythonic language, access to .NET should look Pythonic.

Where it stands today

There is a compiler (using Roslyn), a standard library of the Python modules you expect most: json, os, re, numpy (sort of), sqlite3 (sort of), requests (sort of), itertools, etc., a language server with a VS Code extension, and support for multi-file projects via *.spyproj files (akin to *.csproj files).

Differences from Python and major defining features

Static typing

Sharpy is statically-typed, so no dynamic features are available (yet, or maybe ever). However, there are some things that make static typing more ergonomic:

x = 5            # obviously an `int`, specifically `int32`
                 # (`int` is an alias)

x: str = str(x)  # reassignment with a type annotation is shadowing

x: auto = [x]    # `auto` type infers and simplifies the type
                 # annotation for cumbersome types. here it is
                 # inferred to be `list[str]`. this also shadows.

True optional types

Sharpy supports nullable types AND true optionals. Nullable types are annotated as T | None, and optional types are T?. The reason both exist: .NET APIs return nullables, so Sharpy needs to interop with those, but for Sharpy-native code, true optionals (tagged unions under the hood) are safer and pattern-matchable. T? gets the short syntax because I wanted to promote optionals as the default choice. Null-aware operators work on both, e.g. ?. (safe navigation/optional chaining) and ?? (null-coalescing).

To make working with .NET and nullable APIs easier, you can use maybe in front of a nullable expression to auto-wrap the expression value in a true optional:

x: int | None = some_function_returning_nullable_int()
y: int? = maybe some_function_returning_nullable_int()

match y:
    case Some(v):
        print(v)
    case None():
        print("no value")

Result types

Sharpy also has a result type, with a similar keyword try for auto-wrapping throwing expressions in the result type, with optional type annotation to change the exception type in the result.

x: str !Exception = try some_throwing_function()

y: int !ValueError = try[ValueError] int(x.unwrap_or(""))

Tagged unions (algebraic data types)

Since Sharpy has both true optionals and result types, Sharpy predictably has ADTs/tagged unions (a la Rust):

union HttpResponse:
    case Success(body: str, status_code: int)
    case Redirect(location: str, permanent: bool)
    case ClientError(message: str, code: int)
    case ServerError(message: str, code: int)

def categorize(response: HttpResponse) -> str:
    match response:
        case Success(body, status_code):
            return f"ok: {body}"
        case Redirect(loc, permanent):
            return "moved" if permanent else "found"
        case ClientError(msg, code):
            return f"error {code}: {msg}"
        case ServerError(msg, code):
            return f"server error {code}: {msg}"

Casing and name mangling

As mentioned before, I believe access to .NET APIs and other PascalCase libraries should be Pythonic looking. So, there is name mangling of symbols to PascalCase for lookup:

from system import Console              # Note lowercase namespace

def main():
    Console.write_line("Hello World!")  # Note the snake_case

    print("Hello World!")               # You can also just do this,
                                        # don't worry

The compiler preserves original CLR names through the discovery pipeline, so interop just works: you write snake_case, the generated C# uses the correct PascalCase name, and the .NET runtime sees what it expects.

For cases (har-har) where you don't want name mangling to occur, you can use backticks to block this and let the compiler treat the symbol name as you wrote it:

from `System.Collections.Generic` import HashSet

def main():
    h = HashSet()

Underscores and dunder methods

Leading underscores on type members and methods lead to default access levels being applied. _foobar defaults to C# protected, and __foobar defaults to C# private. You can override this by using the associated access modifier "decorator"/attribute:

class Foobar:
    _something_protected: int

    __something_private: str

    @public
    __something_public_because_of_decorator: bool

    @private
    _something_private_because_of_decorator: float

    # Exception: dunders are public by default
    def __init__(self):
        pass

Dunder methods exist in Sharpy, but they are not real methods. Instead, they are treated by the compiler as an instruction to generate another method(s) to fit in the .NET ecosystem. Some are obvious like, __init__ is a constructor, whose body becomes the constructor's body, and __str__ becomes public string ToString().

Others are not as obvious like operators which create static operators (because that's how they work in .NET's runtime), __enter__ and __exit__ for context managers map to a compiler-generated C# IDisposable implementation, etc. Some are flat out not supported like __pow__ because ** is not an operator nor is it an overloadable method in .NET.

This was tough to reconcile, but I think I landed on something that is acceptable without being too jarring for Python developers.

Testing framework

Sharpy has a built-in @test decorator that maps to xUnit under the hood. You write tests that look like pytest, and the compiler emits [Fact], [Theory], [InlineData], and xUnit lifecycle plumbing:

@test
def addition_works():
    assert 1 + 1 == 2

@test.parametrize([(1, 2, 3), (4, 5, 9)])
def addition_parametrize(a: int, b: int, expected: int):
    assert a + b == expected

@test.skip("not implemented yet")
def todo_test():
    pass

There's also @test.fixture for shared setup/teardown and @test.collection for grouping.

Standard library highlights

The standard library has 31 modules. Some highlights:

  • numpy: NdArray[T] with broadcasting, slicing, linalg, FFT, and random (backed by Math.NET Numerics)

  • sqlite3: Connection, Cursor, Row with parameterized queries

  • requests: Python-compatible HTTP API

  • json: typed deserialization with json.loads[T](), custom encoders/decoders

  • re, os, itertools, functools, collections: the usual suspects

15 of these modules are themselves written in Sharpy (.spy files compiled to .dll).

Other notable features

There's a bunch of stuff in here, it's a bit much to write about exhaustively. Some quick hits:

  • Late-bound defaults (PEP 671): def f(x, y => len(x))

  • @lru_cache / @cache: compiler-innate functools memoization

  • Source generators: user-defined compile-time code generation

  • Inline out declarations: out name: type for .NET interop

  • Incremental compilation: content-hash caching with transitive dependency tracking

I hope you'll play with it and look at the file-based integration test fixtures for working examples. There's also a language server + VS Code extension (not submitted to the marketplace yet, but you can load it locally) with syntax highlighting, doc/type on-hover tooltips, inline argument names, rename support, go-to-definition, and semantic token highlighting. There are probably bugs in the highlighting and stuff, but it works enough to make me happy.

Thoughts on AI-driven development

Honestly, if it wasn't for Claude, this project would've taken me at least 3 years, optimistically. I didn't use AI in the beginning; I hand-wrote a chunk of the standard library, tried to write the parser with ANTLR, and so on, but I got impatient and ran into tougher parts of the compiler that discouraged me. So almost a year later, I leaned into AI-accelerated development with some guardrails: a hand-written language specification, three axioms that govern almost every design decision (modulo my personal preference), and a growing suite of file-based integration test fixtures and property tests.

I think of my role as the "orchestrator", deciding what the language should be, writing the spec, reviewing the output, and steering corrections. Yeah, I didn't learn the nitty gritty of writing a compiler or language server, but it left me room to think about higher-level language design: do these features make sense, do they compose well, do they feel right? I know not everyone in the compiler/programming language space is happy with this direction, but I feel a lot more empowered to implement ideas this way.

The implement-eval/test loop is much faster, and you can validate ideas quickly. At the same time, without oversight, AI can take a language feature in a different direction or implement something narrowly. It's very difficult with the velocity and volume of code generation to keep up as a solo human reviewer. The spec and axioms help, but I'll be honest, there's a degree of blind faith that AI-generated tests aren't hiding poor decisions in the actual implementation. I guess I'll find out when I actually use it for my Unity game.

Next steps

  • Unity plugin: hooking the Sharpy compiler into the Unity build flow, which was the whole point of this project

  • Rounding out the stdlib: filling gaps in existing modules, potentially adding more

  • Actually making the game lol

Hope this has been educational, happy to answer any questions!


r/VibeCodedLanguages • • Aug 03 '26

AI-friendly programming language design

Thumbnail reddit.com
2 Upvotes

r/VibeCodedLanguages • • 23d ago

madc v0.106.1 released — faster C compilation, leaner executables, SQLite support, and improved C++ exceptions

Thumbnail reddit.com
2 Upvotes

r/VibeCodedLanguages • • May 23 '26

👋 Welcome to r/VibeCodedLanguages - Introduce Yourself and Read First!

3 Upvotes

Hey everyone, I'm u/antonation, the founding mod for r/VibeCodedLanguages.

This is a home for all things related to developing programming languages and compilers using AI.

What to Post
Post anything that you think the community would find interesting, helpful, or inspiring. It could your progress, your workflow (MCPs, testing frameworks, etc.), or questions if you're looking to get started.

Community Vibe
This is a friendly, constructive, and inclusive space. I believe AI is here to stay and welcome AI-driven development (which is of course, why you're here).

How to Get Started

  1. Introduce yourself in the comments below.

  2. Post something today, anything you're working on, challenges you run into, etc.

  3. If you know someone who would love this community, invite them to join.

  4. Interested in helping out? I'll be looking for additional mods at some point, so feel free to reach out to me if you're interested.

Thanks for joining and I hope we can all learn from each other.


r/VibeCodedLanguages • • Sep 01 '26

Working on the IDE

Thumbnail reddit.com
2 Upvotes

r/VibeCodedLanguages • • Sep 09 '26

Nyx’s post-v5 compiler architecture: Typed HIR → MIR → target legalization

2 Upvotes

I’ve been working on the next stage of Nyx’s compiler architecture after v5.

Nyx already has a canonical Typed HIR and multiple output targets, but I don’t want every backend to slowly become its own slightly different interpretation of the language. The current work introduces a lower-level MIR between Typed HIR and the backends:

Nyx source
    ↓
AST
    ↓
Canonical Typed HIR
    ↓
Verified MIR
    ↓
Target legalization
    ↓
C++ / LLVM / Wasm / Rust / JavaScript / Python / C17

This is being developed with heavy agent assistance, so I’m deliberately separating implemented and tested work from architectural plans.

What is currently implemented:

  • M0 — Canonical contracts: the language surface, diagnostics, backend capabilities, standard-library availability and semantic policies are recorded in machine-readable contracts.

  • M1 — MIR foundation: a serializable and verifiable CFG-based MIR with functions, locals, basic blocks, places, operands and explicit terminators.

  • M2 — Scalar and control-flow lowering: variables, calls, branches, loops, break, continue, strict evaluation order, wrapping 64-bit arithmetic and division traps.

  • M3 — Semantic control flow: lexical defer cleanup chains, Result propagation with ?, guards, ranges, match lowering and try/catch/throw edges.

  • M4 — Values, memory and ABI: arrays, structs, payload enums, projected places, copy/move operands, use-after-move and double-drop checks, explicit x64/wasm32 layouts, calling-convention classification and checked C adapter contracts.

  • Bundle ABI v1 remains unchanged while a possible ABI v2 is only documented as a draft.

The completed milestones have focused regression suites, including execution through a reference MIR interpreter and selected C++/LLVM oracle comparisons.

What is not finished:

  • MIR is still experimental and is not yet Nyx’s default compilation route.

  • The existing Typed HIR backends remain the production path and parity oracle.

  • M5 backend migration is in progress. C++ is the first MIR consumer; LLVM, Wasm, Rust, JavaScript, Python and C17 still need to be migrated one at a time.

  • A backend must eventually publish exactly which MIR operations, types, effects, runtime calls and ABI forms it accepts.

  • Unsupported operations must produce stable diagnostics before reaching an emitter. There must be no silent or approximate fallback.

  • The ownership analysis is currently a conservative MIR validation model, not a claim that Nyx has a Rust-equivalent borrow checker.

  • C17 and direct LLVM emission remain experimental.

  • Cross-platform CI, artifact-level ABI fixtures and full differential parity are still required before MIR can replace the existing path.

The detailed architecture document explains the representation boundaries, layout model, ABI plan, legalization rules, migration order and later language-surface work:

https://github.com/justsomeone-e/nyx/blob/main/docs/internals/NYX_DEEP_COMPILER_ARCHITECTURE.md

I’d especially appreciate feedback on three questions:

  1. Is the Typed HIR → MIR boundary placed at the right semantic level?

  2. Should legalization transform target-independent MIR into a second target-specific MIR, or is a strict legality pass before emission sufficient?

  3. Which ABI/layout fixtures would you consider mandatory before trusting native and Wasm aggregate interoperability?

I’m interested in criticism of the actual contracts and failure modes, not just the number of planned backends.


r/VibeCodedLanguages • • Sep 17 '26

Klyn 0.1.7

Post image
3 Upvotes

r/VibeCodedLanguages • • Oct 09 '26

madc v0.103.0 released — faster compilation, improved C++ compatibility, and a major TUI facelift

Post image
2 Upvotes

r/VibeCodedLanguages • • Aug 01 '26

Developing my programming language: Gravel

Thumbnail
reddit.com
2 Upvotes

r/VibeCodedLanguages • • Sep 29 '26

Building VBX: An iterative, compiled Basic-to-C99 language with memory pooling and multi-editor tooling

2 Upvotes

Hey everyone!

I wanted to share an ongoing language design project I’ve been building: VBX (Visual Basic X).

Instead of a one-shot prototype or another interpreted toy running inside Python, the goal was to build a real, production-capable procedural language that compiles to standalone native binaries with zero runtime dependencies.

Architectural Decisions & Implementation

  1. Compiler Host (Go) -> Target (C99):

    • The compiler itself is written in pure Go without external packages, leveraging the standard library for AST construction, multi-pass type inference, and process orchestration.

    • Emits clean, standard C99 code and invokes the system toolchain (GCC/Clang) with -O2 optimizations.

  2. Solving the Runtime Memory Problem (Ring-Buffer Pool):

    • Naive transpilation of string operations inside tight loops (s = s & "x") typically floods malloc without high-level deallocation.

    • We implemented a fixed static ring-buffer memory pool (vbx_alloc_str with 256 rotating slots of 4KB) directly in the emitted C runtime. Tested under 10,000 continuous iterations with zero heap leaks and flat memory usage.

  3. Language Syntax & Semantics:

    • Visual Basic-inspired syntax: Dim, Const, If/ElseIf/Else, For/Next, While/Wend, Do/Loop, Select Case (supporting both string and numeric comparisons natively via chained branches), Sub, Function, and 1D fixed arrays.

    • Built-in primitives: Native OS dialogs (MsgBox, InputBox), standard File I/O, and string manipulation routines.

  4. Testing & Tooling:

    • 42 integration and unit test suites running via go test ./....

    • Complete multi-editor support repository: official VS Code extension (available on Visual Studio Marketplace), plus packages for Sublime Text, JetBrains, Vim/Neovim, Notepad++, Emacs, and Micro.

    • Currently designing Phase 2: a dedicated desktop IDE with a visual form designer (vbx-studio).

Repository: https://github.com/M5Devs/vbx Editors: https://github.com/M5Devs/vbx-editors

Would love to discuss the language design trade-offs, transpiler architecture, and experiences building full-scale compilers using modern agentic workflows!


r/VibeCodedLanguages • • Oct 16 '26

madc v0.105.0 — Live C/C++ REPL function redefinition, and faster compilation

Thumbnail
reddit.com
2 Upvotes

r/VibeCodedLanguages • • Aug 17 '26

madc v0.82.0: Linux, macOS and Windows now supported

Thumbnail
reddit.com
2 Upvotes

r/VibeCodedLanguages • • Aug 20 '26

madc v0.92.1 released — std::format, std::println, php::print_r, php::var_dump

Thumbnail
reddit.com
3 Upvotes

r/VibeCodedLanguages • • Aug 23 '26

madc v0.95.2 released — faster startup, faster FP code, and less ceremony

Thumbnail
reddit.com
4 Upvotes

r/VibeCodedLanguages • • Aug 11 '26

madc v0.76.0: macOS support joins Linux — Apple Silicon + Intel

Thumbnail
reddit.com
2 Upvotes

r/VibeCodedLanguages • • 3d ago

Tessera: a tensor-first compiled language. I designed it and wrote the first version by hand, then built most of the rest with Codex and Claude

2 Upvotes

Hi! Someone suggested I share this here. Tessera is an experimental, tensor-first language for numerical computing and data analysis. It compiles to native code through LLVM, and it was built by me together with AI coding agents.

GitHub: https://github.com/dyanos/csec-
(The repo name csec- and the compiler binary csec++ are historical names; the language is Tessera.)

Who did what

  • Me, by hand (late 2024 to early 2026): the language concept and design, the first lexer and parser, the AST, LLVM IR generation, constructors, C++ name mangling, external functions, and the early LaTeX-style math syntax.

  • OpenAI Codex: the native runtime, tensor and simulation features, native library interop, templates, and the first self-hosting bootstrap.

  • Claude (Claude Code): the ownership and move checker, async/await, Erlang-style microthreads, most of the standard library, support for LLVM 18 through 23, Parquet/CSV data frames, and import aliases. About 110 of the ~200 commits are co-authored with Claude.

What I learned about building a language with agents

  • Tests are the real spec. The agents are very productive but will confidently break things. I keep positive and negative fixture suites, ownership suites, and concurrency and stdlib tests, and the same suites run through two compilers: the C++ one and a self-hosted one.

  • Self-hosting is a great lie detector. A second compiler written in Tessera has to compile itself and reproduce the same output (a fixed point). A codegen bug the agent "fixed" often shows up only one stage later, and the fixed-point check catches it.

  • My job changed. I went from writing code to deciding semantics, reviewing diffs, and designing verification. Design decisions such as strict-by-default ownership and tensors as a core type stayed with me. The agents were best at the large, well-specified implementation work.

  • Agents make the same subtle mistakes repeatedly. Examples are an LLVM API that changed behavior silently between versions, and build tools that didn't notice changed header files. Writing these down as project notes for the agent helped a lot.

A taste of the language

// Tensors are a core type, with the shape in the type
def affine(x: Tensor<Double, 1, 3>,
           w: Tensor<Double, 3, 2>,
           b: Tensor<Double, 1, 2>): Tensor<Double, 1, 2> {
    return (x @ w) + b;
}

// Strict-by-default ownership: explicit move `<-` and borrow `&`
val acct: Account = new Account(100);
peek(&acct);        // borrow, acct still usable
close(<- acct);     // move
// using acct now -> compile error: "use of moved value 'acct'"

// Erlang-style microthreads
import std.microthread

def main(): Int {
    val parent = self();
    val worker = spawn([=]() -> {
        val n = receive();
        send(parent, n * 2);
        return 0;
    });
    send(worker, 21);
    return receive();   // 42
}

Other features: arbitrary-precision Nat, built-in Complex/Rational/Quaternion, a symbolic algebra module, async/await, OS threads with channels, pipes, shared memory, and [@DllImport] for calling native libraries. A parallel wc -l written in Tessera runs at about 92% of a hand-written C++ mmap+SIMD version.

Current state

It's experimental. Right now I'm working on performance, starting with std.dataframe. The tensor codegen is still the first, straightforward version: shapes are read at runtime instead of being used at compile time, there's no loop fusion, and some temporaries aren't freed yet. Fixing that is next.

Questions for you

  • How do you verify AI-written compiler code? Do you use self-hosting, differential testing, or something else?

  • Where do you keep design authority, and where do you let the agent decide?

Thanks for reading!


r/VibeCodedLanguages • • Sep 21 '26

Why Nyx Became Rove — and Why r/RoveLang Is for More Than Just Rove

Thumbnail reddit.com
2 Upvotes

r/VibeCodedLanguages • • Aug 30 '26

Klyn 0.1.5

Post image
2 Upvotes

r/VibeCodedLanguages • • Aug 16 '26

I vibe-coded a programming language. It got slightly out of hand.

Thumbnail flooooooooooow.github.io
2 Upvotes

r/VibeCodedLanguages • • Oct 12 '26

madc v0.104.0 released — interactive editing, LSP/MCP support, and madcide gets its own repo

Thumbnail reddit.com
2 Upvotes

r/VibeCodedLanguages • • Sep 29 '26

Nyx isn’t dead — it’s Rove now. Here’s where the language actually stands.

Thumbnail reddit.com
2 Upvotes

r/VibeCodedLanguages • • Aug 17 '26

Velaris: a language where the compiler proves your functions keep their promises

2 Upvotes

The idea: I wanted a language where you can trust a function just by reading its first line. So the signature says what effects it uses (a function without "uses net" can't touch the network), whether it can fail (ignoring that doesn't compile), and any promises it makes about its result.

Those promises get checked by the Z3 theorem prover before the program runs. If your code breaks one, it tells you the exact input that breaks it: error[E700] promise cannot be kept: 'discount' ensures result >= 0 proven without running the program: price = 5 gives result = -5

The part I'm most pleased with is the float handling. It proves in real IEEE-754 rather than pretending floats are perfect decimals, so it refuses to certify x + 0.1 + 0.1 == x + 0.2 and hands you the exact number where it breaks. A lot of tools would just "prove" that and be wrong.

Playground, runs in your browser, nothing to install:

https://gowrishankar-infra.github.io/velaris-lang/playground.html

Repo: https://github.com/gowrishankar-infra/velaris-lang

Built with a lot of AI help over 40+ releases. It's got a REPL, editor support, a standard library written in itself, CI, and one-file downloads for Windows/Mac/Linux. Happy to answer anything. Thank you


r/VibeCodedLanguages • • Sep 04 '26

[RFC] Working on Nyx RC.2 (Wasm pipeline & DOM integration). What features or ergonomics would you expect?

3 Upvotes

Hey everyone,

First off, huge thanks to everyone who checked out the repo, left comments(No one did ngl), and starred the project(2 Stars still thanks!) after my previous post. The feedback and discussions around systems language trade-offs were genuinely invaluable.

I'm currently designing and mapping out Nyx RC.2, with a heavy emphasis on making WebAssembly a first-class, seamless target rather than just an afterthought backend.

What's currently being integrated for RC.2:

  1. Zero-friction TypeScript / JS Interop: When compiling to Wasm, the compiler will automatically emit .d.ts type definition files alongside the .js glue wrapper, allowing Nyx Wasm modules to be imported directly into React/Next.js/Node projects with full IntelliSense.

  2. Deterministic Memory & Cleanup: Continuing to refine the Typed HIR pipeline so that linear memory allocation, defer, and RAII semantics remain memory-safe without requiring a heavy runtime or a complex borrow checker.

  3. Cross-Platform Tooling & "Tour of Nyx": Refactoring our interactive terminal learning suite (tour) to be fully portable across Windows, macOS, and Linux without environment assumptions.

  4. Web / DOM Bindings Exploration: Exploring minimal, zero-overhead DOM and WebGL/WebGPU hooks directly from the language.

I'd love to hear your thoughts:

  • For those who work with Wasm or build compilers: What is currently the most painful part of your Wasm workflow that you wish a language solved out-of-the-box?

  • Are there specific language ergonomics, stdlib modules, or tooling features you'd love to see in RC.2?

  • Any edge-cases or architectural pitfalls in Wasm/C++20 lowering I should watch out for?

Repo is available here if you want to inspect the current codebase: https://github.com/justsomeone-e/nyx

Appreciate any critiques, feature requests, or sanity checks!