On Dec 12, 6:15 pm, Mark Engelberg mark.engelb...@gmail.com wrote:
On Fri, Dec 12, 2008 at 6:37 AM, Rich Hickey richhic...@gmail.com wrote:
I'm appreciate the time you and others have spent on this, and will
improve filter, but I'm not sure where you are getting your
presumptions about
On Dec 10, 10:52 pm, Stephen C. Gilardi [EMAIL PROTECTED] wrote:
On Dec 10, 2008, at 4:38 AM, Ralf Bensmann wrote:
Being a Java trainer for a long time, we talk with students about
the handle-or-declare rule in Java and the two types of
exceptions: checked (declared) and unchecked
On Dec 8, 7:44 pm, Dave Griffith [EMAIL PROTECTED] wrote:
The basic use case is as a guard for I/O, to prevent them from from
filling the disk/spamming the network accidentally in case of
transaction live-lock. Probably a bit more paranoia than is idiomatic
in the dynamically-typed world,
On Dec 11, 2:28 pm, Christian Vest Hansen karmazi...@gmail.com
wrote:
Wo-hoo! I found a fix.
I think it is only a JVM issue to the extent that the 1.6 JVM might be
able to mask the bug by doing escape analysis or some such other
magic, but that dosn't mean that the bug isn't there.
It's
On Dec 11, 4:37 pm, Stefan Rusek sru...@gmail.com wrote:
If we have the following map:
(def m {:key 1 'sym 2 str 3})
The following are equivalent:
(:key m)
(m :key)
As are the following:
('sym m)
(m 'sym)
I think the commutativity of maps with symbols and keywords is a
valuable
On Dec 11, 5:56 pm, Rich Hickey richhic...@gmail.com wrote:
On Dec 11, 2:28 pm, Christian Vest Hansen karmazi...@gmail.com
wrote:
Wo-hoo! I found a fix.
I think it is only a JVM issue to the extent that the 1.6 JVM might be
able to mask the bug by doing escape analysis or some
On Dec 10, 2008, at 1:50 PM, Stephen C. Gilardi wrote:
On Dec 10, 2008, at 8:51 AM, Stuart Halloway wrote:
Thanks for the info. Is this limitation of user.clj arbitrary, or
motivated by some concern that the average Clojure user should know
about? Is the a reason not to load the bindings
On Wed, Dec 10, 2008 at 4:32 PM, Brian Will [EMAIL PROTECTED] wrote:
A Java reference type is basically any type allocated on the heap. The
four Clojure reference types are particular Java reference types. My
complaint is this is exactly the sort of weirdness that causes
learners to scratch
On Wed, Dec 10, 2008 at 12:45 AM, J. McConnell [EMAIL PROTECTED] wrote:
On Tue, Dec 9, 2008 at 7:05 PM, Rich Hickey [EMAIL PROTECTED] wrote:
Thanks. I think it does a bit too much - I only want to relax the
requirement for namespace-qualification, not any of the other
assertions (e.g
On Mon, Dec 8, 2008 at 7:15 PM, Chouser [EMAIL PROTECTED] wrote:
On Mon, Dec 8, 2008 at 10:42 AM, Rich Hickey [EMAIL PROTECTED] wrote:
On Dec 8, 10:08 am, Chouser [EMAIL PROTECTED] wrote:
doseq currently supports both. If both appear on the same binding,
the :while is always test first
On Dec 9, 12:24 am, Matt Revelle [EMAIL PROTECTED] wrote:
The attached patch adds :super-methods option to generate-class as a
map, {local-name [name [param-types] return-type], ...}. The
mechanics work as Rich suggested in an earlier message, a method is
created that has the same type
On Mon, Dec 8, 2008 at 9:21 AM, J. McConnell [EMAIL PROTECTED] wrote:
On Mon, Dec 8, 2008 at 9:05 AM, Rich Hickey [EMAIL PROTECTED] wrote:
On Dec 7, 9:01 am, Mibu [EMAIL PROTECTED] wrote:
Is it possible to remove the asserts in derive that restrict the
parent and child to namespace-qualified
On Dec 6, 11:12 pm, [EMAIL PROTECTED] [EMAIL PROTECTED]
wrote:
I've moved pretty much all my spare-time projects over to clojure and
it's been a pleasure so far. It's a nice piece of work. It seemed
appropriate to say thanks for it. So thanks!
You're quite welcome!
Rich
On Dec 7, 4:10 pm, Christophe Grand [EMAIL PROTECTED] wrote:
Rich Hickey a écrit : I think the problem is that in the original and
subsequent versions,
work was being done in the current case that needn't be (checking the
status of coll), and that we need more laziness than lazy-cons
On Dec 7, 9:01 am, Mibu [EMAIL PROTECTED] wrote:
Is it possible to remove the asserts in derive that restrict the
parent and child to namespace-qualified names?
It would be much more useful if the asserts are moved to the global-
hierarchy case ([child parent]) and the private hierarchies
On Dec 6, 7:52 pm, André Thieme [EMAIL PROTECTED] wrote:
(for [x (range 1 20) :when ( x 8) :while ( 0 (rem x 13))] x) ==
java.lang.Exception: Unsupported binding form: :while
But:
(for [x (range 1 20) :when ( x 8)] x) ==
(9 10 11 12 13 14 15 16 17 18 19)
And:
(for [x (range 1 20)
On Dec 8, 10:08 am, Chouser [EMAIL PROTECTED] wrote:
On Mon, Dec 8, 2008 at 9:06 AM, Rich Hickey [EMAIL PROTECTED] wrote:
On Dec 6, 7:52 pm, André Thieme [EMAIL PROTECTED] wrote:
(for [x (range 1 20) :when ( x 8) :while ( 0 (rem x 13))] x) ==
java.lang.Exception: Unsupported binding
On Dec 8, 9:30 am, Matt Revelle [EMAIL PROTECTED] wrote:
I'm working on a patch to add support for calling the superclass'
implementation of a method when overriding a method in Clojure with
ns/:genclass. This looks like it requires a modification of the
InstanceMethodExpr class in
On Dec 8, 2008, at 8:56 PM, Stephen C. Gilardi wrote:
I think I finally see the problem. The rest expression in filter's
call to lazy-cons has a reference to coll in it. That's all it
takes for coll to be retained during the entire calculation of the
rest.
(defn filter
Returns a
On Dec 7, 5:29 am, Christophe Grand [EMAIL PROTECTED] wrote:
Chouser a écrit : Testing just now on large collections, the version using
'map' is
indeed not only slower, but also overflows the stack. Hm... and
perhaps I see why now. Is it computing the entire chain up to each
result
On Dec 5, 9:03 am, Stephen C. Gilardi [EMAIL PROTECTED] wrote:
On Dec 5, 2008, at 8:50 AM, Mark McGranaghan wrote:
This is indeed the definition used in the clojure.contrib.pred
library:
http://github.com/kevinoneill/clojure-contrib/tree/master/src/clojure...
That's true. However, with
.
There is class, and, more useful, instance?
Rich
2008/12/5 Rich Hickey [EMAIL PROTECTED]
On Dec 5, 9:03 am, Stephen C. Gilardi [EMAIL PROTECTED] wrote:
On Dec 5, 2008, at 8:50 AM, Mark McGranaghan wrote:
This is indeed the definition used in the clojure.contrib.pred
library
On Dec 3, 11:30 pm, samppi [EMAIL PROTECTED] wrote:
I want to put the Clojure
logo:http://clojure.googlegroups.com/web/Clojure-logo.png?gda=y8lqvUIAAABo...
...on Wikipedia's article on Clojure. What is the license of Clojure's
logo--is it a free image? Or can Mr. Hickley give me
On Dec 4, 2:32 am, puzzler [EMAIL PROTECTED] wrote:
OK, after my last goof-up in reporting a bug, I'm reluctant to state
with certainty that this is a bug, but it sure seems that way:
This works:
(sort [[5 2] [1 0] [3 4]])
This works:
(sort [3243214324324132413243243243243243243234
On Dec 2, 12:52 pm, Jan Rychter [EMAIL PROTECTED] wrote:
Rich Hickey [EMAIL PROTECTED] writes:
On Jun 20, 11:58 am, Jaime Barciela [EMAIL PROTECTED] wrote:
Hello Phil,
My understanding is that Common Lisp doesn't have support for
continuations either and that's why Weblocks uses cl
I've added a new reference type - atom.
Docs here:
http://clojure.org/atoms
Feedback welcome,
Rich
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
Clojure group.
To post to this group, send email to
On Dec 4, 8:01 pm, Randall R Schulz [EMAIL PROTECTED] wrote:
Hi,
I have a fairly elaborate library for representing roughly JSON-like
data. It has the ability to create JavaBean counterparts to any of its
values, whether atomic or structured.
In order to see how this might interact with
On Dec 1, 9:35 pm, Timothy Pratley [EMAIL PROTECTED] wrote:
The reason is simple - plain mutable variables have no concurrency
semantics. What if you closed over a mutable local? Now you have an
object with no synchronization, a concurrency mess.
Thanks Rich for the clarification...
On Dec 2, 8:43 am, Luke Amdor [EMAIL PROTECTED] wrote:
The @ symbol is a reader macro. It's a hard coded table so that when
the reader comes across the @ symbol it knows to instead change it to
a deref call. For eg,
(def a (ref 0))
(dosync (alter inc a))
@a ;; is the same thing as
On Nov 18, 5:35 pm, Stephen C. Gilardi [EMAIL PROTECTED] wrote:
I think Clojure should change to allow (bigdec 3) to succeed.
BigDecimal has a valueOf method that accepts a long. It has a
constructor that accepts an int. I haven't made a bug report on this
yet, but here it is.
SVN 1135
On Dec 2, 4:30 am, Kei Suzuki [EMAIL PROTECTED] wrote:
Hi,
Whenever a seq form is preceded by #^metadata, the metadata is ignored
or only {:line n} is associated with.
For example, these return the metadata as expected:
(meta (with-meta '(1) {:v 1}))
(meta (with-meta (quote (1)) {:v
for building Clojure apps without
runtime codegen, for delivery in those environments that preclude it
(e.g. Android, unsigned applets). Looking forward to feedback from
people trying to reach those targets.
Rich
On Nov 27, 10:32 am, Rich Hickey [EMAIL PROTECTED] wrote:
On Nov 26, 11:06 pm, Chas
On Dec 1, 5:07 pm, Stuart Halloway [EMAIL PROTECTED] wrote:
I am thinking about adding a match method to Clojure-contrib. This
would work like Ruby's threequals (===, a.k.a. case equality) and
would be implemented as a multimethod to do sensible things with a
wide variety of types.
(1)
On Dec 2, 2:37 pm, Perry Trolard [EMAIL PROTECTED] wrote:
Clarification: clojure.lang.Repl's behavior hasn't changed, it's just
that the clojure.main default REPL behaves differently from it. Those
who don't call clojure.main in their clj scripts won't notice a
difference.
Fixed (svn
On Sat, Nov 29, 2008 at 6:17 PM, JMan [EMAIL PROTECTED] wrote:
Consider these 2 interfaces:
- PackagePrivateInterface.java
package test;
interface PackagePrivateInterface {
public void myPublicMethod();
}
- PublicTagInterface.java
package test;
public interface
On Dec 1, 3:03 am, bc [EMAIL PROTECTED] wrote:
Hi all,
I've written a blog post titled Clojure could be to Concurrency-
Oriented Programming what Java was to OOP in which I discuss
Clojure's approach to concurrency:http://bc.tech.coop/blog/081201.html
Any comments/criticisms would be
On Dec 1, 10:19 am, Randall R Schulz [EMAIL PROTECTED] wrote:
Hi,
I looked for a version of (get map key) that would supply a default
value if the key was not present in the map. I was surprised to see (by
looking at the Data Structure documentation page,
On Dec 1, 7:37 pm, Timothy Pratley [EMAIL PROTECTED] wrote:
Local variables are good in these situations
1) You want to accumulate some changes eg:
// sum odds
int x = 0;
for (int i=0; i100; i++) {
if ( i%2==1 ) x+=i; }
;It is relatively easy to rearrange these sort of things into a
On Nov 30, 2008, at 12:14 PM, Randall R Schulz wrote:
On Sunday 30 November 2008 09:06, Randall R Schulz wrote:
Hi,
This is my first Clojure how-to question. I tried to find an answer
on the Wiki and in the list archives, but to no avail.
How do I build up a map one association at a
On Nov 30, 2008, at 5:47 PM, Randall R Schulz wrote:
On Sunday 30 November 2008 13:30, André Thieme wrote:
...
Although a standard reader macro for infix syntax would be a nice
thing to have in Clojure.
...
Am I the only person who thinks this is a dead-end proposal that
should
be
On Nov 29, 2008, at 6:49 AM, Daniel Renfer wrote:
Even if you don't think you'll run into the possibility of blowing
your stack, it's still a good idea to use recur when doing tail call
recursion. The compiler will help you out by making sure it really is
a tail call.
Remember, recur
On Nov 28, 8:21 am, Mark Volkmann [EMAIL PROTECTED] wrote:
I've been learning Clojure for about a month now and like it so far.
In the interest of making it easier to convince other people to give
it a try, I think it would be a good idea to carefully consider some
readability issues before
On Nov 28, 8:36 am, Meikel Brandmeyer [EMAIL PROTECTED] wrote:
Dear Clojurians,
currently the trio of require, use and import is slightly
inconsistent.
While use and require allow either symbols or lists, import only
allows
lists. (The vector notation doesn't make sense for import). So
On Nov 28, 2008, at 11:55 AM, Stephen C. Gilardi wrote:
I am not in favor of creating the directory nor fabricating the
classpath.
Clojure currently creates the directory. Since that appears
unintentional, fixing that would go a long way to improving the
behavior that caught me.
On Nov 28, 4:53 pm, Meikel Brandmeyer [EMAIL PROTECTED] wrote:
Hi,
I noticed a problem with AOT if not all libraries
are compiled. For example contrib only provides
a jar with the sources. Compiling a library using
- say - clojure.contrib.def will compile
clojure.contrib.def with the
On Nov 26, 11:06 pm, Chas Emerick [EMAIL PROTECTED] wrote:
Looks good so far, Rich. Should be a blissfully smooth transition
from the legacy gen-class impl.
This is only tangentially related to the docs you're writing, but I
won't let that stop me:
As you know, I have at least one use
On Nov 27, 11:42 am, Michael Reid [EMAIL PROTECTED] wrote:
gen-class will always create a relationship between the stub class and
the load (__init) class, as well as the namespace in which the
implementations will be found, the naming conventions for matching
etc. It's a high-level
On Nov 27, 8:37 am, lpetit [EMAIL PROTECTED] wrote:
On Nov 27, 1:58 pm, lpetit [EMAIL PROTECTED] wrote:
and the modification of trampoline along these lines :
(defn trampoline [f]
(let [ret (f)]
(cond f
(fn? ret) (recur ret)
(instance?
On Nov 26, 10:28 am, dreish [EMAIL PROTECTED] wrote:
Now that you've gone this far, why not do this?
- class clojure.lang.TailCall contains an AFn
- Compiler checks for a tail call position and instead of calling it,
returns new TailCall(AFn)
- In invoke, while returnvalue instanceof
On Nov 26, 2:35 pm, Mark Volkmann [EMAIL PROTECTED] wrote:
On Wed, Nov 26, 2008 at 1:13 PM, Shawn Hoover [EMAIL PROTECTED] wrote:
On Wed, Nov 26, 2008 at 1:55 PM, Mark Volkmann [EMAIL PROTECTED]
wrote:
The documentation for commute says Sets the in-transaction-value of
ref This
On Nov 26, 5:13 pm, Stephen C. Gilardi [EMAIL PROTECTED] wrote:
On Nov 24, 2008, at 11:57 AM, Stephen C. Gilardi wrote:
I've uploaded a patch along those lines:
ant-compile-main.patch,http://tinyurl.com/5azp3u
based on our recent work on this. This includes Compile.java,
main.clj,
I've started documenting AOT compilation and the new :gen-class option
for ns:
http://clojure.org/compilation
It's still a work in progress. Feedback welcome.
Rich
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
On Nov 26, 9:17 pm, Mark Volkmann [EMAIL PROTECTED] wrote:
This is probably more of a Java question than a Clojure question. I'm
thinking most people will want clojure-contrib in their classpath. I
tried this using SVN 1127 without success.
java -cp clojure-contrib.jar -jar clojure.jar
On Nov 25, 12:51 am, [EMAIL PROTECTED] [EMAIL PROTECTED]
wrote:
On Nov 25, 12:50 am, [EMAIL PROTECTED] [EMAIL PROTECTED]
wrote:
On Nov 25, 12:22 am, [EMAIL PROTECTED] [EMAIL PROTECTED]
wrote:
This approach might just be too inefficient -- perhaps it would be
best to implement the
On Nov 25, 10:42 am, Stephen C. Gilardi [EMAIL PROTECTED] wrote:
On Nov 25, 2008, at 9:05 AM, Rich Hickey wrote:
I've added trampoline to ease the conversion/creation of mutually
recursive algorithms in Clojure.
Very cool! Thanks for enabling that.
In looking over the implementation
On Nov 24, 2:41 am, [EMAIL PROTECTED] [EMAIL PROTECTED]
wrote:
On Nov 24, 12:41 am, Kevin Downey [EMAIL PROTECTED] wrote:
I don't think you understand. clojure data structures are IMMUTABLE.
every call to conj, or anyother function returns a new object. To
optimize there is sharing of
On Nov 23, 9:09 am, James Reeves [EMAIL PROTECTED] wrote:
On Nov 23, 11:38 am, [EMAIL PROTECTED] [EMAIL PROTECTED]
wrote:
Hi,
According tohttp://clojure.org/reader:
Keywords are like symbols, except:
o They can and must begin with a colon, e.g. :fred.
o They
On Nov 24, 7:22 pm, dokondr [EMAIL PROTECTED] wrote:
Providing that Clojure is NOT a pure functional language like Haskell,
yet how can I isolate imperative-style computational structures from
the main body of the functional program?
You can't, other than manually.
How can I ensure
On Nov 21, 3:17 am, Mark McGranaghan [EMAIL PROTECTED] wrote:
I've created some experimental HTML docs for Clojure. You can see them
on S3:http://clj-doc.s3.amazonaws.com/tmp/doc-1116/index.html
Or, just for kicks, on Amazon's new Cloud Front
numeric types.
Rich
On Nov 23, 3:42 pm, Rich Hickey [EMAIL PROTECTED] wrote:
On Nov 23, 8:56 am, Rock [EMAIL PROTECTED] wrote:
On Nov 23, 2:37 pm, André Thieme [EMAIL PROTECTED] wrote:
On 23 Nov., 13:29, Rock [EMAIL PROTECTED] wrote:
I've just noticed there is no support
On Nov 22, 1:07 pm, [EMAIL PROTECTED] wrote:
In one of my data structures I have a vector as a buffer where things
are appended to. In addition the things in that buffer sometimes get
modified using map or filter. Now as map and filter return sequences I
wonder how to get a vector back
On Nov 22, 4:59 pm, [EMAIL PROTECTED] [EMAIL PROTECTED]
wrote:
On Nov 22, 9:48 pm, Rich Hickey [EMAIL PROTECTED] wrote:
map and filter don't modify anything. What does it mean to filter a
vector?
Yes yes, I know that. Still in English its sometimes easier to be
sloppy and pretend
On Nov 20, 4:42 pm, Stuart Sierra [EMAIL PROTECTED] wrote:
On Nov 20, 2:14 pm, Stephen Wrobleski [EMAIL PROTECTED] wrote:
Furthermore, requiring the use of (ns ..) to create a class makes defining a
class with a macro somewhat tedious (seems like you'd have to bind *ns*, so
that (ns ..)
On Nov 21, 11:40 am, samppi [EMAIL PROTECTED] wrote:
Yes, thank you—(key) and (val) were what I was interested in, so I'll
use the latter function you gave. What I'm wondering though is, if
MapEntries aren't guaranteed for the future, what is being planned for
(key) and (val) too. Oh, well.
On Nov 21, 12:36 pm, Brett Hoerner [EMAIL PROTECTED] wrote:
I've watched a lot of Clojure videos now, and keep hearing Rich
mention Henry Baker's egal. Does someone have the actual paper
title where Baker talks about this? I have an ACM subscription (and
assume that's where I'd find it) -
On Nov 21, 4:20 pm, Craig McDaniel [EMAIL PROTECTED] wrote:
Testing the new (ns ... :genclass ...), I copied Rich's example
fromhttp://paste.lisp.org/display/70665:
(ns my.hello
(:gen-class
:extends javax.swing.DefaultCellEditor
:constructors {[Integer] [javax.swing.JCheckBox]}
On Nov 20, 6:39 am, Meikel Brandmeyer [EMAIL PROTECTED] wrote:
Hi,
On 20 Nov., 11:29, Rock [EMAIL PROTECTED] wrote:
I was what the difference might be with respect to this:
`(let [frame ~frame]
(.setTitle frame ~title)
(.setVisible frame)
frame)
This won't work, since
On Nov 20, 12:18 am, Chouser [EMAIL PROTECTED] wrote:
Since SVN rev 1110:
user= (compile 'clojure.contrib.str-utils)
java.lang.Exception: Namespace name must match file, had:
clojure.contrib.str-utils and clojure/contrib/str_utils.clj
(NO_SOURCE_FILE:0)
I think the only problem is that
On Nov 20, 7:38 am, Meikel Brandmeyer [EMAIL PROTECTED] wrote:
Hi,
On 20 Nov., 13:30, Rich Hickey [EMAIL PROTECTED] wrote:
Yes. Please use auto-gensyms (name#):
`(let [frame# ~frame]
(.setTitle frame# ~title)
(.setVisible frame#)
frame#)
With this specific example, my
On Nov 20, 12:37 pm, Feng [EMAIL PROTECTED] wrote:
I start getting StringIndexOutOfBoundException since svn rev 1113 (use
source name in smap).
Fixed - rev 1120 - thanks for the report.
Rich
--~--~-~--~~~---~--~~
You received this message because you are
On Nov 20, 11:28 am, Stephen C. Gilardi [EMAIL PROTECTED] wrote:
Currently the compiler writes classes to the hierarchy under the value
of *compile-path* whose root binding is classes.
As we see in Stuart's build.xml patch, it can convenient to be able to
specify such a path as part of the
On Sep 30, 1:17 pm, Allen Rohner [EMAIL PROTECTED] wrote:
Thanks. The summit was really fantastic - so many interesting and
smart people and lots of great presentations and conversations. Left
me exhausted and a bit MIA here, which I'm afraid will continue
through my talk Monday at the
On Oct 23, 9:53 am, Rich Hickey [EMAIL PROTECTED] wrote:
On Oct 21, 10:30 am, mb [EMAIL PROTECTED] wrote:
Hi,
On 21 Okt., 14:41, mb [EMAIL PROTECTED] wrote: (defmacro doto-
The name is actually also up to discussion. doto is already
in use and this change is incompatible to legacy
On Nov 19, 1:12 pm, Raffael Cavallaro [EMAIL PROTECTED]
wrote:
user (def test-array (make-array (. Boolean TYPE) 100))
#'user/test-array
user (aget test-array 0)
false
user (= (aget test-array 0) false)
true
user (if (aget test-array 0) 'true-value 'false-value)
true-value
Same issue
On Nov 19, 6:51 pm, mifrai [EMAIL PROTECTED] wrote:
I know it's minor and nit-picky but so long as we're rolling out so
many breaking changes is it possible to reclaim scan and touch instead
of leaving dead functions that need an :exclude?
Yes, done.
Rich
On Nov 18, 2008, at 12:53 AM, Stephen C. Gilardi wrote:
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
On Tue, Nov 18, 2008 at 3:14 AM, Toralf Wittner [EMAIL PROTECTED]wrote:
On Sun, 2008-11-16 at 01:35 +0100, [EMAIL PROTECTED] wrote:
Currently agent errors are only reported when the agent is derefenced
or further actions are dispatched to the agent. It would be great if
one can get
On Tue, Nov 18, 2008 at 9:42 AM, Raffael Cavallaro
[EMAIL PROTECTED] wrote:
On Nov 18, 1:46 am, Cosmin Stejerean [EMAIL PROTECTED] wrote:
What kind of bugs are acceptable for the
purpose of a known good combination? Is slime starting up sufficient?
It's a whole lot better than slime
On Nov 18, 2:48 pm, Konrad Hinsen [EMAIL PROTECTED] wrote:
On 18.11.2008, at 19:32, Shawn Hoover wrote:
For functions defined in libs that you load into Clojure, you can
find out the file and line from the metadata. For functions you
define in the REPL, this trick won't help. Say you
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, 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/
clj
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
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
On Nov 16, 7:59 am, Jeff Rose [EMAIL PROTECTED] wrote:
Thanks for responding. I had already seen the shebang script hack on
the wiki, and although impressive I don't think it's a solution. It's
shocking to me that someone who is into lisp would even think of getting
rid of read macros
first post to the group, but have been following the
discussions for almost a year. Many thanks to Rich Hickey for creating
a fantastic future-proof language which is a pleasure to use and to
the great community!
The following function (as part of a chemistry-related application)
filters
On Nov 16, 9:47 pm, Stuart Sierra [EMAIL PROTECTED]
wrote:
Hi Rich, and all,
I took a stab at writing a static compiler class, i.e. a main() that
just compiles all the .clj files on the command line and saves the
.class files. Patch attached.
It almost works. The only thing that seems
On Nov 15, 12:09 am, Brian Doyle [EMAIL PROTECTED] wrote:
Another way to create a map is:
user= (apply hash-map [:a 1 :b 2 :c 3])
{:a 1, :c 3, :b 2}
Yes, that's fine, and for the flatten:
(interleave (keys m) (vals m))
Rich
On Fri, Nov 14, 2008 at 9:42 PM, samppi [EMAIL PROTECTED]
On Nov 14, 12:51 pm, Stuart Sierra [EMAIL PROTECTED]
wrote:
Patch attached. This precompiles everything except parallel.clj,
which requires an extra Jar. It also omits the source .clj files from
the clojure.jar file.
-Stuart Sierra
Patch applied (svn 1101) - thanks!
Rich
On Nov 13, 8:36 am, Stuart Halloway [EMAIL PROTECTED] wrote:
Hi Meikel,
I spent a few minutes trying to write a macro to do this that doesn't
use eval. So far no good. Is it truly impossible, though? I have never
seen a good discussion of things that can be done only with eval.
Any
Some people have asked how to donate to Clojure, so I've turned
donations on in SF:
https://sourceforge.net/project/project_donations.php?group_id=137961
Thanks to all for your support!
Rich
--~--~-~--~~~---~--~~
You received this message because you are
We're coming around the other side of the few breaking changes I
wanted to get done before release 1.0.
The changes are:
New regex format:
http://groups.google.com/group/clojure/msg/eddd7f0d292da683
Uniform binding syntax using vectors:
On Nov 13, 2:31 pm, Stuart Halloway [EMAIL PROTECTED] wrote:
(clojure.core/ns clojure)
or if you are on an old build I think it would be
(clojure/ns clojure)
This is coming in my book notes, I promise :), but ns should not be
used to change namespaces in the repl, only in-ns should be
On Nov 13, 11:20 pm, Parth Malwankar [EMAIL PROTECTED]
wrote:
Hello,
While setting ns to clojure.zip, I get the following error:
user= (ns clojure.zip)
java.lang.IllegalStateException: replace already refers to:
#'clojure.zip/replace in namespace: clojure.zip (NO_SOURCE_FILE:0)
On Nov 12, 6:49 pm, samppi [EMAIL PROTECTED] wrote:
Onhttp://clojure.org/reader...
A shorthand version allows the metadata to be a simple symbol or
keyword, in which case it is
treated as a single entry map with a key of :tag and a value of
the symbol provided, e.g.:
#^String
On Nov 12, 7:21 pm, samppi [EMAIL PROTECTED] wrote:
Ah, yes. I meant, what are these hints? What does the compiler change?
Is it some sort of informal type enforcement or something?
The hints are described here:
http://clojure.org/java_interop#typehints
It is strictly a performance
On Nov 10, 2008, at 8:48 AM, Robert Lally wrote:
One of the many things that I really like about Clojure is that it
abandoned Lisp tradition where it was pragmatic to do so. One of the
prime examples for me was the use of first and rest rather than car
and cdr. Sure, I can read code
On Nov 10, 2008, at 9:46 AM, Graham Fawcett wrote:
Hi folks,
I haven't been bitten by the do not use revisions, R1089 onward, but
it seems that others have.
I'm just curious why the team decided not to use a branch for these
breaking changes, and merging back with trunk once the
On Nov 10, 10:17 am, Rich Hickey [EMAIL PROTECTED] wrote:
On Nov 10, 2008, at 9:46 AM, Graham Fawcett wrote:
Hi folks,
I haven't been bitten by the do not use revisions, R1089 onward, but
it seems that others have.
I'm just curious why the team decided not to use a branch
On Nov 9, 8:21 am, Stuart Halloway [EMAIL PROTECTED] wrote:
You should be able to do this without the ref. Have the agent's state
contain a pair of [has-run, fn-result].
The semantics of your runonce aren't clear to me, but here are some
strategies:
As Chouser proposed, if you only want a
701 - 800 of 917 matches
Mail list logo