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

Re: Common Lisp solved this problem 20 years ago

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



Alan Watson <a.watson@xxxxxxxxxxxxxxxx> writes:

> I aplaud this goal. However, rather than create this horrid mess of
> type-specific operators, I would much prefer an approach that used
> type declarations, perhaps:
>
>    (with-flonum (x y) (/ x y))
>    (with-fixnum (n m) (* n m))

Declaring types of identifiers is not enough, because it can't express
the wish to ignore any fixnum overflow and assume that the result will
fit in a fixnum.

-- 
   __("<         Marcin Kowalczyk
   \__/       qrczak@xxxxxxxxxx
    ^^     http://qrnik.knm.org.pl/~qrczak/