[r6rs-discuss] thinko in spec of fxcopy-bit-field
William D Clinger
will at ccs.neu.edu
Thu Sep 27 20:07:56 EDT 2007
> > Why, pray tell, must the third argument to fxcopy-bit-field
> > be less than (fixnum-width)?
> So that your code would still work when you do
> (declare unsafe non-r6rs full-speed-forward)
> and without the compiler coercing the value of
> the shift to some small value. This also forces
> implementors to implement these operations in a
> portable, predictable, reliable, and safe manner.
Since your declaration is already outside the bounds
of R6RS, implementations are permitted to respond to
it by transforming the semantics in arbitrary ways.
Hence the R6RS spec in no way forces implementors to
implement operations in a portable, predictable,
reliable, or safe manner in programs governed by
What you are trying to say, I think, is that excluding
the sign bit from bit fields assists portability and
predictability in R6RS programs that contain no such
declarations, but all bets are off when you do
(declare unsafe non-r6rs full-speed-forward).
More information about the r6rs-discuss