#clojure logs

2013-02-16

00:18lynaghk`dnolen: ping
00:20lynaghk`dnolen: prep is broken on master; (prep '[?x ?x ?x]) only turns the first symbol into an lvar
00:25lynaghk`dnolen: 0fa6dd3 is the guilty commit; why the switch?
05:41modulusDo I need to have JDK to use clojure, or just JRE?
05:42modulusI'm getting an error running the seasaw repl tutorial which is why I'm saking. (display (text "This is a text field.")) says it can't resolve display symbol, no source.
05:47abpmodulus: You mean this one? https://gist.github.com/daveray/1441520
05:48abpHave you defined the function display? It's defined in the tutorial.
05:48modulushmm sec, i may have missed that out
05:51modulusok, i was dumb, i had missed that part
05:51modulusmany thx
05:58abpWow my ideas around graph based web-apps are finally resolving and Prismatics graph is out there. My weekend is over.
06:41maioany midje/clojure expert around? :) is there some way to state some fact inside threading macro? http://pastebin.com/gKwhBEuP
06:43AtKaaZ,(('f 'f))
06:43clojurebot#<NullPointerException java.lang.NullPointerException>
06:44AtKaaZ,(= nil ('f 'f))
06:44clojurebottrue
06:45AtKaaZis there another way I can return the symbol nil? other than ('f 'f)
06:46AtKaaZ,(symbol 'nil)
06:46clojurebot#<NullPointerException java.lang.NullPointerException>
06:46AtKaaZ,'nil
06:46clojurebotnil
06:46AtKaaZ,(= 'nil ('f 'f))
06:46clojurebottrue
06:47AtKaaZ,((quote s) 1)
06:47clojurebotnil
06:49AtKaaZ,((quote true) 1)
06:49clojurebot#<ClassCastException java.lang.ClassCastException: java.lang.Boolean cannot be cast to clojure.lang.IFn>
06:51AtKaaZ,(= (symbol 'java.lang.RuntimeException) (quote java.lang.RuntimeException))
06:51clojurebottrue
06:51AtKaaZ,(= java.lang.RuntimeException (quote java.lang.RuntimeException))
06:51clojurebotfalse
06:51AtKaaZ,(= java.lang.RuntimeException (eval (quote java.lang.RuntimeException)))
06:51clojurebot#<Exception java.lang.Exception: SANBOX DENIED>
06:53abp(GET "/search" _ :search) - invokes graph to compute :search - params/query -> db/search -> view/search-results -> :search
06:53abpI think that's pretty sound. :)
07:24pepijndevoswhat happened to crane?
07:26pepijndevosmaybe i'm looking for pallet, or jclouds? confused.
09:32devlolHi, I just wrote a small lib on top of compojure/clout which allow you to specify custom wrappers for specific endpoints, group of endpoints and generate iodocs documentation. What do you guys think of this approach ? https://gist.github.com/obohrer/c7011444273c36235558
11:32pgmcgeeis there a way to write an data structure to a file and then read it back later?
11:36tgoossensyou could just write it as a string
11:36tgoossensi guess
11:37tgoossensand then slurp it back in again
11:37tgoossensand convert it to a data structure again
11:37tmciverpgmcgee: check this out too: http://clojuredocs.org/clojure_core/1.2.0/clojure.core/*print-dup*
11:37pgmcgeethanks!
11:48tgoossenspgmcgee: you're welcome
12:31palangowhere has the positions function from clojure.contrib.seq-utils gone to? It's not in core and I couldn't find any info on where the namespace moved.
12:44callenbothow are people still using things from contrib?
12:45callenbotalex_baranosky: database URL support - yes?
12:46alex_baranoskyyes?
12:46clojurebotyes isn't is
13:22FrozenlockIs there a way to 'print' something that will only appear in the repl at the next evaluation?
13:22hyPiRion"that will only appeat in the repl at the next evaluation"? Are you talking about time travel here?
13:24seangroveFrozenlock: I'm curious what you mean as well
13:25Frozenlocksomething like (future-print "hey!"). Then (+ 1 2) ---> Hey\n 3
13:28bbloomFrozenlock: let's back up a step. Why do you want that?
13:29FrozenlockI have a sandboxed repl à la tryclj.com. The namespace will expire after a given time. I just want to send a msg to the user letting him know he is now in a new namespace.
13:31bbloomFrozenlock: odd... well if you're hooked into the REP-loop you can do whatever you want
13:33hyPiRionFrozenlock: do a check before evaluating data, and print if the repl has changed?
13:36FrozenlockWell I was hoping to just use the all-in-a-pretty-box clojail solution without fiddling too much around it :/
13:36FrozenlockMight be what I'll have to do however...
13:50yedihows #clojure doing this fine afternoon
13:51FrozenlockPretty well indeed! How about you?
14:05FrozenlockIs it possible to use noir-session related functions in a future call?
14:10dcjacksonIs anyone other than me having trouble pulling down jars from central right now?
14:13dbushenkowhich is the best lib for pattern matching?
14:14bbloomdbushenko: there is core.match, but you probably don't need pattern matching. if you're coming from a language that does have pattern matching built it & you're used to it, you might want to try living without it for a little while
14:15dbushenkobbloom, no way, I need it.
14:15dbushenkocore.match doesn't suit me since it can't match lists
14:15dbushenkosad...
14:15cemerickdbushenko: sure it can
14:16dbushenkocemerick, but how? The list syntax () is reserved for special uses. It does not match a literal list.
14:16dbushenkothats from its official doc
14:17bbloomdbushenko: https://github.com/clojure/core.match/wiki/Overview search "Seq matching"
14:17bbloom~list?
14:17clojurebotlist* doesn't actually make a `list?`
14:17bbloom~seqs
14:17clojurebotseqs and colls is http://www.brainonfire.net/files/seqs-and-colls/main.html
14:17cemerickdbushenko: what bbloom said, and if you absolutely must fix on the concrete list type, add a :guard list?
14:18dbushenkothanks!
14:18bbloombut `list? is 99% of the time NOT what you want
14:18bbloomseqs != lists
14:18dbushenkobbloom? why not? I need exactly lists
14:18bbloomdbushenko: do you need stack push and pop semantics?
14:19dbushenkobbloom, looks like your are Obi Wan :-)
14:19dbushenkobbloom, these are not those lists you are looking for
14:19dbushenko;-)
14:19cemerick99.95%, even ;-P
14:19bbloomcemerick: unless you know what you're doing and are writing a macro :-P
14:19bbloomeven then, seq? is probably better heh
14:20cemerickbbloom: exactly
14:20dbushenkowell, I've got such data structures (((1 [+ 2]) (((+ [2]) (2 [])) [])) [])
14:20dbushenkoI need to fetc the data inside
14:20dbushenkoI have those lists inside
14:20bbloomanyway, dbushenko, unless you need IPersistentStack, you want seqs and you don't care if they are lists
14:20dbushenkohow I cant match them?
14:20cemerickdbushenko: that's fine, but guard on seq?, not list?
14:20bbloom~seqs
14:20clojurebotseqs and colls is http://www.brainonfire.net/files/seqs-and-colls/main.html
14:20bbloomread that^
14:20bbloomheh
14:21dbushenkoI see what you mean. I need to have a look. thanks.
14:21cemericke.g. ##(type (remove odd? (list 1 2 3 4)))
14:21lazybot⇒ clojure.lang.LazySeq
14:21cemerick^^ not a list
14:21bbloomand after you understand what i'm saying about seqs and lists, come back and i'll make you understand what i'm saying about pattern matching :-)
14:22dbushenkoseems like you are inviting me to a cave where you'll give me the lightsaber of my father :-)
14:26musicalchairso I don't want to use list? because pretty much everything returns a seq and whereever I'm concerned about having a list I mostly might as well be concerned about have a seq instead?
14:27bbloommusicalchair: that's the short version, yes
14:29musicalchairbbloom: and you mentioned some nuance when writing macros?
14:30dbushenkobbloom, ok, now I have: (match ['(1 [+ 2])] [([a [b c]] :seq)] (list a)) It works the same as (match ['(1 [+ 2])] [((a [b c]) :seq)] (list a)) (see the parens inside the pattern)
14:30bbloommusicalchair: it's just that list? works as you expect in macros, but really that's not a guarentee, from what i can tell
14:30cemerickseqs are an abstraction, of which lists are a particular implementation. Fixing on lists is equivalent to fixing on array-maps to the exclusion of hash-maps.
14:30dbushenkobut that is not what I want. I need to match only list, not a vector
14:30dbushenkois it possible?
14:31bbloomdbushenko: use a guard with the seq? predicate
14:31dbushenkothanks
14:31bbloomdbushenko: or better yet, use cond
14:31dbushenkobbloom, can you give me an example?
14:31dbushenkobtw, I think not seq? but list?
14:31bbloomdbushenko: that page i linked you too discusses guards
14:31musicalchaircemerick: makes sense
14:32bbloomdbushenko: and you're clearly not listening with respect to seq? vs list?
14:32bbloommusicalchair: list forms from the reader are always lists, so hence list? works in macros when parsing forms... but i don't know if that's enforced
14:32bbloomthe main thing about the List data structure as compared to the Seq abstraction is that lists are counted and implement IPersistentStack
14:33dbushenkolooks like the solution with guards will be overcomplicated....
14:33musicalchairbbloom: ah, gotcha.
14:33bbloomso as cemerick says, 99.5% of the time, you should use seq? not list?
14:33bbloomso much so that a lot of folks think that list? should be removed from core :-P
14:34dbushenkobbloom, btw, that's really confusing since list is usually a chain of cons-cells...
14:35bbloomdbushenko: it's only confusing b/c older lisps got this wrong for so many years....
14:35dbushenko:-D
14:35bbloomcons cells are a data structure, not an abstraction
14:35bbloomclojure works with abstractions
14:35cemerickdbushenko: Clojure lists are *not* chains of conses
14:36dbushenkocemerick, yea, I already saw the explanation a few minutes ago
14:36dbushenkobbloom, in Haskell list is also a chain of cons-cells
14:36bbloomcons cells are not counted and do not provide stack semantics
14:37bbloomdbushenko: eh, not really. haskell does so many funky thinks in the compiler that you can't really trust that to be true, heh
14:37dbushenko:-)
14:38bbloomdbushenko: haskell can leverage it's type system to accomplish deforestation, clojure can not
14:38bbloomhttp://www.haskell.org/ghc/docs/7.0.3/html/users_guide/rewrite-rules.html#id644345
14:39bbloomclojure, instead, utilizes chunked seqs to accomplish a similar optimization
14:39bbloomwhich, again, are not cons cells
14:39dbushenkoshit! thats great!
14:39dbushenkoI definitely have to learn haskell deeper!
14:39dbushenkobbloom, can I ask you something? how old are you?
14:40bbloom26
14:40dbushenkoshame on me that I still don't know haskell...
14:40bbloomgotta start somewhere
14:40dbushenko:-)
14:41abpHe folks, Prismatics Graph is awesome to write web apps.
14:49dgrnbrgIs there a version of autotest that works with lein2?
14:49dgrnbrgI want something that will rerun my tests every time I modify a file
14:50dgrnbrgusing clojure.test
14:50babilendgrnbrg: The newest midje version comes with autotest
14:50babilen(and can run clojure.test tests too)
14:50dgrnbrgcan I use that without changing the ns declarations?
14:51babilendgrnbrg: Sure, just run it: https://github.com/marick/Midje/wiki/Alternate-home-page + https://github.com/marick/Midje/wiki
14:51abpHave a look at that pretty app structure: https://gist.github.com/abp/4966883
14:52babilendgrnbrg: You want lein-midje and midje beta1 at least
14:52dbushenkodam it... core.match is buggy!
14:52dgrnbrgbabilen: very cool! I've used midje in other projects, but this project I started back before I moved through the testing frameworks, so it's still using clojure.test :/
14:53dgrnbrgI've become partial to expectations now, although I did have a fling with midje
15:00babilendbushenko: yeah, it really is a shame that core.match does not receive more love
15:02cemerickdbushenko, babilen: what are the faults you've seen?
15:03dbushenkolooks like it doesn't like nested lists
15:03dbushenkotry this
15:03dbushenko(match '(1 (2 (3))) ([a [b [c]]] :seq) (list a b c))
15:03dbushenkoit always return nil
15:04babilencemerick: I haven't seen any faults. but development certainly slowed and people seem to have lost interest in taking it further. I remember dnolen say something along the lines of: I have more interest in other things, but feel free to take over.
15:04dbushenkoAnd I can't even compile (match '(1 (2 (3))) ((a (b (c))) :seq) (list a b c))
15:08bbloomdbushenko: i'm almost certain your syntax is wrong there
15:08bbloomdbushenko: but i don't use core.match, so i don't know
15:08bbloomthe reason core.match doesn't get more love is b/c 9 times out of 10, destructuring gets the job done and is deeply simpler
15:08babilencemerick: There are also some issues that haven't seen much activity. I am not blaming anyone, but I simply sense a shift in interest. I thought that clojure.match would inspire lots of people and form the basis of things like cond-> (and much much more)
15:09cemerickdbushenko: (match '(1 (2 (3))) ([a ([b ([c] :seq)] :seq)] :seq) (list a b c))
15:09dbushenkocemerick, thank!
15:15babilendgrnbrg: Not sure if you've figured that out already, but you can run the autotest functionality with "lein midje :autotest" (or by calling (autotest) in the REPL, see https://github.com/marick/Midje/wiki/Repl-tools)
15:15dgrnbrgbabilen: yep, i got that working--good stuff :)
15:17babilendgrnbrg: wonderful, enjoy!
15:17clojurebotNo entiendo
15:23warzis there a way to install a clojure lib im writing in my local m2 directory? its not on clojars or anything, it's just on my local machine
15:23warzbut id like to require it from a different project as if it it were
15:24warzi could just copy it out to the m2 directory but that seems like a bad idea
15:26TimMc~repeatability
15:26clojurebotrepeatability is crucial for builds, see https://github.com/technomancy/leiningen/wiki/Repeatability
15:26TimMc^ some options there
15:27TimMcYou can always do lein install in the dependency's directory, but remember to actually push out a release before you release the dependant project.
15:28cemerickbabilen: "slow development" isn't necessarily a bad thing, if what's there works. :-) The rest of it e.g. people's personal level of interest, etc is bound to wax and wane.
15:32warzTimMc, cool. lein install is exactly what i was hoping for. didnt know it could do it for local projects like that.
15:33greywolvehey guys, i'm trying to setup a project specific task in leiningen, but i keep getting a "this is not a task" error
15:33greywolveare there any new tricks for this using leiningen 2?
15:34seangroveAlright, time to see if I can get testing going in cljs now
15:34seangroveI was completely defeated by it a month and a half ago, going to conquer it now
15:34FrozenlockTake cover!
15:34borkdudeI'm using java 1.6 - is it possible to add the jsr166y.ForkJoinPool as a dep via leiningen
15:40augustlany suggestions for how to "flatten" this nested structure the way I want? Really not sure how to go on about this so any suggestion is welcome :) https://www.refheap.com/paste/11346
15:41Frozenlocktechnomancy: why doesn't this throw an exception? &env and &form don't seem to be defined anywhere in your code. https://github.com/technomancy/serializable-fn/blob/master/src/serializable/fn.clj#L23
15:41augustlflattening nested structures sounds like a good fit for recursion, but I've never done something like it so not sure what to do..
15:42cemerickFrozenlock: those symbols are implicit arguments to all macros, that are not documented anywhere AFAIK
15:43cemerickWe talk about them in the book, if you happen to have it.
15:43Frozenlockcemerick: Oh! Yet more undocumented stuff!
15:43Frozenlockcemerick: the oreilly one?
15:43cemerickyeah
15:43cemerickhttp://clojurebook.com
15:43Frozenlockhprm... not yet, on my todo list :/
15:44FrozenlockOr rather on my buy-when-epub-isnt-2x-kindle-price list. :)
15:45cemerickFrozenlock: they're mentioned in some wiki pages on dev.clojure.org
15:46Frozenlock,(doc defmacro)
15:46clojurebot"([name doc-string? attr-map? [params*] body] [name doc-string? attr-map? ([params*] body) + ...]); Like defn, but the resulting function name is declared as a macro and will be used as a macro by the compiler when it is called."
15:46tomojI don't think I ever noticed ##(let [x 3] (if-let [x nil] x x))
15:46lazybot⇒ 3
15:47seangrovetomoj: Interesting, when the if-let fails, it clears its local definition of x?
15:48cemerickno new local is established if the value being bound in the if-let isn't truthy
15:48TimMcseangrove: No, it's just that the binding doesn't cover the alternative clause.
15:48greywolveanyone know how to add a project specific task in leiningen 2 ?
15:48tomoj,(macroexpand '(if-let [x nil] y z))
15:48clojurebot(let* [temp__2390__auto__ nil] (if temp__2390__auto__ (clojure.core/let [x temp__2390__auto__] y) z))
15:49TimMcThe alternative clause *is* covered by a gensym binding, though...
15:50babilencemerick: I completely agree - It's just that I expected more active development when I heard about it first. I like slow development (if bugs get fixed), but I simply had the impression that dnolen lost interest a little and moved on to new lands (logic, cljs, ...) - But everybody has to decide what to spend time one :)
15:56borkdudehmm, it would be nice if there would be also as-?> in 1.5
15:57tomojsome-as-> ?
15:58borkdudetomoj ah, -?> became some->?
15:58technomancybabilen: he said he would like to pick it up and fix the seq/vector disparity, but it's just not a priority right now
15:59tomojborkdude: yes
15:59borkdudetomoj then yes
15:59technomancygreywolve: echo tasks > .lein-classpath; mkdir -p tasks/leiningen; touch tasks/leiningen/mytask.clj
16:05greywolvetechnomancy: thanks! i added .lein-classpath to my tasks/leiningen instead ;p
16:05greywolvegot confused ;p
16:06greywolvetechnomancy: is there a difference between eval-in-leiningen and eval-in :leiningen ?
16:06greywolvewell eval-in-leiningen true
16:13technomancygreywolve: the latter is the lein1 way to specify it, but it's still supported for backwards-compatibility
16:14greywolvetechnomancy: thank you ;)
16:14technomancythat's not what you want if you just want to store a task in your project though
16:16seangroveSo, trying to follow the advanced lein-cljsbuild example project, I can't get tests to run properly
16:18seangroveTrying to run `lein trampoline with-profile test cljsbuild test` tries to compile the test-source file ('./test-src/zenbox/core/test/main.cljs'), but that's trying to :use functions provided by my clojurescript source
16:18seangroveLet me type this out more coherently...
16:34xeqicemerick: is there a way to alter an identity in friend, such as when a user changes their username?
16:34seangroveOk, so here's the rub: https://www.refheap.com/paste/11352
16:36seangroveIn my test code, it's trying to :require a ns from my main cljs source code, but that code isn't in the classpath for the test profile
16:36seangroveThat's not a problem for the advanced example project for some reason though: https://github.com/emezeske/lein-cljsbuild/blob/master/example-projects/advanced/project.clj#L70
16:37seangroveRaynes: Any thoughts on having multi-section pastes? I'd like to separate individual files and the console output
16:38seangroveI don't think I want the main source-code in the source-path though, because then it'll be (presumably) compiled into my source code
16:38seangroveErr, testing code
16:38seangroveThe testing code should be loaded *alongside* the to-be-tested source code, and interact with it externally
16:39seangroveOr maybe not, I have no idea
16:40cemerickxeqi: sure, just put an atom in e.g. :roles (or whereever else you want to be able to mutate the identity)
16:40cemerickI need to generalize the authz stuff to make it easy to account for such things
16:41cemerickmaybe implicitly deref'ing....? :-/
16:45abp(mapcat calculate-deps (graph/->graph graph))
16:45abpnope, not the repl. :D
16:56seangroveIf I constantly get "java.lang.RuntimeException: java.lang.OutOfMemoryError: Java heap space" when compiling, what's that usually a sign of?
16:57abpseangrove: Not enough memory?
16:59seangroveWhen compiling clojurescript on a 8gb machine?
16:59seangroveMuch more likely I'm doing something stupid
16:59seangroveI see yoklov had the same problem here, but no solution http://clojure-log.n01se.net/date/2012-04-15.html
17:05bbloomseangrove: can you compile subsets of your codebase & monitor memory usage? you may be able to binary search to figure out which namespace is causing memory to balloon
17:05erdoshi
17:09MorgawrI have a stupid question.. pardon me for this but... I am in a lein repl and I have loaded some file using (require 'myfile), now if I modify that file and re-launch the require command in the REPL the newly added stuff (a bunch of def) aren't recognized
17:10MorgawrI need to close and re-open the repl
17:10Morgawris there a way to force the refresh?
17:10bbloom(require 'myfile :reload)
17:10Morgawroh.. derp, thanks!
17:11erdosthanks
17:11bbloomwhen it doubt, ##(doc require) !!
17:11lazybot⇒ ------------------------- clojure.core/require ([& args]) Loads libs, skipping any that are already loaded. Each argument is either a libspec that identifies a lib, a prefix list that identifies multiple libs whose names share a common prefix, or a flag t... https://www.refheap.com/paste/11355
17:11hyPiRionor :reload-all
17:14xeqicemerick: hmmm, that might work for roles. I was more thinking about the username, but I'll have to go back and comb throught to understand the name -> map (which includes the name) interaction
17:15tmcivergfredericks: cute. Do you know your Erdős number?
17:19gfrederickstmciver: nope :/ I expect it's finite though.
17:21tmcivergfredericks: You a mathematician? I've perused your blog until my head began to hurt. :) I figure you're a mathematician or you *really* like math.
17:21gfrederickstmciver: the latter; just an amateur
17:21gfredericksI have a CS publication though
17:21gfredericksthus the finiteness
17:22tmciverAh, cool.
17:22gfrederickswriting my advisor right now to see if he knows his number :D
17:22hyPiRionoh, interesting
17:23TimMcgfredericks: I have "My Brain Is Open" in front of me right now. Fun book.
17:24gfredericksTimMc: I've never heard of it
17:24TimMcA book on Erdős.
17:25gfredericksmore Erdös or more math?
17:26gfredericksErdös number is officially unknown. :(
17:26gfredericksthere's an author search that google leads to, but it's locked
17:29brainproxyneed a way to allow website user to effectively create rich text email bodies which will be stored and mailed periodically (e.g. after a successful transaction) from the Clojure-based web server
17:30brainproxywas thinking I could embed CKEditor in a web page, convert HTML -> RTF using Apache FOP, then an email library to fire off the message
17:30brainproxyi mean the basic ideas all seem clearcut, but I was wondering if someone here has done such a thing, knows of an example I could study, etc.
17:34akhudekbrainproxy: why convert to rtf?
17:34akhudekrich email is html
17:34brainproxyakhudek: good point, maybe I could just send out html emails
17:35brainproxyoh, okay, shows what I know :p
17:35akhudeksee postal
17:35akhudekand think a bit about xss
17:35brainproxyof course
17:35brainproxywell luckily, only the site admin would use it, and i would double-check the POSTS and strip out any script tags
17:35brainproxyif there were any
17:36akhudekhttps://www.owasp.org/index.php/OWASP_Java_HTML_Sanitizer_Project
17:36brainproxythis is for a donations site, and the admin-user wants a way to periodically update the automated "thank you" emails
17:36akhudekbelieve it was born from one of the google security guys
17:37brainproxynice, thanks so much!
17:40akhudekhttps://github.com/drewr/postal
17:41brainproxyyep, just checking that out
17:41brainproxylooks awesome
17:41brainproxyexactly what I need
17:41akhudekif you want to do embedded images, it's a bit tricker
17:41akhudekbut still doable
17:42brainproxynah, I think she can live with basic rich formatting
17:42akhudekshould be pretty easy then :-)
18:04seangroveJesus christ, got automated testing in clojurescript + phantomjs working, though it's a bit kludge right now. Anyone have their clojurescript tied into a CI server?
18:07erdoshi! i am working on my very first clj project with incanter. too bad "lein run -m" gives me: "Exception in thread "main" java.lang.ClassNotFoundException: clojure.set, compiling:(incanter/core.clj:2018)"
18:07erdoscould you please explain me what does it mean?
18:19gfrederickserdos: that's a pretty weird one; my foggiest guess is it might be an odd effect of something wrong in your own (ns) declaration
18:20erdosgfredericks: thanks
18:21gfrederickserdos: if your code is pretty minimal you could share it in a gist
18:25erdosgfredericks: here you are with the source (20 lines): https://gist.github.com/anonymous/4969185 thanks in advance
18:29technomancyerdos: probably the version of incanter assumes clojure 1.2
18:29technomancyin 1.2 clojure.set was loaded automatically
18:31gfredericksah; so try to require clojure.set first
18:32technomancyor get a newer incanter slash report an incanter bug report
18:36erdostechnomancy: THANK YOU! it works for me with clj 1.3.0 and inc 1.3.0
18:51augustlhmm, I have a list of functions that I want to call threading macro style. Can I use the threading macro for this? Or do I need to write my own threading macro impersonator?
18:51gfredericksaugustl: would apply comp work?
18:51gfrederickswith or without reverse
18:52augustlgfredericks: looking up comp
18:52gfredericks,((apply comp [inc inc #{/ 2)]) 7)
18:52clojurebot#<ExecutionException java.util.concurrent.ExecutionException: java.lang.RuntimeException: Unmatched delimiter: )>
18:52gfredericks,((apply comp [inc inc #{/ % 2)]) 7)
18:52clojurebot#<ExecutionException java.util.concurrent.ExecutionException: java.lang.RuntimeException: Unmatched delimiter: )>
18:52gfredericks,((apply comp [inc inc #(/ % 2)]) 7)
18:52clojurebot11/2
18:52gfrederickssorry I'm not very good at clojure
18:52augustlhmm, I just realized I don't want threading macro style. I want the return value of calling the first function with the next, but stop as soon as a function returns nil
18:53gfredericksnot too hard to do with reduce
18:53gfredericksI'm assuming you have this list at runtime; else you can just use some-> I would think
18:54gfredericks(reduce (fn [x f] (if (nil? x) (reduced x) (f x))) init-val funcs)
18:54augustlthe list is actually compile time so I could macro it up
18:55gfredericksup to you
19:11lynaghkDoes anyone have a suggestion for a clean way to use core.memoize's TTL cache ONLY for certain return values.
19:11lynaghkI.e., I'm putting it in front of another service and I don't want it to cache upstream 500 errors and such
19:12gfredericksI'd be surprised if you didn't end up having to do a custom caching policy
19:12gfredericksbut I'm not familiar with the two libs in detail
19:17tomojlooks like you have to define a new TTLCache :(
19:21Raynesseangrove: Multipastes is a planned feature. I'm not adding features or fixing bugs at the moment until I finish moving to laser (which won't take very long if I can motivate myself to do it).
19:21Raynesseangrove: The idea is that pastes would be linked so that each paste would be standalone, but would also appear alongside the paste it is linked to.
19:21RaynesBecause I'm purposely avoiding the 'file' connotation that Github uses.
19:22RaynesA paste should be a unit, not a big collage of units OR a unit.
19:22RaynesThey aren't mutually exclusive.
19:22RaynesI'm so damn innovative and thoughtful.
19:22gfredericksa paste should be a whole damn git repo
19:23lynaghkgfredericks, tomoj: alas.
19:23gfrederickswith a wiki
19:23tomojit's strange core.memoize redefines core.cache's through
19:23tomojand gets rid of the wrap-fn
19:23tomojreally, hard codes it
19:24tomojbut that wouldn't have helped anyway
19:24abpRaynes: Move to graphs :P
19:24gfrederickslynaghk: or if you want the bestest of codes, wrap your inner function in a function that throws exceptions on the values you don't want cached, then wrap the memoized function with code to catch and unwrap the exceptions. it's perfect!
19:25Raynesabp: That's funny because it *is* a graph, and where I work we have our own graph database (Jiraph).
19:25Raynesabp: Yet I use mongodb. ;)
19:25abpRaynes: https://www.refheap.com/paste/11358
19:27abpRaynes: yeah, pastes have no genealogy :P
19:29gfredericksI wonder how idiomatic putting :type metadata on the ex-info map would be
19:29Raynesabp: Your father's paste.
19:29Raynes!
19:31abpRaynes: Drop all work, I need that feature now! I want to inherit some good pastes!
19:43AtKaaZis there an idiomatic/easy way of returning (+ a 4) or 4 if a is nil ?
19:43gfredericks,((fnil + 0) nil 4)
19:43clojurebot4
19:44gfredericks,((fnil + 0) 15 4)
19:44clojurebot19
19:44RaynesI think you guys are pretty fine peoples.
19:44AtKaaZthat's pretty epic, thanks gfredericks
19:45gfredericksAtKaaZ: that's maybe the first time in my life I've thought of fnil.
19:45AtKaaZ:D
19:45Raynesamalloy speaks in fnils.
19:45gfredericksif it can't be expressed by combining fnil with juxt then you have no business doing it in the first place.
19:46AtKaaZgfredericks: can you show an example of that?
19:46gfredericksno
19:46AtKaaZok:))
19:48gfredericks(let [append-to-self (comp (partial apply conj) (juxt (fnil identity []) identity))] (map append-to-self [[] [1] [2 3] nil]))
19:48gfredericks,(let [append-to-self (comp (partial apply conj) (juxt (fnil identity []) identity))] (map append-to-self [[] [1] [2 3] nil]))
19:48clojurebot([[]] [1 [1]] [2 3 [2 3]] [nil])
19:48seangroveWhat would be the difference between: `lein trampoline test` and `lein test`
19:48gfredericksthere look what you made me do
19:48seangroveOne runs the tests, the other appears to but doesn't output anything
19:49callenbotgfredericks: you really like being Quickdraw McGraw at these snippets.
19:49gfrederickscallenbot: it's the only thing that keeps me from contemplating my own mortality
19:50gfredericksAlso I'm practicing to someday answer a job posting that asks for somebody to implement a moderately complex algorithm in the next five minutes
19:51AtKaaZ,(apply (fnil + 0) 1 '(nil))
19:51clojurebot#<NullPointerException java.lang.NullPointerException>
19:52AtKaaZah I got: NullPointerException [trace missing]
19:52gfredericksdon't apply it, just call it
19:52AtKaaZbut I kinda wanna put it in a function
19:52gfredericksoh I see that ought to have worked
19:53gfredericksyour args are reversed what I expected
19:53AtKaaZ,(apply + 1 '(nil))
19:53clojurebot#<NullPointerException java.lang.NullPointerException>
19:53gfredericks,(apply (fnil + 0 0) 1 '(nil))
19:53clojurebot1
19:53gfredericks^ that might do what you want
19:53AtKaaZoh right, + does that, i forget
19:53gfredericks,((apply fnil + (repeat 0)) [2 7 nil 8 nil nil 2])
19:54AtKaaZ,(apply (fnil + 0) 1 2 nil)
19:54gfredericks&(apply (apply fnil + (repeat 0)) [2 7 nil 8 nil nil 2])
19:54lazybotjava.lang.OutOfMemoryError: Java heap space
19:54AtKaaZlol?
19:54AtKaaZ&(apply println 1 2 '(nil))
19:54lazybot⇒ 1 2 nil nil
19:55gfredericksoh weird
19:55gfredericksfnil only has three arities
19:55clojurebotExecution Timed Out
19:55clojurebot3
19:56hyPiRionI like how clojurebot times out, whereas lazybot ends out of memory.
19:56gfredericks&(apply assoc-in (repeat :foo))
19:56lazybotjava.lang.OutOfMemoryError: Java heap space
19:56gfredericksit's really weird that it can't throw an arity exception there
19:57gfredericksespecially given that finite arities are limited to 20 or so aren't they?
19:57AtKaaZdoes it try to realize the infinite lazyseq first?
19:57gfrederickspresumably
19:57AtKaaZor something like count on it?
19:57tomoj&(apply + (repeat 40 1))
19:57lazybot⇒ 40
19:58tomojhow could it throw an arity exception?
19:58tomojcount the args, compare to some arbitrarily chosen number?
19:58gfrederickstomoj: how does it throw an arity exception on ##(apply assoc-in (repeat 40 1))
19:58lazybotclojure.lang.ArityException: Wrong number of args (21) passed to: core$assoc-in
19:58AtKaaZapply is special i think
19:58AtKaaZ##*clojure-version*
19:59AtKaaZ##(println *clojure-version*)
19:59lazybot⇒ {:major 1, :minor 4, :incremental 0, :qualifier nil} nil
19:59tomojoh, I see what you mean
19:59AtKaaZ,*clojure-version*
19:59clojurebot{:interim true, :major 1, :minor 4, :incremental 0, :qualifier "master"}
19:59tomojI forgot assoc-in is not variadic
19:59tomoj(grr)
19:59gfredericksyeah that's why I picked it
20:00gfrederickshard to think of a fixed-arity function off the top of your head :)
20:01tomojlooks like args past 20 are turned into an array
20:01gfrederickssurely not all the time
20:01AtKaaZ,(apply (fnil + 0 0) 1 2 '(nil))
20:01clojurebot#<NullPointerException java.lang.NullPointerException>
20:01gfredericks,(apply (fn [& args] (apply + (take 50 args))) (range))
20:02clojurebot1225
20:02gfrederickstomoj: ^ it clearly didn't in that case
20:03AtKaaZ,(apply (fnil + 0 0 0) 1 '(nil 1 nil))
20:03clojurebot#<NullPointerException java.lang.NullPointerException>
20:04gfredericksAtKaaZ: so you want to allow nils anywhere?
20:04tomojhmm
20:04AtKaaZit was fine before, but since I wanna generalize it
20:04gfredericks,(->> [nil 1 nil] (filter identity) (apply + 1))
20:04clojurebot2
20:05tomojoh, RestFn handles that?
20:05gfredericksI have no idea :/
20:05tomoj&(class (fn [& args]))
20:05lazybot⇒ sandbox22420$eval25950$fn__25951
20:05tomoj&(supers (class (fn [& args])))
20:05lazybot⇒ #{clojure.lang.IObj java.io.Serializable java.util.concurrent.Callable java.lang.Object clojure.lang.AFunction java.lang.Runnable clojure.lang.IFn java.util.Comparator clojure.lang.IMeta clojure.lang.RestFn clojure.lang.AFn clojure.lang.Fn}
20:06gfredericks&(supers (class (fn [a])))
20:06lazybot⇒ #{clojure.lang.IObj java.io.Serializable java.util.concurrent.Callable java.lang.Object clojure.lang.AFunction java.lang.Runnable clojure.lang.IFn java.util.Comparator clojure.lang.IMeta clojure.lang.AFn clojure.lang.Fn}
20:06gfredericksthat's an interesting thing to note
20:06tomojso assoc-in isn't RestFn
20:06tomojso it tries to put the remaining args into an array
20:07gfredericksI wonder if there are real edge-cases to worry about with more than 20 args but not RestFn
20:07AtKaaZnice, thanks gf3
20:07AtKaaZgfredericks xD
20:07gfredericks(inc gf3)
20:07lazybot⇒ 1
20:08AtKaaZlol
20:10callenbotgfredericks: don't think too hard.
20:11tomojeven 20 args.. jesus
20:11tomojautogenerated code?
20:11tomojI dunno
20:24AtKaaZwas there a lib that would expect passing maps as function params instead of clojure params something like {:param1 value1 :param2 value2}
20:24seangrovearohner: OOM killer :P
20:26AtKaaZcause I'm stuck with the order of params and I want to skip specifying some params when doing the call without assigning nil to them
20:26AtKaaZsomething like: (defn x [ & {:a :b}] ... )
20:27gfrederickstomoj: clojure won't compile function forms with more than 20 args, even if you emit it from a macro
20:29Rayneslazybot grew a new feature, if anyone cares.
20:29Raynes$metacritic movie Being John Malkovich
20:29lazybotCritics: 90; User: 8.3 - http://www.metacritic.com/movie/being-john-malkovich
20:29RaynesAlso works for 'xbox', 'ps3' and 'pc' (for the various game platforms).
20:29AtKaaZ$metacritic movie the man from earth
20:30lazybotI'm a little drunk. Can't find my keys.
20:30RaynesShould also work for albums but doesn't yet.
20:30RaynesThat does not appear to be on metacritic.
20:30caleb_smith$metacritic movie Pirates of Silicon Valley
20:30lazybotI'm a little drunk. Can't find my keys.
20:30AtKaaZ$imdb the man from earth
20:30AtKaaZ=)
20:30Raynes:p
20:31Raynescaleb_smith: That one isn't there either. :o
20:31caleb_smithEven Bill Gates likes that one
20:31tmciver$metacritic xbox call of duty
20:31lazybotCritics: ; User: - http://www.metacritic.com/game/xbox-360/call-of-duty
20:32caleb_smith$metacritic xbox portal 2
20:32lazybotCritics: 95; User: 8.3 - http://www.metacritic.com/game/xbox-360/portal-2
20:32RaynesHrm. They return different things for games that aren't found than they do for movies it appears.
20:32Raynes$metacritic movie some random movie that doesn't exist
20:32lazybotI'm a little drunk. Can't find my keys.
20:33RaynesThey do throw a 500 for them IIRC.
20:33seangrove$metacritic Supreme Commander 2
20:33lazybotI'm a little drunk. Can't find my keys.
20:33seangroveBah :P
20:33tmciver$metacritic xbox when the hell is portal 3 coming out?
20:33lazybotCritics: ; User: - http://www.metacritic.com/game/xbox-360/when-the-hell-is-portal-3-coming-out?
20:33Rayneslol
20:33seangrove$metacritic pc Supreme Commander 2
20:33lazybotCritics: 77; User: 6.2 - http://www.metacritic.com/game/pc/supreme-commander-2
20:33seangroveNice!
20:34RaynesFunfact: their 404 is a 200.
20:34Raynes-.-
20:34RaynesShould say 404 - Lies
20:34seangrovehah
20:35ChongLihow about ISPs whose DNS answers NOERROR when it should be NXDOMAIN
20:39Raynes$shell git pull
20:39lazybotUpdating c7d4aa4..5798e5b Fast-forward src/lazybot/plugins/metacritic.clj | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-)
20:39Raynes$reload
20:39lazybotReloaded successfully.
20:39Raynes$metacritic xbox call of duty
20:39lazybotI'm a little drunk. Can't find my keys.
20:39RaynesThat's better.
20:39AtKaaZhaha that's pretty epic
20:40musicalchairno tests? =P
20:40RaynesHaha, tests.
20:40Adeon$metacritic pc clojure
20:40lazybotI'm a little drunk. Can't find my keys.
20:40musicalchair;O
20:40callenbotI need to make a shim for integrating casperjs into Clojure apps.
20:42callenbotwhat's the name of that thing like bikeshed that makes code suggestions?
20:43callenbotkibit, n/m
21:00seangrovecallenbot: What do you use casperjs for?
21:02callenbotseangrove: functional testing.
21:02callenbotI didn't know there were any other uses for it.
21:02seangroveJust saw it while finally getting phantomjs to work with my cljs codebase, wasn't sure about its use-case
21:03akhudekcallenbot: do you use selenium?
21:03callenbotakhudek: as little as possible.
21:03callenbotakhudek: casperjs is 10,000% nicer.
21:03seangroveJust about to ask that, going to hook up Webdriver/Selenium2 later tonight
21:03seangroveHow so?
21:04callenbotseangrove: try casper, then use selenium.
21:04callenbotseangrove: going back to selenium after having used casper was like pissing blood.
21:04seangroveJust looking through the documentation now, it looks nice, but the approach seems limited
21:04callenbot"limited". I'd love to hear what's missing.
21:04akhudekit seems casper only does webkit, right?
21:04seangrovecallenbot: Heh, I worked at Sauce Labs for a few years, definitely familiar with Selenium and all its horrid shortcomings
21:05seangroveYeah, that's the first thought, it'll be limited to phantom to begin with
21:05seangroveBut if it ties into the webdriver protocol, it could drive the other browsers directly... but then it'd be Selenium2
21:05akhudektesting web apps is a major pain
21:06callenbotit can be.
21:12AtKaaZhow can I (apply macrohere (rest params)) when I cannot modify the macro ie. it's a lib
21:12gfredericksAtKaaZ: that's a major reason why macros are awkward :)
21:13bbloomAtKaaZ: the only way really is eval, which is probably a terrible plan. much better to ensure there is a -fn variant of the macro, and even then it's probably not really great
21:13seangroveCould you (defn wrapped-macro [args] ...) (apply wrapped-macro) ?
21:13gfredericksusually you end up making your own macro, but that can't work if the length of params is determined at runtime
21:13AtKaaZI see that if the lib would somehow decide in the future to change between macro and fn (or fn to macro) my code doing `apply` (or not doing it) would fail
21:14AtKaaZseangrove: i think, can't take value of macro
21:14AtKaaZor I don't understand what you meant xD
21:15seangroveAtKaaZ: Yes, please ignore it, I realized it wouldn't work
21:15ChongLiAtKaaZ: macros don't have a value and don't operate on values
21:15Raynesweavejester: What are the rules that make lein-ring reload my source files? It doesn't seem to do it even if lein_no_dev isn't set.
21:16ChongLithey merely operate on forms
21:16AtKaaZthey be ghosts:) &(declare ghost)
21:17weavejesterRaynes: It reloads any file changed in the src directory.
21:17AtKaaZ,(declare ghost)
21:17clojurebot#<Exception java.lang.Exception: SANBOX DENIED>
21:17Raynesweavejester: This does not appear to be the case for me.
21:17weavejesterRaynes: Is it inconsistent, or consistently not reloading? Do you expect it to reload instantly, or when the next request hits?
21:18RaynesIt had never reloaded ever under any circumstances since I started using it several versions ago.
21:18RaynesI just thought I had a setting wrong, but all it appears to want is for LEIN_NO_DEV to not be set and I'm not setting. I guess maybe something else is.
21:18RaynesI dunno what that'd be though.
21:18RaynesI'll print the environment in my app and make sure.
21:19weavejesterRaynes: You're using lein ring server, right?
21:19RaynesYup
21:19weavejesterRaynes: You can also add :auto-reload? true
21:19AtKaaZbbloom: i'm trying to find a way with eval, not seeing it yet...
21:19RaynesCool. I'll try that too.
21:19weavejesterRaynes: Which forces auto reloading
21:20bbloom(eval (list* `the-macro args))
21:20weavejesterRaynes: Is your src directory in "src"?
21:20RaynesYeah.
21:20Raynesweavejester: Confirmed LEIN_NO_DEV is unset. I'll try to do the auto-reload thing.
21:20bbloomAtKaaZ: eval & list* is basically macro apply :-P
21:21AtKaaZbbloom: oh that's nice, I gotta try it
21:21marcelluselgatoRaynes: this probably isn't helpful, but I fixed that same problem yesterday by upgrading to lein-ring 0.8.2 from 0.8.0
21:21weavejesterRaynes: Well, the default for auto-reloading is true if LEIN_NO_DEV is not set.
21:21weavejesterYeah, make sure you have the latest version
21:21marcelluselgatonever figured out what was causing it
21:22RaynesI had 0.7.1.
21:22RaynesWill try upgrading.
21:23RaynesNo dice.
21:23weavejesterRaynes: You're on 0.8.2?
21:23RaynesYeah.
21:24weavejesterIt should reload when you send a request.
21:25RaynesYep, won't work. :\
21:25RaynesOh.
21:26Raynesweavejester: https://github.com/Raynes/refheap/blob/develop/project.clj#L19
21:26RaynesIf I had money, I'd pay you for dealing with my idiocy for 10 minutes.
21:27RaynesWell, I have money, but I don't want to pay you for 10 minutes of idiocy.
21:27Raynes:p
21:28RaynesYeah, the problem was between the keyboard and my chair.
21:28RaynesSorry.
21:29weavejesterRaynes: You had :auto-reload? set to false? That would do it :)
21:29RaynesYup.
21:29marcelluselgatohah
21:29weavejesterIt's nice to know that it's not a problem with the reload stuff. There's still a few issues with it.
21:30abpYeah, when I get a stacktrace and hit reload I get the site, functioning in the pre-exception state..
21:32callenbotdoes anybody know of anything like ipdb or pdb for Clojure? Ritz doesn't seem to fit the bill afaict.
21:40seangroveSo noir is dead, and compojure is the recommended migration path, right?
21:40RaynesYes.
21:40RaynesAnd lib-noir, especially if you used noir before.
21:41AtKaaZthanks bbloom, i'm on my way to using that eval+list* after I'm done failing to make a macro which would handle both cases depending on what was passed fn or macro
21:42bbloomAtKaaZ: *sigh* don't take me for that. go patch the up stream library to expose that functionality as a fn instead of a macro
21:42bbloom:-P
21:43AtKaaZbbloom: it's timbre/log, is a macro :) but I wanna use that eval+list* so for that i thnak
21:43bbloomsurely there is no reason timbre can't expose a function version of it's log function?
21:44AtKaaZI could wrap the macro into a function in my lib, if that makes any sense
21:45AtKaaZoh wait, that's what I was trying to do in the first place=)
21:47bbloomi'm looking at timbre now and i'm confused why i'd want all my log expressions to be macros.. that seems like a bad idea to me....
21:47bbloombut i don't like conditionally removing logging at compile time from C programmers either
21:48bbloomi think log levels should be a runtime config.... but that might just be me...
21:48bbloom*shrug*
21:48AtKaaZyeah that sounds good to me, to can do that at runtime
21:50AtKaaZwell actually, I might not need to use timbre for logging, since I'm half way using my own function to return the call position of itself where the call is made, i only need the date and loglevels hmm
21:50AtKaaZbut I still need an epply macro which does apply for fn and eval+list* for macros
21:54amalloybbloom: even if log levels are purely runtime, you want log to be a macro
21:55amalloyso that (log (some expensive calculation)) can check the log level before doing it
21:56AtKaaZis there a cross between macros and functions that would do that?
21:56AtKaaZlike a hybrid
21:56AtKaaZso you don't get the can't take value of a macro
21:56AtKaaZbut the params aren't evaluated before getting in
21:57bbloomamalloy: eh, i don't think i've ever encountered an expensive log statement
21:57AtKaaZi guess you could always just put them in a list and pass the list
21:58amalloyAtKaaZ: whatever problem you are hoping to solve by using eval to call a macro at runtime, there is a solution that is better
22:00AtKaaZamalloy: i'm trying to call timbre/log with a list of params which I get from a function fn [ & params] but I need to pass them as if via apply
22:01AtKaaZand i needed that to be a function because I pass it to some other function which uses it as a print function
22:01AtKaaZbut i guess I could just macro that function which expects a function, i can't think
22:02AtKaaZI just don't want too many macros if they can be functions
22:04gfredericksmacros beget more more more macros
22:05AtKaaZi need a macro that can take anything and return what it is ie. :macro :fn , is there such thing already?
22:06amalloyhaving never heard of timbre before, and now glancing over its source, i would not recommend using it. it doesn't look well thought out
22:06AtKaaZand locals evalled :)
22:06AtKaaZi have something already but it doesn't eval locals, so i can't pass it locals or function params
22:07AtKaaZlike: (#(macro? %) defn)
22:07gfrederickswell it definitely wouldn't work as a function like that
22:07gfredericksthat's a "can't take value of macro" error no matter what that function does
22:07AtKaaZyeah you're right
22:08gfredericksthere are other things I could say but it seems more likely this is a "why on earth do you want to do that in the first place" situation
22:08AtKaaZ=))
22:09AtKaaZexperimenting i guess, but I could use it in this case with epply, need to check if whatever i'm passed is a macro or not(ie.function)
22:10gfredericksepply is your macro version of apply?
22:10AtKaaZyes, but should handle both cases
22:10gfredericksa) I don't think you'd have to distinguish, b) I can't see why epply would be useful
22:10AtKaaZbut don't give me the code if you already have it lol i kinda wanna do it myself xD
22:10gfredericks(epply defn [a b c]) == (defn a b c)
22:11AtKaaZyea
22:11amalloygfredericks: epply could be like bright colors in nature: stay away, i'm dangerous!
22:11gfredericksso may as well write the second one
22:12AtKaaZbut I'm in a fn [& [level :as params]] (epply timbre/log level (rest params))
22:12gfredericksAtKaaZ: and that will never work
22:12AtKaaZthat (rest params) is killing me
22:12AtKaaZwhy not
22:12gfredericksbecause macros (like epply) run at compile-time and deal with code, not the value
22:12gfredericksso (rest params) is a list of two symbols
22:12gfredericksnot the params to your function
22:13AtKaaZoh i see
22:13AtKaaZeval then?
22:13gfredericksif you must
22:13AtKaaZbut I wanted to generalize it
22:13AtKaaZcan't I eval those in the macro? and still work
22:13gfrederickswhat do these params do?
22:13AtKaaZeven though they are locals?
22:13gfredericksno
22:14gfredericksit's still compile time; the values don't exist yet
22:14AtKaaZthey are like the text message "a" "B" "msg"
22:14AtKaaZbut I'm returning it quoted
22:14gfrederickswhat do they mean to timbre?
22:14AtKaaZtimbre/log :info "showthismsg"
22:14gfrederickswill it just join them together with str?
22:14AtKaaZtimbre/log :info "showthismsg" "concatenate" "more"
22:14AtKaaZoh yeah that
22:15gfredericksso why don't you just do that and then pass the single string to timbre?
22:15AtKaaZoh i see what you mean xD
22:15gfredericksmost decent macros don't force you to use eval in order to make use of them
22:15AtKaaZbut what if I want epply in the future for a different macro
22:15gfredericksthen don't use that macro it's a terrible macro
22:15amalloyAtKaaZ: then in the future you'll be just as wrong as you are now :P
22:16AtKaaZ:)
22:16AtKaaZamalloy: "wrong" doesn't tell mee anything
22:17gfredericksmacros aren't meant to be applied
22:17gfredericksthe only way to do it is with eval; which is "wrong" in some senses
22:17AtKaaZis it because it compiles at runtime?
22:20AtKaaZok i'm definitely going with join, thanks gfredericks
22:20gfredericksthat's one reason, yeah
22:20gfredericksAtKaaZ: np; good luck
22:22AtKaaZi don't know why I tend to want to abstractize even the things which I'm likely to use only once; but i kinda like it, though maybe not the process of doing it since it keeps branching and i forget from where i started, which reminds me, need an ide to can do trees like this
22:22AtKaaZlike Tree Style Tab addon for firefox instead of firefox normal tabs
22:26AtKaaZis there some way to keep bookmarks maybe? in emacs
22:26gfrederickswhat would that mean? positions in files?
22:27AtKaaZlike save session as it is, while it follows that I try to implement some requirement and then get back to what the session was
22:27AtKaaZnot just position in current file
22:27gfredericksyou would probably want that to integrate with git? it's already way complicated
22:31caleb_smithyeah, and if git seems to go beyond what you need (just something fast, not worth a branch), you could always try out 'git stash' or using gists
22:36AtKaaZi usually find myself wanting a tree-like history while initially starting from root, like to do X i need Y and Z then i go into Y then i need G then i go into G and need K and L and I do those 2 get back to G out of it and i see for Y I need some more so sibbling of G(which is now completed) I need H and so on, eventually i get back to X; but I may not wanna commit each of these steps, likely
22:36AtKaaZX is a commit when done
22:37AtKaaZdone=completed
22:37cliftonis there a difference between (defn- ...) and (defn ^:private ...)? I was reading some patches on Clojure's JIRA and I saw the latter used a few times
22:38RaynesNo. I prefer the latter because it's more consistent with the rest of Clojure.
22:39RaynesThey won't be adding new '-' private variants of new defing macros, so you end up doing ^:private with some things and defn- with defn and it's weird.
22:39cliftonk, i see the former more often when im browsing others' libraries on github and the latter when looking at clojure source
22:39cliftonah, that's a good explanation
22:39cliftonmakes perfect sense
22:39RaynesYou can certainly use defn- if you prefer, of course. I just prefer the other version.
22:42amalloy^:private is also a lot "louder". it's very clear that the function you're looking at is private
22:42amalloydefn- can easily get lost while you're scanning
22:42RaynesThis is true.
22:42cliftonyeah, it is more clear
23:22cliftona little off topic, but is there anything analogous to CtrlP for emacs fuzzy find-in-project?
23:26AtKaaZ/quit "wrong" is my middle name