Re: Test wether something is an atom (as it is known in Scheme)

2008-12-05 Thread Rich Hickey
On Dec 5, 10:28 am, "Arie van Wingerden" <[EMAIL PROTECTED]> wrote: > Hi Rich, > > right. But still I think Meikel has got a valid point that a function would > need to be defined for that. > > I also wondered whether a kind of type? function would be appropriate. > So (type? 3) would return in

Re: Test wether something is an atom (as it is known in Scheme)

2008-12-05 Thread Rich Hickey
On Dec 5, 9:07 am, Meikel Brandmeyer <[EMAIL PROTECTED]> wrote: > Hi, > > On 5 Dez., 15:03, "Stephen C. Gilardi" <[EMAIL PROTECTED]> wrote: > > > That's true. However, with Clojure now having a specific meaning for > > "atom" that's different from that of the larger Lisp world, I'm > > wondering

Re: Test wether something is an atom (as it is known in Scheme)

2008-12-05 Thread Arie van Wingerden
Hi Rich, right. But still I think Meikel has got a valid point that a function would need to be defined for that. I also wondered whether a kind of type? function would be appropriate. So (type? 3) would return integer etc. Arie 2008/12/5 Rich Hickey <[EMAIL PROTECTED]> > > > > On Dec 5, 9:03

Re: Test wether something is an atom (as it is known in Scheme)

2008-12-05 Thread Arie van Wingerden
Hi Mark, didn't know about that. But I'm glad it appears to be okay then. Arie 2008/12/5 Mark McGranaghan <[EMAIL PROTECTED]> > > This is indeed the definition used in the clojure.contrib.pred library: > > http://github.com/kevinoneill/clojure-contrib/tree/master/src/clojure/contrib/pred.clj#L4

Re: Test wether something is an atom (as it is known in Scheme)

2008-12-05 Thread Rich Hickey
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.

Re: Test wether something is an atom (as it is known in Scheme)

2008-12-05 Thread Meikel Brandmeyer
Hi, On 5 Dez., 15:03, "Stephen C. Gilardi" <[EMAIL PROTECTED]> wrote: > That's true. However, with Clojure now having a specific meaning for   > "atom" that's different from that of the larger Lisp world, I'm   > wondering if it would be a good idea to remove atom? from pred.clj. > > Feedback wel

Re: Test wether something is an atom (as it is known in Scheme)

2008-12-05 Thread Stephen C. Gilardi
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/contrib/pred.clj#L45 That's true. However, with Clojure now having a specific meaning for "

Re: Test wether something is an atom (as it is known in Scheme)

2008-12-05 Thread Mark McGranaghan
This is indeed the definition used in the clojure.contrib.pred library: http://github.com/kevinoneill/clojure-contrib/tree/master/src/clojure/contrib/pred.clj#L45 - Mark M. On Fri, Dec 5, 2008 at 8:07 AM, Arie van Wingerden <[EMAIL PROTECTED]> wrote: > Hi, > > I am learning Clojure by working th

Test wether something is an atom (as it is known in Scheme)

2008-12-05 Thread Arie van Wingerden
Hi, I am learning Clojure by working thru Kent Dybvigs book in Scheme and Clojure at the same time. A nice way to discover the differences ;-) I wonder if the next definition is appropriate to test if something ia an atom (as Scheme sees it): (defn atom? [x] (not (coll? x))) Thx, Arie