Re: Literals embedded in vector and array datums must type-match with the container John Cowan (27 Apr 2026 20:35 UTC)

Re: Literals embedded in vector and array datums must type-match with the container John Cowan 27 Apr 2026 20:35 UTC

On Mon, Apr 27, 2026 at 3:21 PM Peter McGoron <xxxxxx@mcgoron.com> wrote:

> exact integer literals?
\> inexact complex literals?

Yes and yes.   I have fixed issue #333.

> I would leave it unspecified, although I agree in restricting integer
> arrays to exact integers. Is there any harm in a rule that a number that
> would be inferred to be exact in an inexact array is treated as-if it
> had `#i` prepended to it?

It''s misleading at best.  In every other context, "1" is an exact
integer literal: it can be coerced to an inexact value by Scheme
procedures.

> Requiring complex literals sounds somewhat cumbersome if many of the
> numbers I am inserting have zero imaginary part.

A regex search and replace will allow you to insert "+0i" after every
such number pretty easily.

> I would at least add the following as a possible extension:

So that we don't lose track of your proposal, I posted it as a comment at #333.