aboutsummaryrefslogtreecommitdiffstats
path: root/examples/linebreak.aup
diff options
context:
space:
mode:
authoreunhhu <[email protected]>2026-10-19 07:34:12 +0100
committereunhhu <[email protected]>2026-10-19 07:34:12 +0100
commit30eed7886769d838a5d51b70c764c532ca023b1c (patch)
tree38ae2b811d56c217bb4ebf0c843046390d207ecd /examples/linebreak.aup
parent1c3b2475ca2008b7a68e7fbd6281b59fa84a286c (diff)
downloadaup-30eed7886769d838a5d51b70c764c532ca023b1c.tar.gz
aup-30eed7886769d838a5d51b70c764c532ca023b1c.zip
140's apps written with the frictions gone: inflate's and linebreak's lists declared together, linebreak's 0x2010 and 0x25CC (their modules the same), DNS's records = [] and 0xc000, HTTP's trailers, j = fields(...), RFC 6298's abs and tick.period (G written once), layout's lists together, its boxes and root as targets together, boxes = []; lines 121 to 120, 148 to 146, 176 to 169, 116 to 110; instructions within 0.2%
Diffstat (limited to 'examples/linebreak.aup')
-rw-r--r--examples/linebreak.aup17
1 files changed, 5 insertions, 12 deletions
diff --git a/examples/linebreak.aup b/examples/linebreak.aup
index f9735c5..ed1ede3 100644
--- a/examples/linebreak.aup
+++ b/examples/linebreak.aup
@@ -59,7 +59,7 @@ fn next_unit(t, i) {
return j
}
-fn aksara(t, u) = t.eff[u] == AK || t.eff[u] == AS || t.codes[u] == 9676 # U+25CC
+fn aksara(t, u) = t.eff[u] == AK || t.eff[u] == AS || t.codes[u] == 0x25CC
fn pi(t, k) = ranges[t.at[k]].pi
fn pf(t, k) = ranges[t.at[k]].pf
fn east(t, k) = ranges[t.at[k]].east
@@ -111,7 +111,7 @@ fn decide(t, i) {
}
if A == QU && (!east(t, i) || unit == 0 || !east(t, t.start[unit - 1])) { return NONE }
if B == CB || A == CB { return ALLOWED } # LB20
- if (A == HY || base == 8208) && B == AL { # LB20a (U+2010)
+ if (A == HY || base == 0x2010) && B == AL { # LB20a
let w = if unit > 0 { t.eff[unit - 1] } else { SP }
if end(w) || w == SP || w == ZW || w == CB || w == GL { return NONE }
}
@@ -139,7 +139,7 @@ fn decide(t, i) {
if (A == AL || A == HL) && (B == AL || B == HL) { return NONE } # LB28
if A == AP && aksara(t, i) { return NONE } # LB28a
if aksara(t, unit) && (B == VF || B == VI) { return NONE }
- if A == VI && unit > 0 && aksara(t, t.start[unit - 1]) && (B == AK || t.codes[i] == 9676) { return NONE }
+ if A == VI && unit > 0 && aksara(t, t.start[unit - 1]) && (B == AK || t.codes[i] == 0x25CC) { return NONE }
if aksara(t, unit) && aksara(t, i) {
let j = next_unit(t, i)
if j < n && t.eff[j] == VF { return NONE }
@@ -153,15 +153,8 @@ fn decide(t, i) {
}
on line {
- let codes: list of number
- let cls: list of number
- let eff: list of number
- let start: list of number
- let nonspace: list of number
- let ri: list of number
- let at: list of number
- let joined: list of bool
- let numeric: list of bool
+ let codes, cls, eff, start, nonspace, ri, at: list of number
+ let joined, numeric: list of bool
for p in line.points {
let i = codes.count
let r = range(p.code)