On this page
B8002: assumed, not proved
Catalog status: active. Default severity: warning. Stable name: assumption. Family: Warnings and assumptions.
An explicit assumption or an external contract supplies a premise that Verada has not established from the program's implementation. Proofs using that premise are conditional on its truth. The warning identifies a trust boundary for review; a green proof summary does not independently validate the premise.
pragma Assume, Varc assume, and the corresponding supported Vibe specification forms are proof inputs; the generated code does not evaluate them. Do not rely on them to validate external input when the program runs. Write an executable guard and an ordinary assertion or a checked conversion when validation is required.
A function annotated Logical_Equal is assumed to be the prover's equality of its two values: if its body says something else (compares only part of a record, say), proofs that use it can be wrong. Keep such a function's body the plain component-by-component equality.
The contract of a C-imported subprogram is also assumed. Its profile, Global, precondition, postcondition and exceptional behavior must describe the implementation and ABI accurately. The compiler cannot infer that an imported function honors these promises. Embedded predefined library's contracts are trusted the same way by the programs that use it; veradic trust lists them.
Example (Vada)
pragma Assume (X < 100);
X := X + 1; -- Proof depends on the assumption.Example (Varc)
assume x < 100;
x += 1; // Proof depends on the assumption.
What to do
Replace the assumption with a fact derived from a precondition, invariant or proved assertion when it is internal to the program. For facts genuinely supplied by hardware or foreign code, document the evidence, owner and validity conditions. Check input in executable code before trusting it. Review the verification trust boundary when assessing the resulting guarantee.
Trusted enclaves, and --no-assume
The body of a proof enclave (Annotate => (Verada, Enclave)) is proved by the heap engine free of run-time errors and meeting its subprograms' contracts, which are what its clients are proved against. That each operation changes only the cells of its own objects (its frames) is proved with footprints, when each of the enclave's types keeps one; an enclave with a type that keeps none has its frames trusted, and this warning names the enclave on every build (see proof enclaves). --no-assume makes every such assumption (a pragma Assume, an import from C, an enclave with trusted frames) an error, as a release build should.
Regression source and further reading
Complete regression example: source, command arguments and expected results. The fixture deliberately reproduces this diagnostic.
See warnings and assumptions, the code index, and diagnostic interpretation for modes, replay, fix-its and JSON.