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"

Re: Developing in Clojure with Emacs: Mastering the Keyboard

2018-03-05 Thread Phillip Lord
>> You received 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 - plea

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

Re: Clojure core documentation

2017-09-26 Thread Phillip Lord
Alex Miller <a...@puredanger.com> 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

Re: Clojure core documentation

2017-09-26 Thread Phillip Lord
gt; On Monday, September 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

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 >

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 <phillip.l...@newcastle.ac.uk> 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. > >

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,

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

Re: [ANN] Primitive Operator

2017-07-03 Thread Phillip Lord
gt; > On Monday, 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

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

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

[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

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

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

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

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

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

2016-05-23 Thread Phillip Lord
>> 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. &

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

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
//github.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

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

Re: org-mode Clojure babel

2015-11-06 Thread Phillip Lord
sit this group at >> http://groups.google.com/group/clojure?hl=en >> --- >> 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

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

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

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

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

2015-09-22 Thread Phillip Lord
Fluid Dynamics <a2093...@trbvm.com> 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. >> &g

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

Re: Homoiconicity in Clojure - the broken promise

2015-08-27 Thread Phillip Lord
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 64kb method limit. Thanks in advance, Olek -- Phillip

Re: Unable to write GPL software with clojure?

2015-08-19 Thread Phillip Lord
Sean Corfield s...@corfield.org writes: On 8/18/15, 3:04 PM, Phillip Lord clojure@googlegroups.com on behalf of 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 libraries

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 without

Re: multi-arity functions with macros

2015-06-05 Thread Phillip Lord
Fluid Dynamics a2093...@trbvm.com 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 something

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

2015-06-05 Thread Phillip Lord
Fergal Byrne fergalbyrnedub...@gmail.com 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

Re: multi-arity functions with macros

2015-06-05 Thread Phillip Lord
d23736] (dispatch f a23733 b23734 c23735 d23736))) On Thursday, June 4, 2015 at 11:55:23 AM UTC-5, Phillip Lord wrote: 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

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]

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

2015-05-06 Thread Phillip Lord
richard.mo...@posteo.de 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

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

2015-05-06 Thread Phillip Lord
. On 6 May 2015 at 14:17, Phillip Lord phillip.l...@newcastle.ac.uk wrote: richard.mo...@posteo.de 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

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

Re: Performance of defmulti in both ClojureScript and Clojure

2015-04-27 Thread Phillip Lord
Alex Miller a...@puredanger.com 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.

Re: Generating .clj files with content

2015-04-08 Thread Phillip Lord
Tassilo Horn t...@gnu.org 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

Re: clojure, not the go to for data science

2015-04-02 Thread Phillip Lord
Fluid Dynamics a2093...@trbvm.com 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 can still access

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

2015-04-02 Thread Phillip Lord
this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout. -- Phillip Lord

Re: clojure, not the go to for data science

2015-03-31 Thread Phillip Lord
Alexis flexibe...@gmail.com writes: Colin Yates colin.ya...@gmail.com 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

Re: clojure, not the go to for data science

2015-03-31 Thread Phillip Lord
Colin Yates colin.ya...@gmail.com 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'.

Re: clojure, not the go to for data science

2015-03-31 Thread Phillip Lord
Fluid Dynamics a2093...@trbvm.com 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

Re: clojure, not the go to for data science

2015-03-31 Thread Phillip Lord
Mikera mike.r.anderson...@gmail.com 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

Re: clojure, not the go to for data science

2015-03-30 Thread Phillip Lord
Sayth Renshaw flebber.c...@gmail.com 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

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

Re: Satisfies? seems strangely slow

2015-01-23 Thread Phillip Lord
Tassilo Horn t...@gnu.org 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

Re: TDD and lein

2015-01-08 Thread Phillip Lord
this message because you are subscribed to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout. -- Phillip Lord

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

2015-01-07 Thread Phillip Lord
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, Phone: +44

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

2015-01-05 Thread Phillip Lord
Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout. -- Phillip Lord, Phone: +44 (0) 191 208 7827 Lecturer in Bioinformatics

Re: Richelieu: a library for advising functions

2014-12-02 Thread Phillip Lord
;; #'user/mult (4 4) ;; #'user/mult 16 ;; #'user/add (1 4 9 16) ;; #'user/add 30 ;; #'user/sum-squares 30 -- Phillip Lord, Phone: +44 (0) 191 208 7827 Lecturer in Bioinformatics, Email: phillip.l...@newcastle.ac.uk School of Computing Science

Re: Richelieu: a library for advising functions

2014-12-02 Thread Phillip Lord
hooks. Phil Edwin Watkeys e...@poseur.com 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 intentional. Edwin -- Phillip Lord

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

2014-11-20 Thread Phillip Lord
to the Google Groups Clojure group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout. -- Phillip Lord, Phone: +44 (0) 191 208 7827 Lecturer

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

2014-11-18 Thread Phillip Lord
Thomas Huber th0mas.hu...@googlemail.com 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

[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

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

2014-11-14 Thread Phillip Lord
. You need a special tool. But we have that anyway (syntax highlighting, paredit etc.). Nobody programs using a bare text editor. Maybe this idea is not new? What do you think? -- Phillip Lord, Phone: +44 (0) 191 208 7827 Lecturer in Bioinformatics

Re: how clojure infers types.

2014-11-05 Thread Phillip Lord
brobro...@gmail.com 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: Yes, I checked the code. (defn

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: how clojure infers types.

2014-11-04 Thread Phillip Lord
(to IPersistentSet) it would still not work since, IPersistentSet is not assignable from java.util.Set. Phil Nicola Mometto brobro...@gmail.com writes: Actually `set` and a lot of other clojure.core functions are neither inlineable nor have type hints. Phillip Lord writes: I have a piece of code

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: Caching an anon function

2014-10-31 Thread Phillip Lord
Oh, dear, did I leave a trailing reference in my headers? Mars0i marsh...@logical.net 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: I want

Re: [ANN] Clojure 1.7.0-alpha3 now available

2014-10-28 Thread Phillip Lord
Reid McKenzie rmckenzi...@gmail.com 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

Re: [ANN] Clojure 1.7.0-alpha3 now available

2014-10-28 Thread Phillip Lord
Reid McKenzie rmckenzi...@gmail.com 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

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

Re: CCW bug [SEVERE]

2014-10-27 Thread Phillip Lord
Fluid Dynamics a2093...@trbvm.com 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

Re: CCW bug [SEVERE]

2014-10-27 Thread Phillip Lord
Fluid Dynamics a2093...@trbvm.com 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

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

Re: Modelling in Clojure

2014-10-22 Thread Phillip Lord
James Reeves ja...@booleanknot.com 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

Re: Modelling in Clojure

2014-10-21 Thread Phillip Lord
James Reeves ja...@booleanknot.com 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

Re: Modelling in Clojure

2014-10-21 Thread Phillip Lord
James Reeves ja...@booleanknot.com writes: On 21 October 2014 12:52, Phillip Lord phillip.l...@newcastle.ac.uk 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

Re: Modelling in Clojure

2014-10-20 Thread Phillip Lord
James Reeves ja...@booleanknot.com writes: On 17 October 2014 16:21, Phillip Lord phillip.l...@newcastle.ac.uk 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 think

Re: Modelling in Clojure

2014-10-20 Thread Phillip Lord
Fluid Dynamics a2093...@trbvm.com 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.

Re: Modelling in Clojure

2014-10-20 Thread Phillip Lord
James Reeves ja...@booleanknot.com writes: On 18 October 2014 08:28, Mark Engelberg mark.engelb...@gmail.com 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

Re: Modelling in Clojure

2014-10-20 Thread Phillip Lord
James Reeves ja...@booleanknot.com 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

Re: Modelling in Clojure

2014-10-20 Thread Phillip Lord
James Reeves ja...@booleanknot.com 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

Re: Modelling in Clojure

2014-10-17 Thread Phillip Lord
Mark Engelberg mark.engelb...@gmail.com 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

Re: Modelling in Clojure

2014-10-17 Thread Phillip Lord
James Reeves ja...@booleanknot.com 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

[ANN] Tawny-OWL 1.2

2014-10-10 Thread Phillip Lord
://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/phillip.lord

Re: why ( 2) returns true

2014-09-17 Thread Phillip Lord
Robert Tweed fistful.of.spann...@gmail.com 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

Re: why ( 2) returns true

2014-09-17 Thread Phillip Lord
Herwig Hochleitner hhochleit...@gmail.com writes: 2014-09-17 11:51 GMT+02:00 Phillip Lord phillip.l...@newcastle.ac.uk: 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

Re: why ( 2) returns true

2014-09-17 Thread Phillip Lord
Same argument applies (er...) to the zero element case. Phil Ashton Kemerling ashtonkemerl...@gmail.com 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, Phillip Lord

Re: Clojure terminology

2014-09-15 Thread Phillip Lord
jvanderhyde jamesvh...@hotmail.com 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

Re: Clojure terminology

2014-09-15 Thread Phillip Lord
jvanderhyde jamesvh...@hotmail.com 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

Re: why ( 2) returns true

2014-09-15 Thread Phillip Lord
Jeremy Vuillermet jeremy.vuiller...@gmail.com 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

Re: why ( 2) returns true

2014-09-15 Thread Phillip Lord
Jeremy Vuillermet jeremy.vuiller...@gmail.com 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.

Re: Clojure terminology

2014-09-12 Thread Phillip Lord
jvanderhyde jamesvh...@hotmail.com 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

Re: Is Clojure a language for growth?

2014-08-20 Thread Phillip Lord
aboy021 arthur.bo...@gmail.com 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

Re: Is Clojure a language for growth?

2014-08-20 Thread Phillip Lord
gvim gvi...@gmail.com 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 programming at all; perhaps

Re: Transducers are Coming

2014-08-07 Thread Phillip Lord
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 (0) 191 222 7827 Lecturer in Bioinformatics, Email: phillip.l

Re: ANN: Namespace browser for Emacs users

2014-08-01 Thread Phillip Lord
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. Check it out! https://github.com/jxa/cider-browse-ns -- Phillip Lord, Phone

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

Re: leiningen project hooks

2014-06-24 Thread Phillip Lord
, Jun 20, 2014 at 4:06 AM, Phillip Lord phillip.l...@newcastle.ac.uk wrote: I've been struggling with leiningen project hooks as I believe that I need them for my current project. I am writing an manual with code examples, using a literate programming technology. The main source

RE: leiningen project hooks

2014-06-24 Thread Phillip Lord
. 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 phillip.l...@newcastle.ac.ukmailto:phillip.l...@newcastle.ac.uk wrote: But where did you define the hook? In the project itself. My current best solution

leiningen project hooks

2014-06-20 Thread Phillip Lord
I've been struggling with leiningen project hooks as I believe that I need them for my current project. I am writing an manual with code examples, using a literate programming technology. The main source is in asciidoc, but I can untangle these to produce valid clojure, which I can then

lein dependcies and exclusions

2014-06-17 Thread Phillip Lord
I'm struggling a little with dependencies in lein for an artifact that is a dependency of a maven project. I have the following test sample working. This is project.clj (defproject test-exclusion 0.1.0-SNAPSHOT :description FIXME: write description :url http://example.com/FIXME;

  1   2   3   4   >