Verada Language Reference

Verada is one typed language, in the spirit of Ada, with three syntaxes: Vada (Ada's own), Varc (a C-family syntax) and Vibe (typed Python). A project may contain units in all three. Each syntax keeps its own rules where they differ; a familiar Ada, C or Python spelling does not bring every feature of that language with it.
Read the shared chapters for meaning and legality, then use the complete reference for your source presentation. Each syntax reference explains its own notation and vocabulary; you do not need prior Ada knowledge. Small Vada fragments in shared chapters illustrate a rule, and their surrounding prose states the rule independently of the spelling.
Shared rules
| Subject | Contents |
|---|---|
| Programs and names | Files, units, visibility, scope, elaboration, renaming, and main programs |
| Types and scalar values | Type identity, constraints, enums, modular/floating/fixed arithmetic, conversions, and static expressions |
| Integer ranges | Exact implementation bounds and worked arithmetic examples |
| Composite types | Arrays, shape, records, discriminants, aggregates, text, private and tagged types |
| Expressions | Operators, evaluation, membership, conditional values, quantifiers, and declaration expressions |
| Statements | Initialization, assignment, branches, loops, returns, blocks, and effects |
| Subprograms | Parameters, contracts at calls, overloads, nested functions, dispatch, and callbacks |
| Generics | Formal categories, instances, type identity, and inference limits |
| Contracts | Preconditions, postconditions, flow, type conditions, ghost code, invariants, and termination |
| Ownership and resources | Owners, moves, borrowers, observers, reclamation, copying, and finalization |
| Exceptions | User exceptions, exceptional contracts, handlers, effects, and cleanup |
| Concurrency and devices | Tasks, protected state, delays, priorities, volatile objects, and addresses |
| Pipelines | Sources, stages, consumers, lockstep iteration, reductions, and proof recovery |
| APL-style array programming | APL text in each syntax, the subset, shapes and proof, speed, REPL and editor support |
| Attributes | Every recognized attribute and its permitted use |
| Aspects and pragmas | Every aspect and pragma name and its effect |
| Verada and standard Ada | For Ada programmers: the Ada features Verada leaves out and their replacements, differences in meaning, and Verada's extensions |
| Compatibility | Vada, Varc and Vibe against Ada, C-family languages and Python, and translation between the syntaxes |
| Limits and excluded forms | Implementation limits and the forms the language leaves out |
Complete syntax references
- Vada: Ada source files, full supported grammar, declarations, statements, contracts, tasking, and Verada extensions.
- Varc: lexical rules, braces, public package members, mutable arguments, types, operators, contracts, and pipeline forms.
- Vibe: indentation, annotations, modules, classes, collections, sharing, helper forms, and the precise typed-Python subset.
Meaning of a successful command
Parsing establishes only that the source has an accepted shape. Semantic analysis resolves names and types and enforces legality. Flow analysis checks initialization, effects, ownership, and related rules. Proof establishes generated obligations using the declared contracts and assumptions. Native/JIT execution is a later step. These stages are distinct: a program can parse and pass check while its arithmetic or contract proof fails.
build and prove require every proof obligation to succeed. Development modes (run with the proof cache, --advisory, --no-prove) keep unproved checks as run-time checks. No mode changes the language's type bounds or turns signed overflow into wraparound. See the Toolchain Manual for the commands and modes.
Proof trusts the contracts of imported foreign subprograms and of the predefined library at the places your program calls them. Resource exhaustion, foreign faults, and environmental assumptions require separate consideration. A proof of contracts establishes the properties expressed in those contracts under the proof model; it does not establish unstated application requirements.
Conventions
An object is a variable, constant, parameter, or component with storage. A value is what an expression denotes. A subtype restricts an existing type without changing its identity. A unit is a separately loaded package or library subprogram, rather than every lexical block. The glossary defines other common terms.
“Must” states a requirement. “May” describes permission or a possible outcome. Examples marked as fragments need the indicated surrounding unit; complete examples link to maintained files. Where Verada accepts an Ada name without giving it an effect, the aspect and pragma catalog says so.