]> dreyeck.freedombox.rocks Git - topic-maps.git/blob - docs/slice-20f-ctm-integer.md
perf(tmdm): index topic normalization merge candidates
[topic-maps.git] / docs / slice-20f-ctm-integer.md
1 # Slice 20F: the CTM integer literal
2
3 CTM 3.4.1 [28]/[30]/[33] maps the exact bare "*" literal to lexical value "*"
4 and datatype http://psi.topicmaps.org/iso13250/ctm-integer:
5 https://www.isotopicmaps.org/ctm/ctm.html .
6 It does not generate a counter value or create a wildcard identity.
7
8 The existing number-token scanner and all its delimiters remain unchanged.
9 Only its exact-star token label changes from excluded-literal to ctm-integer.
10 The shared read-literal branch consumes that token and returns the literal
11 value and datatype. Existing Occurrence and Variant operations do the model
12 work. Existing Template argument dispatch and syntax-literal accept the same
13 literal token; no new Template productions, TMDM operations, datatype
14 conversions, counter changes, encodings or string syntax are introduced.
15
16 The durable suite uses the existing Slice 20A exercise-case function and the
17 same discovered original Case Record. It checks the original 18 bytes,
18 Document IRI, actual model properties, raw object preservation and exact
19 356-byte CXTM baseline. The explicitly qualified spelling is separately
20 deserialized and compared with that same original baseline. Other controls
21 cover plain strings, numeric literals, Variants, existing Template argument
22 and body paths, token delimiters, wildcard identifiers and nonzero counters.
23 The suite runs unconditionally after the retained Slice 20E report stage.
24
25 Before implementation, a fresh offline SBCL process captured 24 diagnostic
26 cases. The final suite preserves 22 signatures (class, code, offset, unit,
27 line, column and source). Two malformed inputs now reach their actual
28 following syntax errors: "*^^<urn:d>" and "* extra". They still reject, at
29 character offsets 16 and 17 (line 2, columns 11 and 12), rather than stopping
30 at the formerly unsupported "*" at offset 15. Two additional controls reject
31 using the CTM-integer argument as a Topic or as a Name string.
32
33 Obsolete Unsupported assertions are explicitly replaced: the old "*." syntax
34 rejection now tests "*x."; the integer boundary accepts the CTM-integer value;
35 the occurrence feature boundary permits "*"; the prolog boundary still tests
36 an unsupported literal, now a triple-quoted string. New regenerated reports
37 are compared with the previous reports using only the documented label/control
38 substitutions. Historical report bytes are never rewritten.
39
40 Reproduce with an existing SBCL 2.5.4 and a new output directory:
41
42 python3 scripts/validate-slice-20f.py --sbcl /absolute/path/to/sbcl --output /private/tmp/new-slice-20f-report
43
44 The committed preimplementation.json is the default diagnostic reference.
45 For the first run, pass --preimplementation with the captured pre-change file.
46 The validator uses verified local Store sources and unchanged XML patches,
47 with no downloads. Fresh SBCL processes have network denied. The full suite
48 covers TMDM, CTM/CXTM, Include, XML qualification, standalone XTM, CTM/XTM
49 Mergemap, all retained Slice 20 stages, the new literal suite, Python tests
50 and the NFC oracle. It rechecks every pinned corpus file and all historical
51 report hashes. execution.json records actual results rather than predicted
52 conformance totals; current.literal.json contains controls and Conditions,
53 current.cxtm.json the actual/baseline streams and current.validation.json
54 the final shared Case Records.
55
56 The normal execution sandbox previously failed on the configured writable-root
57 symlink /Users/rgb/.nix-profile. These commands use regular require_escalated
58 approval, without changing that symlink or sandbox configuration. No persistent
59 Lisp image, HyperDoc content, original source or baseline is changed.