Jump to text
On this page
Copy and source
Published source confirmed at last check

Source changed 2026-11-23 16:07:44 UTC · snapshot created 2026-11-23 16:09:03 UTC · last check 2026-11-23 19:45:10 UTC

CMP.15:4.6 - Establish preservation on the promised old uses

Preserve the old meanings as well as the old files. For each established operation, compare which body an old input selects after extension and which dependencies that body invokes. A new, more specific method can redirect an old call in a subtype-based dispatcher. Disallow that override, explicitly retain the earlier selection, or treat it as a behavior change requiring its own correspondence.

For a pure tree interpreter with exact keys, a useful preservation argument is available. Suppose the old keys still select the same bodies, the old expressions contain only old constructors, and primitives, environments and dependent operations retain their meaning. A leaf obtains the same result. At a compound old node, induction gives the same child results, and the unchanged body combines them in the same way. Every finite old expression therefore retains its result. This argument depends on those premises; unchanged source text alone does not prove them.

If the input grammar admits a new form under an old constructor, establish what that combination means. Old-use preservation only covered expressions admitted before the extension. A trace of the new call or an argument about all reachable calls can show how recursion reaches the intended implementation. A flat family of forms may require only its admitted operation–form pairs.

When effects, failures or concurrent replacement matter, use the observations and correspondence from CMP.12 and the interaction method in CMP.14. Preserving a returned number may leave an extra effect or a changed failure observable. Selected tests can expose such differences; a promise for an entire class of executions needs an argument at that scope.