application/octet-stream
•
666 B
•
20 lines
(1 (ref [1 2 3] 0))
(2 (ref [1 2 3] 1))
(3 (ref [1 2 3] 2))
(1 (ref '(1 2 3) 0))
(2 (ref '(1 2 3) 1))
(3 (ref '(1 2 3) 2))
(#nil (ref '(1 2 3) 3))
(123 (ref {:asd 123 :qwe 234} :asd))
(#nil (ref {:asd 123 :qwe 234} :asdqwe))
(32 (ref "asd " 3))
(:type-error (try car (ref '(1 2 3) -1)))
(:type-error (try car (ref "" -10)))
(:out-of-bounds (try car (ref "" 10)))
(:out-of-bounds (try car (ref [1 2 3] 10)))
(99 (ref (set! [1 2 3] 0 99) 0))
(:out-of-bounds (try car (set! [1 2 3] 10 99)))
(:type-error (try car (set! [1 2 3] -10 99)))
(:type-error (try car (set! '(1 2 3) 0 99)))
(:type-error (try car (set! '(1 2 3) 0 99)))
(:type-error (try car (set! "asd" 0 99)))