Stricter precondition when strength reducing variable right shifts
authorPaul Khuong <pvk@pvk.ca>
Fri, 31 May 2013 01:49:55 +0000 (21:49 -0400)
committerPaul Khuong <pvk@pvk.ca>
Fri, 31 May 2013 01:57:02 +0000 (21:57 -0400)
commit2378406d6eda78090dfe05e372438495aeace5e0
tree9aeef635487739db3aef4d7278b069d4b676f48a
parent17dd0a1692d807958a48a10d4cc44fe35cd1d37d
Stricter precondition when strength reducing variable right shifts

 Looking at the node's derived type is safer than a result type
 constraint, which seems to consider the LVAR's derived or
 truly-declared type.

 Remove a redundant AVER too. If people call %ash/right directly and
 incorrectly, they're looking for trouble. Moreover, the call's
 type will be derived only if the argument types are correct.

 Reported by Eric Marsden on sbcl-devel; further reduced test cases
 by Christophe Rhodes.
src/compiler/srctran.lisp
tests/compiler.pure.lisp