[CLJ-751] cl-format: ~( thows an exception with an empty string Created: 05/Mar/11 Updated: 01/Mar/13 Resolved: 08/Apr/11
|Affects Version/s:||Release 1.2, Release 1.3|
|Fix Version/s:||Release 1.3|
|Reporter:||Tom Faulhaber||Assignee:||Tom Faulhaber|
|Patch:||Code and Test|
|Comment by Tom Faulhaber [ 05/Mar/11 7:44 PM ]|
The following block of code throws an index out of range exception:
|Comment by Tom Faulhaber [ 06/Mar/11 12:01 AM ]|
Patch that fixes the issue and adds tests
|Comment by Stuart Halloway [ 20/Mar/11 10:17 AM ]|
Patch works. One question: Why does cl-format print "nil" as "Nil"? Is this a CL-ism? Do we want it?
|Comment by Tom Faulhaber [ 21/Mar/11 10:51 AM ]|
Answer: cl-format doesn't print nil as "Nil". The () construction is a case control operator. In this case, it capitalizes the each word in the expression: http://www.lispworks.com/documentation/HyperSpec/Body/22_cha.htm.
In general, I've suppressed the obvious "CL-only" stuff like upper case symbols and such and replaced them with the corresponding Clojure conventions.