73 lines
1.2 KiB
Plaintext
73 lines
1.2 KiB
Plaintext
(def! _macro? (fn* [x]
|
|
(if (map? x)
|
|
(contains? x :__MAL_MACRO__)
|
|
false)))
|
|
|
|
(def! core_ns
|
|
[['= =]
|
|
['throw throw]
|
|
['nil? nil?]
|
|
['true? true?]
|
|
['false? false?]
|
|
['number? number?]
|
|
['string? string?]
|
|
['symbol symbol]
|
|
['symbol? symbol?]
|
|
['keyword keyword]
|
|
['keyword? keyword?]
|
|
['fn? fn?]
|
|
['macro? _macro?]
|
|
|
|
['pr-str pr-str]
|
|
['str str]
|
|
['prn prn]
|
|
['println println]
|
|
['readline readline]
|
|
['read-string read-string]
|
|
['slurp slurp]
|
|
['< <]
|
|
['<= <=]
|
|
['> >]
|
|
['>= >=]
|
|
['+ +]
|
|
['- -]
|
|
['* *]
|
|
['/ /]
|
|
['time-ms time-ms]
|
|
|
|
['list list]
|
|
['list? list?]
|
|
['vector vector]
|
|
['vector? vector?]
|
|
['hash-map hash-map]
|
|
['map? map?]
|
|
['assoc assoc]
|
|
['dissoc dissoc]
|
|
['get get]
|
|
['contains? contains?]
|
|
['keys keys]
|
|
['vals vals]
|
|
|
|
['sequential? sequential?]
|
|
['cons cons]
|
|
['concat concat]
|
|
['vec vec]
|
|
['nth nth]
|
|
['first first]
|
|
['rest rest]
|
|
['empty? empty?]
|
|
['count count]
|
|
['apply apply]
|
|
['map map]
|
|
|
|
['conj conj]
|
|
['seq seq]
|
|
|
|
['with-meta with-meta]
|
|
['meta meta]
|
|
['atom atom]
|
|
['atom? atom?]
|
|
['deref deref]
|
|
['reset! reset!]
|
|
['swap! swap!]])
|