Documentation
Learn how to use varylang, from installation to advanced features.
Alpha. Vary is under active development and not ready for production use. Syntax, APIs, performance, and behaviour may change between releases.
|
|
| Introduction | What Vary is and why it exists |
|
|
| Getting started | Install Vary and write your first program |
| Syntax overview | A guided tour of Vary's syntax and features |
| CLI reference | Commands for running, testing, formatting, and building |
| Configuration | Project settings via vary.toml |
| Project layout | Recommended directory structure for Vary applications |
| Quick reference | Daily command sequences for Vary development |
| FAQ: Frequently asked questions | Common questions about the language and toolchain |
| Glossary | Plain-English definitions for verification, compiler, and language jargon |
|
|
| Types | Primitives, optionals, function types, and type inference |
| Classes and data types | Classes for mutable state, data types for immutable values |
| Generics | Write type-safe code that works with any type |
| Enums and pattern matching | Fixed variant types with payloads and pattern matching |
| Collections and strings | Lists, dicts, sets, and string operations |
| Error handling | Try/except, Result types, and custom error classes |
| Modules and imports | File-based modules, imports, and package structure |
| Concurrency | Spawn tasks, manage task groups, and handle cancellation |
| Contracts | Preconditions and postconditions on functions |
|
|
| Built-in functions | Functions available everywhere without imports |
| Standard library | Importable modules for JSON, crypto, filesystem, HTTP, time, process, env, logging, and more |
|
|
| Check rules | Reference for all vary check diagnostic rules, categories, and auto-fixes |
| Testing | Built-in test blocks with observe assertions and property-based testing |
| CI verification | Set up GitHub Actions for Vary projects with verification profiles |
|
|
| Linux | Install the Vary toolchain on Linux |
| Windows | Install the Vary toolchain on Windows |
| varyup | The toolchain manager that installs and updates Vary |
| Docker | Run Vary in a Docker container |
| VS Code | VS Code extension with syntax highlighting and LSP |
| macOS | Install the Vary toolchain on macOS |
|
|
| Python comparison | Side-by-side syntax and semantics comparison with Python |
| Hypothesis comparison | How Vary's across-based property testing compares to Hypothesis for Python |
| Related languages | Languages that influenced Vary's design |
|
|
| Writing Vary with LLMs | Using AI coding tools to write Vary programs |
| LLM coding checklist | Do-this / don't-do-this rules for LLM coding assistants writing Vary |
|
|
| Varyonic programming | The design philosophy of Vary: observable behaviour, typed domains, pure logic, and verification-first architecture |
| Language design choices | Trade-offs and rationale behind language decisions |
| The compiler | How the compiler pipeline turns source into bytecode |
| Performance | Benchmark results comparing Vary to Java and Python |
| Ecosystem | Tools, extensions, and integrations around Vary |
| What we ship | Distribution formats and what each release includes |
|
|
| Embedded DSLs | Compiler-integrated DSLs for SQL, HTTP, structured logging, and JSON decode |
| HTTP services | Expose interfaces as HTTP services with typed routes |
| SQLite databases | Built-in SQLite support with compile-time typed queries |
| Structured logging | Typed, mutation-aware logging with pluggable sinks |
| JSON decode | Typed JSON extraction with path-aware errors, validation predicates, and the ? operator |
|
|
| Known Issues | Currently known bugs and limitations |
| Versioning | Monotonic channel versioning instead of semver |
|
|
| Releases | Release notes for every version |
|
|
| Brand | Logo, wordmark, and visual identity guidelines |
|
|
| Templates | Pebble-based template rendering with Vary data types as context |