Hi,
On Jul 7, 3:37 am, Pedro Teixeira wrote:
> user> (use 'clojure.test)
> user> (testing (defrecord R []) (new R) )
>
> [exception: Unable to resolve classname: R]
I think you get caught by the toplevel form. Clojure compiles the
complete testing form before executing it. So the (R.) can't see
Steven, I did not know this page, thanks for the link.
But to make it really clear: move-past-close-and-reindent is exactly
what counterclockwise's is doing in "Strict" edition mode (not totally
true concerning the reindentation, currently in ccw it is only
reorganizing closing brackets by removin
At the Bay Area user group meeting in June, there was a very
interesting discussion about how to best use Clojure's concurrency
primitives to field large numbers of concurrent requests, especially
in a long-poll/push type application. We didn't arrive at any solid
conclusion, but it was clear to e
Thanks Markus,
yes, I intentionally wanted to keep it "decoupled from any particular
editor". I had two goals in writing CDT.
The immediate goal was to provide a better tool for debugging
exceptions, which was harder than it should be in Clojure.
The longer term goal was to expose the JDI to Cl
It looks very cool. Great to have a Clojure text interface and not another
adhoc laguage.
Will make working with it easier, as well as building tools around it.
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to cloju
On Wed, Jul 7, 2010 at 11:43 AM, George Jahad
wrote:
> Thanks Markus,
>
> yes, I intentionally wanted to keep it "decoupled from any particular
> editor". I had two goals in writing CDT.
>
> The immediate goal was to provide a better tool for debugging
> exceptions, which was harder than it shoul
On Wed, Jul 7, 2010 at 5:15 AM, Zach Tellman wrote:
> At the Bay Area user group meeting in June, there was a very
> interesting discussion about how to best use Clojure's concurrency
> primitives to field large numbers of concurrent requests, especially
> in a long-poll/push type application. W
On Tue, Jul 6, 2010 at 2:14 AM, George Jahad
wrote:
> My experiment with the JDI:
>
>
> http://georgejahad.com/clojure/cdt.html
>
> --
> 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
I've needed --> a few times in my code. I don't think I need it as
much as just -> or ->>. Most of the time I've needed it is because I
or someone else essentially had parameters
in the wrong order. Maybe it belongs in contrib along with -?> which
I've needed sparingly as well, but have found usefu
2010/7/7 aria42 :
> I've needed --> a few times in my code. I don't think I need it as
> much as just -> or ->>. Most of the time I've needed it is because I
> or someone else essentially had parameters
> in the wrong order. Maybe it belongs in contrib along with -?> which
> I've needed sparingly a
Another way:
suppose test-list -> (list 1 2 3)
`(max ~...@test-list) can translate the form to what you want
so you can use eval or define a macro to handle it.
On Jul 5, 11:38 am, Mike Meyer wrote:
> On Sun, 4 Jul 2010 20:21:22 -0700 (PDT)
>
> dennis wrote:
> > For example:
> > (max 1 2 3)
What about (use 'clojure.test.user) ?
On Jul 6, 6:37 pm, Pedro Teixeira wrote:
> Hi,
>
> The following seems like it was not intended, please let me know if it
> is intended.
>
> user> (use 'clojure.test)
> user> (testing (defrecord R []) (new R) )
>
> [exception: Unable to resolve classname: R]
> [org.jboss.netty/netty "3.2.0.BETA1"]
Netty 3.2.1.Final has been released.
I think the ! mark in "respond!" is kind of misleading. Why not change
it to "arespond"?
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email t
> Thanks for both answers. Two ways of doing it. Great!
The :jvm-opts "-Xmx1g" -option in the project-file doesnt seem to work
with the swank-server.
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googleg
On Wed, Jul 7, 2010 at 4:12 AM, Cachou wrote:
> Another way:
>
> suppose test-list -> (list 1 2 3)
>
> `(max ~...@test-list) can translate the form to what you want
>
> so you can use eval or define a macro to handle it.
>
>
>
> But, most of the time, it is a bad idea.
(Except if you are in situa
On Jul 7, 2:57 am, ngocdaothanh wrote:
> > [org.jboss.netty/netty "3.2.0.BETA1"]
>
> Netty 3.2.1.Final has been released.
>
> I think the ! mark in "respond!" is kind of misleading. Why not change
> it to "arespond"?
For some reason I couldn't get 3.2.1.Final to come in via maven. I
didn't want
Hi!
I try to make a printout witch vill have year 1999->2010 and every
week
Eg.
Year=1999 Week=1
Year=1999 Week=2
Year=1999 Week=3
Year=1999 Week=4
Year=2000 Week=1
I have made the program in java, but like to try making it in Clojure,
but so far i have got
---
First, thanks for your work. I appreciate it. Now some comments:
"Select top level s-expression" and "evaluate current selection or top-
level s-expression" should act on the sexp in front of the cursor,
especially if the cursor is at the end of an sexp. When I tried it, I
was getting the next
(defn print-data2 [year]
(dorun (map #(print-data year %) (range 1 53 1
I think you have both a problem with the syntax of anonymous functions and a
problem of lazyness.
map only creates a lazy seq that do not get evaluated.
dorun do that
You can have a look at list comprehensions (f
On Wed, Jul 7, 2010 at 4:27 AM, Meikel Brandmeyer wrote:
> Hi,
>
> On Jul 7, 3:37 am, Pedro Teixeira wrote:
>
>> user> (use 'clojure.test)
>> user> (testing (defrecord R []) (new R) )
>>
>> [exception: Unable to resolve classname: R]
>
> I think you get caught by the toplevel form. Clojure compil
(for [y (range 1999 2011) w (range 1 52)] (println "year=" y "w=" w))
On Jul 7, 2010, at 10:47 AM, uap12 wrote:
> Hi!
> I try to make a printout witch vill have year 1999->2010 and every
> week
> Eg.
> Year=1999 Week=1
> Year=1999 Week=2
> Year=1999 Week=3
> Year=1999 Week=4
>
> Year=2000 We
On Wed, Jul 7, 2010 at 10:47 AM, uap12 wrote:
> I have made the program in java, but like to try making it in Clojure,
> but so far i have got
>
> (d
You can build a sequence of year week pairs using,
(for [y (range 1999 2011)
w (range 1 53)] [y w])
then you can iterate over that and print,
(doseq [[y w] (for [y (range 1999 2011)
w (range 1 53)] [y w])]
(println "Year " y "Week " w))
Hope it helps...
--
This usage of for is ill-advised: for is not a loop, it is a comprehension.
This will not do what you want if, for example, you assign the result of for to
a variable instead of entering it at the REPL.
Nurullah's response on this thread shows a nice separation of building the
(lazy) structure
2010/7/7 miner :
> First, thanks for your work. I appreciate it. Now some comments:
>
> "Select top level s-expression" and "evaluate current selection or top-
> level s-expression" should act on the sexp in front of the cursor,
> especially if the cursor is at the end of an sexp.
By "in front",
or rather
(for [y (range 1999 (inc 2010))
w (range 1 (inc 52))] [y w])
which remove the 2011 and 53 magic values ;-)
2010/7/7 Nurullah Akkaya :
> You can build a sequence of year week pairs using,
>
> (for [y (range 1999 2011)
> w (range 1 53)] [y w])
>
> then you can iterate over th
Hi,
Am 07.07.2010 um 17:10 schrieb Nurullah Akkaya:
> (doseq [[y w] (for [y (range 1999 2011)
> w (range 1 53)] [y w])]
> (println "Year " y "Week " w))
And just for the record:
If you don't need the intermediate seq you can use doseq directly:
(doseq [y (range 199
Many years of Emacs have trained me to expect evaluation of the form
before the cursor. For example, with | standing for the cursor
position:
--
(+ 3 4)|
(* 2 3)
--
I expect to evaluate (+ 3 4). Often I put my cursor right after an
expression just so I can execute it. Again, that's ho
2010/7/7 miner :
> [...] This also makes it convenient to type and expression and evaluate
> it immediately without having to move the cursor.
Now that's something to consider, indeed ... this makes sense ...
--
You received this message because you are subscribed to the Google
Groups "Clojure"
On Wed, Jul 7, 2010 at 5:15 AM, Zach Tellman wrote:
> With this in mind, I decided to make the thinnest possible wrapper
> around Netty such that a person could play around with alternate ways
> to use Clojure effectively. The result can be found at
> http://github.com/ztellman/aleph.
I played
I've kinda asked this question before, but I framed in the context of
a suggestion, and the discussion got bogged down with no real answer.
So this time, let me keep it simple: if I have a small Clojure
library, "foo", which only has one namespace, what is the idiomatic
name for that namespace?
On Jul 7, 2010, at 11:14 AM, Stuart Halloway wrote:
> This usage of for is ill-advised: for is not a loop, it is a comprehension.
> This will not do what you want if, for example, you assign the result of for
> to a variable instead of entering it at the REPL.
>
> Nurullah's response on this th
Oh, sorry, I misread, I thought you said "*The* usage of for is ill-advised" :-p
- Greg
On Jul 7, 2010, at 11:27 AM, Greg wrote:
> On Jul 7, 2010, at 11:14 AM, Stuart Halloway wrote:
>
>> This usage of for is ill-advised: for is not a loop, it is a comprehension.
>> This will not do what you w
'doseq instead 'for works fine:
(doseq [y (range 1999 2011), w (range 1 52)] (print-data y w))
On Jul 7, 11:14 am, Stuart Halloway wrote:
> This usage of for is ill-advised: for is not a loop, it is a comprehension.
> This will not do what you want if, for example, you assign the result of for
> If you don't need the intermediate seq you can use doseq directly:
>
> (doseq [y (range 1999 2011)
>w (range 1 53)]
> (println "Year" y "Week" w))
That's really cool, I didn't know you can do that.
I just looked over its implementation and it seems pretty complex but
interesting, so
Hi,
2010/7/7 James Reeves :
> I've kinda asked this question before, but I framed in the context of
> a suggestion, and the discussion got bogged down with no real answer.
>
> So this time, let me keep it simple: if I have a small Clojure
> library, "foo", which only has one namespace, what is the
> For some reason I couldn't get 3.2.1.Final to come in via maven.
I think you need to add this to project.clj:
:repositories [["jboss" "http://repository.jboss.org/nexus/content/
groups/public/"]]
> What qualities is it missing that make the bang misleading?
I thinks ! means something dangerous
This is not in answer to the question, but I just wanted to say: I
love that fact that Clojure got namespaces "right" in the sense of
allowing aliasing on import. Some languages don't do this, and you end
up with very difficult naming issues since you suddenly have a huge
desire to keep it short *w
Hello all! Today, I've either discovered a bug, or I've discovered a
flaw in my understanding of macros. Most likely the latter :-) Could
anyone set me straight?
While this is not the macro I was trying to write, it falls over in
the same place.
(user=> (defmacro foo [& xs] `(map identity ~xs))
#
On Wed, Jul 7, 2010 at 12:49 PM, Cameron wrote:
> Hello all! Today, I've either discovered a bug, or I've discovered a
> flaw in my understanding of macros. Most likely the latter :-) Could
> anyone set me straight?
>
> While this is not the macro I was trying to write, it falls over in
> the sam
If you macroexpand the first foo in (foo 1 2), you will see something like
(1 2)
when this gets evaluated, Clojure is not happy about 1 not being a function.
On Wed, Jul 7, 2010 at 5:49 PM, Cameron wrote:
> Hello all! Today, I've either discovered a bug, or I've discovered a
> flaw in my unders
I think you're missing a quote in your original macro.
You wrote:
(defmacro foo [& xs] `(map identity ~xs))
Try this in a REPL:
user=> (macroexpand-1 '(foo 1 2))
(clojure.core/map clojure.core/identity (1 2))
That shows you that it's going to try to evaluate the form (1 2). The
original complai
Of course I meant
(map identity (1 2))
On Wed, Jul 7, 2010 at 6:03 PM, Nicolas Oury wrote:
> If you macroexpand the first foo in (foo 1 2), you will see something like
> (1 2)
>
> when this gets evaluated, Clojure is not happy about 1 not being a
> function.
>
>
> On Wed, Jul 7, 2010 at 5:49 PM,
Hi Cameron,
On Jul 7, 9:49 am, Cameron wrote:
> Hello all! Today, I've either discovered a bug, or I've discovered a
> flaw in my understanding of macros. Most likely the latter :-) Could
> anyone set me straight?
>
> While this is not the macro I was trying to write, it falls over in
> the same
Hi,
Am 07.07.2010 um 18:04 schrieb Greg:
>> If you don't need the intermediate seq you can use doseq directly:
>>
>> (doseq [y (range 1999 2011)
>> w (range 1 53)]
>> (println "Year" y "Week" w))
>
> That's really cool, I didn't know you can do that.
for and doseq are quite similar in it
Thanks for all the replies everyone, I certainly have a solution now.
But I am still a little confused. Take this slight variation...
user=> (defmacro foo [coll] `(map identity ~coll))
#'user/foo
user=> (foo [1 2 3 `(+ 1 1)])
(1 2 3 (clojure.core/+ 1 1))
In this one, I am passing an explicit list
Thanks everyone! I certainly have my solution; but, I'm still a bit
confused. Here's another example...
user=> (defmacro foo [coll] `(map identity ~coll))
#'user/foo
user=> (foo (list 1 2 3))
(1 2 3)
In this example, I pass an explicit list and all I have to do is
unquote 'coll'. How is passing a
Hi,
Am 07.07.2010 um 15:47 schrieb Pedro Henriques dos Santos Teixeira:
> Are there any design guidelines for choosing between defrecords and
> defstruct, when one wants a map with type?
>
> I started with defrecord, but feels like I should switch to defstruct
> to avoid these complex host integ
On Jul 7, 9:12 am, David Nolen wrote:
> On Wed, Jul 7, 2010 at 5:15 AM, Zach Tellman wrote:
> > With this in mind, I decided to make the thinnest possible wrapper
> > around Netty such that a person could play around with alternate ways
> > to use Clojure effectively. The result can be found at
On Jul 7, 8:28 am, ngocdaothanh wrote:
> > For some reason I couldn't get 3.2.1.Final to come in via maven.
>
> I think you need to add this to project.clj:
> :repositories [["jboss" "http://repository.jboss.org/nexus/content/
> groups/public/"]]
>
Thanks, I'll give that a try.
> > What qualitie
On 7 July 2010 17:24, Laurent PETIT wrote:
> Of course, if your library has an especially cryptic name (as we have
> with counterclockwise: ccw), then having also directly foo may also
> not interfere with other's namespaces. That's the path we took for
> counterclockwise, and our top-level namesp
On Wed, Jul 7, 2010 at 1:43 PM, Zach Tellman wrote:
> Developers are still required to "participate" in the NIO design, in
> that blocking calls in the request handler need to be avoided to reap
> the full benefits. Netty provides a lot of nice abstractions over
> NIO, but kind of punts on how t
On 7 July 2010 19:04, David Nolen wrote:
> So something like this:
> (defn hello-world [request]
> (future
> (Thread/sleep 1)
> (respond! request
> {:status 200
> :headers {"Content-Type" "text/html"}
> :body "Hello world!"})))
> Is non-blocking and
On Wed, Jul 7, 2010 at 2:10 PM, James Reeves wrote:
> On 7 July 2010 19:04, David Nolen wrote:
> > So something like this:
> > (defn hello-world [request]
> > (future
> >(Thread/sleep 1)
> >(respond! request
> > {:status 200
> > :headers {"Content-Type" "text/
Hi,
Am 07.07.2010 um 18:13 schrieb James Reeves:
> - foo.core
> - com.github.weavejester.foo
I would go with one of these two. At the moment I prefer the former. I think
putting domain names in the package is suboptimal for a quite simple reason.
I'm a hobbyist. I don't own a domain. Eh? What
On Jul 7, 11:17 am, David Nolen wrote:
> On Wed, Jul 7, 2010 at 2:10 PM, James Reeves wrote:
>
>
>
>
>
> > On 7 July 2010 19:04, David Nolen wrote:
> > > So something like this:
> > > (defn hello-world [request]
> > > (future
> > > (Thread/sleep 1)
> > > (respond! request
> > >
As part of the Clojure Examples Wiki experiment, I created a page
adapted from the Cheatsheet, with links to relevant docs and examples
(not many, yet):
http://clojure-examples.appspot.com/clojure.core
It's been reorganized and revised a bit from the Cheatsheet. The
design is a little plain but i
Is there a library facilitating the navigating and editing nodes in a fairly
complex tree (nested map) structure? billm
--
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
Quick answer (sorry not much time): clojure.zip
It's quite easy to use once you've got the basics "in place"
2010/7/7 Bill Marshall :
> Is there a library facilitating the navigating and editing nodes in a fairly
> complex tree (nested map) structure? billm
>
> --
> You received this message bec
On Wed, Jul 7, 2010 at 2:42 PM, Meikel Brandmeyer wrote:
> Hi,>
> Am 07.07.2010 um 15:47 schrieb Pedro Henriques dos Santos Teixeira:>
>> Are there any design guidelines for choosing between defrecords and
>> defstruct, when one wants a map with type?
>>
>> I started with defrecord, but feels lik
On Wed, Jul 7, 2010 at 2:55 PM, James Reeves wrote:
> On 7 July 2010 17:24, Laurent PETIT wrote:
>> Of course, if your library has an especially cryptic name (as we have
>> with counterclockwise: ccw), then having also directly foo may also
>> not interfere with other's namespaces. That's the pat
On Wed, Jul 7, 2010 at 3:10 PM, James Reeves wrote:
> On 7 July 2010 19:04, David Nolen wrote:
>> So something like this:
>> (defn hello-world [request]
>> (future
>> (Thread/sleep 1)
>> (respond! request
>> {:status 200
>> :headers {"Content-Type" "text/html"}
On Jul 7, 5:24 pm, Laurent PETIT wrote:
> if you intend to share the library, then use the classical prefix notation:
>
> * either of the form net.reeves.james.foo ( or any reversed tld you "own" )
> * either of the form com.yourcorp.foo
>
com.read.to.easy.that.not.its.but
--
You received
To All,
I am extremely interested in LISP and Clojure. I was wondering if it
would be possible to obtain NSF grant funding for further development
of Clojure ??
thanks,
David Blubaugh
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to th
I've whipped up a proof-of-concept of how to implement built-in
examples for functions and macros. The general idea is to add an
attribute to the var that contains a list of docstrings and arg lists
or code that illustrate common usage.
Let me know what you think: http://gist.github.com/466743
It
"Meikel Brandmeyer" wrote:
>Hi,
>
>Am 07.07.2010 um 18:13 schrieb James Reeves:
>
>> - foo.core
>> - com.github.weavejester.foo
>
>I would go with one of these two. At the moment I prefer the former. I think
>putting domain names in the package is suboptimal for a quite simple reason.
>I'm a h
2010/7/7 Cameron :
> Thanks everyone! I certainly have my solution; but, I'm still a bit
> confused. Here's another example...
>
> user=> (defmacro foo [coll] `(map identity ~coll))
> #'user/foo
> user=> (foo (list 1 2 3))
> (1 2 3)
>
> In this example, I pass an explicit list and all I have to do
Here in Canada we have a number
of programs for R&D and the
bureaucratic burden is not worth
the $$$ you get back for it except
if you a budget in the 6 digits range.
And if you want to get the paper done
by a consultant, he/she will charge
20% of the expected refund.
I looked at the NSF documen
I don't think examples should be integrated in the
function-definition. It's *way* to much bloat.
I like the way http://clojure-examples.appspot.com/clojure.core goes.
A wiki-like documentation for examples, linked to every
clojure-namespace. These examples could be serialized into some data
struc
I'm wondering if the following pattern is safe or not. I'm in a
transaction, and I want to create an agent and then send it an initializing
message (the message function isn't transaction-safe, so I don't want to run
it in the transaction). So I want to do something like:
(def my-ref (ref nil))
Hi,
Am 07.07.2010 um 22:46 schrieb Brian Hurt:
> I'm wondering if the following pattern is safe or not. I'm in a transaction,
> and I want to create an agent and then send it an initializing message (the
> message function isn't transaction-safe, so I don't want to run it in the
> transaction
On Wed, Jul 7, 2010 at 5:00 PM, Lars Nilsson wrote:
>
> Maybe
>
> (doseq [year (range 1999 2010 1)]
> (doseq [month (range 1 53 1)]
> (print-data year range)))
>
You could also do this with dotimes instead of doseq. Doesn't matter
for Ns this small, but creating a range just so you have somet
There is also assoc-in and get-in for accessing and associng values in
nested maps.
On Wed, Jul 7, 2010 at 9:26 PM, Laurent PETIT wrote:
> Quick answer (sorry not much time): clojure.zip
>
> It's quite easy to use once you've got the basics "in place"
>
> 2010/7/7 Bill Marshall :
>> Is there a li
Hi,
Am 07.07.2010 um 21:41 schrieb Mike Meyer:
> Why bother renaming it when you move?
Why come into a situation where bothering is a question?
Sincerely
Meikel
PS: You K-9 Mail sends every message twice.
--
You received this message because you are subscribed to the Google
Groups "Clojure"
On Wed, Jul 7, 2010 at 5:04 PM, Meikel Brandmeyer wrote:
> Hi,
>
> Am 07.07.2010 um 22:46 schrieb Brian Hurt:
>
> > I'm wondering if the following pattern is safe or not. I'm in a
> transaction, and I want to create an agent and then send it an initializing
> message (the message function isn't
All I know is that you have to show educational value for NSF. So, funding
for development should be accompanied by teaching or lecturing.
On Jul 7, 2010 4:14pm, Luc Préfontaine wrote:
Here in Canada we have a number
of programs for R&D and the
bureaucratic burden is not worth
the $
On Wed, Jul 7, 2010 at 3:46 PM, Brian Hurt wrote:
> I'm wondering if the following pattern is safe or not. I'm in a
> transaction, and I want to create an agent and then send it an initializing
> message (the message function isn't transaction-safe, so I don't want to run
> it in the transaction)
Hi,
Am 07.07.2010 um 23:11 schrieb Ryan Waters:
>> (send a init-function)
>> (send a f))
>
> It's not guaranteed the init-function will complete before f.
I doubt that. Since only one action can be active at a time and the ordering is
preserved, init-function wi
On Jul 7, 5:06 pm, Isak Hansen wrote:
> On Wed, Jul 7, 2010 at 5:00 PM, Lars Nilsson wrote:
>
> > Maybe
>
> > (doseq [year (range 1999 2010 1)]
> > (doseq [month (range 1 53 1)]
> > (print-data year range)))
>
> You could also do this with dotimes instead of doseq. Doesn't matter
> for Ns thi
"Meikel Brandmeyer" wrote:
>Hi,
>
>Am 07.07.2010 um 21:41 schrieb Mike Meyer:
>
>> Why bother renaming it when you move?
>
>Why come into a situation where bothering is a question?
You would have to ask the people at sun.com who created the convention that one.
>PS: You K-9 Mail sends every me
Laurent PETIT writes:
> But to make it really clear: move-past-close-and-reindent is exactly
> what counterclockwise's is doing in "Strict" edition mode (not totally
> true concerning the reindentation, currently in ccw it is only
> reorganizing closing brackets by removing extra spaces, not
> re
DARPA might be a better bet, they fund potentially useful things
I have nothing to do with them though.
Marc
On 7/7/10, David Blubaugh wrote:
> To All,
>
>
> I am extremely interested in LISP and Clojure. I was wondering if it
> would be possible to obtain NSF grant funding for further develo
On Wed, Jul 7, 2010 at 2:10 PM, James Reeves wrote:
> The main advantage of a non-blocking server is that you're don't use
> up a thread waiting for an event (such as the user sending data, or
> some other external trigger).
>
> - James
I think the main advantage of a non-blocking server is thro
What's the idiomatic way to handle cases where one has a macro rather
than a function?
For example:
intent is as follows but does not work:
(def args [false true false])
(apply or args)
alternatives?
a> (eval `(or @~args))
b> (reduce #(or %1 %2) args)
any recommended?
thanks,
Pedro
On J
On Jul 7, 7:55 pm, James Reeves wrote:
> For the purposes of this discussion, let us assume that "foo" is a
> suitably unique library name, and it is highly unlikely there exist
> any other libraries with the same name.
It sounds like Clojure doesn't have an idiom for namespace names yet,
so I gu
"well I think the main advantage" is memory. :-)
Theoretically (I think), thread-per-connection servers can be very close to
matching asynchronous servers in throughput, but they definitely require much
more RAM to do so. RAM is one of the more expensive commodities to come by on
VPS and cloud
On Wed, Jul 7, 2010 at 4:32 PM, Meikel Brandmeyer wrote:
> Hi,
>
> Am 07.07.2010 um 23:11 schrieb Ryan Waters:
>
>>> (send a init-function)
>>> (send a f))
>>
>> It's not guaranteed the init-function will complete before f.
>
> I doubt that. Since only one action ca
On Wed, 7 Jul 2010 18:53:39 -0700 (PDT)
j-g-faustus wrote:
> On Jul 7, 7:55 pm, James Reeves wrote:
> > For the purposes of this discussion, let us assume that "foo" is a
> > suitably unique library name, and it is highly unlikely there exist
> > any other libraries with the same name.
>
> It s
Just noticed that defprotocol -- or rather, emit-protocol -- simply
assumes that method signatures are well-formed. This leads to the
following behaviour:
;; this compiles fine
(defprotocol PTestProt
(p-test-method "foo" [this]))
;; this does not -- no matching method found
(defrecord RTestRec
(inc clojure.zip); clojure.contrib.zip-filter is a nice companion.
Also, clojure.walk might be worth investigating. It provides no
complex navigational facilities, so only some types of tree
transformations are "walkable", but for dealing with those, it's an
absolutely fantastic tool.
Sincerely,
On Jul 7, 2010, at 8:53 PM, j-g-faustus wrote:
> The disadvantage is of course that you end up with names like
> org.apache.http.client.params.ClientPNames/
> CONNECTION_MANAGER_FACTORY_CLASS_NAME
> which gets old really quick if you have to type it a lot :)
Why would you ever type that more than
>
>
> Why would you ever type that more than once? Just use :as.
>
>
Because you use it in more than one file / project.
--
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
On Jul 7, 2010, at 21:05 , John Cromartie wrote:
> I've whipped up a proof-of-concept of how to implement built-in
> examples for functions and macros. The general idea is to add an
> attribute to the var that contains a list of docstrings and arg lists
> or code that illustrate common usage.
>
2010/7/8 Steven E. Harris
> Laurent PETIT writes:
>
> > But to make it really clear: move-past-close-and-reindent is exactly
> > what counterclockwise's is doing in "Strict" edition mode (not totally
> > true concerning the reindentation, currently in ccw it is only
> > reorganizing closing brac
2010/7/8 Pedro Teixeira
>
> What's the idiomatic way to handle cases where one has a macro rather
> than a function?
>
> For example:
>
> intent is as follows but does not work:
> (def args [false true false])
> (apply or args)
>
>
> alternatives?
>
> a> (eval `(or @~args))
>
big no-no.
>
> b>
I spent a bunch of time today in CCW 0.0.59.RC2, in "default" mode, and thought
I'd report my experience:
- Lots of very nice features and I really appreciate having this -- please
don't take my criticisms below in the wrong way!
- There are some cases in which the indentation doesn't follow t
96 matches
Mail list logo