Just found a quick little bug with format where it behaves differently than printf.<div><br></div><div>It appears to treat values formatted through "~v" as if "~a" was specified. </div><div><br></div><div>
I've only tested this for exact fractional numbers like 11 5/16 so I'm not sure if this happens with other such values.</div><div><br></div><div>For instance:</div><div><br></div><div><div>(printf "~a~n" (+ 11 (/ 5 16)))</div>
<div>> 181/16</div></div><div><br></div><div><div>(printf "~v~n" (+ 11 (/ 5 16)))</div><div>> 11 5/16</div></div><div><br></div><div>now format does not behave exactly this way...</div><div><br></div><div>
<div>(format "~a~n" (+ 11 (/ 5 16)))</div><div>> "181/16\n"</div></div><div><br></div><div><div>(format "~v~n" (+ 11 (/ 5 16)))</div><div>> "181/16\n"</div></div><div><br></div>
<div>Is this expected behavior?</div><div><br></div><div>Thanks,</div><div> Curtis</div>