Ctrl-C terminates REPL

2009-04-13 Thread fft1976
Pressing Ctrl-C terminates the REPL and not the evaluation/editing. Is this the intended behavior? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegr

Re: Ctrl-C terminates REPL

2009-04-13 Thread Meikel Brandmeyer
Hi, Am 13.04.2009 um 10:54 schrieb fft1976: Pressing Ctrl-C terminates the REPL and not the evaluation/editing. Is this the intended behavior? http://groups.google.com/group/clojure/browse_frm/thread/32e4f89300456118/1f2c1f1594c51ccf And: (require '[clojure.contrib.repl-utils :as repl-utils]

Tue, Apr 28th AppEngine talk in Atlanta

2009-04-13 Thread Sari Connard
John Hume is scheduled to talk about AppEngine at the Atlanta Clojure User Group on Tue, April 28th at 7pm. Join us if you can. -- Sari Connard http://www.linkedin.com/in/sariconnard --~--~-~--~--

Re: Got a Clojure library?

2009-04-13 Thread Matt Clark
Name: test-expect URL: http://code.google.com/p/test-expect/ Author: Matt Clark Tags: testing, mocking, expectations, stubbing License: EPL Dependencies: none (optional dependency on test-is) Description: Supports setting up and validating expectations on mocked dependency functions. Informative

Re: Got a Clojure library?

2009-04-13 Thread mikel
Name: xg-model, xg-gf URL: http://code.google.com/p/explorersguild/source/clj/com/explorersguild Instructions for checking out code are at: http://code.google.com/p/explorersguild/source/checkout Files: util.clj, gf.clj, model.clj, model_gf.clj Author: mikel evins Tags: generic function

Re: Has anyone on this group ever tried Forth?

2009-04-13 Thread Victor Rodriguez
On Sat, Apr 11, 2009 at 11:19 PM, fft1976 wrote: ... > > I find stack languages to be obtuse. Sometimes Forth programmers need > variables, and what they do is usually just mutable some global ones. > Also Forth programmers always have to document what they are doing > with the stack: what argume

Re: Amb operator

2009-04-13 Thread David Nolen
Using try-catch for control flow is probably not a good idea. Shameless plug, do you think you could get this to work with clj-cont? clj-cont is a port I did of cl-cont. It has some limitations, but because Clojure has so few special forms (compared to Common Lisp), it has the chance to achieve pre

Re: Amb operator

2009-04-13 Thread David Nolen
One caveat is that because this works by transforming the code into Continuation Passing Style, it's dog slow, like 2 orders of magnitude for regular Clojure code. This is not really much of an issue for user interface related code (which is what I'm using it for), but unrealistic for pretty much a

Updated clojure-pom with AOT compile

2009-04-13 Thread dysinger
I updated my maven setup to include clojure-maven-plugin & AOT compiles now. -> Example hello world project in the README. http://github.com/dysinger/clojure-pom/tree/master PS - Compojure is now maven ready -> http://github.com/dysinger/compojure/tree/master PSS - Compojure POM & hello world e

Re: How to compile in AquaMacs without slime? classpath problem for classes

2009-04-13 Thread dysinger
Bill, I switch between projects with slime using this method -> http://github.com/dysinger/clojure-pom/tree/master which sets up slime with _ALL_ the right jars / paths for each project using the generated ./bin/ repl script with SLIME. -Tim On Apr 12, 5:25 pm, billh04 wrote: > I can compi

Re: Has anyone on this group ever tried Forth?

2009-04-13 Thread Mark Fredrickson
Previous to my discovering Clojure, I wrote a small Scheme library to embed concatenative programming inside a Lisp: http://www.call-with-current-continuation.org/eggs/3/stacktor.html I ultimately found that I didn't use it much when I was writing real programs, but it was a good way to learn ab

Re: Got a Clojure user group?

2009-04-13 Thread Jason Riedy
And Rich Hickey writes: > Got a Clojure user group, meetup etc? After a fashion. There is a (low-traffic) Clojure group on identi.ca for chatting: http://identi.ca/group/clj Jason --~--~-~--~~~---~--~~ You received this message because you are subscribed to th

clojure.contrib.repl-utils/get-source broken

2009-04-13 Thread James Reeves
Hi folks, In the latest versions of Clojure, the :file key in a var's metadata seems to contain the full path of the file (relative to the classpath). e.g. => (:file ^#'html) "compojure/html/gen.clj" => (:file ^#'map) "clojure/core.clj" The get-source function in clojure.contrib.repl-utils seem

in-ns in bootstrap

2009-04-13 Thread Greg Harman
I have a bootstrap file (executed either on the command line or via user.clj) that contains an in-ns call, along with other stuff that I have verified working (e.g. println statements). I'd like the bootstrap file to leave the REPL in whatever namespace I last specified with my in-ns. But I'm get

Re: Amb operator

2009-04-13 Thread Victor Rodriguez
On Mon, Apr 13, 2009 at 2:13 PM, David Nolen wrote: > One caveat is that because this works by transforming the code into > Continuation Passing Style, it's dog slow, like 2 orders of magnitude for > regular Clojure code. This is not really much of an issue for user interface > related code (whic

Re: update-in wildcards?

2009-04-13 Thread Ozzi Lee
Well, I expected someone to tell my that was a horrible idea, not to implement it for me. Thanks! One thing that concerns me is that :* could conceivable be used as a key in a hash-map. Perhaps a separate distinct value should be used as a wildcard? Does clojure have a facility for creating a val

Re: update-in wildcards?

2009-04-13 Thread Ozzi Lee
> Does clojure have a facility for creating a value that > will never be considered equal to any other value? Duh, brainfart. Gensym will work nicely, of course. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cloju

Re: in-ns in bootstrap

2009-04-13 Thread Stephen C. Gilardi
On Apr 13, 2009, at 3:44 PM, Greg Harman wrote: I'd like the bootstrap file to leave the REPL in whatever namespace I last specified with my in-ns. But I'm getting different (unexpected) results in two cases. Case 1: Slime: the in-ns is ignored (although expressions around it are evaluated), a

Re: clojure dependency management and build

2009-04-13 Thread bradford cross
I have written up my journeys so far: http://bradfordcross.blogspot.com/2009/04/clojure-build-and-dependency-management.html I re-used Meikel's ant + ivy successfully. Next step is to get something working for the transative deps , i.e. pulling other clojure projects i depend on and building the

Re: clojure dependency management and build

2009-04-13 Thread Stephen C. Gilardi
On Apr 13, 2009, at 4:58 PM, bradford cross wrote: I have written up my journeys so far: http://bradfordcross.blogspot.com/2009/04/clojure-build-and-dependency-management.html Thanks very much for the write-up! Given the recent discussions and interest in dependency management I thought I'd

Re: clojure dependency management and build

2009-04-13 Thread bradford cross
On Mon, Apr 13, 2009 at 2:31 PM, Stephen C. Gilardi wrote: > On Apr 13, 2009, at 4:58 PM, bradford cross wrote: >> >> I have written up my journeys so far: >> http://bradfordcross.blogspot.com/2009/04/clojure-build-and-dependency-management.html >> > > Thanks very much for the write-up! > > Given

Re: clojure dependency management and build

2009-04-13 Thread Laurent PETIT
Hi, 2009/4/14 bradford cross > > > On Mon, Apr 13, 2009 at 2:31 PM, Stephen C. Gilardi wrote: > >> On Apr 13, 2009, at 4:58 PM, bradford cross wrote: >>> >>> I have written up my journeys so far: >>> http://bradfordcross.blogspot.com/2009/04/clojure-build-and-dependency-management.html >>> >> >

Re: clojure dependency management and build

2009-04-13 Thread bradford cross
On Mon, Apr 13, 2009 at 3:22 PM, Laurent PETIT wrote: > Hi, > > 2009/4/14 bradford cross > >> >> >> On Mon, Apr 13, 2009 at 2:31 PM, Stephen C. Gilardi wrote: >> >>> On Apr 13, 2009, at 4:58 PM, bradford cross wrote: I have written up my journeys so far: http://bradfordcross.blogs

What is the difference between :type and :tag metadata?

2009-04-13 Thread samppi
In this message (http://groups.google.com/group/clojure/msg/ d88d9319adfc41a6), Mr. Hickey mentioned a "supported convention for tagging, the :type metadata". I thought that this was the function of the :tag metadata, though, which isa? and the hierarchy functions use. What is the difference? Do t

Re: clojure dependency management and build

2009-04-13 Thread dysinger
On Apr 13, 10:58 am, bradford cross wrote: > I have written up my journeys so > far:http://bradfordcross.blogspot.com/2009/04/clojure-build-and-dependenc... Nice article. > I re-used Meikel's ant + ivy successfully.   Next step is to get something > working for the transative deps , i.e. pulli

Re: Amb operator

2009-04-13 Thread David Nolen
Wow, this is very interesting, on a MBP 2.53 JDK 1.6 ;; ~2.5 seconds (time (dotimes [_ 100] (new Exception))) ;; ~40ms or 62X faster (time (let [exc (new Exception)] (dotimes [_ 100] (try (throw exc) (catch Exception _) However does also means that you're throwing

Re: Nested loops

2009-04-13 Thread David Nolen
Out of simple curiosity I wondered how hard it would be to implement flow control using proxy. I know Rich isn't hot on non-structured programming, but there may be times where this might be useful: (ns flow.return-from (:import (flow IReturnFrom))) (defn create-return-from [value] (proxy [T

Re: What is the difference between :type and :tag metadata?

2009-04-13 Thread Rich Hickey
On Apr 13, 6:36 pm, samppi wrote: > In this message (http://groups.google.com/group/clojure/msg/ > d88d9319adfc41a6), Mr. Hickey mentioned a "supported convention for > tagging, the :type metadata". I thought that this was the function of > the :tag metadata, though, which isa? and the hierarch

Google includes Clojure in App Engine demo

2009-04-13 Thread levand
http://googleappengine.blogspot.com/2009/04/many-languages-and-in-runtime-bind-them.html As a demo of JVM languages running on the Google App Engine, they included a Clojure REPL. Getting more mainstream, it would seem... --~--~-~--~~~---~--~~ You received this me

Re: test-expect functional mocking/expectation library

2009-04-13 Thread Allen Rohner
>Of course, it was not until I had an early working version that I discovered >Allen > Rohner's expectation tools, but I figured that mine were sufficiently > different to merit further development (at least relative to the > latest code of his I could find). > > > Suggestions for further changes

Re: Amb operator

2009-04-13 Thread Victor Rodriguez
On Mon, Apr 13, 2009 at 9:02 PM, David Nolen wrote: > Wow, this is very interesting, on a MBP 2.53 JDK 1.6 > ;; ~2.5 seconds > (time (dotimes [_ 100] > (new Exception))) > ;; ~40ms or 62X faster > (time >  (let [exc (new Exception)] >    (dotimes [_ 100] >      (try >       (throw exc) >

Re: in-ns in bootstrap

2009-04-13 Thread Greg Harman
On Apr 13, 4:50 pm, "Stephen C. Gilardi" wrote: > % java -cp clojure.jar clojure.main -e "(in-ns 'funky-ns)" --repl > # > funky-ns=> Worked perfectly, thanks! > Regarding your Case 2 where it appeared you were actually in a   > namespace other than the one shown in the prompt, that's very   > u

ATTN contrib authors: Automatic documentation for clojure.contib

2009-04-13 Thread Tom Faulhaber
[This is specifically for contrib authors, but also for anyone whose interested.] There was some discussion (or maybe the wailing and gnashing of teeth) about the fact that there's lots of cool functionally coming into clojure.contrib but no easily accessible documentation. I had been thinking ab

Re: Javascript generator

2009-04-13 Thread David Nolen
Do you have any plans for continuing to support this? If so are you against putting this on GitHub or Google Code so that people can follow it's development? Thanks for contributing it to the community. On Wed, Feb 25, 2009 at 7:49 PM, jim wrote: > > I've just uploaded a javascript generator ala

Re: Javascript generator

2009-04-13 Thread David Nolen
One thing, there are several assertions in js-gen like the following: (assert (= '("obj = {prop2:\"str-val\",prop1:3}") (run out-str (js-assignment '(= obj {prop1 3, prop2 "str-val"}) out-str This assertion statement might fail (and did for me) since maps are not ordered. On Tue, Apr 14, 2