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

Re: #O, an alternate view, yet again.

    Date: 31 October 1980 16:16-EST
    From: Richard L. Bryan <RLB at MIT-MC>
    Subject: Re: #O, an alternate view
    To: RWK at MIT-MC
    cc: BUG-LISP at MIT-MC

    If you don't want your input radix migrating machine-dependently, combine
    the #o and #* notations: type the PDP10 fixnum <-1,,0> as #o*777777000000
    where the "*", rather than meaning "read in machine-dependent input radix",
    means "read in and truncate to machine-dependent number of bits".
    Implementation Note: the reader code for #x and #b, at least, currently
    needs to peek at the following char for '"'-ness, and could check for
    "*"-ness as well.
Sigh, why do people persist in thinking I want truncation?  I don't, I want
unsignedness!  If I'm into truncation I can simply truncate my input.  There is
no truncation involved in specifying the sequence of bits represented by the
unsigned octal number 777777000000 in a 36 bit word.  In fact, I'd not have
complained about it being a BIGNUM if it weren't for BOOLE or somebody not
likeing it.  But I specified 36 bits; it makes sense to give me 36 bits.  If I
give a 37-bit number I'd expect it to give me a bignum; truncation would be a

There might be use for truncation, but I doubt it's important enough to provide
a reader syntax for it (besides #.).  There IS reason to want to specify
unsignedness.  Now if we take RLB's proposal, substitute 'unsigned' for
'truncated to a machine-dependent number of bits', and reverse the '*' and 'o',
we have my proposal.  Now, I don't care about the order of the '*' and the 'o'.
But I don't think BOTH proposals should exist; it would be too confusing.  How
about if we just don't offer truncation, and do offer unsigned reading?

Does anybody REALLY believe there is ANY use or justification for having your
input radix vary with implementation, ala #*?  Why?