On 6 May 2010 18:53, Alan Ruttenberg alanruttenberg@gmail.com wrote:
Since Java doesn't have a standard macro facility or a concept like eval, I can't think of an wasy way to output the tested assertion without repeating the string twice (which tends to lead to errors in my experience).
My java buddy says use this facility: http://java.sun.com/j2se/1.4.2/docs/guide/lang/assert.html
That doesn't, unfortunately, solve the concern Mark states above. What we'd like to have is capability to say Assert((5 + 6 + 7) == 18); and have that output the parameters in string form and as computed values as well. You can do something like that pretty easily with lisp, but not with java. ;)