code/room: Improve type-format database initialization for simple vector types.
authorAlastair Bridgewater <nyef@kana.lisphacker.com>
Sat, 27 Apr 2013 12:31:22 +0000 (08:31 -0400)
committerAlastair Bridgewater <nyef@kana.lisphacker.com>
Sat, 11 May 2013 13:56:43 +0000 (09:56 -0400)
commit4c86741fbb42b15472c3e4b615935159566427d9
treeec7e2fd0e019e5509ffae51151f54cc3626fccf0
parent4ff9d1fe33f936d40e329bedc8e2872fc2edf36a
code/room: Improve type-format database initialization for simple vector types.

  * There has been a longstanding FIXME comment on a piece of code
which contains a hand-maintained list of specialized vector types
and the shift count for converting the length from elements to
octets.

  * It turns out that all of this information, plus the type names
that we currently do a song-and-dance with INTERN, SUBSEQ, and
MISMATCH to obtain, plus information for the string types, is
available from *SPECIALIZED-ARRAY-ELEMENT-TYPE-PROPERTIES*.  And
*S-A-E-T-P* is guaranteed to be up-to-date, as it's too central to
our implementation of UPGRADED-ARRAY-ELEMENT-TYPE and MAKE-ARRAY
for it to be allowed to break.

  * So, replace nasty KLUDGE of an initialization for simple
vector types with something more principled, making it explicit
which properties need to be derived and which are simply already
available, and picking off the one specialized array type that
needs to be handled differently (SIMPLE-ARRAY-NIL).
src/code/room.lisp