Hi
On Sun, Nov 16, 2008 at 11:46 PM, Stephen C. Gilardi [EMAIL PROTECTED] wrote:
On Nov 16, 2008, at 1:21 PM, Stuart Sierra wrote:
I would like both the REPL and Script to be callable from the same main
(), i.e. you should just be able to call java -jar clojure.jar without
naming a class.
Hi,
On 17 Nov., 09:07, Michael Wood [EMAIL PROTECTED] wrote:
#!/usr/bin/env java -cp /sq/ext/clojure/clojure.jar clojure.lang.Script
Most systems only allow one argument to the command.
scsh solved this issue with the special \ argument and
block comment #! ... !#
#! /usr/bin/scsh \
-m ore -o
On Nov 16, 11:01 pm, Brian W [EMAIL PROTECTED] wrote:
I'm going to assume this is serious and not a joke, but you do realize
Clojure is already quite well documented at clojure.org?
I admit I started without reading the documentation, but having got
stuck I then read the documentation - both
On Nov 17, 7:43 am, Howard Lewis Ship [EMAIL PROTECTED] wrote:
I generally like that Clojure dispenses with parens that exist for the
benefit of the evaluator rather than the developer; thus far fewer
parens when using (cond). Still, my old Lisp habits (20 years without
use) succumbed as
I hope you are either 14 years old, or joking. Rather than sitting down
and attempting to conjure up perfect lines of a new programming language
you have never used before, it might be good to spend some time reading!
Learning new things is good for your brain, and I can promise you
Hi Stuart,
Cool additions - I will certainly use them.
Regarding test-is additions, did you ever get a chance to check out the
patch I submitted a while back?
http://groups.google.com/group/clojure/browse_thread/thread/c509d589e181df1e/4319c02c9930d12e?lnk=gstq=PATCH+test-is#4319c02c9930d12e
Stuart:
I read through the table of contents. Are you planning on addressing
interacting with a database (preferably postgres or mysql) in
Clojure?
Maybe the Working with Java chapter will be sufficient, but one of
the benefits of Clojure is batteries included, so helping folks get
up to speed
Given the function
(defn replace-syms
[sym-map expr]
(let [replace #(replace-syms sym-map %)]
(cond (contains? sym-map expr) (get sym-map expr)
(list? expr) (map #(replace-syms sym-map %) expr)
(vector? expr)
Hi,
On 17 Nov., 13:05, Konrad Hinsen [EMAIL PROTECTED] wrote:
(defn replace-syms
[sym-map expr]
(let [replace #(replace-syms sym-map %)]
(cond (contains? sym-map expr) (get sym-map expr)
(list? expr) (map #(replace-syms sym-map
Thanks Stuart!
It will certainly make writing tests more enjoyable :-)
Inspiration for :equal-pairs/each= came from the test framework I wrote
for newLISP:
http://newlisp-on-noodles.org/wiki/index.php/Function_Testing
Tests there are written as each= with 2 exceptions:
'-' evaluates the next
On Nov 17, 2008, at 13:33, mb wrote:
vals returns a clojure.lang.APersistentMap$ValSeq, which
is not a list. Hence list? returns false and you get the true
branch, ie. the thing itself.
A. It looks like a list, but it isn't a list.
I know. It doesn't help much, but it shows, that
On Nov 17, 3:52 am, Luc Prefontaine [EMAIL PROTECTED]
wrote:
Since it's existence, LISP has not gained a large acceptance in the
commercial market compared to other conventional programming
languages.
This is true; I think, though, it's largely a fashion thing. In the
days when you and I
On Nov 17, 2008, at 13:56, Simon Brooke wrote:
However, you're dead wrong about Lots of Irritating Stupid
Parentheses. They are the heart of the language: the fact that it does
not need any irregular syntax, because everything is regular.
For me, the heart of Lisp is that code is expressed
On Nov 17, 7:56 am, Konrad Hinsen [EMAIL PROTECTED] wrote:
On Nov 17, 2008, at 13:33, mb wrote:
vals returns a clojure.lang.APersistentMap$ValSeq, which
is not a list. Hence list? returns false and you get the true
branch, ie. the thing itself.
A. It looks like a list, but it
On Nov 17, 2:06 am, mb [EMAIL PROTECTED] wrote:
Hi,
On 17 Nov., 02:09, Chouser [EMAIL PROTECTED] wrote:
You could of course work around this by putting your loop in some
other function and calling it from inside catch.
In this specific case I used:
(last (take-while #(not (nil? %))
On Nov 17, 4:52 am, Luc Prefontaine [EMAIL PROTECTED]
wrote:
I never read anywhere in the documentation or in the user group that
Clojure is a Common LISP implementation.
Since it's existence, LISP has not gained a large acceptance in the
commercial market compared to other conventional
On Nov 16, 2008, at 10:34 PM, Rich Hickey wrote:
Since it only requires main, might I suggest you write this in
Clojure instead?
I gave that a try.
Here's a simple version of a driver for the compiler, stored in src/
clj/clojure/compile.clj:
(ns clojure.compile)
(defn
On Mon, Nov 17, 2008 at 4:18 PM, Stuart Halloway
[EMAIL PROTECTED] wrote:
Hi Simon,
I have converted a bunch of the examples from Practical Common Lisp
into Clojure [1]. You might find this helpful in seeing things from a
Clojure perspective.
Cheers,
Stuart
[1]
On Nov 17, 8:50 am, Stephen C. Gilardi [EMAIL PROTECTED] wrote:
On Nov 16, 2008, at 10:34 PM, Rich Hickey wrote:
Since it only requires main, might I suggest you write this in
Clojure instead?
I gave that a try.
Here's a simple version of a driver for the compiler, stored in src/
--- On Mon, 11/17/08, Rich Hickey wrote:
I've presented Clojure to many of the people who wrote
CL and Scheme, and no one can deny it is a Lisp.
I'd also add that at Lisp50 Clojure was very well received by many Lisperati,
and many, if not most, of the folks there were *way* into Scheme and
On Nov 17, 8:50 am, Stephen C. Gilardi [EMAIL PROTECTED] wrote:
In working through this, I also found that a compiler driver written
in Java may be preferable for use via build.xml because of a bootstrap
problem.
Yes, that's why I wanted to implement it in Java.
-S
I think you've got some of the interim work I've done integrating gen-
class. main now needs to be called -main, as all methods will be
defined with leading -.
I'm at SVN 1106 which doesn't appear to have any changes relative to
1104 in this area. My compiled hello.clj works with its
I'm really interested in how you would coordinate a database
transaction with an STM transaction. Do you message an agent to do
the database update?
On Mon, Nov 17, 2008 at 6:13 AM, Stuart Halloway
[EMAIL PROTECTED] wrote:
Hi Brian,
The libraries chapter will cover a bunch of different
I fully agree with you Konrad.
If Clojure eases up code reading for non-Lispers while not changing the
principles behind then what's the problem ?
As far as breaking the s-expr esthetics... bof, I could not care less.
Easier here means easier to understand for non-Lispers.
They are the ones we
Hi,
Clojure users might find this ACM Queue article interesting:
-==--==--==--==--==--==--==--==--==--==--==--==--==--==--==--==-
Parallel Programming with Transactional Memory
http://acmqueue.com/rd.php?c.557
While still primarily a research project, transactional memory
shows promise for
It's harder than that. :-) In general, to coordinate two transactional
systems, you need a transaction coordinator, like Microsoft's DTC or
the ones baked into various JEE containers. And that is what you are
talking about here: the Tx system in Clojure + the Tx system in a
database.
On Nov 17, 2008, at 14:30, Rich Hickey wrote:
It's best to do this as generally as possible, building on something
like this:
(defn map-same [f coll]
(let [ret (into (empty coll) (map f coll))]
(if (seq? coll)
(reverse ret)
ret)))
OK, so I have as a minimal set of
Hi All,
I've run into a bug since upgrading past revision 1100, specifically
around adding to the classpath at runtime using add-classpath. I've
attached a test case here:
http://s3.amazonaws.com/nullstyle/precompile-bug.tar.gz
That file has three versions of clojure (r1100, r1101, r1106) and
On Nov 17, 1:00 pm, Scott Fleckenstein [EMAIL PROTECTED] wrote:
Hi All,
I've run into a bug since upgrading past revision 1100, specifically
around adding to the classpath at runtime using add-classpath. I've
attached a test case
Thanks Rich,
While I understand the desire to stick with java conventions when it
comes to adding to the classpath, it is too bad because it takes away
from the 'explorability' you get with a Repl. I've gotten into the
habit of just dumping jars into my scratch folder and tooling away on
my
Is there are way to make (slime-redirect-inferior-output) happen by
default?
Stuart
--~--~-~--~~~---~--~~
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
the vector syntax seems nice to me. you get the whole () means
function, [] means sequential binding, {} means associative
binding, and it makes code easier to read/skim over.
you could have lists for seq binding, but i think using a different
syntax gets you out of that everything is a list way
On Nov 17, 2008, at 9:51 AM, Rich Hickey wrote:
main now needs to be called -main, as all methods will be defined
with leading -.
Seeing that makes me think of Objective-C where instance methods have
a leading - and static methods (class methods) having a leading +. I
think a convention
You could add the following to your .emacs file:
(add-hook 'slime-mode-hook 'slime-redirect-inferior-output)
--
Bill Clementson
On Mon, Nov 17, 2008 at 11:31 AM, Stuart Halloway
[EMAIL PROTECTED] wrote:
Is there are way to make (slime-redirect-inferior-output) happen by
default?
Stuart
Hey All,
I've finally found some time to start getting the project hosting site
together, and i need a name.. so lets put it to a vote.
Here are some suggestions so far, but please feel free to chime in
with your own as well.
- projecture
- clojr
- proj4cloj
- clojforge, cloforj,
- forj
-
On Mon, Nov 17, 2008 at 12:52 PM, Drew Crampsie [EMAIL PROTECTED]wrote:
Hey All,
I've finally found some time to start getting the project hosting site
together, and i need a name.. so lets put it to a vote.
Here are some suggestions so far, but please feel free to chime in
with your own
Maybe it was just my setup, but that didn't work for me. What did
work was:
(add-hook 'slime-connected-hook 'slime-redirect-inferior-output)
--Darren
On Nov 17, 11:42 am, Bill Clementson [EMAIL PROTECTED] wrote:
You could add the following to your .emacs file:
(add-hook 'slime-mode-hook
I like it and Obj-C inspired syntax on the JVM is cosmic justice.
On Nov 17, 2008, at 2:37 PM, Stephen C. Gilardi [EMAIL PROTECTED]
wrote:
On Nov 17, 2008, at 9:51 AM, Rich Hickey wrote:
main now needs to be called -main, as all methods will be defined
with leading -.
Seeing that
I'm liking projecture
On Mon, Nov 17, 2008 at 2:52 PM, Drew Crampsie [EMAIL PROTECTED] wrote:
Hey All,
I've finally found some time to start getting the project hosting site
together, and i need a name.. so lets put it to a vote.
Here are some suggestions so far, but please feel free to
my vote is for projecture or clojects
--~--~-~--~~~---~--~~
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 unsubscribe from this group, send email to [EMAIL
Other options:
- creatjure?
- featjure?
- cultjure?
All three have low Google search hit counts. I think cultjure is
better suited for discussion forums. Creatjure seems a good place for
our Clojure creatures.
On Nov 17, 2:52 pm, Drew Crampsie [EMAIL PROTECTED] wrote:
Hey All,
I've
+1 for projecture
Vincent
--~--~-~--~~~---~--~~
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 unsubscribe from this group, send email to [EMAIL PROTECTED]
On Nov 17, 11:52 am, Drew Crampsie [EMAIL PROTECTED] wrote:
Here are some suggestions so far, but please feel free to chime in
with your own as well.
What about something made of whole words, like clojureforge? It has
the benefit of discoverability and being pronounceable by the human
tongue.
2008/11/17 Matt Revelle [EMAIL PROTECTED]:
Is the project site going to be more similar to the Python package
index and CLiki or Sourceforge?
The closest analog is common-lisp.net.. which is like sourceforge.
However, I like the idea of an index as well, and building the backend
seems like a
I'm in favor of something with clojure in it (like clojureforge).
Something simple to spell and pronounce. I'm also in favor of not
forcing code hosting, but providing it as an option.
Paul
On Mon, Nov 17, 2008 at 4:18 PM, Drew Crampsie [EMAIL PROTECTED] wrote:
2008/11/17 Matt Revelle
Ah! Thank you.
On Nov 17, 2:48 pm, Rich Hickey [EMAIL PROTECTED] wrote:
On Nov 17, 4:22 pm, samppi [EMAIL PROTECTED] wrote:
Inhttp://groups.google.com/group/clojure/browse_thread/thread/62140a28b...,
the following example was given:
(defn test1 [{x :x, y :y, :or {:y 3}}]
[x
On Nov 17, 5:16 pm, Mark Volkmann [EMAIL PROTECTED] wrote:
On Mon, Nov 17, 2008 at 3:48 PM, Rich Hickey [EMAIL PROTECTED] wrote:
On Nov 17, 4:22 pm, samppi [EMAIL PROTECTED] wrote:
Inhttp://groups.google.com/group/clojure/browse_thread/thread/62140a28b...,
the following example was
Mark,
You can read some about destructuring in the documentation for the
special form let:
http://clojure.org/special_forms#let
You can also explore the functionality at the repl:
user= (destructure '[{x :x, y :y, :or {y 3}} given])
[map__59 given y (clojure.core/get map__59 :y 3) x
Thinking about test-is little more...
Lets look at this test for minus:
(deftest test-minus
(all-true
(number? (- 1 2))
(integer? (- 1 2))
(float? (- 1.0 2))
(ratio? (- 2/3 1))
(float? (- 2/3 (/ 1.0 3
(throws IllegalArgumentException (-))
(each=
(- 1)
Hello,
Doing some small experiments I stumbled over map returning a lazy seq instead
of performing the function. I had to convert that to a doseq. Is there any
rationale for not having an eager map. Or was I just not reading the docs
properly?
--
Robert Ewald
On Nov 18, 1:26 am, Robert Ewald [EMAIL PROTECTED] wrote:
Hello,
Doing some small experiments I stumbled over map returning a lazy seq instead
of performing the function. I had to convert that to a doseq. Is there any
rationale for not having an eager map. Or was I just not reading the
On Nov 17, 3:26 pm, Robert Ewald [EMAIL PROTECTED] wrote:
Hello,
Doing some small experiments I stumbled over map returning a lazy seq instead
of performing the function. I had to convert that to a doseq. Is there any
rationale for not having an eager map. Or was I just not reading the
Hi,
Am 18.11.2008 um 00:13 schrieb Frantisek Sodomka:
B) What about 'throws' macro? Could this become a function returning
true/false? Then we could stick it inside 'is' or 'all-true'. (I
guess it
doesn't matter that much, does it?)
I have a is-like construct, which is build-up slightly
Hi Raffael,
On Mon, Nov 17, 2008 at 4:21 PM, Raffael Cavallaro
[EMAIL PROTECTED] wrote:
As the mention of Aquamacs in the title suggests, I'm on Mac OS X.
I've read Bill Clementson's Blog on setting up clojure, and I'm not
exactly a neophyte - I've been using slime with sbcl, openmcl, and
On Nov 17, 5:22 pm, Robert [EMAIL PROTECTED] wrote:
Is there a server that tests every day if Clojure builds correctly? I
pulled the latest a few days ago and couldn't get it to build (whereas
the 2008-09-16 release does build for me). Having such a server
would
assist in determining if
+1 for projecture
=
ANGOL
=
-|[EMAIL PROTECTED], =|+^_^X++~_~,@-
The only thing worse than a hopeless romantic is a hopeful one
Magbasa bago Mamuna. Mag-isip bago mambatikos
Without Truth there is no Justice,
Without Justice, there is Tyranny
Semper fi
Proof of Desire is
On Mon, Nov 17, 2008 at 9:01 PM, Adam Jones [EMAIL PROTECTED] wrote:
I'm in the middle of writing some code to extract sql results, which
means I'm doing a *lot* of forcing right now. It's almost enough for
me to wish there was a convention (and provided definitions) for
denoting lazy/strict
On Nov 14, 3:42 pm, Chouser [EMAIL PROTECTED] wrote:
On Fri, Nov 14, 2008 at 2:11 PM, Jeff Rose [EMAIL PROTECTED] wrote:
Does my dispatch function have to inspect the passed in values to
figure out whichtypeof struct they are, or can I query that
somehow?
My understanding is that
On Nov 17, 8:43 pm, Bill Clementson [EMAIL PROTECTED] wrote:
Rather than ask someone to assemble a package and post it for you, it
is usually nicer (and a better learning experience) if you list
exactly what you did, and post the minimal config scripts that you the
tried out and which
On Nov 17, 2008, at 10:33 PM, Rich Hickey wrote:
Fixed (SVN 1108) - thanks for the report.
Cool, thanks. I especially like loadClassForName.
It seems there's something not quite right, though. I did a fresh
checkout of 1108 and built with ant and ran with java -jar
clojure.jar and got an
How about 'conj'?
conj is (1) for 'conj' in Clojure, and (2) for abbrev of 'conjure',
meaning (Conjuring Clojure).
'cons' for lisp, and 'conj' for clojure. :-)
--
Chul-Woong Yang
On Nov 18, 4:52 am, Drew Crampsie [EMAIL PROTECTED] wrote:
Hey All,
I've finally found some time to start
What a great name 'conj' is, for project hosting site name!
(no shame for self-complement :-) )
user= (def repository '(proj-foo proj-bar))
#=(var user/repository)
user= (conj repository 'proj-yours)
(proj-yours proj-foo proj-bar)
However, conj.net is already occupied. ;-(
conj.us is avaliable,
On Nov 17, 2008, at 11:42 PM, Stephen C. Gilardi wrote:
It seems there's something not quite right, though. I did a fresh
checkout of 1108 and built with ant and ran with java -jar
clojure.jar and got an exception:
Making pushNS public on line 4461 of src/jvm/clojure/lang/
Compiler.java
I'm from the UK, but I live in Munich, Germany.
2008/11/17 [EMAIL PROTECTED] [EMAIL PROTECTED]
+1 for Baltimore.
On Oct 17, 8:12 am, Paul Barry [EMAIL PROTECTED] wrote:
Baltimore, Maryland, US
On Oct 17, 5:27 am, Rastislav Kassak [EMAIL PROTECTED] wrote:
Hello Clojurians,
I
Hi,
On 18 Nov., 03:01, Adam Jones [EMAIL PROTECTED] wrote:
I'm in the middle of writing some code to extract sql results, which
means I'm doing a *lot* of forcing right now. It's almost enough for
me to wish there was a convention (and provided definitions) for
denoting lazy/strict versions
65 matches
Mail list logo