Generally, changed working with tags as strings to as values.

This seems both cheaper and safer; what's not to like?
This commit is contained in:
Simon Brooke 2021-08-17 16:09:00 +01:00
parent eadb125b83
commit 93d4bd14a0
No known key found for this signature in database
GPG key ID: A7A4F18D1D4DF987
17 changed files with 87 additions and 88 deletions

View file

@ -1,6 +1,6 @@
#!/bin/bash
expected='(lambda (l) l) (1 2 3 4 5 6 7 8 9 10)'
expected='<Anonymous Function: (λ (l) l)> (1 2 3 4 5 6 7 8 9 10)'
output=`target/psse 2>/dev/null <<EOF
(set! list (lambda (l) l))
(list '(1 2 3 4 5 6 7 8 9 10))

View file

@ -16,7 +16,7 @@ fi
#####################################################################
# Create an empty map using make-map
expected='{}'
actual=`echo "(make-map)" | target/psse | tail -1`
actual=`echo "(hashmap)" | target/psse | tail -1`
echo -n "Empty map using (make-map): "
if [ "${expected}" = "${actual}" ]
@ -31,7 +31,7 @@ fi
# Create a map using map notation: order of keys in output is not
# significant at this stage, but in the long term should be sorted
# alphanumerically
expected='{:two 2, :one 1, :three 3}'
expected='{:one 1, :two 2, :three 3}'
actual=`echo "{:one 1 :two 2 :three 3}" | target/psse | tail -1`
echo -n "Map using map notation: "
@ -47,10 +47,10 @@ fi
# Create a map using make-map: order of keys in output is not
# significant at this stage, but in the long term should be sorted
# alphanumerically
expected='{:two 2, :one 1, :three 3}'
actual=`echo "(make-map '((:one . 1)(:two . 2)(:three . 3)))" | target/psse | tail -1`
expected='{:one 1, :two 2, :three 3}'
actual=`echo "(hashmap nil nil '((:one . 1)(:two . 2)(:three . 3)))" | target/psse | tail -1`
echo -n "Map using (make-map): "
echo -n "Map using (hashmap): "
if [ "${expected}" = "${actual}" ]
then
echo "OK"