Hi,
user> (definline sqrt [x]
`(Math/sqrt ~x))
#'user/sqrt
user> (map sqrt (range 1 10))
(1.0 1.4142135623730951 1.7320508075688772 2.0 2.23606797749979
2.449489742783178 2.6457513110645907 2.8284271247461903 3.0)
--
http://www.nostdal.org/
--
You received this message because you ar
Is it possible to use this approach to create a callable record which can take
a variable number of arguments?
I can't get the following to work:
(defrecord Foo [a]
clojure.lang.IFn
(invoke [this & args] (println (str a args
(def yo (Foo. "sam"))
(yo 1 2 3 4) ;=>
sc-one.Foo.invoke(Ljav
Hello all.
I'm currently using Netbeans' clojure IDE and I quite like it. It has
a REPL. It highlights syntax and matches parentheses. It supports
maven and mercurial/git. It provides completion and doc for both
clojure and java. It has allows evaluation of forms from source code
to repl. It also
>>(defn refer-private [ns]
>> (doseq [[symbol var] (ns-interns ns)]
>>(when (:private (meta var))
>> (intern *ns* symbol var
>>
>> As he says, "this is slightly evil, and I would never recommend it for
>> any purpose except unit testing, but there it is." This wor
On Sat, Jun 18, 2011 at 4:44 AM, Sam Aaron wrote:
> Is it possible to use this approach to create a callable record which can
> take a variable number of arguments?
>
> I can't get the following to work:
>
> (defrecord Foo [a]
> clojure.lang.IFn
> (invoke [this & args] (println (str a args
On Sat, Jun 18, 2011 at 7:07 AM, James Keats wrote:
> Hello all.
>
> I'm currently using Netbeans' clojure IDE and I quite like it. It has
> a REPL. It highlights syntax and matches parentheses. It supports
> maven and mercurial/git. It provides completion and doc for both
> clojure and java. It h
On Sat, Jun 18, 2011 at 7:16 AM, Stuart Halloway
wrote:
> To access a private var, simply deref through the var:
> @#'some-ns/some-private-var
> This is in the coding standards doc
> (http://dev.clojure.org/display/design/Library+Coding+Standards). The doc is
> pretty short and worth reading if yo
Never used Cake, but Lein works great.
Emacs is all about customization - something bothers you? Just change it
The standard keybindings are extremely bad, change them.
I use this one: http://xahlee.org/emacs/ergonomic_emacs_keybinding.html
Just ignore the controversy around the guy, the binding
James Keats writes:
Hi James,
> I'm currently using Netbeans' clojure IDE and I quite like it.
So why are you bothering to use something else?
> but emacs, i find, is unnecessarily arcane compared to a modern java
> IDE. It's keyboard shortcuts and combinations are based on ancient
> keyboard
Hi Clojure Gurus :)
I've a somewhat contrived use-case for macros that I've been
struggling with.
Let's say there's an interface called EWrapper that I'm trying to
implement with methods "tickPrice" and "tickSize", a concrete class
EWrapperMsgGenerator that has methods with those names that retur
James,
For working with Clojure, if you are happy with Netbeans, use it. Especially
if you are relatively new
to Clojure, switching to Emacs won't do groundbreaking changes to your
productivity in the short term.
As you become more and more savvy with Lisp, Emacs will have more and more
to offer y
Hi,
I have 3 namespaces, each with functions that relate to the name of the ns:
core -- contains config and *server* var
query -- contains fn's related to querying
update -- contains update/delete fn's
I want to be able to "use" my core ns in my application, and call all of the
public fn's in
On Sat, Jun 18, 2011 at 4:44 AM, Sam Aaron wrote:
> Is it possible to use this approach to create a callable record which can
> take a variable number of arguments?
>
> I can't get the following to work:
>
> (defrecord Foo [a]
> clojure.lang.IFn
> (invoke [this & args] (println (str a args
On Fri, Jun 17, 2011 at 11:51 PM, Jian Liu wrote:
> Hi Clojure Gurus :)
>
> I've a somewhat contrived use-case for macros that I've been
> struggling with.
>
> Let's say there's an interface called EWrapper that I'm trying to
> implement with methods "tickPrice" and "tickSize", a concrete class
>
Hi,
these modern IDEs really do a tremendous job at organizing projects and
providing additional information at programming time. It's just, their
text-editor components suck.
If you are a Java developer, it's probably better to stay away from Emacs.
Should you ever get used to it, you're doo
Hi David,
Yes, the expansion I essentially want, and which runs properly without
the macro:
(proxy [EWrapper] []
(tickPrice [& args] (println "tickPrice" (. EWrapperMsgGenerator
tickPrice args)))
(tickSize [& args] (println "tickSize" (. EWrapperMsgGenerator
tickSize args)))
... other metho
So I realized that the method wasn't being found because args# is a
single argument, and I actually need it spliced in.
At this point I'm rather stuck. For example:
(defmacro make-msg-ewrapper [method-names]
`(proxy [EWrapper] []
~@(map
(fn [method-name]
(let [args (gensy
I want to know how to do it with netbeans ide ?
any nice step by step instructions will be very helpful ,
as emacs learning curve and setup is taking much time
thanks in advance .
vincent
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to t
2011/6/18 Vincent
> I want to know how to do it with netbeans ide ?
> any nice step by step instructions will be very helpful ,
>
Vincent,
Check out http://www.enclojure.org/gettingstarted
--
MK
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To
On Sat, Jun 18, 2011 at 4:07 AM, James Keats wrote:
> I'm currently using Netbeans' clojure IDE and I quite like it.
I'm currently using Eclipse with CCW and I quite like it. Much depends
on what you've been used to. I've worked in an Eclipse environment for
several years and use it for all my da
My main motivation for using Emacs is that it is rock-solid stable. I
look forward, however, to the day when the clojure plug-ins for the
other IDEs reach that level of maturity and stability, so I can leave
Emacs behind.
--
You received this message because you are subscribed to the Google
Grou
21 matches
Mail list logo