all repos — min @ 9b10fb86580cb0dca000c7bd5d8cf45cdf86e558

A small but practical concatenative programming language.

keys now returns an array of strings instead of symbols (as documented).
h3rald h3rald@h3rald.com
Sat, 05 Aug 2017 20:24:45 +0200
commit

9b10fb86580cb0dca000c7bd5d8cf45cdf86e558

parent

585f8bd8af2f956c97dc8bc50ac113cec5a073cc

2 files changed, 3 insertions(+), 3 deletions(-)

jump to
M core/utils.nimcore/utils.nim

@@ -96,7 +96,7 @@ proc keys*(i: In, q: MinValue): MinValue =

# Assumes q is a dictionary result = newSeq[MinValue](0).newVal(i.scope) for v in q.qVal: - result.qVal.add v.qVal[0] + result.qVal.add v.qVal[0].getString.newVal proc values*(i: In, q: MinValue): MinValue = # Assumes q is a dictionary
M tests/seq.mintests/seq.min

@@ -39,7 +39,7 @@ (((a 1)(b 2)(c 3)) ' :dict dict 5 'b dset 7 %d =newdict newdict ((a 1)(b 5)(c 3)(d 7)) == dict ((a 1)(b 2)(c 3)) == and) assert

(((a 1)(b 2)(c 3)) ' :dict dict 'b ddel =newdict newdict ((a 1)(c 3)) == dict ((a 1)(b 2)(c 3)) == and) assert - (((a 1)(b 2)(c 3)) keys (a b c) ==) assert + (((a 1)(b 2)(c 3)) keys ("a" "b" "c") ==) assert (((a 1)(b 2)(c 3)) values (1 2 3) ==) assert

@@ -66,4 +66,4 @@

((1 2 3 (4 5 6) 7 (8 9)) flatten (1 2 3 4 5 6 7 8 9) ==) assert report - clear-stack+ clear-stack