hello Lutz,
further stress testing newLisp: is this a bug or a feature (possibly for efficiency reasons)?
This leads to an endless loop:
Code: Select all
newLISP v.10.5.3 64-bit on Linux IPv4/6 UTF-8, options: newlisp -h
>
(context 'Ctx)
(context MAIN)
(context? Ctx)
(context 'Ctx2)
(context MAIN)
;;
(set 'Ctx:sub Ctx2)
;;
(push '("foo" "bar") Ctx:sub)
;;
;; not OK:
(delete 'Ctx2)
(assoc "foo" Ctx:sub) ; -> endless loop
;; copy/paste until here ;;
Ctx
MAIN
true
Ctx2
MAIN
Ctx2
(("foo" "bar"))
true
^CERR: received SIGINT - in function assoc
(c)ontinue, (d)ebug, e(x)it, (r)eset:x
Code: Select all
newLISP v.10.5.3 64-bit on Linux IPv4/6 UTF-8, options: newlisp -h
>
(context 'Ctx)
(context MAIN)
(context? Ctx)
(context 'Ctx2)
(context MAIN)
;;
(set 'Ctx:sub Ctx2)
;;
(push '("foo" "bar") Ctx:sub)
;;
;; OK:
(delete 'Ctx2)
(delete 'Ctx2)
(assoc "foo" Ctx:sub) ; -> expected error message
;; copy/paste until here ;;
Ctx
MAIN
true
Ctx2
MAIN
Ctx2
(("foo" "bar"))
true
true
ERR: list expected in function assoc : nil
>
Best regards,
Stephan