Found some unexpected behavior to me

2014-02-27 Thread Brent Millare
Clojure 1.5.1 user= (defprotocol IEmit (-emit [x])) IEmit user= (defrecord css [y] IEmit (-emit [_] y)) user.css user= (-emit (-css 3)) 3 user= (map -emit [(-css 3)]) IllegalArgumentException No matching field found: emit for class user.css clojure.lang.Reflector.getInstanceField

Re: Funding Clojure 2010

2009-12-15 Thread Brent Millare
Rich, What prevents Clojure from being funded by grants like NSF and DARPA which normally fund academic research? Best, Brent Millare -- 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

Manual Installation (not using ELPA) of swank-clojure

2010-01-18 Thread Brent Millare
this should clear things up for some. http://tentclube.blogspot.com/2010/01/manual-installation-not-using-elpa-of.html Best, Brent Millare -- 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

Re: Manual Installation (not using ELPA) of swank-clojure

2010-01-18 Thread Brent Millare
The basic install prerequisites are emacs, slime, java, and git. On Jan 18, 6:22 pm, Mark Hamstra markhams...@gmail.com wrote: Does from scratch assume Slime is already installed? On Jan 18, 4:42 pm, Brent Millare brent.mill...@gmail.com wrote: I made a write up of my experiences setting up

Re: Clojure Conference Poll

2010-01-23 Thread Brent Millare
Weekend, and East coast, either near the DC area or New York Area, maybe Boston area is OK too. On Jan 22, 12:36 pm, dysinger t...@dysinger.net wrote: We will be organizing a conference in the next month for 2010 (probably in the fall).  One question I would like to ask is, given the

simple-peg, sharing my experience and looking for advice, forks, patches, or anything I can get

2010-01-29 Thread Brent Millare
don't see that being a problem. I'm trying out the if you feel you're ready to release, you've released to late philosophy. Best, Brent Millare -- 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

Re: Simple clojure and contrib install, with SLIME ... ?

2010-02-11 Thread Brent Millare
Paul, I first struggled to find a way to do everything manually cause I didn't like someone else's self installer messing up my distributions setup. I think I've found a satisfactory hybrid approach to setup my IDE on any machine now in 4 chunked steps. 1. I rely on the distro to install emacs,

Re: Simple clojure and contrib install, with SLIME ... ?

2010-02-11 Thread Brent Millare
Michael, I'm not sure of the full feature list of leiningen but since it maintains a local repo, there might be a way (or if not, it should be added) to install locally built libs and clojure versions (projects normally without project.clj files). Perhaps there is a way to add that information

Idea for operations on mixed data structures of maps and sequences

2010-02-13 Thread Brent Millare
Recently, I've been taking advantage of the rich API for manipulating clojure's builtin data structures such as Maps and Vectors. In a small example, I have different user settings stored as maps and I can easily merge them using the function merge. As I've developed the application further,

Re: How to turn quick Slime workaround into a real patch?

2010-02-13 Thread Brent Millare
I think Phil is writing a guide about how he wants others to send him patches but I think I can still provide some hints. First, I think this belongs in swank-clojure.el its the only place where the context of a clojure repl comes up. Phil prefers pull requests so fork swank- clojure (I only know

Re: Leiningen, Clojure and libraries: what am I missing?

2010-03-10 Thread Brent Millare
Since leiningen downloads everything to a local repo, can't we do away with copies and use symlinks if they are supported by the filesystem? I feel there should be an option for this. -Brent On Mar 4, 1:59 pm, David Nolen dnolen.li...@gmail.com wrote: On Thu, Mar 4, 2010 at 10:19 AM, Stuart

Re: Leiningen, Clojure and libraries: what am I missing?

2010-03-29 Thread Brent Millare
hardlinking is a more elegant solution as ~/.m2/repository can act as a true cache with size bounds but without the fear that projects that depend on deleted artifacts would be affected. Phil Hagelberg wrote: On Wed, Mar 10, 2010 at 10:24 PM, Meikel Brandmeyer wrote: On Mar 11, 5:07 am, Brent

Re: Leiningen, Clojure and libraries: what am I missing?

2010-03-30 Thread Brent Millare
to facilitate automating the deployment of alternative branches of leiningen. Brent Alex Osborne wrote: Brent Millare brent.mill...@gmail.com writes: Can someone please elaborate on this subclassloader process? Although the design for leiningen is architecturally simple and understandable

Re: My non-ELPA Emacs swank-clojure setup

2010-04-07 Thread Brent Millare
http://tentclube.blogspot.com/ I made a blog post on this a while ago, but I've simplified the process now. I'm still working on making it easier to deploy on different systems though. -Brent On Apr 7, 5:12 pm, Ævar Arnfjörð Bjarmason ava...@gmail.com wrote: I stubbornly refuse to use ELPA. I

wget replacement code review

2010-04-21 Thread Brent Millare
Hey all, I wrote a clojure version of the simplest functionality of wget. I basically translated the java version into clojure code, but I'm not quite happy with the wget-binary function because I use a loop, and I feel like someone else has a more idiomatic solution to iterating through a

Re: wget replacement code review

2010-04-21 Thread Brent Millare
. That's the only low hanging fruit I see. On Apr 21, 1:47 pm, Brent Millare brent.mill...@gmail.com wrote: Hey all, I wrote a clojure version of the simplest functionality of wget. I basically translated the java version into clojure code, but I'm not quite happy with the wget-binary

Re: wget replacement code review

2010-04-24 Thread Brent Millare
idiomatic clojure question, but extract-url- filename will have problems because of this: user (.getFile (URL. http://www.foo.com/;)) / On Apr 21, 1:08 pm, Brent Millare brent.mill...@gmail.com wrote: Technically I didn't write my own cause I just copied pasted it ;) For the purposes

dynamic loading of jars during runtime solutions

2010-04-24 Thread Brent Millare
My only solution to loading a new jar during runtime is to extract the jar (its just a zip file) into a directory which was already in the classpath. This allows me to retain incremental development without restarting the runtime. Are there alternative solutions out there? I have heard of OSGi

weird repl + classloader behavior

2010-05-23 Thread Brent Millare
Why does dereferencing clojure.lang.Compiler/LOADER change in different calls in the repl? For example, Clojure 1.2.0-master-SNAPSHOT user= (dotimes [x 10] (java.lang.Thread/sleep 500) (prn (.deref (clojure.lang.Compiler/LOADER #DynamicClassLoader clojure.lang.dynamicclassloa...@407e75d2

Re: weird repl + classloader behavior

2010-05-24 Thread Brent Millare
I am creating another dependency management system that using dynamic compilation to load dependencies during runtime. My actual issue is I needed to reconstruct the new effective classpath which should include the classpath given (from (System/getProperty java.class.path)) at the commandline and

Re: weird repl + classloader behavior

2010-05-25 Thread Brent Millare
incredible performance, and if you use them incorrectly, performance can be pretty poor.  Plan to do lots of experimentation, and best of luck! On May 24, 9:06 am, Brent Millare brent.mill...@gmail.com wrote: I am creating another dependency management system that using dynamic compilation

Possible namespace bug

2010-05-25 Thread Brent Millare
May have found a bug, here is how to duplicate it. Hopefully someone can confirm this. Here is expected behavior when run in the repl: Clojure 1.2.0-master-SNAPSHOT user= (ns foo) nil foo= (defmacro f [] `(eval `(def ~'~'x 'foo))) #'foo/f foo= (ns bar) nil bar= (defn b [] (foo/f)) #'bar/b bar=

Re: Possible namespace bug

2010-05-26 Thread Brent Millare
of starting a new classloader). Best, Brent On May 26, 1:27 am, Meikel Brandmeyer m...@kotka.de wrote: Hi, On May 26, 12:17 am, Brent Millare brent.mill...@gmail.com wrote: ^^ That should read #'bar/x instead of #'user/x No. foo/f expands into a macro calling eval on a def. This eval is put

Re: Possible namespace bug

2010-05-26 Thread Brent Millare
Ah wait, I may have read that wrong. So what I understand is because I am calling it from the the -e, it is ran in the user ns. Ok that makes sense. On May 26, 2:28 am, Brent Millare brent.mill...@gmail.com wrote: Hi Meikel, Well if #'user/x is the correct behavior, then the repl behavior

Re: weird repl + classloader behavior

2010-05-26 Thread Brent Millare
, 4:31 am, Erik Söhnel eriksoeh...@googlemail.com wrote: On 25 Mai, 08:03, Brent Millare brent.mill...@gmail.com wrote: Erik, what you said seems to make sense. So the question now is, since a new classloader is started during each eval at the repl, does that mean that it is closed after each

Trying to make my code extensible

2010-06-01 Thread Brent Millare
I'm trying to make my code extensible and I'm having trouble deciding what is the best way to do this. The algorithm is a tree walker that modifies a few data structures before, post, and during the traversal of each node. The code detects circular dependencies, resolves dependencies once, and

Protocols/records and namespaces

2010-06-22 Thread Brent Millare
user= (in-ns 'protocol.test) #Namespace protocol.test protocol.test= (defrecord person [name age]) protocol.test.person protocol.test= (person. bobby 23) #:protocol.test.person{:name bobby, :age 23} protocol.test= (in-ns 'user) #Namespace user user= (protocol.test/person. alice 2)

Re: Protocols/records and namespaces

2010-06-22 Thread Brent Millare
: hello, 2010/6/22 Brent Millare brent.mill...@gmail.com: user= (in-ns 'protocol.test) #Namespace protocol.test protocol.test= (defrecord person [name age]) protocol.test.person protocol.test= (person. bobby 23) #:protocol.test.person{:name bobby, :age 23} protocol.test= (in-ns

Protocols and visitor pattern

2010-06-24 Thread Brent Millare
Are there any good articles on clojure double dispatch using protocols (not multimethods) via the visitor pattern or whatever would be appropriate? I feel like that after single dispatch on type, double dispatch on type is the next common use case for multimethods. I somewhat recall Rich talking

Re: Trying to make my code extensible

2010-06-24 Thread Brent Millare
If anyone is curious, I ended up learning about and using protocols. It was pretty trivial to convert since it was basically what I was already doing, although I wasn't really using protocols for dispatching but for grouping of functions together with shared data. On Jun 1, 7:09 pm, Brent Millare

Re: Clojure's n00b attraction problem

2010-06-28 Thread Brent Millare
On Jun 28, 6:34 pm, Lee Spector lspec...@hampshire.edu wrote: Speaking for me only: Let a million IDEs bloom. I'm just expressing my interest in there being at least one that allows new users to download/install/edit/run code with minimal work and minimal prior knowledge. Technically if

Re: Clojure's n00b attraction problem

2010-06-28 Thread Brent Millare
, Brent Millare wrote: On Jun 28, 6:34 pm, Lee Spector lspec...@hampshire.edu wrote: Speaking for me only: Let a million IDEs bloom. I'm just expressing my interest in there being at least one that allows new users to download/install/edit/run code with minimal work and minimal

Re: Clojure's n00b attraction problem

2010-06-28 Thread Brent Millare
While I agree his wording wasn't really the best, I think it can also be interpreted differently depending on what kind of n00b he is talking about. I definitely would see a lot of the mid-late sections of stuarts book be way over my head when I started learning programming. Kinda like when I was

Re: Clojure's n00b attraction problem

2010-06-28 Thread Brent Millare
, but I only crossed that hurdle with persistence and generous hand-holding, dealing with things that were quite independent of the Clojure language itself. On Jun 28, 2010, at 11:54 PM, Brent Millare wrote: Well indentation is a function of the editor you are using. Emacs has it builtin

Re: Clojure's n00b attraction problem

2010-06-28 Thread Brent Millare
compared to other basics. This is different than a, clojure is only for elites viewpoint. Best, Brent On Jun 29, 12:54 am, Daniel Gagnon redalas...@gmail.com wrote: On Tue, Jun 29, 2010 at 12:39 AM, Brent Millare brent.mill...@gmail.comwrote: While I agree his wording wasn't really the best

Re: Clojure distribution (like what ubuntu is for linux)

2010-06-29 Thread Brent Millare
Well it looks like I have some competition ;) I haven't tried either yet so I can't really comment, but I like the idea of creating and integrated package manager and repl utility.  Clj also seems nice in the way it integrates with clojars.org. At the moment, dj uses several maven

Re: Installing Clojure on Windows 7

2013-01-24 Thread Brent Millare
I regularly develop clojure on emacs on windows. I wrote up a guide for myself, you can read it and adapt it to your needs. https://github.com/bmillare/dj/wiki/Emacs-Setup https://github.com/bmillare/dj/wiki/Installation-Walkthrough On Thursday, January 24, 2013 12:56:59 PM UTC-5,

Re: fressian

2013-01-25 Thread Brent Millare
Ok, well I bit the bullet and figured out how to add vectors myself. See the results here: https://github.com/bmillare/dj.fressian On Monday, January 21, 2013 6:26:48 PM UTC-5, Brent Millare wrote: Has anyone checked out fressian, the binary serialization/deserialization used by datomic

Re: ANN: NEVER use clojure.core/read or read-string for reading untrusted data

2013-02-11 Thread Brent Millare
Is it possible to elaborate on the reasons for not using read/read-string with *read-eval* bound to false for clojure 1.5 and greater? Is it just because they can execute dumb code that takes CPU cycles? It's not obvious to me. Best, Brent On Monday, February 11, 2013 1:59:06 PM UTC-5, Mimmo

Re: Why is this so difficult?

2013-02-26 Thread Brent Millare
On another note, I wonder if a leiningen2 wizard installer for windows would be in high-demand (does one already exist?). Anyone familiar with writing windows wizards? -- -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send

Re: features expression

2013-03-06 Thread Brent Millare
+1 Isn't is possible to accomplish all these efforts using tagged literals? https://github.com/miner/wilkins This way the facilities for read-time code generation can be customized and any reader that supports tagged-literals will support this. All of this is data provided as arguments, no

Re: features expression

2013-03-07 Thread Brent Millare
that's relevant to the current Clojure dialect. The only complication with this scheme is that all information in *clojure-version* is related to the version numbers only; however, this could be changed easily. On Thu, Mar 7, 2013 at 7:46 AM, Brent Millare brent@gmail.comjavascript

Re: Prismatic Plumbing and Graph Open-Source Release

2013-03-07 Thread Brent Millare
Hi, Very nice work. I'm interested in using graph but just curious in terms of your priorities for future development. I noticed that you listed as a todo, you might want to save the body of a fnk which I see as a potential for inlining the bodies and thus eliminating the fn call when

Re: Windows Installation

2013-03-09 Thread Brent Millare
Does anyone see value in a wizard for lein? Does anyone know how to write a wizard, preferably with a scripting language, or xml, rather than c++? And can you alter system variables from within the wizard? On Saturday, March 9, 2013 8:18:44 AM UTC-5, BJG145 wrote: As long as you have wget,

Composable mutual recursive function composition

2013-03-09 Thread Brent Millare
I recently asked about mutual referenced support in the prismatic library plumbing https://github.com/Prismatic/plumbing and currently its an open question about how to implement that. So I made a proof-of-concept version of a graph-like library that supports mutual recursion.

Re: Composable mutual recursive function composition

2013-03-11 Thread Brent Millare
I just added aliasing support. This way you can have interface keywords and depend on those. Then instead of redefining all functions to use a different key, you just change the alias. -- -- You received this message because you are subscribed to the Google Groups Clojure group. To post to

Re: ANN: Windows installer for Leiningen

2013-03-30 Thread Brent Millare
Nice work! On Saturday, March 30, 2013 1:39:12 PM UTC-4, David Powell wrote: Hi, I've put together an installer for Leiningen on Windows: http://leiningen-win-installer.djpowell.net/ Hopefully it should make it a bit easier for Windows people to get Leiningen and a Clojure repl up and

dj updates

2011-06-28 Thread Brent Millare
It's been a year and I'm still using dj and still developing for it. git://github.com/bmillare/dj.git Some recent additions: * You can depend on clojure contrib github projects via: :src-dependencies [clojure/core.logic] All projects with clojure/ prefixed to the name are considered to be a

Re: Collaboration Proposal: Beyond CLOS Generic Methods, Predicate Dispatch, and Pattern Matching

2011-07-06 Thread Brent Millare
How's the progress on this project going? During my spare time I've been reading through some of the logic programming literature, trying to learn about this, but there is still much to learn. While I could spend hours continuing to read the literature, I feel it might be more productive to get

Re: Tail Calls and Continuations in Clojure

2011-07-15 Thread Brent Millare
That's really cool. I'm glad someone got it to work and with little modification! On Jul 15, 4:21 pm, Joel Dice joel.d...@gmail.com wrote: (sorry about the lack of subject in my original post; I've added one to this email) On Fri, 15 Jul 2011, George Jahad wrote: very cool Joel!   I'd also

Re: following Rich's talk at NYC Clojure this Wednesday

2011-07-18 Thread Brent Millare
Please give the time when it is ready. I want to be on IRC when this happens. Chat + livestreaming is always good. On Jul 18, 12:15 pm, Baishampayan Ghose b.gh...@gmail.com wrote: Yoohoo!  Thanks a bunch, Stu co. Regards, BG --- Sent from phone. Please excuse brevity. On Jul 18, 2011

Re: Excellent intro to core.logic

2011-07-18 Thread Brent Millare
Nice, I'll be sure to go through it. On Jul 18, 10:56 am, David Nolen dnolen.li...@gmail.com wrote: I highly recommend checking this out if you're curious about core.logic,https://github.com/frenchy64/Logic-Starter/wiki David -- You received this message because you are subscribed to the

Re: Excellent intro to core.logic

2011-07-20 Thread Brent Millare
Should the example: (run* [q] (geto 'g [['f :- Integer]] Integer) (== q true)) ;= () The type association ['g :- Integer] does not occur in the environment [ ['f :- Integer] ], so geto succeeds. Read so geto fails instead? since the result is ()? On Jul 20,

Re: Libraries and build management hell

2011-07-28 Thread Brent Millare
I have to chime in my solution to the problem, dj. git://github.com/bmillare/dj.git Acts more like a distro then a build tool though. On Jul 28, 7:49 pm, Sean Corfield seancorfi...@gmail.com wrote: On Thu, Jul 28, 2011 at 2:23 PM, Michal B mibu.cloj...@gmail.com wrote: Why does it have to be

Re: Libraries and build management hell

2011-07-31 Thread Brent Millare
My solution to these problems is my run command, where you can run a script in the dependency context of a particular project. So lets say you have a scratch project with many common dependencies. Then I run anywhere, dj run foo.clj scratch-project. I'd imagine there is something like this for

Re: New to Clojure -- Errors Are Frustrating

2011-08-02 Thread Brent Millare
The following code may prove useful as well. (defmacro log for debugging, output code and code-val to stdout or optional writer, returns val, custom-fn accepts two arguments, the code, and the result, it must return a string ([code] `(let [c# ~code] (prn '~code)

Re: Video Slides on Pattern Matching and Predicate Dispatch in Clojure

2011-08-21 Thread Brent Millare
I have a question about the presentation. You mention that you can't achieve the same dispatching performance in the open case compared to the closed space. Lets ignore the namespace issue (maybe by restricting ourselves to only one namespace). Also lets assume the predicate ordering is solved.

Re: Video Slides on Pattern Matching and Predicate Dispatch in Clojure

2011-08-22 Thread Brent Millare
wrote: On Sun, Aug 21, 2011 at 11:27 PM, Brent Millare brent.mill...@gmail.comwrote: I have a question about the presentation. You mention that you can't achieve the same dispatching performance in the open case compared to the closed space. I meant to say that the problem is hard

Re: Video Slides on Pattern Matching and Predicate Dispatch in Clojure

2011-08-22 Thread Brent Millare
For pattern matching code size is a one time cost. For predicate dispatch, that's a lot of code to generated, since every new predicate case will produce an entirely new tree. But perhaps people won't care that much. Only time and experience reports will tell. If you want, you can be lazy

Re: Video Slides on Pattern Matching and Predicate Dispatch in Clojure

2011-08-22 Thread Brent Millare
Actually to simply further, instead of wrapping the old DAG tree, it simply replaces the DAG tree with the compilation step. The compilation step then makes the new DAG tree and calls it. On Aug 22, 3:07 pm, Brent Millare brent.mill...@gmail.com wrote: For pattern matching code size is a one

Re: Video Slides on Pattern Matching and Predicate Dispatch in Clojure

2011-08-23 Thread Brent Millare
of extend-pred won't compile unnecessarily. The only other option I can see is to make the compile step like a hook that is integrated to the build process and runs at the very end. -Brent On Aug 22, 3:12 pm, David Nolen dnolen.li...@gmail.com wrote: On Mon, Aug 22, 2011 at 3:07 PM, Brent Millare

Making clojure.lang.IDeref a protocol

2011-08-25 Thread Brent Millare
Hey, Has there been discussion about making clojure.lang.IDeref a protocol? I'd like to extend some java types to this the IDeref interface but currently this is not possible. I feel like this is such a common idiom, to get values, and doing so will allow me to leverage the @ reader macro for

Re: Making clojure.lang.IDeref a protocol

2011-08-25 Thread Brent Millare
That said, I don't know many Java classes that have value-yielding semantics. And if you are writing your own class, you can implement the IDeref interface. There aren't many value-yielding semantics from many java classes, but the ones I care about, do matter. Also, in my case, I'm adding

Re: Clojure 1.3 Beta 3

2011-09-06 Thread Brent Millare
I'm confused about the notes on section 2.2 Better Exception Reporting. There is a link to the Error Handling notes but it only lists several approaches for handling errors, but it doesn't describe how messages will be reported better in this release. I feel this would be a good place to provide

clojure type casting vs java type casting

2011-09-17 Thread Brent Millare
Is the following clojure code: (long (.some-method-that-returns-int this)) equivalent in semantics and performance to the following java code: (long)some-method-that-returns-int(); I need to make type casts in an inner loop (hot zone), and I was wondering if there was something implicit that

Casting numbers to ints

2011-09-17 Thread Brent Millare
Is it possible to cast a number into an int in 1.3.0-RC0? ;user= (type 0) java.lang.Long ;user= (type (int 0)) java.lang.Long -- 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

Re: Casting numbers to ints

2011-09-18 Thread Brent Millare
18.09.2011 um 07:31 schrieb Brent Millare: Is it possible to cast a number into an int in 1.3.0-RC0? ;user= (type 0) java.lang.Long ;user= (type (int 0)) java.lang.Long int does cast to an integer for direct java interop. type is function so the integer will be boxed. 1.3 will use only

Accessing static fields of clojure.lang.DynamicClassLoader

2011-09-18 Thread Brent Millare
Using 1.3.0-RC0 I can't seem to access clojure.lang.DynamicClassLoader's public static fields. Is there something else preventing me from doing this? ;user= clojure.lang.DynamicClassLoader/classCache CompilerException java.lang.RuntimeException: Unable to find static field: classCache in class

Re: Casting numbers to ints

2011-09-18 Thread Brent Millare
15:36 schrieb Brent Millare: Even if I use what type does underneath and call .getClass myself (so there is no boxing), I still get type long. Also to be more specific, I am interested in the primitive int, not java.lang.Integer. You could do a hardcore try and use a specific class

Re: Accessing static fields of clojure.lang.DynamicClassLoader

2011-09-18 Thread Brent Millare
Figured it out, those fields are private. Just reading the source code I didn't realize if you don't declare it public, it defaults to private. Shows how much I know about java syntax... -Brent On Sep 18, 10:22 am, Brent Millare brent.mill...@gmail.com wrote: Using 1.3.0-RC0 I can't seem

Re: Accessing static fields of clojure.lang.DynamicClassLoader

2011-09-18 Thread Brent Millare
. The distinction is without a difference for you here, of course — especially since Clojure treats all package-private and protected fields as private (modulo the various reflection-wrapping accessor fns out there). - Chas On Sep 18, 2011, at 12:54 PM, Brent Millare wrote: Figured it out

How does clojure class reloading work?

2011-09-19 Thread Brent Millare
(Note: I've copied my question from stackoverflow to get more looks in case there are people in here that are not on stack. http://stackoverflow.com/questions/7471316/how-does-clojure-class-reloading-work I will sync the good answers) I've been reading code and documentation to try to understand

Trying to use CDT on 1.3.0

2011-09-22 Thread Brent Millare
Hi I'm trying to use the clojure debugging toolkit but I'm getting an exception when I reach a breakpoint. exception in event handler java.lang.RuntimeException: java.util.zip.ZipException: error in opening zip file. You may need to restart CDT Anyone know what's going on? Best, Brent -- You

Re: How does clojure class reloading work?

2011-09-22 Thread Brent Millare
to clojure.lang.DynamicClassLoader/defineClass. Calling deftype again leads to another call to defineClass, but doing this manually results in a Linkage Error. What is happening underneath here that allows clojure to do this with deftypes? -Brent On Sep 19, 9:07 am, Brent Millare brent.mill

Re: Trying to use CDT on 1.3.0

2011-09-22 Thread Brent Millare
: clojure/ set.clj$ error in process filter: Search failed: clojure/set.clj$ On Sep 22, 1:10 pm, Brent Millare brent.mill...@gmail.com wrote: Hi I'm trying to use the clojure debugging toolkit but I'm getting an exception when I reach a breakpoint. exception in event handler

Re: How does clojure class reloading work?

2011-09-22 Thread Brent Millare
there. On Thu, Sep 22, 2011 at 1:52 PM, Brent Millare brent.mill...@gmail.com wrote: Hi, An update to this question. While Chouser gave a good explanation about the details behind proxy, reify, and gen-class, I feel that the explanation behind deftype is incomplete. It's not clear how clojure

Re: How does clojure class reloading work?

2011-09-22 Thread Brent Millare
Wow, using what you just explained, I am now able to reload .class files. (defn reload-class [classname] (.defineClass (clojure.lang.DynamicClassLoader.) classname (to-byte-array (io/file /home/user/dj/usr/src/scratch/src/scratch/ hello.class))

Re: Trying to use CDT on 1.3.0

2011-09-26 Thread Brent Millare
wrote: This is the most up-to-date documentation:http://georgejahad.com/clojure/swank-cdt.html Is that what you are using? g On Sep 22, 1:25 pm, Brent Millare brent.mill...@gmail.com wrote: Hmm, I think it was a version mismatch for target repl and debug repl. So it works now. New

Clojurescript output effect

2011-09-27 Thread Brent Millare
I'm trying to figure out why when I require('cljs.core') in a javascript file, the hello world example doesn't work. hello.js goog.require('cljs.core'); ;;--- If I delete this line, then everything works. goog.require('goog.dom'); function sayHi() { var myc__2284 =

Re: Clojurescript output effect

2011-09-27 Thread Brent Millare
Nolen dnolen.li...@gmail.com wrote: What was the error and what were your compile options? On Tuesday, September 27, 2011, Brent Millare brent.mill...@gmail.com wrote: I'm trying to figure out why when I require('cljs.core') in a javascript file, the hello world example doesn't work

Re: Clojurescript output effect

2011-09-27 Thread Brent Millare
the require is what seemed to prevent the behavior. -Brent On Sep 27, 7:26 pm, Brent Millare brent.mill...@gmail.com wrote: You can try out the code I posted, but basically I wanted to create a hello world canvas. Without the require, I get the canvas. With the require, I get a blank white

Re: Clojurescript output effect

2011-09-28 Thread Brent Millare
. Best, Brent On Sep 27, 8:51 pm, Brent Millare brent.mill...@gmail.com wrote: Also as for compile options, there are none. I initially tried advanced, but again got a blank page. So I tried no args, and it made the out folder. I looked in there and saw the generated js file. I looked through

Re: Clojurescript output effect

2011-09-28 Thread Brent Millare
@David Nolen, All the files are there in the script tab. autogen'd file out/F6baq.js: goog.provide('hello'); goog.require('cljs.core'); hello.greet = (function greet(){ return hello world; }); goog.exportSymbol('hello.greet', hello.greet); hello.js: goog.addDependency(../cljs/core.js,

Re: Clojurescript output effect

2011-09-28 Thread Brent Millare
No, I get a similar error, but instead of hello not being defined, it says b is not defined. On Sep 28, 12:55 pm, David Nolen dnolen.li...@gmail.com wrote: Does it work when you use the advanced compilation settings? On Wed, Sep 28, 2011 at 12:35 PM, Brent Millare brent.mill

Re: Clojurescript output effect

2011-09-28 Thread Brent Millare
Hi David, I'm not sure what you mean by this. If I replace hello.greet() with greet(), I get greet is not defined instead. On Sep 28, 2:03 pm, David Nolen dnolen.li...@gmail.com wrote: Did you try this wIthout a single element namespace? On Wednesday, September 28, 2011, Brent Millare

[ANN] dj 0.1.0 released

2011-10-12 Thread Brent Millare
I've been using dj for a while for personal use but I never put a version on it. Hopefully doing this from now on I might get more useful feedback. git://github.com/bmillare/dj.git Main changes are: * Runtime altering classpath * Runtime dependency resolution * Runtime reloading of select

Re: [ANN] dj 0.1.0 released

2011-10-13 Thread Brent Millare
0.2.0 Released Made a new API namespace called dj Now all the utilities I think users would typically need are in this namespace. This also allowed me to clean up the core code since it doesn't cater to the users anymore. The functions currently are: get-classpaths get-current-classloader -

Re: [ANN] dj 0.1.0 released

2011-10-14 Thread Brent Millare
In master, I added clojurescript support. Note: the clojurescript bootstrap scripts require curl, make sure you have that before installing. dj cljs install installs clojurescript to dj/usr/src/ dj cljs repl starts a cljs repl -- You received this message because you are subscribed to the

Blog post declare type implements protocol feature

2011-10-25 Thread Brent Millare
I recently read the article http://www.colourcoding.net/blog/archive/2011/10/25/clojure-is-a-get-stuff-done-language.aspx?utm_source=feedburnerutm_medium=feedutm_campaign=Feed%3A+ColourCoding+%28Colour+Coding%29 and it mentions in the Better than a better java section, that Compojure defines a

Simplicity, and implications on usage of SQL

2011-10-25 Thread Brent Millare
In the thread about Rich Hickey's talk on simplicity, people bring up the point that Rich suggests to *finally*, learn SQL. The idea is to use declarations to describe your solution, decoupling implementation details. However, its arguable that SQL itself is hard. For example, programmers can

Re: A Taste of cKanren (via a coding challenge)

2011-10-30 Thread Brent Millare
Looks really cool. Can't wait to see the talk. -- 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 members are moderated - please be patient with your first post. To

Re: Clojure on PyPy

2011-11-16 Thread Brent Millare
The JVM is an advanced, mature JIT compiler. PyPy's generated JIT compilers are not as mature. As a result, the JVM does many of the things in the article and more. From what I see, the benefits of Clojure targetting PyPy would be exploring the performance advantages of very experimental work.

Re: Clojure on PyPy

2011-11-17 Thread Brent Millare
Couple of clarifications. My main point is the maturity of the JVM, so when comparing what is presented in the article (which isn't much), it can do what is listed. That's not to say the converse isn't true, that PyPy's JIT can do things the JVM can't do. Like I said, there are a lot of

Re: Clojure on PyPy

2011-11-21 Thread Brent Millare
On Monday, November 21, 2011 10:28:18 AM UTC-5, tbc++ wrote: Rpython is very restrictive. Basically it's garbage collected C++ with a different syntax. So this means we can't import modules at runtime. So any additional libraries must be added via C FFI. So as an example, let's take a look

Can we make implements? public

2011-11-28 Thread Brent Millare
I need to verify if an object implements a protocol. Looking at the source code, I noticed that protocol objects act as a map, and has the key :impls. From this is a map I can look up a class to see if there are functions. The resulting code is: (defn implements? [protocol obj] (boolean

Re: Baltimore Functional Programming

2011-11-28 Thread Brent Millare
I'm in the B'more area. -- 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 members are moderated - please be patient with your first post. To unsubscribe from this

Re: Can we make implements? public

2011-11-28 Thread Brent Millare
satisfies? is the solution. Thanks. -- 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 members are moderated - please be patient with your first post. To unsubscribe

[ANN] dj-peg released 0.1.0

2011-12-03 Thread Brent Millare
dj-peg 0.1.0 A Ring inspired (aka functional and composable) parsing expression grammar (PEG) library. A while back I wrote a PEG generator. Since it was buggy, I've completely rewritten it and also tried to write it psuedo literate programming (LP) style, in that I try to make it more of a

Re: [ANN] dj-peg released 0.1.0

2011-12-03 Thread Brent Millare
Forgot to post the github link: git://github.com/bmillare/dj-peg.git -- 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 members are moderated - please be patient with

Re: [ANN] dj-peg released 0.1.0

2011-12-06 Thread Brent Millare
I've added a little overview in the code, hopefully this should make things clearer. Also I made parse, the main invocation point, extensible to users of the library. -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email

  1   2   3   >