1
0
mirror of https://github.com/janet-lang/janet synced 2025-11-05 01:53:01 +00:00

Fix bug in pretty printing.

This commit is contained in:
Calvin Rose
2018-11-30 11:46:05 -05:00
parent f8ab60f487
commit 523d909cca
2 changed files with 4 additions and 4 deletions

View File

@@ -891,7 +891,7 @@ value, one key will be ignored."
[xs]
(flatten-into @[] xs))
(defn dict-seq
(defn kvs
"Takes a table or struct and returns and array of key value pairs
like @[k v k v ...]. Returns a new array."
[dict]
@@ -1408,6 +1408,6 @@ value, one key will be ignored."
(some uqs? x) (tuple tuple.slice (tuple.prepend (map uqs x) array.concat))
(apply tuple tuple (map qq x)))
:array (apply array (map qq x))
:struct (apply struct (map qq (dict-seq x)))
:table (apply table (map qq (dict-seq x)))
:struct (apply struct (map qq (kvs x)))
:table (apply table (map qq (kvs x)))
x))