Re: characters permitted in symbols??

2010-03-31 Thread Meikel Brandmeyer
Hi, On Apr 1, 6:58 am, Douglas Philips wrote: > According to:http://clojure.org/reader > Symbols begin with a non-numeric character and can contain   > alphanumeric characters and *, +, !, -, _, and ? (other characters   > will be allowed eventually, but not all macro characters have been   > de

printf question

2010-03-31 Thread Mark Engelberg
printf doesn't seem to do anything inside a gen-class -main function, when run from the executable jar program (compiled by the latest Netbeans Enclojure release). Is this normal, and if so, what's the workaround? Thanks, Mark -- You received this message because you are subscribed to the Goog

Re: formatting hex string

2010-03-31 Thread Mark J. Reed
On Thu, Apr 1, 2010 at 12:29 AM, Armando Blancas wrote: > But if numbers should default to positive but not be coerced to > negative, e.g., a -189 just for (short -0xBD) this might work, using > nil for out of range values: Yeah, but I was assuming (insert standard caveat here) that the goal is t

characters permitted in symbols??

2010-03-31 Thread Douglas Philips
According to: http://clojure.org/reader Symbols begin with a non-numeric character and can contain alphanumeric characters and *, +, !, -, _, and ? (other characters will be allowed eventually, but not all macro characters have been determined). ... It seems that '>' is permitted in 1.1, a

Re: formatting hex string

2010-03-31 Thread Armando Blancas
> The full, future-proof solution is something like this: > > (map #(let [n (Integer/parseInt % 16)] (short (if (bit-test n 15) > (bit-or n -65536) (bit-and n 65535 ["ff43" "0032"]) (-189 50) But if numbers should default to positive but not be coerced to negative, e.g., a -189 just for (shor

Getting started embedding Clojure into an existing codebase

2010-03-31 Thread Josh Daghlian
I greatly appreciate the excellent recent spate of “getting started” discussions/docs, and I’ve had no trouble at all in bootstrapping new Clojure projects. But I wonder if there is (yet? anymore?) a canonical way of embedding Clojure into my existing codebase without refactoring my existing deploy

Re: formatting hex string

2010-03-31 Thread Mark J. Reed
On Wednesday, March 31, 2010, Richard Newman wrote: > > ur=> (map #(Integer/parseInt % 16) ["ff43" "0032"]) > (65347 50) > > > ...that yields ints, not shorts. > > > At the risk of diverging from the question: why are you concerned with the > specific type of the number? I am because the OP was.

Re: formatting hex string

2010-03-31 Thread Richard Newman
ur=> (map #(Integer/parseInt % 16) ["ff43" "0032"]) (65347 50) ...that yields, not shorts. At the risk of diverging from the question: why are you concerned with the specific type of the number? You realize that Java doesn't allocate less memory for a short than for an int, right? The on

Re: formatting hex string

2010-03-31 Thread Mark J. Reed
On Wed, Mar 31, 2010 at 7:22 PM, Glen Rubin wrote: > I have a sequence of hex strings, e.g. > > "ff43" "0032" ... (you get the idea) > > I want to use clojure's short form on them, but short expects an > authentic hex input, e.g. > > (short 0xff43) > > it will not accept something like (short "0xf

Clojure Added to "Casting SPELs" Site

2010-03-31 Thread Conrad
Hi, just wanted you folks know I've put up a Clojure version of my "Casting SPELs" tutorial on macros. I want to thank Wei-Ju Wu for putting it together, with new code and a nicely updated text. http://www.lisperati.com/clojure-spels/casting.html That being said... my "Casting SPELs" tutorial is

New release of Enclojure is up (v1.1) with the labrepl included as a sample project.

2010-03-31 Thread Eric Thorsen
http://groups.google.com/group/enclojure/browse_thread/thread/70ed4602a3577924 I'm working on a standalone downloadable version of Netbeans with the Enclojure plugin already installed to make things easier for those coming from never working with a Java IDE before. I hope to have a couple of shor

Re: formatting hex string

2010-03-31 Thread Richard Newman
"ff43" "0032" ... (you get the idea) I want to use clojure's short form on them, but short expects an authentic hex input, e.g. (short 0xff43) it will not accept something like (short "0xff43") Any suggestions would be gratefully appreciated!! user=> (map #(Integer/parseInt % 16) ["ff43" "00

formatting hex string

2010-03-31 Thread Glen Rubin
I have a sequence of hex strings, e.g. "ff43" "0032" ... (you get the idea) I want to use clojure's short form on them, but short expects an authentic hex input, e.g. (short 0xff43) it will not accept something like (short "0xff43") Any suggestions would be gratefully appreciated!! -- You re

Re: labrepl issues & feedback from the Dundee Clojure Dojo

2010-03-31 Thread Rick Moynihan
One other issue I forgot to mention, is that all of the Netbeans installs did not manage to download a copy of clojure-1.2.0 and clojure-contrib-1.2.0. Things still seemed to work (presumably because of the Enclojure clojure install)... Could this be due to the artifact at build.clojure.org/snaps

Re: Set performance

2010-03-31 Thread Krukow
On Mar 29, 10:21 pm, Krukow wrote: > Hello, [snip..] > What was surprising to me wasn't that "inserts" are slower - that is > ok and it could be improved with transients. The surprising thing was > that iterating through the entire set was significantly slower. [snip..] I've dug through the sou

Re: Trying to set emacs for some clojure coding

2010-03-31 Thread Stefan Kamphausen
Hi, On 31 Mrz., 13:52, Pelayo Ramón wrote: just to add one more to the list... Note however, that this is what worked *for me* and it means going against the grain. So if there is anything wrong with that setup don't ask the authors of the fine software used, go and blame me ;-) Uh, and Clojur

Re: Trying to set emacs for some clojure coding

2010-03-31 Thread Pelayo Ramón
On Wed, Mar 31, 2010 at 4:58 PM, Baishampayan Ghose wrote: > Pelayo Ramón wrote: > >> I tryied this http://riddell.us/ClojureWithEmacsSlimeSwankOnUbuntu.html >> this: >> http://freegeek.in/blog/2009/08/setting-up-emacs-clojure-with-emacs-starter-kit/ > > Since I wrote the above post and am respons

Re: Trying to set emacs for some clojure coding

2010-03-31 Thread Sankara Rameswaran
I followed the instructions in http://data-sorcery.org/2009/12/20/getting-started/ (only yesterday) and got Clojure working in Emacs quite easily. (If you are in windows and face issues installing slime follow this link http://osdir.com/ml/clojure/2010-01/msg00074.html) Thanks, Sankara Rameswaran

Re: towards definitive "getting started" assistance

2010-03-31 Thread Stuart Halloway
This suggests a broader conversation. Clojure stuff currently exists in multiple places as a consequence of point-in-time decisions and organic growth. For now I am going to stick with Assembla, but in the medium run (months) there I want to revisit this idea. Stu Just a thought. Would it

Re: Trying to set emacs for some clojure coding

2010-03-31 Thread Baishampayan Ghose
Pelayo Ramón wrote: I tryied this http://riddell.us/ClojureWithEmacsSlimeSwankOnUbuntu.html this: http://freegeek.in/blog/2009/08/setting-up-emacs-clojure-with-emacs-starter-kit/ Since I wrote the above post and am responsible in some way for your pain, I apologise. I have edited the post

Re: Trying to set emacs for some clojure coding

2010-03-31 Thread Phil Hagelberg
Did you try the readme for swank clojure? It is up to date and pretty comprehensive. Of course there is a lot of old documentation out there that we can't do anything about apart from asking the authors to update or remove it. On Mar 31, 2010 5:39 AM, "Pelayo Ramón" wrote: Hi all. I'm trying to

Re: Trying to set emacs for some clojure coding

2010-03-31 Thread David Nolen
Some accurate instructions here: http://www.assembla.com/wiki/show/clojure/Getting_Started_with_Emacs ? David -- 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 membe

Re: Getting started with open source Clojure projects

2010-03-31 Thread David Nolen
On Tue, Mar 30, 2010 at 10:26 PM, Daniel wrote: > Thanks for all the quick replies. I should've mentioned that I'm > already using leiningen, so the problem isn't so much getting the > dependencies and building the application as it is figuring out a way > to get inside the code and play with it

Infixup: DWIM hoisting and splicing in the reader

2010-03-31 Thread Per Vognsen
I spent the last few days sick in bed in a Jakarta hotel room without any Internet. What little lucidity I had was spent on odd hacks. One of them was particularly neat or particularly nasty depending on your perspective. It is a reader extension for list hoisting and splicing. You can write (a `b

Trying to set emacs for some clojure coding

2010-03-31 Thread Pelayo Ramón
Hi all. I'm trying to lear some clojure. I'be been coding with plain vim but i got tired of not having any support for the laguaje in the editor so i tried to install vimclojure. I failed miserably and got tired. I saw that emacs has a better clojure support so im trying to set clojure in emacs a

Re: Getting started with open source Clojure projects

2010-03-31 Thread Daniel
Thanks for all the quick replies. I should've mentioned that I'm already using leiningen, so the problem isn't so much getting the dependencies and building the application as it is figuring out a way to get inside the code and play with it a bit. I'd like to be able to load the source files, execu

Help with proxy method

2010-03-31 Thread Sergio Arbeo
I'm porting some code from Java to Clojure but I'm still stuck porting a JComponent. The original code is here: http://github.com/Serabe/RMagick4J/blob/master/Magick4J/src/magick4j/MagickImage.java#L282 It is quite simple, I just need it to display an image. I implemented the JComponent using the