js-on-sx: TypeError-on-not-callable uses type-of, not (str fn-val)
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 56s
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 56s
Formatting wrapper dicts with (str fn-val) recursively walks the proto chain through SX inspect — for String/Number wrappers whose prototype contains lambdas this hangs. Switched the message to (type-of fn-val), e.g. "dict is not a function". Less specific but always terminates. built-ins/String: 73/99 → 75/99 (canonical). conformance.sh: 148/148.
This commit is contained in:
@@ -430,7 +430,7 @@
|
||||
(raise
|
||||
(js-new-call
|
||||
TypeError
|
||||
(list (str (str fn-val) " is not a function"))))
|
||||
(list (str (type-of fn-val) " is not a function"))))
|
||||
(cond
|
||||
((= (len args) 0) (callable))
|
||||
((= (len args) 1) (callable (nth args 0)))
|
||||
|
||||
Reference in New Issue
Block a user