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

Re: / and \



What should the \ function be renamed to?  Is \\ reasonable?  And should
the present rem function (friend of remove, which is a friend of delete,
which is a friend of member) be renamed to something else so that name
can be used for some sort of remainder?

I would like to make new functions, div and mod, which are like quotient
and remainder but truncate toward negative infinity rather than zero
(more precisely, mod has the sign of the divisor whereas remainder
has the sign of the dividend, and div is the division function that goes with it).
I guess it isn't necessary to worry about fixnum-only names for these, since
computer manufacturers perversely don't provide the operation anyway.
(If my documentation is up-to-date, the S-1 has an instruction for mod
but doesn't have one for div!  However, it has so many kinds of numbers
that no naming scheme can possibly accomodate them all and declarations
necessarily are required.)

As far as I know, everyone agrees that the present \\ (fixnum gcd) is
useless and can simply be flushed.

Of course, in the Lisp machine this vast plethora of arithmetic functions
are all identical, so I don't care as much as some people.  But it would
certainly be unacceptable to make this change in some parts of the Maclisp
family and not others.