English 中文(简体)
How to improve Clojures error messages
原标题:
  • 时间:2009-11-18 15:19:25
  •  标签:
  • clojure

I ve been playing a bit with Clojure and so far is fairly impressed, but one thing that I keep running into is wierd error messages from Clojure. This comes in two forms: Java errors, like null pointer exceptions and in clojure syntax errors, like missing parenthesis pair. I was wondering if anyone know of a way to get better error messages?

Part of it is of course from learning a new language, but improving the error messages can never hurt :)

最佳回答

Well, the compiler and other stuff are being developed by a fairly small band of people led by Rich Hickey, and if you re a competent programmer then it s conceivable you could contribute to the compiler s development.

Clojure headquarters is at: http://clojure.org

You can get information and documentation there, and access to the source code and git repository...

...and there s a Google Group for it: http://groups.google.com/group/clojure?pli=1

Take a look and offer your help, if you dare. Good luck and power to you!

问题回答

This might help: http://github.com/mmcgrana/clj-stacktrace.

You can use it on the REPL to get more useful stack traces. It s still not great, but definitely better than nothing.





相关问题
How to improve Clojures error messages

I ve been playing a bit with Clojure and so far is fairly impressed, but one thing that I keep running into is wierd error messages from Clojure. This comes in two forms: Java errors, like null ...

clojure rmi classpath problem

I am trying to use clojure to implement a "plugin" for some vendor supplied software. Here is a little background on the vendor supplied software. It expects me to implement a particular interface ...

Help translating this Java codeblock to Clojure?

I m getting my feet wet with Clojure, and trying to get used to functional programming. I ve been translating various imperative functions from other languages into their Clojure equivalents -- and ...

Is functional Clojure or imperative Groovy more readable?

OK, no cheating now. No, really, take a minute or two and try this out. What does "positions" do? Edit: simplified according to cgrand s suggestion. (defn redux [[current next] flag] [(if flag ...

taking java method names as function arg in clojure

All, I want to create a function that takes a symbol representing a java method and applies it to some object: (user=> (defn f [m] (. "foo" (m))) When I execute this, I get a result much ...

how to efficiently apply a medium-weight function in parallel

I m looking to map a modestly-expensive function onto a large lazy seq in parallel. pmap is great but i m loosing to much to context switching. I think I need to increase the size of the chunk of work ...

热门标签