#clojure logs

2015-09-13

00:19Trioxinlol @ this first paragraph http://www.braveclojure.com/java/
00:20Trioxinso, we've got to deal with the spear chuckers
00:21Trioxinbtw does clojurescript just run in the browser after including a js library or something?
00:22justin_smithit's js
00:22Trioxinoh
00:22justin_smithclojure compiles to jvm byte code, cljs compile to js
00:22Trioxinoooooooh
00:28Trioxinand so I'm guessing while you're coding clojurescript you can use any js lib then
00:28Trioxinobviously but do you have to compile it first?
00:28Trioxinto test/debug or is it like how I'm testing Clojure right now in IDEA
00:28justin_smithTrioxin: you need to compile the cljs in order for the browser to use it, and yeah, the js interop is as easy as clojure java interop is
00:29justin_smithTrioxin: there's a nice setup called figwheel that auto-recompiles as you save files and pushes the new code into the browser
00:29justin_smithit's really sweet actually
00:29Trioxini've worked with things like that for node-webkit and cordova so I can imagine it. all in good time. thx
00:30justin_smithit also gives you an interactive repl, which is like the javascript console, but for cljs
00:30Trioxincan you use regular js in the repl?
00:30justin_smithno, but you can in the browser console of course
00:31justin_smithbut interop is easy enough
00:31Trioxink
00:32Trioxinone more thing, what are the benefits? programming paradigms and more libs, maybe speed too? cause I already know js
00:34Trioxini've read a few people comment on why they like it
00:35Trioxini guess this pretty much covers it http://www.quora.com/Why-ClojureScript
00:35kavkazI find myself using partial a lot when using the thread macro (->)
00:36kavkazIs this normal? It's my first time using that macro so I'm not sure I'm doing it right
00:36Trioxinseems like Quora got popular out of nowhere doesn't it?
00:36gcommerkavkaz, could you give an example of how you're using it?
00:37justin_smithkavkaz: if you are using -> and partial, you should probably be using ->> instead
00:37kavkazI do this because if the next form is something like (map f), since -> inserts the last form as the second item in the next expression, I use partial so the form becomes ((map f))
00:37kavkazsorry
00:37kavkaz((partial map f))
00:37gcommerI thought so
00:37justin_smith,(-> [1 2 3] (->> (map inc)))
00:37clojurebot(2 3 4)
00:38justin_smithkavkaz: that's only if you need to mix positions, if you don't, just use ->> in the first place
00:38kavkazhaha, these macros take some time getting used to
00:38justin_smith,(->> [1 2 3] (map inc))
00:38clojurebot(2 3 4)
00:38kavkazjustin_smith: Ah I see
00:39gcommerThis library is cool: https://github.com/rplevy/swiss-arrows
00:39kavkazI see (:
00:39kavkazyeah ->> made my life easier just now
00:40kavkazAh that's pretty cool gcommer
00:40kavkazI think however, that using such a library is pretty much using a new language now
00:40Trioxineh, IDEA doesn't even want me to write my lisp like C and I'm really wanting to nest things similarly
00:41kavkazbecause now you're introducing syntax into your code that will be unfamiliar to any Clojure programmer unaware of that library
00:42gcommerThe same is true for any library.. I typically only use the basic -<> and -<>> anyways because they're so similar to the normal ->/->>
00:43Trioxinwhat's the difference between a macro and member macro was it? I remember that clojure cannot create them for some unknown reason
00:46gcommerTrioxin, I've never heard of a "member macro" and don't see the term used anywhere..
00:47Trioxinreader macros. sorry
00:47Trioxinlet's you create new syntax or something?
00:48gcommergoogle is awesome: https://gist.github.com/chaitanyagupta/9324402
00:49Trioxini suppose I'm more curious as to why it seems so important to Lisp but isn't in Clojure
00:50gcommerI think tagged literals can do the same thing, sortakinda
00:50gcommerer no
00:52awwaiidTrioxin: I'm not completely sure, but I think avoiding reader macros keeps more consistency; it encourages fancy things to be defined in the language instead of per-project
00:53Trioxinif I pay the creator of Clojure will he add it?
00:53awwaiidmaybe :)
00:53Trioxinlol
00:54awwaiidif it is something that would make the language better, and the trade-offs are in its favor, then I bet patches are welcome
00:54Trioxinsome day my new friends, I'll bring you the gift
00:55awwaiidthe most recent version introduced the first reader-macro-like-thing, which lets you put in clojure and clojurescript in the same file
00:55gcommeryou mean reader conditionals
00:57Trioxinlike if I wanted to create my own programming language though I see some example of that http://gigasquidsoftware.com/blog/2013/05/01/growing-a-language-with-clojure-and-instaparse/
00:57Trioxinso maybe I'm missing the point of it a bit as I haven't read all that other article yet
00:58gcommerSo one issue with including reader macros is that they would almost certainly break (or need significant rejiggering of) clojure namespacing/:require'ing
01:00awwaiidyeah, reader conditionals. it's confusing that the docs talk about reader macros though they don't seem to be user-defined-reader-macros at all. (looking at http://clojure.org/reader)
01:00gcommeryep
01:01justin_smithawwaiid: if you make a file named readers.clj you can define your own
01:01justin_smithjust has to be on the classpath
01:01gcommerit's a shame clojure syntax isn't strictly EDN
01:01justin_smithwhen you run defrecord it creates reader macros for you
01:02Trioxinhmm
01:02gcommeryou mean data_readers.clj?
01:02gcommeror something different
01:02justin_smithyeah
01:03justin_smithsorry, I had the name wrong
01:03gcommerk just wanted to make sure I found the right doc
01:03justin_smithbut that's more limited than cl reader macros, iirc
01:03TrioxinI got excited reading that CL has some java interop but then further down the page read why it isn't nearly the same
01:04Trioxinhttps://www.reddit.com/r/lisp/comments/2um8qh/picolisp_java_interoperability_why_bother_with/
01:05awwaiidinteresting
01:06awwaiidI guess these make sense to be called macros as I think of it. So like @foo is (deref foo). There is no expanded form of just "7".
01:06awwaiid(just thinking out loud)
01:07gcommerThe docs for *data-readers* makes it seem like all data_readers.clj on the classpath are globally loaded.. does this mean they bypass typical namespacing? Like I can use them just by having a library on the classpath, regardless of require'ing them?
01:08justin_smithgcommer: yes
01:08justin_smiththey are not namespaced
01:09justin_smithas the name hints, they should be used for constructing data literals
01:10Trioxindoes EVERYONE close their functions and whatnot on the same line as the other ) or do some people nest as in C? isn't it more of a preference? It just seems like it would be more readable.
01:11justin_smithTrioxin: code that is bad and weird puts braces on their own line.
01:11justin_smithcode that is by normal reasonably intelligent people has braces on the same line
01:12justin_smithTrioxin: it's a convention, the conventional thing is the more readable thing.
01:12Trioxinthat isn't true of C style
01:12justin_smithTrioxin: OK, this isn't C
01:12awwaiidTrioxin: seems to be pretty universal in the lispses
01:12Trioxinj
01:12Trioxink***
01:12awwaiidI resisted at first, but have succumb, and find that when I have two many of those icky closing things it is a strong hint that I should break my function up
01:13justin_smithTrioxin: if you go to England, drive on the left side of the road, if you write in a lisp, don't leave dangling braces on their own line
01:13awwaiidyeah
01:13Trioxinheh
01:13Trioxinthey hate me over there
01:17Trioxinjust as a lisp has been made for java, I will make one for PHP to facepalm the world
01:18Trioxinhah it's already been done
01:20Trioxinman there are so many lisps
01:20awwaiidTrioxin: here is some random code from the 80's -- no dangling parens. Long history. https://hanshuebner.github.io/lmman/fd-flo.xml#list-and-tree-section
01:20Trioxinthis seems like the logical choice though for now having java behind it
01:21justin_smithTrioxin: a reasonably intelligent and determined programmer can make a lisp in a weekend or two
01:21awwaiidon purpose or on accident even :)
01:21justin_smithespecially if gc is already provided by the platform
01:23gcommerI can rest easy knowing that clojure throws an exception if there are conflicing tags in different data_readers.clj (rather than some arbitrary precedence scheme)
01:23Trioxinwell I like what i see so far. Lisp is on my roadmap to more capable and efficient AI programming and clojure has a lot at its disposal. I just watched a video of a girl who wrote a few lines and was controlling a robot
01:23justin_smithgcommer: oh, nice
01:24gcommeryeah, the data_readers implementation is nicely at the very end of clojure.core and is super simple
01:25Trioxinalso facial recognition she was doing was easy
01:27Trioxinhttps://github.com/gigasquid
01:34Trioxinyou guys should make a Slack room and link it to here
01:34justin_smithTrioxin: clojurians
01:34justin_smithTrioxin: it's very active
01:35Trioxino
01:35Trioxinthere's an IRC bridge
01:35TrioxinI run one in #Xamarin
01:35justin_smithI don't use slack when I'm not at work though :P
01:35Trioxingoes both ways
01:36justin_smithI am not at work when I'm not signed into slack?
01:36Trioxinno i meant the bridge goes both ways
01:37TrioxinChatRelay is the slack bot on freenode. I op #xamarin
01:41Trioxinoh cs uses react
01:42Trioxinand is faster lol
02:03Trioxinwell I see one familiar thing so far, lists
02:04Trioxinimmutable
06:42visofhi guys
06:43visofcan i do this lazy thing in clojure if i have struct called person, (struct person (rest (iterate foo p1) x (rest (iterate bar p2)))) ?
06:43visoffoo and bar are methods should be applied to p1 and p2
06:43visofhow can i do this in lazy way in clojure?
07:28visofanybody here?
07:28mungojellyvisof: yeah
07:28mungojellybut i don't know the answer to your question, sorry
07:29visofis it that hard?
07:29mungojellyno i just don't know anything
07:29visofokay thanks man
07:30mungojellythe "lazy thing" in clojure is made out of sequences, right? are there other lazy things?
07:30visofi don't know
07:32mungojellygoogle says there's something called lazy-seq but i haven't tried it yet
07:32mungojellythere are some helpful people here often but i think they're probably asleep now
07:33visofyeah
07:33mungojellyi'm watching "The Language of the System" by Rich Hickey, it's brilliant, very sensible
07:33Bronsavisof: structs have been deprecated of years
07:34Empperimungojelly: most of the talks given by Hickey are
07:34mungojellyok yay so now i know that there's something called structs and that i shouldn't use them, good good, building knowledge, i guess :)
07:37visofBronsa: so what is the alternative to do this in clojure?
07:37visofBronsa: i want to define my type which will consist of two infinte lists and one element
07:37Bronsarecords
07:48mungojellyso what i'm thinking for my tile-toybox is like {:grid {[1 3] :a} :tiles {:a {:ascii-1x1 "a" :ascii-3x3 "****a****"}}} does that make sense
09:19visofhi guys
09:20visofif i have list of lists with this ((true false false) (false false true) (false false false)) and want to print each list like this: f f t\nf f t\n f f f
09:20visofin the terminal
09:20visofhow can i do this?
09:25visofdone
10:32lodin_visof: Using records is often good, if not to give things names, but you can also make do with just a map for a lot of things.
11:41timothywHey all
11:41timothywI'm trying to control an infinite sequence display in my “lein repl”
11:41timothyw(lein 2.5.2 on (Java 1.8.0_45) / nREPL (Clojure 1.7.0, REPL-y 0.3.7, nREPL 0.2.10))
11:41timothywcider repl can truncate the below, but lein's repl hangs
11:41timothyw(repeatedly (fn [] (rand 35))) ;; hangs in lein repl
11:41timothyw(iterate inc 0) ;; also hangs in lein repl
11:42timothywAnd neither (set! *print-length* 103) nor (set! *print-level* 15) help with this lein repl (http://blog.n01se.net/blog-n01se-net-p-85.html)
11:42timothywAny ideas?
11:47kwladyka_timothyw, cider works with that? it is infinite, it shouldnt
11:47timothywcider’s repl elide’s bother expressions, out of the box
11:48kwladykaonly one way what i know is to use take
11:48timothyw… without the *print-length* or *print-level* settings
11:48kwladyka(take 10 (inifite-lazy-loop))
11:48kwladykai am doing like that
11:49timothywhmm… I’m digging into cider’s source to see if there’s something special it does
12:03noogahttps://www.reddit.com/r/Clojure/comments/3ksasg/is_there_lisplookalike_overlay_for_clojure/
12:03noogawow
12:13lodin_nooga: wow indeed.
12:48expezYeah, the responses are shameful. Glad at least one guy took a stand.
12:48expezI think his request is pretty unreasonable too, but there's no need to shit on the guy like that :/
12:53brunotimothyw: you need to add *print-length* in your .lein/profiles.clj check this out https://github.com/clojure-emacs/cider#limiting-printed-output-in-the-repl
12:54brunoonce added in your profiles.clj will be available for all REPL sessions
13:42mungojelly obviously i'm saying this wrong (defn put-a-in-world [w x y] (update w :grid #(put-a-in-grid % x y))) how do i mean to put things through rather than that ugly inner anonymous function? :/
13:42justin_smithmungojelly: (update w :grind put-in-grid x y)
13:43justin_smitherr s/grind/grid of course
13:43justin_smith,(update 1 + 2)
13:43clojurebot#error {\n :cause "java.lang.Long cannot be cast to clojure.lang.IFn"\n :via\n [{:type java.lang.ClassCastException\n :message "java.lang.Long cannot be cast to clojure.lang.IFn"\n :at [clojure.core$update invokeStatic "core.clj" 5936]}]\n :trace\n [[clojure.core$update invokeStatic "core.clj" 5936]\n [clojure.core$update invoke "core.clj" -1]\n [sandbox$eval25 invokeStatic "NO_SOURCE_FILE" ...
13:43justin_smithoh wait
13:43justin_smith,(update [1] 0 + 2)
13:43clojurebot[3]
13:44mungojellyoh i was wondering wtf [m k f x y z & more] meant in the update docs
13:44justin_smithit gets even more fun when you mix swap! and update
13:44justin_smith,(def a (atom [1]))
13:44clojurebot#'sandbox/a
13:45justin_smith,(swap! a update 0 + 41)
13:45clojurebot[42]
13:45justin_smithalmost like forth or something
13:45mungojellyclojure is too convenient, your program just flows out of your hands like sand, then there's just a few golden words left and you're confused whether or not you wrote anything
13:46justin_smithhaha
13:46mungojellyis there any 2d grid access, like should i write my own subsectioning
13:46justin_smithif you use the naiive approach (vector of vectors) just use (get-in field [x y])
13:47justin_smithor (update-in field [x y] op)
13:47mungojellyum no sorry that's useful thanks but actually what i have is {[0 0] :a} means an :a at 0,0 and there's just entries for the filled spaces
13:48justin_smithwell, that's just simple get rather than get-in
13:48mungojellybut i'd happily rearrange if there's a different idiom than that for an infinite space like that
13:49mungojellybut like i'm going to want to say, give me everything from [0 0] to [10 10]
13:49justin_smithmungojelly: no, that representation, plus get / update, seems like it would work just fine
13:49justin_smithoh
13:49mungojellywhich should give a vector of vectors that looks like [[:a nil nil nil nil...
13:49justin_smiththen make sure it's a sorted-map and not just a map I guess...
13:49lodin_mungojelly: I will have to quote you now. :-)
13:49mungojellylodin_: what? what did i say?
13:50lodin_mungojelly: "a few golden words", I will call it. :-)
13:50mungojellyi haven't actually used a sorted-map yet. that'd be fun to put enough tiles to have to worry about it being performant!
13:53mungojellyok so maps and sorted-maps both look like {key val key val} and respond to the same interface and everything it's just you get different performance depending on which you ask for?
13:54justin_smithmungojelly: it's that if you are looking for all entries within some range, with a sorted map they are already sort of in order so faster to find all of them
13:54mungojellyhow do i time things in a repl so i can feel the difference
13:55justin_smithas opposed to a map, where you would always need to walk the entire map to find out what is inside a given rectangle
13:56justin_smithfirst, you need to use an algorithm that actually uses the sorted-map's special properties to its advantage, then you can use criterium.core/bench for real results, or clojure.core/time for tea leaves
13:56lodin_haha
14:06mungojellyyeah ok i see, clojure.core/time just gives you the raw timing of one execution of something without warming the JIT or anything, i guess i'll learn criterium then :)
14:08justin_smithit's pretty simple to use, there's bench and quick-bench, I put it in my profiles.clj so it's always available
14:08justin_smith(half the time because someone asks "which of these is faster"? and I'm curious)
14:10mungojellyi don't know what profiles.clj is, is that something lein looks for?
14:11justin_smithmungojelly: every project.clj is merged with ~/.lein/profiles.clj
14:12justin_smithso you can use that file for dependencies that you want available at dev time regardless of project
14:12justin_smith(or other user local but not project specific settings)
14:12mungojellyok great, thanks! lein is very slick and magical
14:47PupenoI need to temporarily switch to another namespace, I was using in-ns, but with that I lose access to Clojure's core, what should I use instead?
14:47justin_smithPupeno: in-ns creates a namespace but does not initialize it properly
14:48lodin_Pupeno: Just (ns foo)?
14:48justin_smithPupeno: ns creates an ns
14:48justin_smith(and also initializes)
14:49justin_smithalso if you are stuck in an uninitialized namespace created by in-ns, you can fix it with (clojure.core/refer-clojure)
14:51Pupenolodin_: I don't think I can just use ns in my case: https://github.com/luminus-framework/conman/blob/master/src/conman/core.clj#L12-L24
14:52Pupenojustin_smith: good to know.
14:52justin_smithPupeno: if you can't use ns, you can invoke clojure.core/refer-clojure in the new ns. But creating namespaces inside runtime code is suspicious to me
14:52PupenoIt seems when I return to the original namespace I lose the original requires and I have to do them again.
14:53justin_smithPupeno: also, the create-ns call is redundant, in-ns already does that
14:54justin_smithPupeno: is it a question of losing the require, or just a question of the clojure compiler throwing an error when compiling code that will use a function not-yet-required as of compile time? I think the latter is much more likely.
14:56mungojellyi just need to read a bunch of code to soak up idioms. any suggestions what i should read?
14:57justin_smithmungojelly: flatland/useful is a good lib
15:00PupenoI'm having both problems now.
15:09mungojellywhat is this character soup? (defn compare-bytes [^"[B" a ^"[B" b]
15:10justin_smithmungojelly: ^"[B" is a type hint for an java array of bytes
15:10justin_smithso it's saying "two args, a and b, and both are byte-arrays"
15:10justin_smithI think ^bytes would work there
15:11justin_smith(but maybe the author did not know that, or that annotation was not available when the code was written)
15:11mungojellyif i can't figure out what it means i'll just stew it up with carrots and tildes for lunch. oh ok thanks i guess! wait what? what is ^"[B]" is that a weird word or ^ + ""
15:11justin_smithmungojelly: ^ means add metadata
15:11justin_smithit often is used to indicate a type
15:11justin_smith"[B" means "byte-array"
15:11mungojellyi've gotten a vague sense everything has metadata somewhere which seems awesome
15:12justin_smithso ^"[B" means "add a metadata indicating that this thing is a byte array"
15:13rhg135Most things do
15:13mungojellyevery {} has metadata :o and it doesn't affect the value for comparisons :o omg
15:14justin_smithmungojelly: any native clojure data type (and additionally, any other type that has the clojure.lang.IMeta interface implemented properly) can carry metadata
15:14justin_smithmungojelly: in practice that means, functions, vars, vectors, maps, hash-maps all carry metadata
15:15mungojellythat's fantastic
15:15justin_smithbut not eg. numbers, strings, arrays
15:16lodin_or classes/types.
15:17rhg135Keywords don't ofc, since they couldn't be identical with differing metadata iirc
15:17gfredericksmetadata is 95% about either communicating with the compiler or stashing away info about vars for fancy metaprogramming purposes
15:18gfredericksrhg135: yep
15:18rhg135But symbols do
15:18justin_smith,^:OK 'OK
15:18clojurebotOK
15:18gfredericks,(meta ^:OK 'OK)
15:18clojurebotnil
15:18mungojellybecause otherwise you'd have to say all over the place, do these two annotated thingies have the same underlying base, and you'd have to tear them apart all the time to compare their fronts
15:18justin_smiththat one is wrong because of the quote form, yeah
15:19gfredericks,(meta '^:OK OK)
15:19clojurebot{:OK true}
15:19justin_smith(inc gfredericks)
15:19justin_smiththat's the trick
15:20justin_smith,(= '^:OK OK '^:this-works OK)
15:20clojurebottrue
15:31borkdudeI am using wrap-reload so I can interactively develop a ring application. But I am losing my session (in memory) also. Any way around that?
15:32justin_smithborkdude: use a defonce to define your session store?
15:32borkdudejustin_smith I'm using the default session store from ring
15:32justin_smithyou can provide a store as an optional arg to the middleware
15:32justin_smithit's just an atom
15:32justin_smithuse defonce
15:32borkdudejustin_smith cool, thanks
15:32borkdudeI love "just atoms"
15:32justin_smith:)
15:34justin_smithborkdude: https://github.com/ring-clojure/ring/blob/master/ring-core/src/ring/middleware/session.clj#L16 this is the optional arg
15:34borkdudethanks
15:34justin_smithwith the source of memory-store showing what I meant https://github.com/ring-clojure/ring/blob/master/ring-core/src/ring/middleware/session/memory.clj#L20
15:39borkdudejustin_smith works like a charm
15:40justin_smithawesome
15:49wasamasawhat kind of data type is a clojure vector exactly?
15:49justin_smith,(type [])
15:49wasamasais it a growable array that does extend itself once it's needed or more than that?
15:49clojurebotclojure.lang.PersistentVector
15:50justin_smithwasamasa: persistent hashed trie - check out hyPiRion 's blog series on the implementation!
15:50justin_smithwasamasa: http://hypirion.com/musings/understanding-persistent-vector-pt-1
15:50wasamasajustin_smith: thanks!
15:52justin_smithwasamasa: I got the type wrong - not hashed (d'oh), but the hyPiRion article explains it well
15:53wasamasa"A more formal name for Clojure's persistent vector structure is persistent bit-partitioned vector trie"
15:53justin_smiththere we go
15:54mungojellyboth "tree" and "try" are other words it should be some other vowel
15:55justin_smithjust so talking about these things outloud will be as confusing as possible
15:56mungojellytruys and troys should be something that's applicable to either trees or tries so you can talk about the distinctions between truy tries vs troy trees
15:57justin_smithoh yes, good idea
17:12xenohi, in intellij/cursive, when I run the application, the println's don't appear in the window
17:12xenowhat's da problem?
17:14cflemingxeno: How are you running the app?
17:16xenoctrl-shift-f10
17:16xenoshift-f10 is enough btw
17:16xenobut same result
17:17xenoit's the same as Run=>Run
17:17xenohmm...
17:17xenoI'll add a sleep to the main method and see if it has effect
17:18cflemingRight, Cursive will execute your file like a script, it won't automatically invoke main
17:21xenook
17:23gfrederickshelp I'm about to reinvent finger trees
17:24amalloygfredericks: you have so much to live for
17:25gfredericksI'm trying to use the actual finger trees but somehow it and clojure disagree about whether a certain deftype ought to be nthable
17:26lodin_I love the Wikipedia entry on Finger tree. The See also section just says "* Monoid".
17:27gfredericksI guess the problem is that clojure can't tell the deftype implements Sequential
17:27gfrederickswhich is exciting
17:29gfredericksthis line appears to be ineffective: https://github.com/clojure/data.finger-tree/blob/master/src/main/clojure/clojure/data/finger_tree.clj#L319
17:31gfredericksre-evaling the finger-tree file fixed it. O_O
17:31gfredericksI bet this is related to dynamically loading the library
18:07noncom|2in clojurescript how do i load a resource from the resources/public folder?
18:07noncom|2say, a text file
18:17justin_smithnoncom|2: you'll need to make a request to the server, unless you plan to embed it into the cljs itself
18:20noncom|2yeah, just realized that make it a cljs/edn is much simpler! :)
20:35mathiasxWhat are most people using for building up web apps with Postgres on Clojure? Manually building up a library of functions and queries on top of JDBC, or using a library?
20:40mathiasxI guess I'm more interested in existing libraries, since I don't know that I have time to really build and test something robust from scratch on just JDBC methods. I am not beholden to things like wanting to build up queries in Clojure, but I'd like some niceties like injection protection. And some sort of support to help with tests would be great, as well
20:40mathiasxas some sort of way to do migrations and manage schemas.
20:41justin_smithmathiasx: if you paramaterize your query, that will do something to prevent injection. Just be sure you are not using data sourced from the client to build the query string itself
21:04TrioxinI learned the syntax last night in like 6 mins lol. that was interesting
21:05Trioxinnow to memorize the core functions
21:05TEttingermap reduce apply filter concat into <-- common
21:06Trioxinthis whole immutability thing is weird. I've encountered it before of course but never to this extent
21:06TEttingermapcat partition zipmap <-- less common, still useful
21:07justin_smithTrioxin: be sure to check out http://conj.io
21:07Trioxink
21:07TEttinger,(partition 2 "hello, world")
21:07justin_smithTrioxin: most of the basics are on that page
21:07clojurebot((\h \e) (\l \l) (\o \,) (\space \w) (\o \r) ...)
21:07Trioxinlearning of macro and reader data
21:08TEttinger,(take-nth 2 "hello, world")
21:08clojurebot(\h \l \o \space \o ...)
21:08Trioxinmacros
21:09justin_smith~macros
21:09clojurebotBarking spiders!
21:10justin_smithhaha
21:10Trioxinwhen this guy says "Evaluates from the outside in does he also mean right to left?
21:11justin_smithTrioxin: it means macros decide how the form is evaluated
21:11justin_smithTrioxin: as opposed to functions, where the arguments are evaluated before the function sees them
21:11dbasch,(apply str (map #(char (bit-xor 1 (int %))) "idmmn-!vnsme"))
21:11Trioxin(def me (+ 1 2))
21:11clojurebot"hello, world"
21:11TEttingerfor functions, that's left to right
21:12justin_smithfor macros it's "whatever order the macro decides, including not at all, or four times in a row"
21:13Trioxinin this simple case I just posted am I creating a function or a variable? or both?
21:13Trioxinit's a variable right
21:13justin_smithTrioxin: a variable
21:13Trioxink
21:13justin_smithor, to be more specific, you are adding a var to the namespace
21:14Trioxinright
21:14TEttingerright, Trioxin, for (def me (+ 1 2)), if def was a function it would try to evaluate "me" as soon as it saw it. def is a special form I think, but you can think of it like a macro because it doesn't evaluate "me" right away
21:14justin_smith,(defmacro do3 [& body] (list 'do body body body))
21:14clojurebot#'sandbox/do3
21:15justin_smith,(do3 (println "hello"))
21:15clojurebothello\n#error {\n :cause nil\n :via\n [{:type java.lang.NullPointerException\n :message nil\n :at [sandbox$eval127 invokeStatic "NO_SOURCE_FILE" 0]}]\n :trace\n [[sandbox$eval127 invokeStatic "NO_SOURCE_FILE" 0]\n [sandbox$eval127 invoke "NO_SOURCE_FILE" -1]\n [clojure.lang.Compiler eval "Compiler.java" 6943]\n [clojure.lang.Compiler eval "Compiler.java" 6932]\n [clojure.lang.Compiler eval...
21:15justin_smithhmm
21:15Trioxinoh right there's fn
21:15Trioxinduh
21:16justin_smith,(defmacro do3 [& body] (list 'do (cons 'do body) (cons 'do body) (cons 'do body)))
21:16clojurebot#'sandbox/do3
21:16justin_smith,(do3 (println "hello"))
21:16clojurebothello\nhello\nhello\n
21:16justin_smiththat evaluates the println 3 times
21:16TEttingernow with syntax-quote!
21:16justin_smithwith a function, the argument would just show up as nil, it could not control the evaluation
21:16Trioxinand I'd call those iterations...
21:16justin_smithTEttinger: that's 201 level stuff
21:16clojurebotI don't understand.
21:16TEttingerit just makes that line simpler
21:17TEttingerbrave clojure has a good intro to macros that include syntax-quote
21:17justin_smithTrioxin: iterations? no function or data source was passed in. I'm just demonstrating that a macro has full power to how its args are used (including multiple evaluation, or not evaluating them at all)
21:17Trioxinok
21:18Trioxinalright must get back to tutorials before being told more things
21:18justin_smithTEttinger: I have my own agenda with this stuff, which includes making it clear that all macros have to do is construct a form, and syntax-quote being a convenient way to construct forms, but not an aspect of defmacro
21:19TEttingerk
21:21Trioxinman this is so different. I'm getting the same feeling I got when I first started learning procedural programming some 17 years ago
21:22Trioxinand oop which wasn't bad. but I do get the feeling I will have new magic spells
21:23lodin_Trioxin: I would really recommend ignoring macros until you can write just about any program you like without using them.
21:24Trioxini think this guy is just explaining how the code is interpreted
21:24justin_smith*compiled
21:24Trioxinright
21:25Trioxini meant that in an abstract way
21:25justin_smithas in, evaluated maybe?
21:25Trioxinyeah lol
21:25lodin_Trioxin: Just treat any macros like a special keyword in another language. For all practical purposes when learning Clojure, existing macros = keywords.
21:25justin_smithif clojure were interpreted instead of compiled we could do some cool things with macros we can't actually do
21:26justin_smithwell, not without using eval at least
21:26Trioxinisn't that part of what were talking about last night with the difference between clojure and CL?
21:27justin_smithCL is usually compiled too (but that can vary with implementations)
21:27Trioxinyou have to use an eval function to execute data as code?
21:28Trioxinjust about every language has an eval
21:28Trioxini thought lisp was special in its ability to treat data as code and vise versa
21:28justin_smithTrioxin: sure, the E in rEpl stands for eval, it runs eval on everything you type in
21:29justin_smithTrioxin: it's more that our code has a higher level representation - I mean every language can treat a string / array of bytes as code
21:29justin_smithbut the extra power with lisp is being able to use lists as code
21:30lodin_Trioxin: The point about data and code is that the AST in Clojure is defined with Clojure data structures.
21:30justin_smithbecause you can do cool things with list transforms (and that is what macros are for) but really most of the really good macros are there already, don't expect to make new macros very often (at least not really useful ones)
21:33lodin_Trioxin: And the AST being Clojure data means that all Clojure functions can operate on it, so that makes macros easier to write.
21:33Trioxinwell let's say I wanted to create some kind of code optimization program using this functionality with some fitness function. I was thinking of doing cool things like defining some code/functions and then running searches on that code space
21:34justin_smithyeah, in that case you'll probably be using eval rather than macros I'd think
21:34justin_smithmacros are for things humans make
21:35justin_smithTrioxin: this is something the twitter bot @tweegeemee does (where the fitness function is twitter likes and retweets of the images the code generates)
21:35justin_smithit has various methods for manipulating the image creating code (splicing in parts of other successful image code, randomly mutating parts of the syntax tree)
21:36Trioxini remember ray kursweil or however you spell him saying he could write a superintelligence in 50 lines of lisp. of course the computational power to search an entire programming space would be out of the question but I was thinking of doing something similar with predefined functions (Not creating a superintelligence but experimenting with what I could get to come out)
21:40Trioxinnvm all that I just want to learn all this first. I'm just a bit paranoid as someone last night told me that if I learn clojure and then decide I want to use CL it will be easy to do so but that I'd be more likely to write bad CL
21:43lodin_Trioxin: Why do you want to learn Clojure, btw?
21:47Trioxinlodin_ to enhance my abilities as a coder, write more efficient code, learn a new paradigm (Mostly pure functional which I've never done). I also write a lot of ML code and have read that a lot of people do so in Lisp. Then there's the fact that you can use all that is java in Clojure and there's also Clojurescript and I write most my mobile and GUI code in HTML5 for nw.js and cordova.
21:49TrioxinI was also impressed by the comparisons to Java and Clojure by the creator of Clojure
21:49Trioxincontrasts rather
21:49lodin_Trioxin: When you said "write a lot of ML code" I thought you meant ML the programming language and I was like "what?". :-)
21:50Trioxinsorry, machine learning. deep learning, etc.
21:50lodin_Yes, I realized.
21:51lodin_Trioxin: Good reasons. Why do you also consider CL?
21:51lodin_(I don't know CL, btw.)
21:53Trioxinlodin, mostly because I hear people argue about the non-existence of custom reader macros in Clojure
21:53lodin_Trioxin: And these people are CL people, I presume? :-)
21:53Trioxinno, usually people trying to decide which Lisp to go with
21:54Trioxinhttp://stackoverflow.com/questions/5746801/what-advantage-does-common-lisp-reader-macros-have-that-clojure-does-not-have
21:55Trioxinthat's not my thread btw
21:57Trioxini mean reading through that whole thread you do get a sense of it being useful
21:57Trioxinthe last answer for instance
21:58lodin_It's a feature, so it can be useful. And I think that reader conditionals proved that for clj/cljs libraries.
22:00Trioxintoo bad dotlisp is no longer maintained
22:00TrioxinI know C#
22:01lodin_I don't think I would choose a language based off it though. Or rather, I'm sure.
22:02Trioxinbased off the whole reader macro thing?
22:02lodin_Yeah. Perl has source filters which is akin to reader macros but a nightmare to implement properly (because you need to parse Perl!). Don't see people use that feature as an argument for Perl. Ever. ;-)
22:03Trioxinright but in ML the tendency is to attempt to push boundaries
22:04Trioxini do that in any language really
22:04justin_smiththey are doing reader-macro like things in boot - for example a syntax for multi line strings
22:06Trioxinno multi line strings in Lisp?
22:06justin_smithnot in the specific style they are doing (that is, with leading whitespace trimmed so your indentation looks nice)
22:07Trioxinyeah that's what I meant
22:07justin_smithyeah - that doesn't exist in clojure itself, but you can get it via a boot module
22:08Trioxinwhat was clojure coded in?
22:08justin_smitha mix of java and clojure
22:08Trioxino
22:08lodin_Something I do miss is alternative string syntax, actually.
22:09lodin_Like Python's """ or Perl's qq operator.
22:09justin_smithlodin_: you might just have a reason to try boot now :)
22:10Trioxinpython will come after clojure for me since it's so popular in acedamia, prototyping
22:10lodin_Mostly it's for docstrings, really. Having to quote your strings in code examples in docstrings is really not pretty.
22:11Trioxinanother reason for me wanting to learn Clojure is that I've used Java before on a pretty big project and from the videos it looks like I could have saved myself a lot of time
22:12Trioxinmy c# is fun but i don't like dealing in mono and you kind of have to
22:14Trioxini like reusable code as in my html5 development and for that there's clojurescript
22:15Trioxinand I'm sure Clojure can do heavy lifting for clojurescript on the backend
22:16Trioxinso I imagine having node-webkit, using clojurescript in my apps, then using Clojure for any system level heavy lifting or to expose more native API functionality
22:17lodin_justin_smith: I've been glancing at boot before. It's just too convenient to default to leiningen. Like when I wanted to try devcards. Leiningen template, of course.
22:18Trioxinthat's another thing I wanted to ask. When I started out last night in IDEA you guys had me start with a leiningen project. Is there a difference between doing that and starting with a traditional clojure project?
22:18Trioxinany downside?
22:18justin_smithTrioxin: clojure is a java library
22:19justin_smithTrioxin: leiningen is a dependency and project management tool
22:19cflemingNot sure if this came through, I was disconnected: Once someone has done something like (alter-var-root #'my-var memoize), there's no way to access the original unmemoized function, right?
22:19Trioxinoh ok. so it doesn't matter it's the same code
22:19justin_smitha "traditional clojure project" is any java project that uses the clojure library to evaluate .clj files
22:20justin_smithcfleming: not unless you hold your own copy of the original I guess
22:20cflemingjustin_smith: That's what I thought. Sadly I can't do that - this is in the lein code, and they use defn and then immediately memoize it
22:20cflemingDamn
22:20justin_smithTrioxin: right, the difference with using leiningen vs. boot vs. maven vs. doing everything yourself by hand is a difference of convenience and tooling, it's still clojure
22:21cflemingLooks like it's cut and paste for me
22:21justin_smithouch!
22:21Trioxinok
22:23justin_smithcfleming: I still find it funny that alter-var-root doesn't have like three exclamation points at the end of the name
22:23Trioxinoic just by reading the github
22:23Trioxinhttp://screencast.com/t/WgxTdq2yl
22:24justin_smithyup, leiningen is very well documented
22:24justin_smithTrioxin: the leiningen wiki, and the example project.clj, are also very informative
22:25Trioxinwell I'm up and running with it in IDEA and it seems simple
22:25justin_smithyeah, it's a well integrated tool
22:26cflemingjustin_smith: Yeah, that would be great. Those who say that Haskell's type system can't help should look at lein's use of memoization.
22:26Trioxinwhat about the "Fetching dependencies for your project" aspect. Is there a package manager like npm where I can install libs to my project?
22:26justin_smithalter-var-root!!!-no-really-I-want-to-do-this!!!!
22:26cflemingIn this case, it's a function which only exists to print a message, which is memoized so the message is only printed once.
22:27justin_smithTrioxin: lein figures out what deps your project needs, and caches them in a local directory (~/.m2/)
22:27lodin_Haha. Great use for memoization!
22:27justin_smithTrioxin: when it starts up, it tells your vm where all the libs it needs are
22:27cfleminglodin_: For some definition of "great", yes :)
22:28Trioxinoic it even makes reference to npm
22:28justin_smithTrioxin: we call it a cache because it's not quite an install, we know where to get exactly the same artifact again later if you need to clear the cache eg. for disk space reasons, and always gets it automatically if it is needed and not present
22:29justin_smithcfleming: I've used delay for that, using memoization for at-most-once behavior feels hacky
22:30cflemingjustin_smith: No doubt.
22:31justin_smithI mean delay has exactly the semantics we want here - by default it doesn't run, if forced once the code is run, if forced again it just uses the same return value as the first time without running the code
22:32lodin_I guess it wouldn't help cfleming though, since a delay would also hide away the code.
22:32justin_smithlodin_: fair point
22:34justin_smithlodin_: that's a question of reusability I guess, while I am talking about the separate issue of parsimony (I prefer the solution that does the least irrelevant stuff if possible, and delay is as easy to use as memoize (if not easier))
22:35Trioxinjustin_smith, I seem to be missing something in IDEA, the command prompt where I would normally run npm (Im this case leiningen) commands
22:35TrioxinIn*
22:35lodin_justin_smith: I'm just happy memoize is being used. ;-) I figured it was getting lonely, only getting mentioned in blogs about how easy it is to do memoization in Clojure.
22:35justin_smithTrioxin: sadly lein doesn't have an interactive console mode any more (it once did but it was taken out with 2.0)
22:36justin_smithlodin_: haha
22:36lodin_Anyway, I'm off.
22:36Trioxinso what I use my system's CLI from the project dir?
22:36Trioxinpowershell
22:36justin_smithlodin_: nothing stops you from wrapping all your non-returning statements in memoize
22:36justin_smith,(memoize nil)
22:36clojurebot#object[clojure.core$memoize$fn__5467 0x1bb0c7f6 "clojure.core$memoize$fn__5467@1bb0c7f6"]
22:37justin_smithTrioxin: I think cursive might have a menu for common lein tasks (like compile, check, test, jar, uberjar, run, deploy)
22:39Trioxinjustin_smith, nothing to do with the REPL window right?
22:40justin_smithno
22:40cflemingCode cut and pasted, now I just need a shower
22:40justin_smithhaha
22:41cflemingTrioxin: You can open a command line prompt via View->Tool Windows->Terminal
22:41talios'lo cfleming
22:41cflemingHey talios
22:42gganleyhail talos
22:42Trioxinoh right, my brain didn't notice it as I was just in there
22:42cflemingTrioxin: If you want to run lein commands from within IntelliJ then View->Tool Windows->Leiningen will show some common commands under the project
22:42cflemingBut the command line is generally easier if you have everything installed and working
22:42mcktrtlWhat's the standard way to map over a hash-map? The equivalent in python would be to use a list comprehension with .items().
22:43justin_smithmcktrtl: do you want the results, or is this just for side-effects?
22:43Trioxincfleming, the command is "leiningen" right? in that case I don't think I have the env var setup or something
22:43justin_smithmcktrtl: all the standard clojure collection ops work on hash-maps (filter, map, reduce, doseq, for, ...)
22:43mcktrtlno side effects. Specifically, I used clojure.set/index to index a hash map, and now I want to project a specific field based on that index
22:44cflemingTrioxin: 'lein' is what you want, i.e. you need "lein version" to show you something
22:44Trioxinno it's not setup. must locate and add path
22:44justin_smithmcktrtl: sounds like you might want reduce-kv
22:44justin_smith(doc reduce-kv)
22:44clojurebot"([f init coll]); Reduces an associative collection. f should be a function of 3 arguments. Returns the result of applying f to init, the first key and the first value in coll, then applying f to that result and the 2nd key and value, etc. If coll contains no entries, returns init and f is not called. Note that reduce-kv is supported on vectors, where the keys will be the ordinals."
22:45justin_smithmcktrtl: that lets you pass a new hash-map along as an accumultor, and do a new transform on that accumulator for each k/v pair in the input
22:45mcktrtlthat indeed is exactly what I needed, thanks :)
22:45Trioxincfleming, i also ready that if I add a dependency and refresh the project from the lein window or whatever it will then add it from a repo I think? So it will fetch any dep I define for the project or no?
22:45justin_smithmcktrtl: just be aware you need to return the next version of the hash-map at every iteration of the function
22:45cflemingTrioxin: yes, that's right.
22:46mcktrtlright... thanks again, i'm failing at google foo hard today
22:46cflemingTrioxin: So you add it to your project.clj, hit refresh, and it will be downloaded and added
22:46Trioxini'd rather use the CLI though. if I use the CLI will it add the dep to my project file?
22:46justin_smithmcktrtl: also check out http://conj.io for a great overview of the clojure core stuff
22:46Trioxinin that case I need to add lein's location to path
22:47Trioxinwherever that is
22:47cflemingTrioxin: No, you generally have to add the dep to your project file, although I'll shortly be adding a command to add a dep to the project file and refresh automatically.
22:47Trioxinok. yeah that would be nice.
22:50justin_smithTrioxin: on your platform it might be named "lein.bat"
22:53justin_smithTEttinger: check out this awesome article http://eev.ee/blog/2015/09/12/dark-corners-of-unicode/
22:53justin_smithTEttinger: for example, TIL there is an "astral plane" in unicode
22:53TEttingerha
22:54justin_smithnow I am convinced that the unicode consortium must have been a D&D group in their off hours
22:55justin_smith"everything is uniquely terrible; welcome to computers"
22:56Trioxinjustin_smith, here are all the results. that folder is empty http://screencast.com/t/oUP5GSPhSCc
22:57Trioxinjustin, should I create a .bat file that calls one of those jars?
22:58justin_smithTrioxin: the default is that lein.bat would invoke one of those jars. And cursive must already be doing the equivalent.
22:58Trioxinjustin_smith, well there is no such .bat file on my computer
22:58justin_smithTrioxin: there's a lein.bat you can download that will use those jars (or install them itself in its own cache)
22:58Trioxinbut I haven't had any problems with REPL
22:58justin_smithinteresting, I assumed cursive would use lein.bat, but maybe it is using the jars directly
23:00Trioxinmust find this bat file in github I guess
23:01justin_smithTrioxin: http://leiningen.org
23:01justin_smithor from github, yeah
23:02Trioxinhttps://github.com/technomancy/leiningen/search?utf8=%E2%9C%93&amp;q=lein.bat
23:02Trioxini mean I already have lein. I wouldn't want to break IDEA
23:02justin_smithyup, here's the raw file https://raw.githubusercontent.com/technomancy/leiningen/35aef5832bec8b8daed20400b6acf9fc9fb0a7a0/bin/lein.bat
23:02justin_smithTrioxin: it wouldn't break idea
23:02justin_smithand it's good to make sure you can use it from the terminal
23:03Trioxinor cursive. so I should put it in the same dir as. well see in that pic. there's lein in the temp dir so I'm assuming put it with the .jar in the .idea plugins dir?
23:03Trioxinnot in temp of course
23:04justin_smithTrioxin: it doesn't matter where lein.bat is, as long as it's on your executable path
23:04justin_smithTrioxin: it will self-install the jars it needs into ~/.lein/
23:04Trioxink, I guess I'll just put it in C:\Users\root\.IntelliJIdea14\config\plugins\clojure-plugin\lib
23:05cflemingjustin_smith: Trioxin: Yes, Cursive uses the jars directly.
23:05justin_smithcfleming: that would explain it then! so yeah, good to have lein.bat too
23:05TEttingerjustin_smith:
23:05TEttinger,(reduce - [3 2 1])
23:05clojurebot0
23:06cflemingClearly I need a lein console in IntelliJ so people can enter lein commands directly
23:06justin_smithLOL that's great
23:06Trioxinthen i'll add that dir to path
23:06TEttinger,"\u1680"
23:06clojurebot" "
23:06justin_smithcfleming: I miss lein interactive (which can't exist with lein 2 for reasons I guess?)
23:07Trioxinwill I be calling the .bat each time or some lein file it grabs?
23:07cflemingjustin_smith: I have no idea. I'm actually developing a deep hatred of lein after embedding it.
23:07justin_smithTrioxin: you call the .bat, and it does the rest for you
23:07Trioxinok thx
23:07justin_smithclojurebot: :( maybe boot?
23:07clojurebotI don't understand.
23:07justin_smitherr
23:07cflemingI mean, it's great but it's definitely painful to embed.
23:08justin_smithyeah, I think that how friendly lein is to contributors and added features is probably a double edged thing
23:16Trioxincfleming | justin_smith, http://screencast.com/t/5kbymHPL
23:16Trioxin C:\Users\root\.IntelliJIdea14\config\plugins\clojure-plugin\lib\ is in PATH
23:17Trioxinthe bat is in the same dir
23:17cflemingTrioxin: You only need lein.bat on your path
23:17Trioxinright but as you can see I ran the ban
23:17Trioxinbat
23:17cflemingIf you run lein self-install, it should then download the latest version and put it in ~/.lein/self-installs
23:18Trioxinok it won't junk up the lib dir?
23:18cflemingNope
23:18cflemingIn fact you don't need that jar file in there, lein will never use it.
23:18justin_smithTrioxin: as the tool mentions (and cfleming), you should run "lein self-install"
23:19cflemingI'm surprised it doesn't do that itself to be honest, I thought it did
23:19justin_smithweird that the self-install command is not automatic with lein.bat (with the *nix version it is assumed)
23:19justin_smithyeah
23:19Trioxinproblem: http://screencast.com/t/RMOkk3Er0Dy
23:20justin_smithhmm
23:20justin_smiththat's a bug in lein.bat, maybe it isn't compatible with your system or the specific shell you are using?
23:20justin_smith#leiningen might be more helpful at this point
23:20Trioxinim on 8.1 in powershell. i could go to cmd
23:21justin_smithyeah, see if cmd is any better
23:21Trioxinsame
23:22justin_smithyeah, I'd check the lein bug tracker for similar errors and ask on #leiningen at this point
23:22Trioxinline 145 of the bat
23:23Trioxinoh wait maybe I need to install wget
23:24Trioxinit should work in powershell though from what I can see in this script
23:24justin_smithhttps://i.imgur.com/nsf6vy7.png
23:27Trioxinhttps://github.com/technomancy/leiningen/releases/download
23:27Trioxinshouldn't that have a dir listing?
23:28Trioxinset LEIN_JAR_URL=https://github.com/technomancy/leiningen/releases/download/%LEIN_VERSION%/leiningen-%LEIN_VERSION%-standalone.zip
23:28Trioxinthat's from the bat
23:28cflemingFWIW I'm now totally convinced I need a lein interactive type thing in Cursive
23:28justin_smithsometimes directory listings are not allowed, sometimes there isn't a true directory to list and things are actually being generated on the fly
23:29cflemingjustin_smith: How did that work? Just a console where you typed lein commands but without the leading "lein"?
23:29TrioxinI'm going to mod the .bat to echo the url
23:29justin_smithcfleming: right, it shouldn't be hard to find in the 1.x source - it was ditched because of bugs caused by lein code that expects to run once and die
23:30justin_smithcfleming: which to me sounds a lot like "it was easier to remove this feature than fix N bugs that break that feature"
23:30cflemingjustin_smith: Interesting. I can solve that now with ShimDandy, which is what I'm moving my lein integration to anyway.
23:30justin_smithoh, very cool!
23:34cflemingjustin_smith: Looks like that was actually a plugin: https://github.com/ujihisa/lein-interactive
23:36justin_smithaha
23:37Trioxinthe bat file doesn't work because the file it's trying to download doesn't exist. I printed it to the console: https://github.com/technomancy/leiningen/releases/download/2.5.3-SNAPSHOT/leiningen-2.5.3-SNAPSHOT-standalone.zip
23:38TEttingerthat's what it tries to download?
23:38Trioxinyeah
23:39TEttingerah!
23:39TEttingeryou didn't get the bat from the stable branch
23:39TEttingerhttps://github.com/technomancy/leiningen#installation
23:39Trioxinuh oh
23:39justin_smith(inc TEttinger)
23:39TEttinger(dec lazybot)
23:39justin_smithTrioxin: just use the stable version, it should work just fine
23:40TEttingerit's not even... that old. latest update was last month
23:40cfleminglazybot has been out of action for a while I think, I just tried to look at the logs and they're 5 days out of date
23:40cfleming4 days, sorry lazybot, I slander you
23:41Trioxinill just use the installer
23:44Trioxindo you guys use the 64bit jdk mostly or 32?
23:45TEttingerI haven't found much difference for desktop usage. 64-bit probably only matters when you need one process to use more than... what is it, 4 GB RAM?
23:45justin_smithTrioxin: there's not much reason to use a 32 big jdk I don't think
23:46justin_smithTEttinger: 64 bit will be a faster for a bunch of stuff (especially considering clj uses doubles and longs by default)
23:46Trioxini installed jdk1.8.0_60 and now it shows me in IDEA 2 versions of jdk1.8.0_45 in the list to choose from
23:46TEttingerthere's better floating point arithmetic behavior with 64-bit than 32-bit, can't think of any other differences. oh yeah, longs are the hardware word size on 64, yeah use 64
23:46TEttingeridea comes with its own jdk as well
23:46justin_smithTEttinger: right, floats are doubles by default in clj, and doubles are faster with a 64 bit process
23:46Trioxinoh so it's not even listing jdk1.8.0_45
23:46TEttingerask cfleming, he's the intellijent one here :)
23:47Trioxinbecause I have both SDKs in my program files dir
23:47Trioxini mean not listing _60
23:47TEttingerit could be in program files (x86)
23:48TEttingerwhich would mean that's a 32-bit _60 jdk
23:48TEttingernot sure how this all works on windos 8 and newer
23:48Trioxinno it's in program files it's the x64
23:48cflemingTEttinger: Idea comes with its own JDK, but you can't use it for running application code
23:48cflemingAFAIK
23:49Trioxini was just using the one it comes with for REPL
23:49TrioxinI'm restarting IDEA though and going to try to add the newest 64bit jdk though
23:50TEttingermight need to restart windows if it's a PATH mixup gone bad
23:52Trioxinthat worked
23:52Trioxinnow to get lein using the same
23:53Trioxinoops, did the stupid uppercase project name thing again