In src/gamma.lisp, (defun simp-erf ...
Add this immediately after the checks for minf and inf
((and (or (not (numberp ($imagpart z))) (/= 0 ($imagpart z)))
(and (numberp ($realpart z)) (= 0 ($realpart z))))
(mul -1 '$%i (take '(%erfi) (mul '$%i z))))
Then, by default, erf(%i*z) will become %i erfi(z). And
the float will be evaluated if requested. But, I think that's
not the best, and I bet not foolproof, way to test for an
explicitly imaginary argument. I didn't run tests to see
what it breaks.
-- John Lapeyre