So, this started when I read Keith Swallow's article on a simple web server:
http://keithcelt.com/a-simple-web-server-in-clojure
I took his code and ran "lein new" to create a new project and I copy and
pasted his code to core.clj and made some minor adjustments, adding
gen-class and main so I
I've written several of the Clojure programs on the site. I'm not omniscient
when it comes to writing efficient Clojure code, but I know a few of the
techniques. Several, if not most, of the Clojure solutions already take
advantage of mutable data structures, for example.
There are some faste
Looking at clojure's benchmarks they seem to already be highly optimized
(in terms of employing all the standard tricks). Does anyone have any
idea if more could be done to lessen the gap between java and
clojure[1]? Or are these benchmarks representative of the performance
gap between clojur
It's easy enough to test: fire up a small EC2 instance and use Emacs over
an SSH+tmux session. You could also try using your own local Emacs that way
by SSH'ing to localhost.
In my experience, commands don't work in a terminal if they use modifier
keys (Control, Meta, Shift) AND non-letter keys
Maybe my impressions are out of date. Personally, I have neither the time
nor the interest, but optimizers do your stuff!
-S
--
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 post
Alexsandro,
I don't know about Parsatron, but Parse-EZ (
https://github.com/protoflex/parse-ez) provides the 'line-pos' function
that returns the line and column info.
Here is the equivalent code for your example using Parse-EZ:
--
(use 'protoflex.parse)
(defn anbn []
(let [as (re
Same here. Working fine.
On Mon, Aug 27, 2012 at 4:42 PM, Mayank Jain wrote:
> Working fine for me.
>
>
> On Tue, Aug 28, 2012 at 12:58 AM, Chris Ford
> wrote:
>
>> Hi,
>>
>> clojure.org seems to be down. I've mailed h...@wikispaces.com.
>>
>> Cheers,
>>
>> Chris
>>
>> --
>> You received this m
On Mon, Aug 27, 2012 at 11:56 PM, Denis Labaye wrote:
>
>
> On Mon, Aug 27, 2012 at 11:23 PM, larry google groups <
> lawrencecloj...@gmail.com> wrote:
>
>> I am in emacs at a clojure swank slime repl. I do this:
>>
>> user> (def ss (Socket. "localhost", 4))
>> #'user/ss
>>
>> user> ss
>> #
>
On Mon, Aug 27, 2012 at 11:23 PM, larry google groups <
lawrencecloj...@gmail.com> wrote:
> I am in emacs at a clojure swank slime repl. I do this:
>
> user> (def ss (Socket. "localhost", 4))
> #'user/ss
>
> user> ss
> #
>
>
> All is good. All is working. I now do this, which is exactly the s
Hi,
I am happily using clj-http to fetch JSON from my REST URIs.
And happily extracting data from XML using enlive.
Now I would like to combine the two:
Fetch JSON with clj-http AND extract informations from it with enlive.
Does anyone know what's the most straightforward way to do that?
Th
I am in emacs at a clojure swank slime repl. I do this:
user> (def ss (Socket. "localhost", 4))
#'user/ss
user> ss
#
All is good. All is working. I now do this, which is exactly the same thing:
(def client5 (Socket. "localhost" 42000))
I get:
java.lang.reflect.InvocationTargetExceptio
Adam Frey from wikispaces pinged me back. Seems like he fixed whatever the
problem was.
On 27 August 2012 20:42, Mayank Jain wrote:
> Working fine for me.
>
> On Tue, Aug 28, 2012 at 12:58 AM, Chris Ford
> wrote:
>
>> Hi,
>>
>> clojure.org seems to be down. I've mailed h...@wikispaces.com.
>>
>
Working fine for me.
On Tue, Aug 28, 2012 at 12:58 AM, Chris Ford wrote:
> Hi,
>
> clojure.org seems to be down. I've mailed h...@wikispaces.com.
>
> Cheers,
>
> Chris
>
> --
> You received this message because you are subscribed to the Google
> Groups "Clojure" group.
> To post to this group, se
Looks like it's back up.
On 27 August 2012 20:28, Chris Ford wrote:
> Hi,
>
> clojure.org seems to be down. I've mailed h...@wikispaces.com.
>
> Cheers,
>
> Chris
>
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email t
Hi,
clojure.org seems to be down. I've mailed h...@wikispaces.com.
Cheers,
Chris
--
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 b
>
>
> But if I do the same in an Emacs nrepl buffer, I got the exception as
> described in the ac-nrepl issue. So it does seems nrepl related. Can
> someone explain why? Thank you.
>
> I am using lein2 preview 10, and nrepl.el 0.1.4 preview
>
Hi Warren,
I added an explanation to the issue you refer
On Thursday, August 23, 2012 3:34:50 PM UTC-4, Warren Lynn wrote:
>
>
> I don't think it is nREPL server related. It has to do with with
> clojure.complete and lein repl.
>>
>>
>> https://github.com/kingtim/nrepl.el/issues/63
>>
>> -Tim
>>
>
> Thanks. I did not understand it correctly. I will
Hi Moritz,
Simply beautiful. That works!
Thank you all
Erlis
On Mon, Aug 27, 2012 at 2:06 PM, Moritz Ulrich wrote:
> This is a result of Light Table's instarepl: The test details get
> printed as string to *test-out*, which instarepl doesn't display.
>
> Tryclj seems to have a bug where it does
This is a result of Light Table's instarepl: The test details get
printed as string to *test-out*, which instarepl doesn't display.
Tryclj seems to have a bug where it doesn't redirect *out* to the
web-repl.
Anyway, try the following in instarepl:
(binding [*test-out* *out*]
(run-tests))
Thi
Hi Mayank,
That's not the part that's confusing me. Suppose I have 100 tests, and when
I run my tests I only get
{:type :summary, :pass 99, :test 100, :error 0, :fail 1}
Can you tell which one was the one that filed? I need more information, the
information that's described in the documentation,
correction :
("a" != "b") I mean (b has "" around it i..e)
On Mon, Aug 27, 2012 at 10:31 PM, Mayank Jain wrote:
>
>
> On Mon, Aug 27, 2012 at 10:17 PM, Erlis Vidal wrote:
>
>> Hi Mayank,
>>
>> I'm still unable to see why the test failed!
>>
>
> The test failed because "a" is not equal to "b" ! I
On Mon, Aug 27, 2012 at 10:17 PM, Erlis Vidal wrote:
> Hi Mayank,
>
> I'm still unable to see why the test failed!
>
The test failed because "a" is not equal to "b" ! Is that part confusing
you? or is the question something else?
Total tests = 1 (deftest declaration i.e.)
How many passed? = 1 (
Hi Mayank,
I'm still unable to see why the test failed!
Anyone knows why I'm getting this?
[image: Inline image 1]
On Mon, Aug 27, 2012 at 7:22 AM, Erlis Vidal wrote:
> I'm expecting the expected & actual detail. Maybe my problem is due to I'm
> executing this from lighttable insta repl.
> Ru
Nice, ok thanks.
Tim
On Sun, Aug 26, 2012 at 7:59 PM, Alan Malloy wrote:
> I just use C-j instead of RET in the rare cases that I want to leave the
> previous line alone.
>
>
> On Sunday, August 26, 2012 4:15:54 PM UTC-7, frye wrote:
>>
>> Hey all,
>>
>>
>> There'll probably be a quick solutio
On Aug 27, 6:53 pm, David Nolen wrote:
> On Mon, Aug 27, 2012 at 9:50 AM, Shantanu Kumar
>
> wrote:
>
> > On Aug 27, 6:45 pm, David Nolen wrote:
> >> We don't throw on arity, only warn.
>
> > It doesn't seem to be warning in the other examples (let ...) in CLJS
> > I showed above.
>
> > Shanta
On Mon, Aug 27, 2012 at 9:50 AM, Shantanu Kumar
wrote:
>
>
> On Aug 27, 6:45 pm, David Nolen wrote:
>> We don't throw on arity, only warn.
>
> It doesn't seem to be warning in the other examples (let ...) in CLJS
> I showed above.
>
> Shantanu
Yes it only currently warns on tops levels. It doesn
On Aug 27, 6:45 pm, David Nolen wrote:
> We don't throw on arity, only warn.
It doesn't seem to be warning in the other examples (let ...) in CLJS
I showed above.
Shantanu
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, sen
We don't throw on arity, only warn.
On Monday, August 27, 2012, Shantanu Kumar wrote:
> Hi,
>
> I noticed the following at the CLJS REPL:
>
> ClojureScript:cljs.user> (let [f #(do 1)] (f 2))
> 1
> ClojureScript:cljs.user> (let [f (fn [] (do 1))] (f 2))
> 1
> ClojureScript:cljs.user> (let [f (fn [
Hi,
I noticed the following at the CLJS REPL:
ClojureScript:cljs.user> (let [f #(do 1)] (f 2))
1
ClojureScript:cljs.user> (let [f (fn [] (do 1))] (f 2))
1
ClojureScript:cljs.user> (let [f (fn [_] (do 1))] (f 2))
1
ClojureScript:cljs.user> (let [f (fn [_ _] (do 1))] (f 2))
1
ClojureScript:cljs.use
Alexsandro,
I don't know about Parsatron, but Parse-EZ (
https://github.com/protoflex/parse-ez) provides the 'line-pos" function
that returns [line# column#] vector.
Here is the equivalent code for your example using Parse-EZ:
(use 'protoflex.parse)
(defn anbn []
(let [as (regex
Wow I can't believe my silly question actually led to a whole independent
project!
On Friday, February 10, 2012 9:36:53 AM UTC-6, tbc++ wrote:
>
> >> I have some set of algorithms that needs such-and-such operations to
> be as fast as possible. Can I create a VM that is tailored for that?
>
> Yes
I'm expecting the expected & actual detail. Maybe my problem is due to I'm
executing this from lighttable insta repl.
Running this code in the web repl give me the same result.
http://tryclj.com/
Enter some Clojure code to be evaluated.
Clojure> (use 'clojure.test)
nil
Clojure> (is (= "a" "b"))
OK I will address further questions on the proper mailing list...just a
quick comment about your snippet though
It doesn't exactly help me because you've got 'invoke-later' as the 2nd
arg to the future which means I'm losing the value that should be
returned from the long running calculati
Hi,
I am organizing a code retreat in September.
All languages are accepted, I want to use Clojure for this time, which
exercises would make Clojure shine?
Thanks!
Denis
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send e
Try calling with-test-out :-
user> (use 'clojure.test)
*nil*
user> (deftest test1
(is (= "a" "b"))
(is (= "1" "1")))
*#'user/test1*
user> (with-test-out
(run-tests))
*Testing user
FAIL in (test1) (NO_SOURCE_FILE:1)
expected: (= "a" "b")
actual:
35 matches
Mail list logo