Parma Polyhedra Library requirements
Internal Box cached-status assertions
1. Box cached claims and independent status ownership PPL-SPEC-000671

Box<ITV>::Status shall own three Boolean claims: emptiness is current, the box is empty, and the box is universe. An empty flag shall establish emptiness only when the current flag is set. A stale empty flag may coexist with a universe claim. Simultaneous current emptiness and universality shall violate the status invariant.

Default construction shall clear all three claims. Copy construction and assignment shall retain the source's claims in an independent owner; assignment shall admit self-assignment and return its target. Later mutation or destruction of either owner shall not change the other's claims. These operations shall not inspect coordinate intervals.

Calls shall use live owners and synchronized access against mutation. The owning box shall establish that its claims agree with its mathematical value. Direct flag updates may create temporary inconsistent claims; validity queries shall admit those states, but a box shall not use them as a valid status. No library/thread initialization or coefficient-constant stage shall be required for status operations alone.

PPL-SPEC-000672
2. Independent cached-status bit updates and queries PPL-SPEC-000672

The three test_* queries shall return their respective stored Boolean claims without mutation. Each set_* shall set exactly its named claim and each reset_* shall clear exactly its named claim, retaining every other claim. Updates shall not refresh emptiness, inspect coordinates or implicitly reconcile other claims.

For a mask composed of the three named flags, internal test_all(mask) shall report whether every selected flag is set; the zero mask shall return true. test_any(mask) shall report whether any selected flag is set; the zero mask shall return false. Internal set(mask) and reset(mask) shall set or clear exactly the selected flags. Prerequisites and temporary state handling shall follow 🔗 1. Box cached claims and independent status ownership.

PPL-SPEC-000673
3. Status consistency query and diagnostic PPL-SPEC-000673

OK() shall return false exactly when current emptiness and universe are all asserted, and true for every other combination. It shall not refresh claims or change the status.

With assertion diagnostics enabled, the inconsistent case shall write The status asserts emptiness and universality at the same time. followed by a newline to std::cerr. Other cases shall emit no diagnostic; with diagnostics disabled, no case shall emit that diagnostic. Stream failures shall follow the stream's ordinary exception-mask rules. The checker shall admit the temporary states described in 🔗 1. Box cached claims and independent status ownership.

PPL-SPEC-000674
4. Status ASCII export preserves cached claims PPL-SPEC-000674

ascii_dump shall insert the three status fields in this order: EUP for current emptiness, EM for the empty flag and UN for universe. Each field shall consist of + when its claim is set or - when clear, followed by its keyword and one space. With default compatible formatting, the zero status shall therefore emit -EUP -EM -UN followed by one space. The inserted characters and strings shall follow ordinary stream formatting, including any pending width, fill and alignment settings.

The no-argument ascii_dump() shall write that representation to std::cerr. print() shall write No user level output operator defined for Box<ITV>::Status. followed by a newline to std::cerr. Export shall preserve the stored claims, including stale flags, and shall not inspect the box's coordinate payload or refresh its emptiness. Partial output and stream exceptions shall follow ordinary stream rules. Other prerequisites shall follow 🔗 1. Box cached claims and independent status ownership.

5. Status ASCII loading and partial rejection state PPL-SPEC-000675

ascii_load shall extract three fields in the order and spelling of 🔗 4. Status ASCII export preserves cached claims. Each token shall begin with + or - and contain exactly the corresponding keyword. Extraction shall follow ordinary string rules, including stream width and whitespace settings. A complete consistent triple shall replace all three claims and return true, independently of the destination's previous claims; trailing tokens shall remain available for subsequent extraction.

A missing, malformed or out-of-order token shall return false. Each successfully parsed preceding field shall already have replaced its claim; the rejected field and following claims shall retain their preceding values. A completed triple asserting current emptiness and universality shall be rejected with false. Rollback and status consistency after a failed load shall not be promised; callers shall restore a consistent status before using it as box state. Stream exceptions shall propagate under ordinary exception-mask rules, with preceding field updates retained.

The internal get_field helper shall assign its output Boolean only when it successfully matches the requested signed keyword. It shall preserve that Boolean on rejection. Other prerequisites shall follow 🔗 1. Box cached claims and independent status ownership.