This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2016-04-17
Channels
- # admin-announcements (3)
- # beginners (15)
- # boot (5)
- # cider (25)
- # cljs-dev (9)
- # cljsjs (5)
- # clojure (30)
- # clojure-belgium (20)
- # clojure-boston (1)
- # clojure-greece (1)
- # clojure-japan (3)
- # clojure-russia (17)
- # clojure-uk (2)
- # clojurescript (49)
- # clojurewerkz (2)
- # cursive (5)
- # datomic (1)
- # emacs (1)
- # euroclojure (1)
- # hoplon (155)
- # jobs-discuss (17)
- # mount (6)
- # off-topic (1)
- # om (87)
- # proton (2)
- # re-frame (3)
- # remote-jobs (4)
- # spacemacs (2)
- # untangled (12)
@urbanslug: try (prn "ClojureScript is" 5 "years old.")
vs. (println "ClojureScript is" 5 "years old.")
.
mfikes: playing with migrating from lein to boot so really can’t get a repl but I assume the first fails.
@urbanslug: (You should be able to type lein repl
in a directory without a project.clj
whenever you want a REPL.)
@urbanslug: I'd also recommend doing doc
on each; you'll gain insight into the rationale for each. :)
@urbanslug: No problem. That's a perceptive question for someone new to this. :)
So, I thought I understood how destructuring works, but then I ran across this (http://stackoverflow.com/questions/3208347/how-to-create-default-value-for-function-argument-in-clojure) question. I tried running Matthew Gilliard's answer:
(defn string->integer [s & {:keys [base] :or {base 10}}]
(Integer/parseInt s base))
string->integer "18F" 16
I get IllegalArgumentException No value supplied for key: 16 clojure.lang.PersistentHashMap.create (PersistentHashMap.java:77)
.