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

Issue: BIT-ARRAY-FUNCTIONS (version 6)



    Date: Mon, 19 Jun 89 13:44 EDT
    From: David A. Moon <Moon@stony-brook.scrc.symbolics.com>

	Date: Mon, 19 Jun 89 13:31 EDT
	From: Barry Margolin <barmar@Think.COM>

	I'd like to suggest an additional change, which seems to be consistent
	with the attitude about use of bit vectors expressed in the proposal.
	The BIT and SBIT functions should return 0 if asked to access outside
	the bit array.  This would maintain the tautology

		(bit (bit-XXX v1 v2) n) == (logXXX (bit v1 n) (bit v2 n))

	If slowing down these functions (they'd be the only array accessors
	REQUIRED to check the dimensions) is considered unacceptable, then a new
	accessor should be added.

    I don't like this idea.

Could you elaborate?  Why is it that you like the idea of assuming 0
elements on the end when combining bit vectors, but not when accessing
them?  Either you think of them as being infinitely padded with zeros,
or you don't.

I'm not sure I really grasp the whole motivation for this change.
Anyone who needs the kind of functionality being proposed can already
get it by using the boolean integer functions.  They already provide the
infinitely-padded-with-zeroes feature.  In fact, they also provide
infinitely-padded-with-ones, also, in the form of negative numbers.
                                                barmar