Osprey Language Specification
Version: 0.2.0
Date: 2026-06-19
Author: Christian Findlay
Table of Contents
- Introduction
- Lexical Structure
- Syntax
- Type System
- Function Calls
- String Interpolation
- Pattern Matching
- Block Expressions
- Boolean Operations
- Iterators and Iteration
- Fibers and Concurrency
- Built-in Functions
- Error Handling
- HTTP
- WebSockets
- Security and Sandboxing
- Algebraic Effects
- Memory Management
- Foreign Function Interface
- Language Server & Editor Integrations
About This Specification
This specification defines the complete syntax and semantics of the Osprey programming language. Each section is available as a separate page for easy navigation and reference.
The Osprey language is designed for elegance, safety, and performance, emphasizing:
- Algebraic effects with compile-time safety — unhandled effects are compilation errors
- Named arguments for multi-parameter functions to improve readability
- Strong type inference (Hindley-Milner) to reduce boilerplate while maintaining safety
- String interpolation for convenient text formatting
- Pattern matching for elegant conditional logic
- Immutable-by-default variables and persistent collections
- Fast HTTP/HTTPS servers and clients with built-in streaming support
- C interoperability via a typed foreign function interface
Implementation Status
🚧 NOTE: The Osprey language and compiler are actively under development. This specification represents the design goals and planned features. Please refer to individual sections for current implementation status.