On this page
veradic translate
Write source in a requested syntax, retaining comments where supported by the frontend.
veradic [GLOBAL OPTIONS] translate --to SYNTAX [-o DIR] [--plain-ada] FILES...
--to is required: vada, varc or vibe (target lookup is case-folded). DIR defaults to the current directory and is created if absent. At least one explicit input is required; there is no --project argument or project-wide implicit enumeration. Source files can use mixed registered extensions.
veradic translate --to varc -o converted src/counters.vads src/counters.vadb
veradic translate --to vada --plain-ada -o ada-source src/counters.vaFile names and the output directory are relative to the shell's current directory. The tool parses each input, checks the program to learn names, parameter modes and generic instances, then prints the units in the target syntax. It does not prove the result; no solver, C compiler or program runs.
Output rules
Vada specs/bodies may merge into a target package file; reverse translation can create separate spec/body/implicit-instance units. Names are determined from units and target conventions rather than a single caller-chosen output filename. Existing same-named files in DIR are overwritten. Use an empty separate directory to avoid changing active inputs or leaving stale old outputs. Original sources are not edited unless the chosen output directory/names overlap them.
--plain-ada is applied only when the target is Vada. It expands supported Verada extensions for ordinary Ada use, including forms whose semantics are expressed as generated loops/conditions. It does not promise whole-program GNAT/library compatibility for every accepted source.
Human diagnostics use stderr; each written file is listed on stdout. Listings still accompany JSON diagnostics, so stdout is not one JSON document. Success exits 0, translation or read errors 1; the units that translated are written even when others fail.
Checking a translation
Check, prove and run the translated program before replacing the original; a successful translation means the files were written. Review case, visibility, mutable parameters and results, and generic instances. The translation workflow describes a reviewable conversion and the GNAT and Python boundaries.