Verifies: SYS-REQ-014 [formal]
(t *testing.T)
| 266 | |
| 267 | // Verifies: SYS-REQ-014 [formal] |
| 268 | func TestRemoval3_MathematicalProof(t *testing.T) { |
| 269 | // Mathematical proof: decodeSingleUnicodeEscape computes |
| 270 | // h1<<12 + h2<<8 + h3<<4 + h4 |
| 271 | // where h1..h4 are in [0, 15]. |
| 272 | // Maximum: 15<<12 + 15<<8 + 15<<4 + 15 = 61440 + 3840 + 240 + 15 = 65535 = 0xFFFF |
| 273 | // This equals basicMultilingualPlaneOffset exactly. |
| 274 | // Therefore r <= basicMultilingualPlaneOffset is ALWAYS true. |
| 275 | maxR := rune(15<<12 + 15<<8 + 15<<4 + 15) |
| 276 | if maxR != basicMultilingualPlaneOffset { |
| 277 | t.Fatalf("max possible rune 0x%X != basicMultilingualPlaneOffset 0x%X", maxR, basicMultilingualPlaneOffset) |
| 278 | } |
| 279 | t.Logf("PROVEN: max rune from \\uXXXX = 0x%X = basicMultilingualPlaneOffset", maxR) |
| 280 | } |
| 281 | |
| 282 | // ============================================================================= |
| 283 | // REMOVAL 4: `data[i] == '{'` block removed in EachKey |
nothing calls this directly
no outgoing calls
no test coverage detected