Re: New developments in beginner-friendly editing/repl environments?

2018-08-29 Thread Phillip Lord
Have you asked the developer to provide an option? >From my experience is that parinfer is weird for the first 5 mins. Then it gets less confusing than trying to work out why the indentation is wrong. In paren mode, it does allow adding and removing brackets also. Phil "'Lee' via Clojure" wri

Re: Developing in Clojure with Emacs: Mastering the Keyboard

2018-03-05 Thread Phillip Lord
this message because you are subscribed to the Google >>> Groups "Clojure" group. >>> To post to this group, send email to clo...@googlegroups.com >>> >>> Note that posts from new members are moderated - please be patient with >>> your fi

Re: Clarification on how Clojure libraries can be included in other software

2017-10-02 Thread Phillip Lord
My reading of this is slightly different. As far as I can tell, it is possible to use Clojure within GPL libraries or applications, as Clojure would fall under the definition of "System Library" implementing the "Standard Interface". It's the same clause in GPL which allows, for example, GPL appl

Re: Clojure core documentation

2017-09-26 Thread Phillip Lord
Alex Miller writes: > On Monday, September 25, 2017 at 11:42:12 AM UTC-5, Phillip Lord wrote: >> Clojure's doc strings, though, contain knowledge that is not >> clear. Consider, this documentation: >> >> Returns a new seq where x is the first element and seq i

Re: Clojure core documentation

2017-09-26 Thread Phillip Lord
ber 25, 2017 at 9:42:12 AM UTC-7, Phillip Lord wrote: >> >> >> >> Clojure's doc strings, though, contain knowledge that is not >> clear. Consider, this documentation: >> >> Returns a new seq where x is the first element and seq is the rest. >&

Re: Clojure core documentation

2017-09-25 Thread Phillip Lord
Clojure's doc strings, though, contain knowledge that is not clear. Consider, this documentation: Returns a new seq where x is the first element and seq is the rest. x is the name of a parameter. So is the the second occurence of seq, but not the first. Neither first, nor rest refer to the func

Re: [ANN] clojure.java.jdbc 0.7.0 Beta 2

2017-07-23 Thread Phillip Lord
Yep, appears that you are right. I ended with this: (doseq [[k v] (ns-map ns) :when (= (find-ns 'clojure.core) (:ns (meta v)))] (ns-unmap ns k)) which is pretty ugly. Justin Smith writes: > refer-clojure doesn't ever remove mappings, it only adds them > > The reason a refer-c

Re: [ANN] clojure.java.jdbc 0.7.0 Beta 2

2017-07-22 Thread Phillip Lord
Apologies, didn't mean to follow that thread! Phillip Lord writes: > I am confused about how to exclude clojure.core from a namespace already > exists. That is, I have not just created the namespace, but it's been > given to me by a tool. > > Consider, for example: &g

Re: [ANN] clojure.java.jdbc 0.7.0 Beta 2

2017-07-22 Thread Phillip Lord
I am confused about how to exclude clojure.core from a namespace already exists. That is, I have not just created the namespace, but it's been given to me by a tool. Consider, for example: lein repl nREPL server started on port 41054 on host 127.0.0.1 - nrepl://127.0.0.1:41054 REPL-y 0.3.7, n

Re: Migrating nREPL out of Clojure Contrib

2017-07-21 Thread Phillip Lord
Alex Miller writes: > On Tuesday, July 18, 2017 at 1:03:09 PM UTC-5, Chas Emerick wrote: >> (Parenthetically, it strikes me as very strange for a project to have a >> copyright assignment to an individual that hasn't lodged any commits, at >> least insofar as the project gone "solo". It's inter

Re: [ANN] Primitive Operator

2017-07-03 Thread Phillip Lord
, July 3, 2017 at 11:44:40 AM UTC+2, Phillip Lord wrote: >> >> >> >> This is the first alpha release of my new library! Comments welcome. >> >> Clojure has an extensive system for dealing with numbers, including >> error on overflow, or auto-promotion, defau

Re: [ANN] Primitive Operator

2017-07-03 Thread Phillip Lord
Nicola Mometto writes: > Hi Phillip, > > I've had a very quick look at the code and I've spotted a few issues, > here's my feedback: > > 1- all your functions will cause input args and return value to be > boxed. There's a few ways to avoid it, none of which are particularly > pretty. If your lib

Re: [ANN] Primitive Operator

2017-07-03 Thread Phillip Lord
Nicola Mometto writes: > Hi Phillip, > > I've had a very quick look at the code and I've spotted a few issues, > here's my feedback: > > 1- all your functions will cause input args and return value to be > boxed. There's a few ways to avoid it, none of which are particularly > pretty. If your lib

[ANN] Primitive Operator

2017-07-03 Thread Phillip Lord
This is the first alpha release of my new library! Comments welcome. Clojure has an extensive system for dealing with numbers, including error on overflow, or auto-promotion, defaulting to long and double data types. This is all well and good, but irritating if you need to implement an algorith

Scripting with a pre-prepared environment

2017-06-30 Thread Phillip Lord
I am trying to build a clojure environment which can run pre-prepared scripts, using functions from my own library. I've been trying out boot and it's nice. I can do things like so: #!/usr/bin/env boot (set-env! :dependencies '[[uk.org.russet/tawny-owl "2.0.0-SNAPSHOT"]])

Re: Numbers/math in Clojure

2017-06-27 Thread Phillip Lord
Alex Miller writes: > On Sunday, June 25, 2017 at 1:55:42 AM UTC-5, henrik42 wrote: >>> Oh, I thought because there is the float-function floats are supported. >> Clojure could use "0.2f" to print/read floats and still use double "0.2" as >> the default (but float's "Infinity" may be challengin

Re: Why transducers are not (yet) fundamental?

2017-06-22 Thread Phillip Lord
writes: > I'm doing a little research for a talk and asking clojurists around. The > thesis I'm supporting is that transducers should completely replace > "normal" (non-reducing based) sequential processing. People have different > reactions to this, usually going from "what's wrong with threa

RE: Let and For Doesn't Execute - Where Is My Misunderstanding?

2017-05-17 Thread Phillip Lord
They are lazy -- change "for" to "doseq" From: clojure@googlegroups.com [clojure@googlegroups.com] on behalf of Kevin Kleinfelter [kleinfelter.gro...@gmail.com] Sent: 17 May 2017 19:14 To: Clojure Subject: Let and For Doesn't Execute - Where Is My Mis

RE: How to Create Clojure `defn` Functions automatically?

2017-05-14 Thread Phillip Lord
I don't think that they are the same, unfortunately. In the `def` form the symbol is unquoted as so much be known at the time that the form is compiled. In the second case, the symbol is quoted and so can also be a variable. Hence, it cannot be guaranteed to be known at compile time. The practic

Re: Following type annotations across call sites to eliminate reflection?

2016-05-23 Thread Phillip Lord
gt; 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 >

Re: Clojure docstring style

2016-05-16 Thread Phillip Lord
The problem is that the var might not be a var yet. You'd have to re-render code after evaluation. Phil Christopher Small writes: > Seems like this shouldn't be a problem as long as you only try to render a > link if there's actually such a var. This might be a little messier, but > would m

Re: [ANN] CIDER 0.11 Released!

2016-03-04 Thread Phillip Lord
Kudos to Benedek Fazekas who added that feature. Raymond Huang <12ay.hu...@gmail.com> writes: > Congrats. This was a really awesome release. I really how jack-in > dynamically adds the dependencies & plugins. > > No more out of sync issues :) > > On Thu, Mar 3,

Re: [ANN] CIDER 0.11 Released!

2016-03-03 Thread Phillip Lord
com/clojure-emacs/cider/releases/tag/v0.11.0 > > Enjoy! -- Phillip Lord, Phone: +44 (0) 191 208 7827 Lecturer in Bioinformatics, Email: phillip.l...@newcastle.ac.uk School of Computing Science, http://homepages.cs.ncl.ac.uk/phillip.lord

Re: [ANN] Clojure 1.8.0-RC1 is now available

2015-11-11 Thread Phillip Lord
I've been trying out RC1. I've tried enabling the direct linking in leiningen, by sticking: :jvm-opts ["-Dclojure.compiler.direct-linking=true"] I can't see any particular performance change (when running tests anyway). Is there a way to know whether it is actually working? Phil Alex Miller

Re: org-mode Clojure babel

2015-11-06 Thread Phillip Lord
>> You received this message because you are subscribed to a topic in the >> Google Groups "Clojure" group. >> To unsubscribe from this topic, visit >> https://groups.google.com/d/topic/clojure/PldQTR3yB3A/unsubscribe. >> To unsubscribe from this group an

Re: [meta] Unwelcome changes around here.

2015-10-08 Thread Phillip Lord
We've been here before with Fluid Dynamics. The whole rational explanation/discussion thing didn't work last time, and probably won't this time. I'd suggest ending this thread immediately. Timothy Baldridge writes: > To expand my previous reply. What site are you talking about? I got your > em

Re: Where do I find javadoc for clojure interfaces?

2015-10-01 Thread Phillip Lord
Probably because they are not documented. This is the source code for ISeq in total /** * A persistent, functional, sequence interface * * ISeqs are immutable values, i.e. neither first(), nor rest() changes * or invalidates the ISeq */ public interface ISeq extends IPersistentCollection {

Re: Using metadata to specify how calls to a macro should be indented

2015-09-23 Thread Phillip Lord
Artur Malabarba writes: >> > Yes, that's what the current (but unmerged) implementation does. :) > >> If this cache were persisted between Emacs sessions then the problem >> largely goes away. >> > Yes, that's very plausible to do. I am happy to do the implementation for this (i.e. the persistanc

Re: Using metadata to specify how calls to a macro should be indented

2015-09-23 Thread Phillip Lord
Artur Malabarba writes: > You're right about indentation depending on the code being evaluated, but > that's still better than nothing. ☺ > > People who do a significant amount of coding without a live session can > still manually configure indentation like they currently do, and they're no > wor

Re: Using metadata to specify how calls to a macro should be indented

2015-09-22 Thread Phillip Lord
Fluid Dynamics writes: > On Tuesday, September 22, 2015 at 6:31:34 AM UTC-4, Phillip Lord wrote: >> >> ... The interesting question then is what >> percentage of the time do Clojure developers work *without* a repl >> active. >> > > Uhhh, zero? :) Some

Re: Using metadata to specify how calls to a macro should be indented

2015-09-22 Thread Phillip Lord
Artur Malabarba writes: > Over at CIDER we're adding a feature where the author of a macro (or > function) can specify how that macro should be indented by adding an :indent > metadata to its definition. This way the editor (and other tools, like > cljfmt) will know what's the proper way of

Re: Homoiconicity in Clojure - the broken promise

2015-08-27 Thread Phillip Lord
y way to switch Clojure to interpreted mode instead of compiling > the data structure form? The structure what causes the headache are arrays > initializers. > I would like to keep the code simple since the language should solve the > problem for me, not me for the case of stupid

Re: Unable to write GPL software with clojure?

2015-08-19 Thread Phillip Lord
Sean Corfield writes: > On 8/18/15, 3:04 PM, "Phillip Lord" phillip.l...@russet.org.uk> wrote: > > >>There *is*, however, an issue with use of many parts of the Clojure >>Ecosystem. > > Even if the "Clojure/core" definition extended to Contrib l

Re: Unable to write GPL software with clojure?

2015-08-18 Thread Phillip Lord
Bodil is wrong, I belive. You can write GPL software with clojure, in the same way that you can write GPL software with Java. Or GPL software for Windows. The relevant provision in the GPL is the bit about "standard interface" and "system libraries". You can link GPL code to a system library with

Re: [ANN] Time-Bombed Open License - thoughts?

2015-06-05 Thread Phillip Lord
Fergal Byrne writes: > That's a great post (and the Mailpile post is also a great discussion of > the topic), thanks for sharing. > > The GPL already has a clause which allows the owner (and downstream user) > to defer, for 12 months, the full obligations of GPL It really doesn't. > see this guy

Re: multi-arity functions with macros

2015-06-05 Thread Phillip Lord
;>] > (dispatch f <> > > > (clojure.core/defn > default-ontology-dispatch > ([f] (dispatch f)) > ([f a23733] (dispatch f a23733)) > ([f a23733 b23734] (dispatch f a23733 b23734)) > ([f a23733 b23734 c23735] (dispatch f a23733 b23734 c23735)) > ([f a2

Re: multi-arity functions with macros

2015-06-05 Thread Phillip Lord
Fluid Dynamics writes: >> (defn ^:private form-with-arity[n] >> ;; left as an exercise for the reader >> ) >> >> (defmacro ^:private m-default-ontology >> `(defn default-ontology >> ~@(map form-with-arity (range 1 10 >> >> (m-default-ontology) >> >> Or am I missing somethi

multi-arity functions with macros

2015-06-04 Thread Phillip Lord
I have a number of fairly nasty functions with a form that looks like this: (defn default-ontology ([f] (dispatch f)) ([f a] (dispatch f a)) ([f a b] (dispatch f a b)) ([f a b c] (dispatch f a b c)) ([f a b c d] (dispatch f a b c d)) ([f a b c d e] (dispa

Re: [ANN, GSoC] A Common Clojure Source Metadata Model

2015-05-06 Thread Phillip Lord
a docstring. > > On 6 May 2015 at 14:17, Phillip Lord wrote: > >> writes: >> > The goal of this project is to develop a comprehensive and extensible >> > model for describing Clojure sources from an API perspective. I will >> > also write a program that ana

Re: [ANN, GSoC] A Common Clojure Source Metadata Model

2015-05-06 Thread Phillip Lord
writes: > The goal of this project is to develop a comprehensive and extensible > model for describing Clojure sources from an API perspective. I will > also write a program that analyses Clojure sources according to this > model and outputs data documenting their usage. This could be compared > t

Re: Performance of defmulti in both ClojureScript and Clojure

2015-04-27 Thread Phillip Lord
Alex Miller writes: > Sounds like you might have been running into the absence of multimethod > caching for the default case (http://dev.clojure.org/jira/browse/CLJ-1429), > which has been fixed in 1.7. No, I don't think; my default case was and is "throw an exception". > Just on a side n

Re: Performance of defmulti in both ClojureScript and Clojure

2015-04-27 Thread Phillip Lord
I think that the answer is, it depends, and, there might be some surprises in store. In my own use, I found multimethods collapse in performance as a result of changes to the interface hierarchy in the library I was using (my tests cases went from 45s to over 4mins). I circumvented this by fiddl

Re: Generating .clj files with content

2015-04-08 Thread Phillip Lord
Tassilo Horn writes: > Using qualified names (like clojure.core/ns) is perfectly fine except if > a human is going to read the code. But you can force unqualified > symbols by using ~'sym. And you can create a symbol from a string with > the function `symbol`. You might want to take a look at

Re: Any chance of a module system being added to the language?

2015-04-02 Thread Phillip Lord
..@googlegroups.com >> For more options, visit this group at >> http://groups.google.com/group/clojure?hl=en >> --- >> You received this message because you are subscribed to the Google Groups >> "Clojure" group. >> To unsubscribe from this group and stop

Re: clojure, not the go to for data science

2015-04-02 Thread Phillip Lord
Fluid Dynamics writes: > On Tuesday, March 31, 2015 at 8:45:31 AM UTC-4, Phillip Lord wrote: >> >> The benefit is that Emacs is that its not constantly changing, and it >> gives you some stability over the years. I like latex, for instance, for >> the same reason. I

Re: clojure, not the go to for data science

2015-03-31 Thread Phillip Lord
Mikera writes: >> I would say, lack of numpy or equivalent. And nice tools to link between >> Clojure and the many C/Fortran numeric libraries. Python and R do this >> natively. >> > > core.matrix is effectively the equivalent of NumPy > > In some ways it is much more versatile, because it wor

Re: clojure, not the go to for data science

2015-03-31 Thread Phillip Lord
Fluid Dynamics writes: >> That's nonsense. As soon as you have made yourself acquainted with the >> basic Emacs terminology and concepts, getting started with Clojure >> development is a piece of cake. Of course, > > > the devil is in the details. Including the implementation details that lea

Re: clojure, not the go to for data science

2015-03-31 Thread Phillip Lord
Colin Yates writes: > The camel breaking straw for me was yet another iteration of 'come on, > let's tame this beast, find package X to scratch itch Y, update and > watch something break. Spend hours numptying and googling around, give > up, fresh re-install, do some paid work'. Rinse and repeat.

Re: clojure, not the go to for data science

2015-03-31 Thread Phillip Lord
Alexis writes: > Colin Yates writes: > >> I used it a few years back > > [snip] > >> [and] even after man-months spent tinkering, hunting down the right version >> on MELPA or MARMALADE (or whatever it is called) > > i basically only use MELPA and GNU ELPA. In terms of the ~200 packages i've > i

Re: clojure, not the go to for data science

2015-03-30 Thread Phillip Lord
Sayth Renshaw writes: > I last learned clojure in 1.2. Just curious why Clojure hasn't > developed as a go to for data science? > > It never seems to get a mention R,Python and now Julia get the > attention. By design it would appear that Clojure would be a good fit. > Is it a lack of libraries

RE: Licensing of software products created with Clojure and related

2015-02-20 Thread Phillip Lord
Well, you have to read the license, or employ a lawyer to do so. You mostly can do what you want with Clojure under EPL. You can build proprietary products with Clojure and distribute them with or without Clojure itself. The main limitation is that you cannot distribute a modified version of Cl

Re: Satisfies? seems strangely slow

2015-01-23 Thread Phillip Lord
Tassilo Horn writes: >> I don't think satisfies? is worth optimizing as using ton of it seems >> antithetical to protocols. It signals to me that a caller does in fact >> care about the implementation, whereas protocols are about not >> caring. Like your PR, if you want to ensure a protocol's cove

Re: TDD and lein

2015-01-08 Thread Phillip Lord
t;> 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 group, send email to >> clojure+unsubscr...@googlegroups.com >> For m

[ANN] lentic 0.6: Multiple syntactic views over Emacs buffers

2015-01-07 Thread Phillip Lord
tored from previous versions and includes an incremental update feature which performs well, coping well with buffers of 3-4k lines in length. Available on MELPA-stable, MELPA and Marmalade https://github.com/phillord/lentic http://www.russet.org.uk/blog/3035 -- Phillip Lord,

Re: Is there a reason ns macro is not a function?

2015-01-05 Thread Phillip Lord
s.com >> For more options, visit this group at >> http://groups.google.com/group/clojure?hl=en >> --- >> You received this message because you are subscribed to the Google Groups >> "Clojure" group. >> To unsubscribe from this group and stop receiving em

Re: Richelieu: a library for advising functions

2014-12-02 Thread Phillip Lord
t to implements hooks. Phil Edwin Watkeys writes: > Phillip, > > I’d cry if it weren’t so funny; I’ve just begun to make my way through the > lastest Read Eval Print λove and the first page or two dwells on reinvention. > At least mine wasn’t intentiona

Re: Richelieu: a library for advising functions

2014-12-02 Thread Phillip Lord
es)) > > (advise-ns 'user trace) > > (sum-squares 1 2 3 4) > ;;; The above invocation produces the following output: > > ;; > #'user/sum-squares (1 2 3 4) > ;; > #'user/mult (1 1) > ;; < #'user/mult 1 > ;; > #'user/mult (2 2) >

Re: [ANN] clj-fl 0.1.0.prealfa5 - Frame language library for Clojure

2014-11-20 Thread Phillip Lord
bers are moderated - please be patient with your >> first post. >> To unsubscribe from this group, send email to >> clojure+unsubscr...@googlegroups.com >> For more options, visit this group at >> http://groups.google.com/group/clojure?hl=en >> --- >

Re: If code is data why do we use text editors?

2014-11-18 Thread Phillip Lord
Thomas Huber writes: > Hi Phil, thanks for your reply. > > The source data structure doesn't have to contain only "bare" source code. > It could contain everything that is in a text file, but just saved in a > structured way. To contain "everything", then the data model needs to be rich enou

Re: If code is data why do we use text editors?

2014-11-14 Thread Phillip Lord
What > is the biggest function? Thinks like that become easy. Again you can ship > this queries as a library. > > > > > The drawback is you can’t simply program using any text editor. You need a > special tool. But we have that anyway (syntax highlighting, paredit etc.). >

[ANN] Tawny-OWL 1.3.0

2014-11-14 Thread Phillip Lord
I am pleased to annouce the 1.3.0 release of Tawny-OWL, now available on clojars and github (http://github.com/phillord/tawny-owl). What is Tawny-OWL = Tawny-OWL allows construction of OWL ontologies, in a evaluative, functional and fully programmatic environment. Think of it as t

Re: how clojure infers types.

2014-11-05 Thread Phillip Lord
la Mometto writes: > The reason why that call doesn't require reflection is that > Collection.unmodifiableSet has no overloaded methods, it only takes a > Set so the compiler doesn't have to disambiguate between different > signatures. > > Phillip Lord writes: > &g

Re: how clojure infers types.

2014-11-04 Thread Phillip Lord
ess even if set was type hinted (to IPersistentSet) it would still not work since, IPersistentSet is not assignable from java.util.Set. Phil Nicola Mometto writes: > Actually `set` and a lot of other clojure.core functions are neither > inlineable nor have type hints. > > Phillip Lord

how clojure infers types.

2014-11-04 Thread Phillip Lord
I have a piece of code that looks like this (.getOWLEquivalentClassesAxiom (owl-data-factory) (set classlist) (union-annotations classlist)) The method signature is getOWLEquivalentClassesAxiom(Set,Set) On runing lein check I get Reflection warning, tawny/owl.clj:2219:6

Re: Caching an anon function

2014-10-31 Thread Phillip Lord
Oh, dear, did I leave a trailing reference in my headers? Mars0i writes: > Phil, I think your post accidentally ended up in the wrong place. I > believe you intended to create a new thread. > > On Friday, October 31, 2014 4:55:39 AM UTC-5, Phillip Lord wrote: >> >>

Caching an anon function

2014-10-31 Thread Phillip Lord
I want to pass a java method call to a function. So instead of this: (defn call-method [] (.getCanonicalName Object)) I have something like this... (defn indirect-call [f clazz] (f clazz)) (defn indirect-call-memfn [] (indirect-call (memfn ^java.lang.Class getCanonicalName) Object))

Re: [ANN] Clojure 1.7.0-alpha3 now available

2014-10-28 Thread Phillip Lord
Reid McKenzie writes: > For the special case of a "reduction" over varargs as in #'clojure.core/+ > or #'clojure.core// where you're just generating Duff's I think the macro > should be pretty straightforward but it won't be general at all. I tend to agree with the lack of generality -- from a l

Re: [ANN] Clojure 1.7.0-alpha3 now available

2014-10-28 Thread Phillip Lord
On Tue, Oct 28, 2014 at 2:39 AM, Phillip Lord > wrote: > >> Reid McKenzie writes: >> > This suggests that |apply| is immensely expensive in general, >> > and that such arity unrolling even for trivial functions would be a good >> > thing. Albeit hard to buil

Re: [ANN] Clojure 1.7.0-alpha3 now available

2014-10-28 Thread Phillip Lord
Reid McKenzie writes: > This suggests that |apply| is immensely expensive in general, > and that such arity unrolling even for trivial functions would be a good > thing. Albeit hard to build. Wonder whether it is macroable. Something like (def new-function (with-arities [20] [args]

Re: CCW bug [SEVERE]

2014-10-27 Thread Phillip Lord
Fluid Dynamics writes: >> Really, you expect me to create an account and publish every little >> > bit of code I play around with on github? >> >> Publication of code for VCS isn't really necessary. RCS which was >> released in 1982 didn't require it (actually, didn't support it). With >> the

Re: [ANN] Clojure 1.7.0-alpha3 now available

2014-10-27 Thread Phillip Lord
on it. > > On Monday, October 27, 2014 2:23:15 AM UTC-5, Phillip Lord wrote: >> >> >> I am curious, with path CLJ-1430 why stop at 3 arguments? Why not unroll >> to 20? >> >> I ask for a practical reason. In my own library, I have unrolled several

Re: CCW bug [SEVERE]

2014-10-27 Thread Phillip Lord
Fluid Dynamics writes: > On Saturday, October 25, 2014 10:42:24 PM UTC-4, tbc++ wrote: >> >> "What if my file had been corrupted, or truncated and only the first 42 >> bytes of the new version written thus far, or something like that at the >> moment when the hang started?" >> >> So there's thi

RE: [ANN] Clojure 1.7.0-alpha3 now available

2014-10-27 Thread Phillip Lord
I am curious, with path CLJ-1430 why stop at 3 arguments? Why not unroll to 20? I ask for a practical reason. In my own library, I have unrolled several functions which get called a lot. Moving from all variadic to non-variadic up to 5 args has produced a given a 2x increase in my code under e

RE: Demoralising experience trying to install on Win 7

2014-10-25 Thread Phillip Lord
Not to contradict anything that you say, because I agree that "to run clojure you need to install leiningen" is a confusing message, there is an easier way to a REPL, which is Clojure.org -> download. Download clojure-1.6.jar, then run this with java -- something like java -jar clojure-1.6.jar

RE: Demoralising experience trying to install on Win 7

2014-10-25 Thread Phillip Lord
You could try this, although I don't have a windows box handy,, so can't vouch for it. http://leiningen-win-installer.djpowell.net/ From: clojure@googlegroups.com [clojure@googlegroups.com] on behalf of Geoff Caplan [ghcap...@gmail.com] Sent: 25 Octobe

Re: Modelling in Clojure

2014-10-22 Thread Phillip Lord
James Reeves writes: > > Sure, laziness feels like a subset of UAP. > > > Regardless, we have a nice example in Clojure, where we not >> distinguishing between data and computation allows us to do something >> nice. >> > > Yes... I agree it allows us to do something, but let's agree to disagree on

Re: Modelling in Clojure

2014-10-21 Thread Phillip Lord
James Reeves writes: > On 21 October 2014 12:52, Phillip Lord wrote: > >> >> Okay. I can give you a very concrete example, and one where I think that >> it probably has been actually useful to you. >> >> Imagine you write the following piece of code: >&g

Re: Modelling in Clojure

2014-10-21 Thread Phillip Lord
James Reeves writes: >> Which is nice and simple, yes. And has negative consequences in terms of >> extensibility. I understand if you are happy with this compromise. But >> it is a compromise. >> > > I don't disagree, but I do consider the compromise to be a minor one. > > UAP has huge disadvanta

Re: Modelling in Clojure

2014-10-20 Thread Phillip Lord
James Reeves writes: >> Yes, which is what I have done, of course. Now it won't work in any IDE >> which looks for the docstring as :doc metadata. It is totally >> unextensible. I do not think that this is good. >> > > Clojure prefers "simple" solutions over "easy" solutions. A nice aphorism some

Re: Modelling in Clojure

2014-10-20 Thread Phillip Lord
James Reeves writes: >> > Yes, Clojure pretty much rejects the idea of uniform access. > > >> I don't think it does. I think it just does not support it which is a >> somewhat different thing. >> > > I thought it was pretty clear that Clojure prefers data over APIs. The > uniform access principle

Re: Modelling in Clojure

2014-10-20 Thread Phillip Lord
James Reeves writes: > On 18 October 2014 08:28, Mark Engelberg wrote: > >> Yeah, it's hard to deny the convenience of Clojure's keyword lookups and >> standard assoc mechanism for getting and setting stored values, but I think >> Bertrand Meyer's Uniform Access Principle reflects some pretty de

Re: Modelling in Clojure

2014-10-20 Thread Phillip Lord
Fluid Dynamics writes: >> I don't know who is the outlier. The point is that Scala, for instance, >> has explicit support to hide the distinction between accessing a value >> and computing a value. The point is to support the uniform access >> principle. >> >> http://en.wikipedia.org/wiki/Unif

Re: Modelling in Clojure

2014-10-20 Thread Phillip Lord
James Reeves writes: > On 17 October 2014 16:21, Phillip Lord wrote: >> http://en.wikipedia.org/wiki/Uniform_access_principle >> >> To my knowledge, Clojure cannot do this. >> > > Yes, Clojure pretty much rejects the idea of uniform access. I don't t

Re: Modelling in Clojure

2014-10-17 Thread Phillip Lord
James Reeves writes: >> >> Actually, I think that this is a real problem with Clojure, and with >> data access. It is very hard to change between accessing a var as a >> value and through calling a value. >> > > Curiously, this is something I don't think I've ever run into. > > Perhaps I'm the ou

Re: Modelling in Clojure

2014-10-17 Thread Phillip Lord
Mark Engelberg writes: > But let's say later you decide you want your data model to be {:first-name > "Alice", :last-name "Beasley", :email "al...@example.com"}, and you want to > change name to be a computed value that concatenates first and last names > -- this is going to break all your existin

[ANN] Tawny-OWL 1.2

2014-10-10 Thread Phillip Lord
le. https://github.com/phillord/tawny-owl/blob/master/docs/releases.md -- Phillip Lord, Phone: +44 (0) 191 222 7827 Lecturer in Bioinformatics, Email: phillip.l...@newcastle.ac.uk School of Computing Science, http://homepages.cs.ncl.ac.uk/ph

Re: why (> 2) returns true

2014-09-17 Thread Phillip Lord
Same argument applies (er...) to the zero element case. Phil Ashton Kemerling writes: > I wouldn't be surprised if the 1 arg form is to help people who use > along > with apply, just in case the list is only 1 element long. > > On Wed, Sep 17, 2014 at 7:40 AM, P

Re: why (> 2) returns true

2014-09-17 Thread Phillip Lord
Herwig Hochleitner writes: > 2014-09-17 11:51 GMT+02:00 Phillip Lord : > >> >> So, why not special case 1 arg as well, and have that except? It's a >> reasonable question. I would submit a bug report and see if anyone else >> agrees. Something is wrong for su

Re: why (> 2) returns true

2014-09-17 Thread Phillip Lord
Robert Tweed writes: > In writing this, I thought I'd better also test what (>) and (<) evaluate to, > because by the above definition, those should also evaluate to true. > Unfortunately, at least in v1.6, they throw an arity error. IMO, by the same > logic that says a single argument is valid,

Re: why (> 2) returns true

2014-09-15 Thread Phillip Lord
Jeremy Vuillermet writes: > Thanks, that' clearer. > Also I didn't take time to read the docstring > "Returns non-nil if nums are in monotonically decreasing order, > otherwise false." > > so I guess [2] is monotonically decreasing and increasing at the same > time. Yeah, so the same list

Re: why (> 2) returns true

2014-09-15 Thread Phillip Lord
Jeremy Vuillermet writes: > Could it return a (partial > 2) ? Because > works with n args and not just two. (> 2) => (partial > 2) then why not (> 2 3) =? (partial > 2 3) when is the sensible place to stop? Now, if > took at most two args, this would be a sensible thing. As far as I ca

Re: Clojure terminology

2014-09-15 Thread Phillip Lord
jvanderhyde writes: > Another random thought: What to you call this? > [(+ 2 3) (+ 4 5)] > It is an expression, but it is not a literal--I cannot say it "evaluates to > itself." So, only symbols and keywords really evaluate to themselves. All you are showing is that vectors and lists are eval

Re: Clojure terminology

2014-09-15 Thread Phillip Lord
jvanderhyde writes: > Thanks for the help, everyone. You managed to pin down my problem. I was > using "Clojure from the ground up" and a Scheme book, and the two together > got me confused. So, I can say it like this: > > Every expression is evaluated (meaning converted to a value), unless it

Re: Clojure terminology

2014-09-12 Thread Phillip Lord
jvanderhyde writes: > I want to say something like this: > > A word is considered a var unless it is quoted. Example: 'hello > > A list is considered a function invocation unless it is quoted. Example: > '(1 2 3) > I think you really need to bite the bullet and say "everything is evaluated, u

Re: Is Clojure a language for growth?

2014-08-20 Thread Phillip Lord
gvim writes: > On 20/08/2014 14:09, Phillip Lord wrote: >> When I got my first Java job, I had no experience at it; day one was >> popping into town to buy a "how to program Java" book. >> >> Actually, I had very little experience and no qualifications in >

Re: Is Clojure a language for growth?

2014-08-20 Thread Phillip Lord
aboy021 writes: > We've had trouble finding Clojure devs, and others have complained of how > hard it is to learn Clojure and read the code from open source projects, > especially for those with backgrounds in languages like C++. > > I think Clojure should be a good fit for us because it is ex

Re: Transducers are Coming

2014-08-07 Thread Phillip Lord
ansducers together with core.async's new > support for them. > > I am very excited about this powerful technique and how we all might use it. > > Please have a look. > > Feedback welcome, > > Rich -- Phillip Lord, Phone: +44 (

Re: ANN: Namespace browser for Emacs users

2014-08-01 Thread Phillip Lord
> > On Monday, July 28, 2014 5:48:20 AM UTC+3, John Andrews wrote: >> >> Emacs users: I have put together a namespace browser which builds upon the >> existing functionality of Cider. It is in early stages of development but I >> find it quite useful. >> >>

Re: Is Clojure fit for giant space-efficient in-memory tree structures?

2014-06-27 Thread Phillip Lord
When you get to very large size the efficiency of your data representation is more likely to be the defining factor that the data representation of the language that you are using. So, I don't think that there is a specific answer, other than general advice for optimisation. Try it first, and opti

RE: leiningen project hooks

2014-06-24 Thread Phillip Lord
y to write. I'm not sure you need the lien exec plugin... an alias for ["run" "-m" "foo.bar/baz"]? On Tue, Jun 24, 2014 at 12:03 PM, Phillip Lord mailto:phillip.l...@newcastle.ac.uk>> wrote: But where did you define the hook? In the project itself. My

  1   2   3   4   >