Closed alanruttenberg closed 6 months ago
For a <file:~xx> whose contents are
694656019000000000.0d0
yields
CL-USER> (with-open-file (i #p"~/xx" :direction :input) (read i)) 6.94656019d17
I can read a serialized version from a stream of file bytes, ok. How are you abusing READ?
Slime repl. Played around and definitely not a lisp issue, sorry about that. What happened was I copy-pasted the long part 694656019000000000 then added .0d0 at the end. But the long was a repl result (italicized) and for some reason it read that separately. So two things read: 694656019000000000 then 0.0d0 , and hence 0.0d0 result since it was last.
By comparison (* 694656019000000000 1.0d0) -> 6.94656019d17