summaryrefslogtreecommitdiff
path: root/lib/array.fnl
blob: 11e4d2ae9a560d654b46591e17ce2ae6d9a5c063 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
(import-macros {: reduce} :lib.macro)

(fn concat [a b]
  (local copy
   (fn [a b]
     (reduce
      (fn [_ v c]
       (table.insert c v)
       c)
      b a)))
  (copy a b))

{: concat}