Re: alternate syntax

2009-02-23 Thread Fogus
> Removing parens doesn't solve the problem with (+ 1 2). For writing out math > formulas a macro that allows infix notation would be useful (and I'm pretty > sure I've seen at least one). A long time ago I worked for a company that for reasons I will not go into now, wanted to distribute a modif

Re: You know you've been writing too much Clojure when...

2009-06-03 Thread Fogus
Question: You know you've been writing too much Clojure when... (dorun Question) -m --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Not

Re: multimethods

2009-06-17 Thread Fogus
> would it be possible for routines to check to see if they are not > using multimethod-ness, and in that case be performance optimized, yet > have the syntax for them all be somehow less different? There is certainly a case for that, but (correct me if I'm wrong), but one of the underlying philo

Re: What are people using Clojure for?

2009-06-19 Thread Fogus
I've been finding it difficult to work Clojure into the mix at my job due to its Lispiness, therefore my experiences have been isolated to free time hacking. However, I hope to make some headway on getting buy-in on using clojure.jar -- specifically the immutable structs and the Ref class. I was

Clojure Golf, episode 1

2009-08-14 Thread Fogus
Wanna play golf? (defn filter-collecting [predicate collector & lists] (lazy-seq (loop [lists lists out []] (if (empty? (first lists)) (reverse out) (let [heads (map first lists)] (if (apply predicate heads) (recur (map rest lists) (cons (apply collecto

Re: Clojure Golf, episode 1

2009-08-14 Thread Fogus
> (defn filter-collecting [predicate collector & lists] >   (for [v (apply map vector lists) :when (apply predicate v)] (apply > collector v))) This is very nice. It's short, sweet, and actually describes the functionality. -m --~--~-~--~~~---~--~~ You received

Re: Generation of random sequences

2009-08-25 Thread Fogus
A quick and dirty way would be to use a map as your intermediate storage with your generated numbers as keys and some constant as their assoc'd value. Once you've populated said map with the proper number of entries (keeping track of clashes along the way) then get a sequence using `(seq (.keySet

Re: Generation of random sequences

2009-08-25 Thread Fogus
> Why not just use a HashSet rather than a SortedSet to begin with? Yes, that is clearly better. -m --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@goog

Re: clojure vs scala

2009-08-27 Thread Fogus
RE (1) --- Agreed on all points. Clojure seems to have captured a large share of excitement and the effort put into the community documentation [1] is staggering and only set to get better. I liken the excitement behind Clojure to that behind Ruby (minus the drama). More and more people are

Qi in Clojure (Shen) project underway

2009-08-31 Thread Fogus
It looks like there is a thrust to rewrite Qi (http:// lambdassociates.org) in Clojure. With the impending departure of Dr. Mark Tarver the effort could use some help from the Clojure community. There has been discussion in the past few weeks at http://groups.google.co.uk/group/Qilang. Likewise

Clojure Golf – Episode 2: Largest Prime Factor

2009-09-09 Thread Fogus
;; largest prime factor (defn lpf "Takes a number n and a starting number d > 1 and calculates the largest prime factor of n starting at number d. usage: (lpf 364362978 2) => 8675309" [n d] (if (> d n) (- d 1) (recur (#(if (zero? (rem % d)) (recur (/ % d))

Re: Cells for Clojure

2009-09-11 Thread Fogus
Even more information here: https://www.assembla.com/spaces/clojure-contrib/tickets/19-Re-add-auto-agent-clj -m --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to cl

Re: type checking/inference?

2009-09-16 Thread Fogus
I'm pretty sure that the next generation Qi implementation is targetting Clojure. http://github.com/snorgers/Shen -m --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email

Re: Getting REPL transcript

2009-09-23 Thread Fogus
If you're running it with JLine, then the transcript is usually stored in ~/.jline-clojure.lang.Repl.history --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to cloju

Re: Neophyte question

2009-10-21 Thread Fogus
The problem is that hexchar? expects a CharSequence, but by using every? you're actually passing a Character into it. The quick fix is to change hex? to (defn hex? [s] (every? #(hexchar? (str %)) s)). However, the better solution is probably to change hexchar? to accept Characters instead -- a la

Re: Strange behavior seen when ints have leading zeros

2009-11-12 Thread Fogus
> Why does Clojure hate 8's? :-) It doesn't. By adding a leading zero you're telling Clojure that you want octal numbers. There is no number 08 in octal, instead to write the base-10 number 8 you would use 010 in octal. -m -- You received this message because you are subscribed to the Google

Re: JScheme

2009-11-17 Thread Fogus
My history man be wrong, but wasn't JScheme the original starting point for DotLisp? http://dotlisp.sourceforge.net/dotlisp.htm -m -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note tha

Re: Clojure as a first programming language?

2009-12-01 Thread Fogus
> Because simply, I couldn't appreciate functional programming until I > did a fair bit of imperative programming first. As did I, but for a different reason... the end of a long stretch of torture. Seriously though, I'm probably like many programmers (at least in the states) in that my first exp

Re: Any interest in a Nova Clug?

2009-12-16 Thread Fogus
> I'm looking into setting up a Northern Virginia Clojure User Group and > would like to know who is interested. Sounds like fun. Count me in. -m -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegrou

Re: Processing list more elegantly

2009-12-27 Thread Fogus
How about this? (defn left-total [coll] (map (fn [[l r]] [l (reduce + r)]) (for [i (range (count coll))] [(first (drop i coll)) (take i coll)]))) -m -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email

Re: Processing list more elegantly

2009-12-27 Thread Fogus
> That one is elegant, but uses more than the minimum number of > additions, one of the conditions I mentioned in the original post. (In Ah yes... *now* I see that requirement. Well, thanks for the interesting exercise in any case. :-) -m -- You received this message because you are subscribe

Re: hash literal oddity?

2010-01-18 Thread Fogus
> => {1 "this", 1 "is", 1 "strange"} The literal representation is just blasted into an array map when the number of entries are below a certain threshold (8 maybe). I think the general view is that a literal with duplicate keys is the error and to check for dups would sacrifice speed. > (into {

Re: hash literal oddity?

2010-01-18 Thread Fogus
> This uses a regular hash map. No it doesn't apparently... it uses conj instead. -m -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please

Re: Clojure Conference Poll

2010-01-22 Thread Fogus
Since Clojure is clearly an East-Coast language, I suggest DC as the most logical locale. (hopes someone buys this line of reasoning) -m -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com No

Re: Why I have chosen not to employ clojure

2010-03-21 Thread Fogus
> 1)As soon as I see the copy of this email in my "clojure mailbox", I will > unsubscribe from this mailing list, delete the clojure mailbox and I will not > be following up in any way. Really? This is not c.l.l and it's not likely that this thread would have devolved into flaming or worse. It's

Re: Question about overriding print-method for deftypes

2010-03-21 Thread Fogus
> (defmethod clojure.core/print-method ::Piece [piece writer] ???what goes > here???) (defmethod clojure.core/print-method ::Piece [piece writer] (.write writer (str (:number piece) (:letter piece)) 0 2)) Extending Piece to provide a str method can replace that ugly bit in the middle. -m --

Re: promoting contrib.string to clojure, feedback requested

2010-05-26 Thread Fogus
> Changed our mind. It helps keep the people with prerelease books   > busy. ;-) Oh great! I'm going to have to cancel my appearance on "The View" because of this. I have mentioned my gripes in the IRC, but for public view I would love better names for chomp and chop. In isolation those names a

Re: promoting contrib.string to clojure, feedback requested

2010-05-26 Thread Fogus
> "chomp" has a clear meaning to anyone who's touched Perl/Ruby/shell- > scripting. Believe me I can sympathize with this, but just because they are well- known to some doesn't mean that they are good names. On that note, just because rtrim and less make sense to me... you know the rest. :-) :f

Marginalia needs a new home

2013-08-07 Thread Fogus
right now is exactly what I need it to do. Therefore, if **you** have great ideas about making Marginalia something more and you're interested in taking over Marginalia (and lein-marginalia) development then contact me at me -at- fogus -dot- me. [1]: http://blog.fogus.me/2013/08/07/marginal

[ANN] Marginalia has a new home

2013-08-12 Thread Fogus
A few days ago I posted that I was looking for a new home for Marginalia[1] and today I am happy to say that I have found one. Gary Deer (https://github.com/gdeer81) has graciously agreed to take the reins and push Marginalia in new and exciting directions. Two projects fall under the Marginal

[ANN] Cognitect Labs' aws-api 0.8.515

2021-06-28 Thread Fogus
Cognitect Labs' aws-api 0.8.515 is now available! CHANGES - add support for calculating TTL values based on supplied Java Instant objects or Longs representing milliseconds since the epoch time #160 - new AWS service APIs availa

[ANN] New Cognitect Labs aws-api service APIs available!

2021-08-09 Thread Fogus
New Cognitect Labs aws-api service APIs available! CHANGES new AWS service APIs available (services version v811.2.958 and v813.2.963): Route53 Recovery Cluster, AWS Route53 Recovery Control Config, AWS Route53 Recovery Readiness, Amazon Chime SDK Identity, and Amazon Chime SDK Messaging REA

[ANN] New aws-api service APIs available

2021-08-20 Thread Fogus
New Cognitect Labs aws-api service APIs available! CHANGES new AWS service APIs available (services version v813.2.972.0): Amazon MemoryDB, AWS Snow Device Management README: https://github.com/cognitect-labs/aws-api/ API Docs: https://cognitect-labs.github.io/aws-api/ Changelog: https://github.

[ANN] New Cognitect Labs aws-api service APIs available!

2021-09-10 Thread Fogus
New Cognitect Labs aws-api service APIs available! CHANGES new AWS service API available (services version v814.2.986.0): opensearch README: https://github.com/cognitect-labs/aws-api/ API Docs: https://cognitect-labs.github.io/aws-api/ Changelog: https://github.com/cognitect-labs/aws-api/blob/ma

[ANN] New Cognitect Labs aws-api service APIs available

2021-10-15 Thread Fogus
New Cognitect Labs aws-api service APIs available! CHANGES - new endpoints version 1.1.12.88 - new AWS service API available (services version v814.2.1008.0): account, cloudcontrol, grafana, voice-id, wisdom README: https://github.com/cognitect-labs/aws-api/ API Docs: https://cognitect-labs.git

Re: What's the point of -> ?

2013-03-11 Thread Fogus
I wrote a post about -> and ->> a few years ago that might be helpful. http://blog.fogus.me/2009/09/04/understanding-the-clojure-macro/ -- -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com

Re: Enhanced Primitive Support

2010-06-22 Thread Fogus
One of our reviewers made a fantastic comment on the book and I thought I would share it for public consumption: "I know that you Lisp guys are incredibly proud of arbitrary-precision arithmetic, but I can't help but think that it is entirely missing the point: infinite precision is infinitely slo

Re: --> macro proposal

2010-07-06 Thread Fogus
> Once they read it, I think it becomes intuitive. Again, even The Joy > of Clojure points out that people use commas with -> and ->> to > indicate the location of the parameter. This is no different, except it Well "The Joy of Clojure" is clearly wrong! Actually, the latest version says "You can

Re: --> macro proposal

2010-07-06 Thread Fogus
> I think that is a terrible practice and should be left out of the book. Sold! It gives us enough room to put the infix example back in. :O ;-) :f -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googl

Re: --> macro proposal

2010-07-06 Thread Fogus
> And I don't think you should be ashamed to admit that. That's a relief! ;-) > helpful learning tool, or "training wheels" if you will, is not only > prudent, but shows that people find the placeholder syntax > of --> to be intuitive. I should say that while I do think that the ,,, trick could

Re: What is the reason Lisp code is not written with closing parenthesis on new lines?

2010-08-18 Thread Fogus
I wrote a post about this very thread. http://blog.fogus.me/2010/07/12/wadlers-law-extended-to-clojure/ :f -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members

Re: Clojure 1.2 Release

2010-08-19 Thread Fogus
What a day for Clojure! If anyone wants more information than what's available in Rich's links, then you can view the slides for a talk I'm giving tonight: http://fogus.me/static/preso/clj1.2+/ -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post

Re: Lisp/Scheme Style Guide

2010-08-31 Thread Fogus
> It would be a tragedy if The State ordered Picasso to make his paintings more > realistic I think your confusing the virtue in shuffling parentheses around. If you want to place your parentheses on their own line then more power to you, it's your style -- but don't confuse it with making high

Re: Joy of Clojure errata: Chapter 5

2011-05-16 Thread Fogus
Hi Ken, Thanks for this. I agree that a different name would be much more clear. As a side note, maybe we could use a single thread for JoC related flubs so as not to clog the mailing list on a chapter-by-chapter basis? Another option is to use Manning's forum at http://www.manning-sandbox.com/

Re: Clojure 1.3 Alpha 7

2011-05-20 Thread Fogus
In the alpha7 release the defrecord macro was changed to generate a couple of auxiliary functions (for a record R) named map->R and ->R. The first takes a map and returns a function of its contents. The second takes the same number of arguments as the record constructor. It's the definition of thi

Re: Clojure 1.3 Alpha 7

2011-05-20 Thread Fogus
I have a potential fix that handles the extra ->R parameters. However, there are some existing caveats: 1. The 20+ args path is much slower than the <20 args path. This is a limitation that may not go away unless the <20 function args limitation does. The speed difference comes from the ability

Re: ClojureScript Compile errors

2011-08-05 Thread Fogus
> how do I deal with ClojureScript compile errors? For > instance: Would it be possible to look at you project source? -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from

Re: Problem when use google closure library when use optimizations (simple/advanced)

2011-08-05 Thread Fogus
Thank you for sharing your eventual solution. For the future, the Google Closure library reference is at http://closure-library.googlecode.com/svn/docs/index.html -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to c

Re: ClojureScript Compile errors

2011-08-05 Thread Fogus
The following lines looks problematic: (ns mainpage (:use lib.dom-helpers)) That is, ClojureScript only supports the (ns foo (:require [a.b :as c])) form. Try changing your ns declaration accordingly. The error message could be slightly better I agree. ;-) :F -- You received thi

Re: Interfacing Cljs with external libs.

2011-08-05 Thread Fogus
To access global JavaScript interop thingies (a technical term) you should use the `js` namespace. The use of `js*` should be considered a bad idea. It's used in core, but only for very low-level operations. It should be considered undocumented and therefore off- limits (we're working to elimina

A place to talk Marginalia

2011-08-10 Thread Fogus
If anyone is interested, I have a group for talking about Marginalia and the art of documentation and code reading. Various other topics will be fair-game (within reason). Follow this link if you dare: http://groups.google.com/group/marginalia-clj -- You received this message because you are su

ANN: ring-clj-params

2012-02-15 Thread Fogus
# What is it? A Ring <https://github.com/mmcgrana/ring> middleware that augments :params according to a parsed Clojure <http://clojure.org/> data literal request body. # Where is it? https://github.com/fogus/ring-clj-params # Leiningen Usage In your :dependencies section add t

ANN: ClojureScript Cheatsheet

2012-02-15 Thread Fogus
I've created a ClojureScript cheatsheet. It's a high-level overview and not meant to cover every capability. The repo is at: https://github.com/fogus/clojure-cheatsheets The PDF is at: https://github.com/fogus/clojure-cheatsheets/blob/master/pdf/cljs-cheatsheet.pdf?raw=true Fe

ANN: Marginalia v0.7.0

2012-03-06 Thread Fogus
://fogus.me/fun/marginalia/). **Usage notes and examples are found on the [Marginalia Github page](http://github.com/fogus/marginalia).** Places -- * [Source code](https://github.com/fogus/marginalia) * [Ticket system](https://github.com/fogus/marginalia/issues) * [manifesto](http

Re: ANN: Marginalia v0.7.0

2012-03-06 Thread Fogus
> > CORRECTION: def form should be > > (def a-var "The docstring" value) -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient

ANN: Himera

2012-03-27 Thread Fogus
ClojureScript compilation as service. Some background and deeper discussion: http://blog.fogus.me/2012/03/27/compiling-clojure-to-javascript-pt-3-the-himera-model/ Himera itself: http://himera.herokuapp.com/ Source (patches welcomed): https://github.com/fogus/himera Feedback welcomed

[ANN]: Trammel (contracts programming) v0.7.0

2012-04-06 Thread Fogus
ve in your `project.clj` file: [trammel "0.7.0] For Maven-driven projects, use the following slice of XML in your `pom.xml`'s `` section: org.clojure trammel 0.7.0 Enjoy! Places -- * [Source code](https://github.com/fogus/trammel) * [Ticket system](https://github.com/

ANN: Marginalia v0.7.1

2012-06-08 Thread Fogus
website](http://fogus.me/fun/marginalia/). **Usage notes and examples are found on the [Marginalia Github page](http://github.com/fogus/marginalia).** Places -- * [Source code](https://github.com/fogus/marginalia) * [Ticket system](https://github.com/fogus/marginalia/issues) * [manifesto

ANN: core.cache version 0.6.1 (SoftCache + bug fixes)

2012-07-13 Thread Fogus
core.cache v0.6.1 Release Notes === core.cache is a new Clojure contrib library providing the following features: * An underlying `CacheProtocol` used as the base abstraction for implementing new synchronous caches * A `defcache` macro for hooking your `CacheProtoco

ANN: core.cache v0.6.2

2012-08-14 Thread Fogus
core.cache v0.6.2 Release Notes === Source code and README at https://github.com/clojure/core.cache Wiki (in progress) at https://github.com/clojure/core.cache/wiki core.cache is a Clojure contrib library providing the following features: Overview * An u

ANN: Minderbinder v0.2.0

2012-10-16 Thread Fogus
Minderbinder is a Clojure library for defining unit conversions available at read, compile and run time. More information is available on the [Minderbinder source repo](https://github.com/fogus/minderbinder). Use Include the following in your [Leiningen](https://github.com/technomancy

Re: Michael Fogus will talk about ClojureScript tomorrow night (8/25)

2011-08-25 Thread Fogus
That about sums it up. Specifically, I will talk about how some of the Clojure features (fns, types, protocols, etc.) are emitted in JavaScript and why one compiled form was chosen over any other (with proper caveats for future change). -- You received this message because you are subscribed to

Re: Notation conventions

2011-08-26 Thread Fogus
I guess the first question is; why so many atoms? But regardless, there is no standard for naming such things. If you know you're dealing with atoms only (as opposed to a reference in general) then something like `foo-atom` would suffice I'd say. -- You received this message because you are sub

Re: Neighbors function from The Joy of Clojure

2011-09-14 Thread Fogus
> diagonals as neighbors.  We don't think we take advantage of the > flexibility anywhere in the book, so perhaps your version would indeed > be better. It was used again only briefly in section 11.2 to define the legal moves that a king can make in chess, which of course includes diagonals. :-)

Re: docs for 1.3

2011-10-04 Thread Fogus
> (it doesn't help that this is now a child page of Release.Next > Planning which now refers to Clojure 1.4!) Good catch. That was my fault. It's now nested under the Core page in the same space. > Improving documentation looks to be a focus of Clojure > 1.4:http://dev.clojure.org/display/desi

[ClojureScript]: Breaking change coming WRT object property access syntax

2011-10-14 Thread Fogus
The ticket http://dev.clojure.org/jira/browse/CLJS-89 and the design page http://www.google.com/url?sa=D&q=http://dev.clojure.org/display/design/Unified%2BClojureScript%2Band%2BClojure%2Bfield%2Baccess%2Bsyntax describe the details of the change in ClojureScript. I would like to make this change (

Clojure Conj extracurricular activities spreadsheet

2011-10-25 Thread Fogus
All, We talked about the possibility of getting some ideas about extracurricular activities during the Conj days (and possibly training days). I've created a spreadsheet at the link below to collect ideas. It is not my intention to be the organizer of these activities. Instead, if you have an i

Re: Clojure Conj extracurricular activities spreadsheet

2011-10-25 Thread Fogus
Please note that nothing is too humble! If you have a cool piece of code or technique that you'd like to show off for 10 minutes then by all means put it on the spreadsheet. -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send

Re: Clojure Conj extracurricular activities spreadsheet

2011-10-25 Thread Fogus
> BTW, is this meant to be editable by anyone else? Or are you going to > collect the ideas off this thread and enter them? It should be editable by anyone with a Google account. Please let me know if that's not the case. -- You received this message because you are subscribed to the Google Gro

Re: Clojure Conj extracurricular activities spreadsheet

2011-10-31 Thread Fogus
I've added everyone to this thread as an editor of the spreadsheet. Please feel free to add yourself and your sessions at your leisure. -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note

Re: Clojure Koan-Engine 0.1.1

2011-12-05 Thread Fogus
Really great. Looking forward to boring everyone with contracts- koans. The next step is to have this project spit out a 4clojure- esque site automatically. ;-) -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to cl

ANNOUNCEMENT: core.cache version 0.5.0

2011-12-13 Thread Fogus
an efficient buffer replacement policy based on the *low inter-reference recency set* algorithm (LIRSCache) * Factory functions for each existing cache type core.cache is based on a library named Clache, found at http://github.com/fogus/clache that is planned for deprecation. Places

ANN: core.memoize v0.5.1

2011-12-14 Thread Fogus
core.memoize v0.5.1 Release Notes = core.memoize is a new Clojure contrib library providing the following features: * An underlying `PluggableMemoization` protocol that allows the use of customizable and swappable memoization caches that adhere to the synchronous `

Re: Codox: an API doc generator for Clojure

2012-01-04 Thread Fogus
> It might be an idea to figure out some standard syntax we could use, > like Markdown, that could be used for formatting docstrings. My vote is for Markdown as well. -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email t

ANN: core.unify v0.5.2

2012-01-09 Thread Fogus
unification binding, subst, and unification functions, with or without occurs checking, recognizing variables tagged as symbols prefixed with `?` characters core.unify is based on a library named Unifycle, found at http://github.com/fogus/unifycle that has been deprecated. This is likely the last release

ANN: ClojureScript property access syntax

2012-01-13 Thread Fogus
I've just merged to ClojureScript master the new property lookup syntax as outlined in the ticket http://dev.clojure.org/jira/browse/CLJS-89 and the design page at http://dev.clojure.org/display/design/Unified+ClojureScript+and+Clojure+field+access+syntax. This is a potentially *breaking* change t

Re: ANN: ClojureScript property access syntax

2012-01-13 Thread Fogus
Notes from the trenches. I successfully migrated both ClojureScript One and Domina to the new syntax in about ~35 minutes (including tests). I had an unfair advantage having worked on the ClojureScript change, but for your own purposes the following techniques for migration should help: - length

Re: ANN: ClojureScript property access syntax

2012-01-13 Thread Fogus
FYI: You can see my changes to ClojureScript One at https://github.com/brentonashworth/one/tree/props and those to Domina at https://github.com/fogus/domina/commit/cc2ee723b28fd3de6023156cab23b86daaa72210 -- You received this message because you are subscribed to the Google Groups "Cl

Re: Literate programming in emacs - any experience?

2012-02-01 Thread Fogus
I would love to see your .emacs setup around these tools. -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first

Re: SoftCaching in core.cache

2012-02-01 Thread Fogus
Oddly enough it was leaking memory, but suspect it had to do with the queue reaper. I'd think that what's in Clache needs only a little work. Patches welcomed. -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to cloj

Land of Lisp's Conrad Barski M.D. speaking about Clojure (Nov. 18, DC/VA/MD area)

2010-11-15 Thread Fogus
Conrad Barski, author of "Land of Lisp" (http://www.amazon.com/gp/ product/1593272812) will be giving a talk entitled *Land of Lisp: The Clojure-ish Parts* at the National Capital Area Clojure Users Group (CAPCLUG) on November 18, 2010 at 6:15 pm. The meeting will be held at 12021 Sunset Hills Roa

Re: Any news on pull requests?

2011-02-06 Thread Fogus
> Not every potential contributor lives in downtown > Megalopolis, Coastal State, USA. Agreed, but you must see that your particular case lays at the extreme. I'm of the opinion that if someone is inclined to contribute, then they will not be deterred by the cost of a postage stamp -- par avion o

Re: Time/size bounded cache?

2011-02-06 Thread Fogus
> A while back the discussion on the "bounded memoize" A truly classic thread, immortalized in JoC and at https://github.com/fogus/anamnesis :-) -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group

Re: Any news on pull requests?

2011-02-06 Thread Fogus
> Does it really? 20% of the population of the US > still lives outside of major cities. That's > not a majority but it's hardly an "extreme" > minority either. I'm sorry, I was referring more to your description of a treacherous hike through a vast winter wonderland; not of the hordes of potentia

Re: Help writing a simple destructuring function.

2011-02-07 Thread Fogus
I have a library called Evalive (http://github.com/fogus/evalive) that could help. Specifically I added a macro named `destro` that will do _mostly_ what you want. Basically, it looks like the following: (destro [a b [c d & e]] [1 2 [3 4 5 6 7 8]]) Which returns: {vec__2183 [1 2 [3 4 5 6

evalive a go go

2011-02-09 Thread Fogus
Hi all. I've mentioned my spunky little library evalive numerous times, but never got around to announcing it officially. Well here you go. evalive: a tiny clojure library providing another eval... and destro. http://github.com/fogus/evalive or http://fogus.me/fun/evalive/ Hav

Re: Clojure language influences

2011-02-10 Thread Fogus
While the speaker at the video linked below is no absolute authority in the matter, he does talk (well, mostly gibber) about some of Clojure's influences. http://clojure.blip.tv/file/4501296/ -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to

Re: better error messages > smaller stack traces

2011-02-10 Thread Fogus
> reporting issue: pre and post conditions.  They are a great feature > and I'd like to use them more often, but the error messages they > produce are virtually useless in comparison to just writing your own > check with a custom exception.  How about having optional error > messages for the condit

Re: better error messages > smaller stack traces

2011-02-10 Thread Fogus
> (defn f [x] {:pre [^{:msg "..."} (some-fancy-validation x)]} ..) That idea (or some variation) is actually kinda nice. Additionally, I've always hoped for separate PreConditionAssertionError and PostConditionAssertionError types, but keep forgetting to discuss it. -- You received this message

Re: Sorting of function definitions in namespaces

2011-02-11 Thread Fogus
> Well... It is Robert C. Martin's opinion. Who? > I should have said that I _think_ that it is essential to > writing readable code. I definitely agree with this. Another thing that I happen to agree with is that Clojure's model fits my way of programming in Clojure. -- You received this mes

Re: assert, illegal arguments, pre-conditions

2011-02-25 Thread Fogus
> I want to gather some feedback on how others are dealing with the > issue of pre-conditions raising AssertionError instead of > IllegalArgumentException, whereas the general practice is to catch AssertionError and IllegalArgumentException are meant for entirely different conditions. That is, yo

Tracking Clojure 1.3/2.0 progress

2011-03-09 Thread Fogus
Hi all, I've put together a Jira dashboard to display a distillation of the current progress toward the 1.3/2.0 release. I believe that anyone can view it, so pass the link far and wide. http://dev.clojure.org/jira/secure/Dashboard.jspa?selectPageId=10014 There is additional information display

On Lisp -> Clojure

2008-09-30 Thread Fogus
In an attempt to get a feel for Clojure I have started porting Paul Graham's "On Lisp". I have a good feel for the syntax so far, but I feel that perhaps I am simply writing Common Lisp in Clojure. If anyone is interested, my early attempts are at: http://www.earthvssoup.com/tag/onlisp/ Feel f

Re: On Lisp -> Clojure

2008-09-30 Thread Fogus
The comment was held in moderation. Sadly, if I did not perform some triage on the site comments I would be inundated with comments on Viagra and mortgage loans. Far from being discouraged, I am enthusiastic by your recommendations. I am far less interested in being correct than in doing it corr

Re: On Lisp -> Clojure

2008-10-02 Thread Fogus
Thanks for the pointers Alexander. I decided to take to heart the criticisms and rewrite a few of the functions from chapter 2; hopefully they are more Clojure-esque. :) http://www.earthvssoup.com/2008/10/02/on-lisp-clojure-chapter-2-redux/ -m --~--~-~--~~~---~--~--

(seq? "abc")

2008-10-02 Thread Fogus
OK. So we can do: (map (fn [x] x) "abc") (first "abc") (rest "abc") (filter (fn [x] (if (= x \b) false true)) "abc") (seq "abc") etc... So why is (seq? "abc") false? -m --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Grou

Re: (seq? "abc")

2008-10-02 Thread Fogus
> Hope that helps, It does. My assumption was that (seq?) meant Seq-able. Thanks -m --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com To

Re: On Lisp -> Clojure

2008-10-08 Thread Fogus
Chapter 4 now up. http://www.earthvssoup.com/2008/10/08/on-lisp-clojure-chapter-4/ In this episode we see Rich Hickey slap a n00b. ;) -m --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to

Making a living on Clojure

2008-10-14 Thread Fogus
I am attempting to work Clojure (at least partially) into my job, but in doing so I wonder how many of you here use it at your own jobs as opposed to relegating it to hobby. -m --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Googl

Specializing on type hints

2008-10-17 Thread Fogus
This would be interesting: (defn foo ([#^String x] (dosomething)) ([#^Number x] (dosomethingelse)) ([x] (dodefault))) I realize that I can do essentially the same thing with multimethods and I realize that type hints were not meant for this and I realize that there is likely an implication

  1   2   >