Est. 2019 Beginner

V (Vlang)

A simple, fast compiled language for developing maintainable software, with C-like performance and Go-like simplicity.

Created by Alexander Medvednikov

Paradigm Multi-paradigm: Imperative, Functional, Concurrent
Typing Static, Strong
First Appeared 2019
Latest Version V 0.5.0 (2025)

V (also known as Vlang) is a statically typed, compiled programming language created by Alexander Medvednikov in 2019. V aims to combine the simplicity of Go with the performance characteristics of C, while incorporating safety features inspired by Rust – all in a language designed to be learnable in a weekend.

History & Origins

V was born from frustration with the complexity and tradeoffs of existing systems programming languages. Alexander Medvednikov began developing V as a personal project in early 2019, originally intending it for private use. Public interest led him to open-source it under the MIT License on June 22, 2019.

The language attracted significant attention upon release, though it also drew scrutiny for ambitious early claims about features and performance. Since then, V has matured through its beta releases, steadily delivering on its goals of simplicity and fast compilation.

Design Goals

V was designed with specific goals in mind:

  • Fast compilation - The self-hosted compiler, written in V, reportedly compiles itself in under a second on typical hardware
  • Simplicity - A small language with no hidden control flow
  • Safety - No null, no undefined behavior, immutability by default
  • C interop - V compiles to human-readable C, leveraging GCC and Clang backends
  • No dependencies - The standard library avoids external dependencies

Language Design

V takes an opinionated approach to language design. Many features common in other languages are deliberately omitted:

  • No classes or inheritance - Structs with methods and interfaces (similar to Go)
  • No global variables by default
  • No exceptions - Error handling uses Result types with or blocks
  • No macros - Code is explicit
  • Immutability by default - Variables, structs, and function arguments are immutable unless marked mut

Variables and Types

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
fn main() {
    // Immutable by default
    name := 'World'

    // Mutable requires explicit declaration
    mut count := 0
    count += 1

    // Type inference with explicit option
    age := 25          // int inferred
    pi := 3.14159      // f64 inferred
    active := true     // bool inferred

    println('${name} ${count} ${age}')
}

Error Handling

V uses a Result type with or blocks instead of exceptions:

1
2
3
4
5
6
7
fn read_file(path string) !string {
    // ! indicates this function can fail
    content := os.read_file(path) or {
        return error('failed to read: ${path}')
    }
    return content
}

Compilation Model

V compiles source code to human-readable C, which is then compiled by a C compiler (GCC, Clang, or MSVC). This approach provides:

  • Broad platform support through existing C compiler infrastructure
  • Optimization benefits from mature C compiler backends
  • Easy interoperability with C libraries

Cross-compilation is built in: v -os windows or v -os linux works from the command line for targeting Windows, Linux, and FreeBSD.

Concurrency

V supports Go-style concurrency with lightweight threads and channels:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
fn expensive_computation(id int) int {
    // simulate work
    return id * id
}

fn main() {
    // Spawn concurrent tasks
    t := spawn expensive_computation(42)

    // Do other work...

    // Get the result
    result := t.wait()
    println('Result: ${result}')
}

Built-in Tooling

V includes a comprehensive toolchain:

  • v run - Compile and execute in one step
  • v fmt - Auto-format source code (enforces consistent style)
  • v test - Built-in testing framework
  • v doc - Generate documentation
  • v vet - Static analysis and linting
  • v translate - C to V translation tool (C2V)

V vs. Go Comparison

V is frequently compared to Go due to similar syntax and design philosophy:

FeatureVGo
Null safetyNo nullnil exists
MutabilityImmutable by defaultMutable by default
Error handlingResult type with orMultiple return values
GenericsYesYes (since Go 1.18)
CompilationTo C, then nativeDirect to native
Garbage collectionAutofree + optional GCGC

Platform Support

According to the official documentation, V supports Windows, macOS, Linux, FreeBSD, OpenBSD, NetBSD, and DragonflyBSD. Cross-compilation between supported platforms is built into the compiler.

Current Status

V remains in active development and is pre-1.0. The API and language features may change before a stable 1.0 release. V 0.5.0 was released on December 31, 2025, with approximately 3,700 fixes since V 0.4.

The V Community

  • vlang.io - Official website
  • docs.vlang.io - Language documentation
  • GitHub - github.com/vlang/v
  • Discord - Active community chat

Timeline

2019
Alexander Medvednikov announces V; open-sourced under MIT License on June 22
2020
V 0.2 released on December 22, focusing on stability and compile-time memory management
2022
V 0.3 released with C2V translation tool and 'v translate' command
2023
V 0.4 released on July 1, adding coroutines with scheduler for Linux and macOS
2025
V 0.5.0 released on December 31 with approximately 3,700 fixes since V 0.4

Notable Uses & Legacy

Vinix

An operating system kernel written in V, capable of running bash, GCC, V itself, and nano.

Gitly

A lightweight alternative to GitHub/GitLab, built entirely in V.

Veb

V's built-in web framework, included as part of the standard library.

Boundstone

A Minecraft: Bedrock Edition server implementation written in V.

Language Influence

Influenced By

Running Today

Run examples using the official Docker image:

docker pull thevlang/vlang:alpine

Example usage:

docker run --rm -v $(pwd):/app -w /app thevlang/vlang:alpine v run hello.v

Topics Covered

Last updated: