Artifact 1b1d0ce11eacf49ddf385fb38b0c5d062a9700104a6c460ee6467b124e7c69c7:
- File typeparse/tests_tclsh/t86_codec_c_liens.out — part of check-in [289eebd31b] at 2026-11-06 11:24:44 on branch tip-764_tcl90 — Complete revision of "sums" (sum types). A distinction is now made between two clearly separate categories: "unions," where the specific variant can be reliably inferred from the structure of the data string, and "sums," where the structure of the data string is insufficient to definitively determine the variant. A new syntax for unions has been introduced, now utilizing the `|` symbol. E.g.: `type def matrix {{list(3).list(3)}matrice3x3 | {list(2).list(2)}matrix2x2}` Any ambiguous union will be rejected during construction, triggering an error message. "Sums" now function like "tagged unions" in C—that is, they consist of a union paired with a tag. Consequently, one must reference the tag to identify the specific variant. Sums are always written using commas (`,`). E.g.: `type def Temperature {{double}celsius, {double}farenheit}` (user: Florentis, size: 1027) [annotate] [blame] [check-ins using]
// 7 octets C=Tcl 1 relu C=Tcl 1 relu=v 1 07050000000102 // nat 10 octets C=Tcl 1 relu C=Tcl 1 relu=v 1 07000000080000000102 ./ 7 octets C=Tcl 1 relu C=Tcl 1 relu=v 1 09030505060708 ./ lu C=Tcl 1 9 {0 1} {2 3} . 4 octets C=Tcl 1 relu C=Tcl 1 relu=v 1 00010708 ../ C=Tcl 1 0 {0 {10 11}} ../ écrit 5 octets C=Tcl 1 relu C=Tcl 1 relu=v 1 0000030a0b liste 7 octets C=Tcl 1 relu C=Tcl 1 relu=v 1 02030501020304 taille après 9 octets C=Tcl 1 relu C=Tcl 1 relu=v 1 030003010203040506 chaînée C=Tcl 1 1 {some {2 {some {3 none}}}} chaînée écrite 6 octets C=Tcl 1 relu C=Tcl 1 relu=v 1 010202040300 signé C=Tcl 1 1 5 6 {5 6} at + lien 4 octets C=Tcl 1 relu C=Tcl 1 relu=v 1 04020909 lien nul à défaut : 1 {0 0} 0300 -linkdepth 0 : 5 &*(//,int(u,32,le)).rec cycle : 1 type binary: link cycle at offset 0 (field s of boucle) dedupe : 09030505060708 chaîne de 300 : 1 1