2008-02-17
| 00:20 | jh06 | omg |
| 00:21 | jh06 | I am having the hardest time with the Java classpath |
| 00:21 | jh06 | I have three jars in a single folder |
| 00:21 | jh06 | and I've set my CLASSPATH=jar1:jar2:jar3; but Java continues to give me errors when I try to invoke one of the classes from the jars |
| 00:25 | jh06 | ha |
| 00:25 | jh06 | after having problems for an hours, the first time I complain about it on IRC I get it to work... |
| 21:47 | ericthor_ | what do you think is a good strategy for dealing with invariants for function arguments when you want to provide meanful error messages (clojure idiomatic of course) |
| 21:47 | ericthor_ | consider: |
| 21:47 | ericthor_ | (defn go-left |
| 21:47 | ericthor_ | [{item :item {left :left up :up right :right :as path } :path}] |
| 21:47 | ericthor_ | (cond (= top path) "error - left of top called" |
| 21:47 | ericthor_ | (nil? left) "error - left of first" |
| 21:47 | ericthor_ | :else (struct loc left (struct node left up (:right item))))) |
| 21:48 | ericthor_ | here I'm destructuring the arguments (amazing by the way) and i have a couple of conditions to check for where I want to fail...i guess throw an exception |