[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: SRFI-47 -- types and declarations.

This page is part of the web mail archives of SRFI 47 from before July 7th, 2015. The new archives for SRFI 47 contain all messages, not just those from before July 7th, 2015.

bear wrote:
> Rather than introducing some kind of explicitly typed array, I think
> we should have multidimensional arrays (a la SRFI-25) enhanced with
> optional type declarations that allow compilers aware of them to
> produce optimized code -- but still have arrays be conceptually
> untyped.

There are good reasons to declare types for semantic reasons, not just
for space efficiency. For example, a few C programs rely on the implicit
modular arithmetic that you get by declaring a variable as unsigned.

However, this SRFI as written doesn't permit that kind of thing anyway
-- there's no guarantee of modular arithmetic (indeed, there's no
guarantee that #Au32 et al. exist at all).
Bradd W. Szonye