Is it possible to define ordering functions for own type?

2009-12-06 Thread John Ky
Hi, Is it possible to define the functions >, <, >=, <=, ==, min, and max for my own defstruct type? My type is: (defstruct deadline :value) where I initialise value with an object of type long. Thanks -John -- You received this message because you are subscribed to the Google Groups "Cloju

Re: clojure vim shebang

2009-11-11 Thread John Ky
Mine is almost the same: Vim 7.2, vimclojure 2.1.2, java 1.6.0_10 On Thu, Nov 12, 2009 at 10:47 AM, MarkSwanson wrote: > > Does anyone know why if the first character in my *.clj file is '#', then > > when I open it in VIM, ClojureVIM fails to recognise it as a Clojure > file? > > I don't know w

Re: How to write a macro

2009-11-11 Thread John Ky
Hi Alex, I had to ~(keyword (str sym)) instead of ~(keyword sym), but now it works well. Cheers, -John On Thu, Nov 12, 2009 at 12:40 AM, Alex Osborne wrote: > John Ky wrote: > > Hi all, > > > > I'm looking for a way to write a defkw macro so that (defkw ABSENT) >

Re: How to print without spaces?

2009-11-11 Thread John Ky
Thanks, On Thu, Nov 12, 2009 at 12:34 AM, Alex Osborne wrote: > John Ky wrote: > > How to I print without spaces? > > (println (str "a" "b" "c")) > > -- > You received this message because you are subscribed to the Google > Groups "

clojure vim shebang

2009-11-11 Thread John Ky
Hi all, Does anyone know why if the first character in my *.clj file is '#', then when I open it in VIM, ClojureVIM fails to recognise it as a Clojure file? Thanks -John -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send em

How to write a macro

2009-11-11 Thread John Ky
Hi all, I'm looking for a way to write a defkw macro so that (defkw ABSENT) expands to (def ABSENT (kw "ABSENT" :ABSENT )). Thanks, -John -- 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

How to print without spaces?

2009-11-11 Thread John Ky
Hi all, How to I print without spaces? For example: (println "a" "b" "c") Gives: a b c Rather than abc Thanks, -John -- 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 t

Re: Generating Java and C# wrappers

2009-10-31 Thread John Ky
? Is that feasible or even possible or desirable? Or am I just being silly? Cheers, -John On Sat, Oct 31, 2009 at 1:16 AM, Stuart Sierra wrote: > > On Oct 30, 6:18 am, John Ky wrote: > > I've been wondering if there was a way to specify the Java and C# wrapper > > classes/i

Generating Java and C# wrappers

2009-10-30 Thread John Ky
Hello, I've been wondering if there was a way to specify the Java and C# wrapper classes/interfaces to wrap Clojure code in Clojure, and then writing out them to a file so that they can ge compiled by their respective compilers. I'm asking this because in my work, I need to support these two lang