Skip to content
Commit bccd6a98 authored by Raymond Toy's avatar Raymond Toy
Browse files

Fix #58: Bogus type error in comparison of complex number with `THE` form

The deftransforms `upgraded-complex-real-contagion-arg1` and
`upgraded-complex-real-contagion-arg2` were coercing the complex
number to the exact type of the float number.  Because of the `THE`
form, the type of the float was `(member 1d0)`, so the compiler was
coercing `#c(1/2 1/2)` to `(complex (double-float 1d0))`, which is
wrong.

Therefore, coerce the complex to just the type format of the real
part, ignoring any bounds.

* src/compiler/float-tran.lisp
  * Coerce to format type, discarding any bounds
* src/general-info/release-21d.md
  * Update notes
* tests/issues.lisp
  * Added test for this
parent 31c6bf9f
Loading
Loading
Loading
Pipeline #288 passed with stage
in 9 minutes and 33 seconds
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment