Hi Patrick,
Sorry for requesting code you already posted.
I'm quite unsure about what functions (in particular get-key-instance)
should do.
Btw there's two easy ways to test if a collection is empty in clojure
(rather than (= 0 (count coll))):
(empty? coll) ;; true when empty
or (seq coll)
2009/4/28 jim jim.d...@gmail.com:
Hey Antonio,
I'm getting a similar error. I wanted to call setuid from Clojure, so
I followed this link's example:
http://www2.sys-con.com/itsg/virtualcd/Java/archives/0510/Silverman/index.html
to build a java class and a shared library. I added the class
http://ianp.org/2009/04/embedding-clojure-in-an-existi
Also, since writing thse notes down I've worked out getting my app
data into Clojure; that, combined with Christophe's notes about and
I'm pretty much set to go for most of what I want to do.
Notes and code snippets here
I'm trying to create a macro that will splice in some additional
elements to a structure. If I have an input struture like so:
(p (s (c foo bar)) (s (c baz qux)))
I'd like to be able to do (splice grp layout (rest my-data)) and have
it return:
((s grp layout (c foo bar)) (s grp layout
ianp a écrit :
I'm trying to create a macro that will splice in some additional
elements to a structure. If I have an input struture like so:
(p (s (c foo bar)) (s (c baz qux)))
I'd like to be able to do (splice grp layout (rest my-data)) and have
it return:
((s grp layout (c foo
On Tue, Apr 28, 2009 at 1:56 AM, jim jim.d...@gmail.com wrote:
[...]
Finally discovered what I think is a bug in the ng-server script. The
find command has a '1' between the -depth and -print0. Removing
[...]
I believe the find command on OS X (and probably on *BSD) treats
-depth n like the
On Tue, Apr 28, 2009 at 9:39 AM, Christophe Grand christo...@cgrand.net wrote:
[...]
`~sbody is equivalent to body
[...]
I think you mean it is equivalent to sbody.
--
Michael Wood esiot...@gmail.com
--~--~-~--~~~---~--~~
You received this message because you
On Apr 22, 9:41 am, Antonio, Fabio Di Narzo
antonio.fa...@gmail.com wrote:
Hi all.
I'm having problems with using swig-generated wrappers with Clojure.
I'm running ubuntu-8.04-i386, gcc-4.2.4, swig-1.3.33, openjdk-1.6.0,
latest clojure release.
I've cut down a minimal reproducible
On Apr 27, 10:04 pm, Boris Mizhen bo...@boriska.com wrote:
Thanks to all who replied.
To summarize what I learned - Clojure has a special form (. ) to
*call* java functions, but does not have concept of a *value*
corresponding to a java function.
This makes Java functions a second class
On Apr 27, 4:26 pm, Boris Mizhen bo...@boriska.com wrote:
Hello all,
It seems to me that areduce can not be used with an anonymous array.
Consider:
(areduce (.. System getProperties values toArray) i r 0
(some_expression))
It seems to me that there is no way to get i'th element of the
2009/4/28 Rich Hickey richhic...@gmail.com:
On Apr 22, 9:41 am, Antonio, Fabio Di Narzo
antonio.fa...@gmail.com wrote:
Hi all.
I'm having problems with using swig-generated wrappers with Clojure.
I'm running ubuntu-8.04-i386, gcc-4.2.4, swig-1.3.33, openjdk-1.6.0,
latest clojure release.
It works for me. Are you trying to look up a built-in clojure function
or one from your own application? How did you install SLIME and
swank-clojure etc?
Any ideas with the problem? I provided all the info in the earlier mail.
This issue is really biting me :)
Regards,
BG
--
Baishampayan
On Mon, Apr 27, 2009 at 3:08 AM, Baishampayan Ghose b.gh...@ocricket.comwrote:
Phil,
It works for me. Are you trying to look up a built-in clojure function
or one from your own application? How did you install SLIME and
swank-clojure etc?
It doesn't work for either. When I try looking
On Apr 27, 5:01 pm, Laurent PETIT laurent.pe...@gmail.com wrote:
New patch with corrections posted to google code,
That patch has been applied. I recommend everyone who is able to
please try out the latest version from SVN - this will become a
release candidate. The patch generates jar files
Hi,
2009/4/28 Rich Hickey richhic...@gmail.com:
On Apr 27, 5:01 pm, Laurent PETIT laurent.pe...@gmail.com wrote:
New patch with corrections posted to google code,
That patch has been applied. I recommend everyone who is able to
please try out the latest version from SVN - this will
On Apr 28, 2009, at 15:26, Rich Hickey wrote:
That patch has been applied. I recommend everyone who is able to
please try out the latest version from SVN - this will become a
release candidate.
After modifying my build scripts to take into account the new name of
the jar file, all the
Shouldn't ant clean remove all generated files, including jars from
the source tree?
--~--~-~--~~~---~--~~
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
2009/4/28 Marko Kocić marko.ko...@gmail.com:
Shouldn't ant clean remove all generated files, including jars from
the source tree?
I also asked this to myself, but it was the previous behaviour and I
didn't want to do more than one thing in the patch.
Shawn,
In case of a function that I wrote somewhere in a file and loaded in
SLIME, I get an exception - java.lang.StringIndexOutOfBoundsException:
String index out of range: -1 (NO_SOURCE_FILE:0) (in *Messages* I get
funcall: Synchronous Lisp Evaluation aborted)
I don't
2009/4/28 Laurent PETIT laurent.pe...@gmail.com:
2009/4/28 Marko Kocić marko.ko...@gmail.com:
Shouldn't ant clean remove all generated files, including jars from
the source tree?
I also asked this to myself, but it was the previous behaviour and I
didn't want to do more than one thing in
Now that the files are versioned, should ant clean do
* 1. a brute force equivalent of rm clojure*.jar in %CLOJURE_INSTALL%
* 2. or just try to delete clojure jars with names equal to the
current values in version.properties
I prefer 1., since with 2. if version numbers have changed in
Thanks Rich,
What's correct is what is documented here: http://clojure.org/java_interop
RTFM is still very relevant :)
Boris
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
Clojure group.
To post to this group,
Hi,
Am 28.04.2009 um 01:56 schrieb jim:
java.lang.NoClassDefFoundError: clojure/lang/APersistentMap (wrong
name: clojure/proxy/clojure/lang/APersistentMap)
This is a sign, that the clojure.jar is missing from the classpath.
Please change the -depth to -maxdepth (keeping the one) as
was noted
Hi,
Am 28.04.2009 um 09:26 schrieb ianp:
(defmacro create-form [#^Container container #^Map components
body]
(let [layout (GroupLayout. container)]
(.setLayout container layout)
...))
Please note, that these annotations are wrong. Since
create-form is a macro, container
FYI, for those interested in using Git for Clojure sources, here's
Google's advice on how to use Git with Google Code:
http://google-opensource.blogspot.com/2008/05/develop-with-git-on-google-code-project.html
-SS
--~--~-~--~~~---~--~~
You received this message
Hello,
I want to use line-seq, and have it close the input reader.
My first attempt was
(with-open [stream (BufferedReader.)]
(line-seq stream))
Which crashes immediately because you can't read lines from a closed
seq. So, the only way to explicitly close the reader associated with
line-seq is
Dear Clojurians,
Am 28.04.2009 um 15:26 schrieb Rich Hickey:
Feedback welcome,
I updated my Clojure+Ivy patch to use the new
version information. Using the publish target is
only possible on none-interim releases and
publishes the given version.
publish-local will use SVNAnt to extract the
On Tue, Apr 28, 2009 at 2:33 AM, Baishampayan Ghose
b.gh...@ocricket.com wrote:
It works for me. Are you trying to look up a built-in clojure function
or one from your own application? How did you install SLIME and
swank-clojure etc?
Any ideas with the problem? I provided all the info in the
Hi,
Am 28.04.2009 um 19:01 schrieb Bradbev:
Is it a good idea for line-seq to close its BufferedReader when there
is no more data? Or at least provide an optional parameter that
allows/disallows close?
The cleanest solution with respect to lazy sequences is
realisation.
(with-open [rdr
Success!
After changing ng-server to be correct, I set up CLOJURE_EXT and
CLASSPATH, then called it. Calling ng from the command line showed
that it still couldn't find clojure-contrib.jar, so I added that to
CLASSPATH. Then calling ng from the command line gave me 'usr'.
Gvim was still failing
Hi,
Am 28.04.2009 um 20:24 schrieb jim:
Success!
\o/ Good to hear. Will fix the launcher script.
After changing ng-server to be correct, I set up CLOJURE_EXT and
CLASSPATH, then called it. Calling ng from the command line showed
that it still couldn't find clojure-contrib.jar, so I added
Phil,
I suspect the problem might have to do with the fact that you're
configuring slime for both SBCL and Clojure. I know it's possible to
get this working, but it's a lot more complicated that way. I'd
suggest having one file for clojure slime config and one for sbcl, and
only load one of
clojure.contrib-duck-streams has a similar function, read-lines, that
does close the Reader after all the lines have been read (and the
sequence consumed). It's not entirely safe, because if an exception
or something prevents you from reading all the lines, the Reader
remains open.
-Stuart
Meikel,
I've been poking at vimclojure and I like it. I'm looking forward to
get good at using it. So far, I've changed it so that the preview
window and new REPL's open to the right of the current window.
One question, is it possible to restart a REPL so that any definitions
loaded previously
Hi,
Am 28.04.2009 um 21:55 schrieb jim:
I've been poking at vimclojure and I like it. I'm looking forward to
get good at using it. So far, I've changed it so that the preview
window and new REPL's open to the right of the current window.
The next version will have a vimclojure#SplitPos so
On Apr 28, 12:53 pm, Stuart Sierra the.stuart.sie...@gmail.com
wrote:
clojure.contrib-duck-streams has a similar function, read-lines, that
does close the Reader after all the lines have been read (and the
sequence consumed). It's not entirely safe, because if an exception
or something
Hello all,
I am starting to learn clojure. I would appreciate comments on the
utility function below.
Coding style, idiomatic Clojure, comment style, efficiency, naming
conventions, indentations (used slime) ... anything I should
improve :)
(defn seq-to-multimap [s key-fn]
takes a sequence s
Git still sucks on windows :\
On Apr 28, 11:04 am, Stuart Sierra the.stuart.sie...@gmail.com
wrote:
FYI, for those interested in using Git for Clojure sources, here's
Google's advice on how to use Git with Google Code:
http://google-opensource.blogspot.com/2008/05/develop-with-git-on-goo...
The position setting sounds good.
As far as the new REPL goes, in much of my code, I set the namespace
and I would like to have all those blown away as well. Would it be
possible to add a command to the nailgun server that would cause it to
shutdown and automatically restart? Alternatively, I
On Apr 28, 10:45 am, Meikel Brandmeyer m...@kotka.de wrote:
Hi,
Am 28.04.2009 um 19:01 schrieb Bradbev:
Is it a good idea for line-seq to close its BufferedReader when there
is no more data? Or at least provide an optional parameter that
allows/disallows close?
The cleanest solution
Hi Boris, welcome to Clojure!
This function looks reasonable to me. In your example, you don't need
to write #(identity %) -- just identity is enough. If you want to
preserve the order of objects in the sequence, you can use a vector
instead of a list.
I would use contains? in the conditional
Thanks Stuart,
preserving order is a nice touch :)
I also did not realize that conj preserves sequence type ...
BTW, I hope I'm not abusing this mailing list by asking questions like
this?
Boris
On Apr 28, 5:15 pm, Stuart Sierra the.stuart.sie...@gmail.com wrote:
Hi Boris, welcome to
Hi Boris,
Boris Mizhen a écrit :
I am starting to learn clojure. I would appreciate comments on the
utility function below.
Coding style, idiomatic Clojure, comment style, efficiency, naming
conventions, indentations (used slime) ... anything I should
improve :)
(defn seq-to-multimap [s
Marko Kocić marko.ko...@gmail.com writes:
Since Clojure seems like feature complete for 1.0 release, I am
starting to be curious what are the features planned for after 1.0
release?
You can check the issues list:
http://code.google.com/p/clojure/issues/list
These are mostly bug fixes
Hi,
Am 28.04.2009 um 23:28 schrieb Boris Mizhen:
BTW, I hope I'm not abusing this mailing list by asking questions like
this?
This list and the #clojure channel are the right place to ask
such questions. That said, there is the search facility of google
groups and the log of the channel at
(defn seq-to-multimap
takes a sequence s of possibly repeating elements
and converts it to a map, where keys are obtained by applying key-
fn
to elements of s and values are sequence of all elements of s with
the particular key
[s key-fn]
(apply merge-with concat
(map (fn [x]
I just wanted to chime in and say I'm also a fan of vimclojure. I find
it to be one of the more enjoyable dev environments I've worked in and
the ability to send arbitrary expressions to the REPL is really
convenient. I have found a few issues with it though, and I'm
wondering what the
Likewise a real fan!
In the absence of an issue tracker at this time, could I mention the
following relating to indenting;
(defn xxx
Some stuff...
(defmacro xxx
Some stuff...
(defroutes xxx
Some stuf...
That is, the indenting starts under the argument for non-recognised
On Tue, Apr 28, 2009 at 4:36 PM, Rayne disciplera...@gmail.com wrote:
Git still sucks on windows :\
On which grounds?
Or as wikipedia would put it [citation needed]
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
49 matches
Mail list logo