js-on-sx: arr.length = N extends the array
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 41s
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 41s
js-list-set! was a no-op for the length key. Added a clause that pads with js-undefined via js-pad-list! when target > current. Truncation skipped: the pop-last! SX primitive doesn't actually mutate the list (length unchanged after the call), so no clean way to shrink in place from SX. Extension covers common cases. built-ins/Array: 16/45 → 17/45. conformance.sh: 148/148.
This commit is contained in:
@@ -2800,7 +2800,13 @@
|
||||
(else (do (js-pad-list! lst n i) (append! lst val))))))
|
||||
((and (= (type-of key) "string") (js-is-numeric-string? key))
|
||||
(js-list-set! lst (js-string-to-number key) val))
|
||||
((= key "length") nil)
|
||||
((= key "length")
|
||||
(let
|
||||
((target (js-num-to-int (js-to-number val))) (n (len lst)))
|
||||
(cond
|
||||
((< target 0) nil)
|
||||
((> target n) (js-pad-list! lst n target))
|
||||
(else nil))))
|
||||
(else nil))))
|
||||
(define
|
||||
js-pad-list!
|
||||
|
||||
@@ -1,30 +1,42 @@
|
||||
{
|
||||
"totals": {
|
||||
"pass": 43,
|
||||
"fail": 4,
|
||||
"skip": 0,
|
||||
"timeout": 3,
|
||||
"pass": 17,
|
||||
"fail": 21,
|
||||
"skip": 5,
|
||||
"timeout": 7,
|
||||
"total": 50,
|
||||
"runnable": 50,
|
||||
"pass_rate": 86.0
|
||||
"runnable": 45,
|
||||
"pass_rate": 37.8
|
||||
},
|
||||
"categories": [
|
||||
{
|
||||
"category": "built-ins/Number",
|
||||
"category": "built-ins/Array",
|
||||
"total": 50,
|
||||
"pass": 43,
|
||||
"fail": 4,
|
||||
"skip": 0,
|
||||
"timeout": 3,
|
||||
"pass_rate": 86.0,
|
||||
"pass": 17,
|
||||
"fail": 21,
|
||||
"skip": 5,
|
||||
"timeout": 7,
|
||||
"pass_rate": 37.8,
|
||||
"top_failures": [
|
||||
[
|
||||
"Test262Error (assertion failed)",
|
||||
4
|
||||
16
|
||||
],
|
||||
[
|
||||
"Timeout",
|
||||
3
|
||||
7
|
||||
],
|
||||
[
|
||||
"TypeError: not a function",
|
||||
2
|
||||
],
|
||||
[
|
||||
"ReferenceError (undefined symbol)",
|
||||
2
|
||||
],
|
||||
[
|
||||
"Unhandled: Not callable: {:2 43 :1 42 :0 41 :length 3}\\",
|
||||
1
|
||||
]
|
||||
]
|
||||
}
|
||||
@@ -32,14 +44,26 @@
|
||||
"top_failure_modes": [
|
||||
[
|
||||
"Test262Error (assertion failed)",
|
||||
4
|
||||
16
|
||||
],
|
||||
[
|
||||
"Timeout",
|
||||
3
|
||||
7
|
||||
],
|
||||
[
|
||||
"TypeError: not a function",
|
||||
2
|
||||
],
|
||||
[
|
||||
"ReferenceError (undefined symbol)",
|
||||
2
|
||||
],
|
||||
[
|
||||
"Unhandled: Not callable: {:2 43 :1 42 :0 41 :length 3}\\",
|
||||
1
|
||||
]
|
||||
],
|
||||
"pinned_commit": "d5e73fc8d2c663554fb72e2380a8c2bc1a318a33",
|
||||
"elapsed_seconds": 71.8,
|
||||
"elapsed_seconds": 151.1,
|
||||
"workers": 1
|
||||
}
|
||||
@@ -1,24 +1,30 @@
|
||||
# test262 scoreboard
|
||||
|
||||
Pinned commit: `d5e73fc8d2c663554fb72e2380a8c2bc1a318a33`
|
||||
Wall time: 71.8s
|
||||
Wall time: 151.1s
|
||||
|
||||
**Total:** 43/50 runnable passed (86.0%). Raw: pass=43 fail=4 skip=0 timeout=3 total=50.
|
||||
**Total:** 17/45 runnable passed (37.8%). Raw: pass=17 fail=21 skip=5 timeout=7 total=50.
|
||||
|
||||
## Top failure modes
|
||||
|
||||
- **4x** Test262Error (assertion failed)
|
||||
- **3x** Timeout
|
||||
- **16x** Test262Error (assertion failed)
|
||||
- **7x** Timeout
|
||||
- **2x** TypeError: not a function
|
||||
- **2x** ReferenceError (undefined symbol)
|
||||
- **1x** Unhandled: Not callable: {:2 43 :1 42 :0 41 :length 3}\
|
||||
|
||||
## Categories (worst pass-rate first, min 10 runnable)
|
||||
|
||||
| Category | Pass | Fail | Skip | Timeout | Total | Pass % |
|
||||
|---|---:|---:|---:|---:|---:|---:|
|
||||
| built-ins/Number | 43 | 4 | 0 | 3 | 50 | 86.0% |
|
||||
| built-ins/Array | 17 | 21 | 5 | 7 | 50 | 37.8% |
|
||||
|
||||
## Per-category top failures (min 10 runnable, worst first)
|
||||
|
||||
### built-ins/Number (43/50 — 86.0%)
|
||||
### built-ins/Array (17/45 — 37.8%)
|
||||
|
||||
- **4x** Test262Error (assertion failed)
|
||||
- **3x** Timeout
|
||||
- **16x** Test262Error (assertion failed)
|
||||
- **7x** Timeout
|
||||
- **2x** TypeError: not a function
|
||||
- **2x** ReferenceError (undefined symbol)
|
||||
- **1x** Unhandled: Not callable: {:2 43 :1 42 :0 41 :length 3}\
|
||||
|
||||
Reference in New Issue
Block a user