Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Updating to 0.2

Version 0.2 is the first breaking release of qFALL since its publication on crates.io. Its most important change is invisible in most code: qfall-math moved from FLINT 2.8 to FLINT 3.6. Beyond that, the release adds reproducible (seeded) sampling, several convenience functions, a prototype of ML-DSA, and fixes a few bugs.

The following chapters cover the release in detail:

  • New Features lists everything that was added to qfall-math, qfall-tools, and qfall-schemes.
  • Bug Fixes lists the fixed bugs, including fixes that change the output of existing functions.
  • How to Transition explains step by step how to move your project from version 0.1 to 0.2.

Main Novelties

  • FLINT 3.6 via flint3-sys replaces FLINT 2.8 via flint-sys.
  • Seeded sampling: every sampling function has a _seeded variant that takes a 256-bit seed and produces reproducible output.
  • Negation via the unary - operator for all integer, rational, and residue class types.
  • New functions: hamming_weight, norm_eucl for polynomials, get_representative_least_absolute_residue for all residue class types, and change_modulus/change_q to switch the modulus of an existing value.
  • ML-DSA: a prototype of the signature scheme behind FIPS 204 in qfall-schemes.

Do I Need to Change My Code?

Most projects that only use the safe API of qFALL need nothing but a version bump, a call to cargo clean, and a newer Rust toolchain. The table below tells you which parts of the transition guide are relevant for you.

If your project…then you need to…Details
uses any qFALL crateupdate all qFALL crates to 0.2 and Rust to 1.88 or newerUpdating Dependencies
builds in CI or Docker imagesremove existing cache and check the build requirementsBuilding FLINT 3
uses unsafe getters/setters like get_fmpz or calls FLINT directlyswitch from flint-sys to flint3-sys and adapt to FLINT 3Migrating Direct FLINT Usage
uses Zq::get_representative_least_absolute_residuecheck whether you rely on a non-negative resultBehavior Changes
initializes samplers from qfall_math::utils::sample directlyadd the new seed parameterChanged Signatures
uses MatZq::sample_discrete_gauss or MatZq::sample_binomial(_with_offset)remove workarounds for unreduced entriesBehavior Changes
compares Debug outputupdate the expected stringsBehavior Changes