Skip to content

Quod 0.3.1

Choose a tag to compare

@github-actions github-actions released this 06 Nov 09:47
· 53 commits to main since this release

Quod 0.3.1: what the first agents to write 0.3 ran into. No proof changes: a program that compiled gives the same verdicts, and only the C# class of a file that holds a type of its own name changes.

Install

As for 0.1.0: download the package for
your system, unpack it, and run quod from that folder (z3 4.12.1 is inside). On macOS, run
xattr -d com.apple.quarantine quod z3 in the folder first. The MCP server:
claude mcp add quod -- /path/to/quod mcp, or see
docs/mcp.md. Quod.Build, attached, is a NuGet package:
see its README.

Fixed

  • C#: a type named like its file. struct Money in money.quod was proved, and its C# did not compile. The class of the file is now MoneyModule, and the type MoneyModule.Money.
  • Ok where option.Ok is meant. The message now gives the full name of a case of an imported module.
  • A literal in the cases of a match takes the bounded type its context wants, as in the branches of an if: let p: i32 = match c { Regular => 0, Staff => 30 }; needed to_i32.

Measured

  • An agent on the features of 0.3, on 0.3.0: Haiku wrote 12 small tasks 3 times each from the reference alone. 36 of 36 verified and passed hidden tests, and 33 of 36 compiled in C#. No cost of i32 against int could be seen, on tasks this small. They are easy, and the contracts were not measured: this says the features can be written, not that they hold on a real program.
  • All compiler tests pass. The mutant benches were not rerun: no proof changes.

Known

Those of 0.3.0, except the above.

  • A function whose body is made of statements cannot be used in a contract, and that includes strings.find: a contract needs a function of a single expression.
  • i32 * i32 stays i32 when an int is expected, and must fit: let q: int = x; widens first.