From: David M. <sv...@ya...> - 2004-11-11 03:46:23
|
Lars Brinkhoff wrote: > Using SBCL 0.8.16 on a PowerPC, I'm getting the classical error > message below. I understand there's a solution to this involving > type declarations, but I don't know where to put them. Should I > hack the internals of CL-SDL? > > This small program is sufficient to get the message: > (progn > (sdl:init sdl:+init-video+) > (cl-sdl:clear-screen (sdl:set-video-mode 512 512 32 sdl:+hwsurface+)) > (sdl:quit)) > > ; in: LAMBDA NIL > ; (SB-ALIEN-INTERNALS:NATURALIZE > ; (SB-SYS:SAP+ SB-ALIEN::SAP (/ SB-ALIEN::OFFSET SB-VM:N-BYTE-BITS > ; '#<SB-ALIEN-INTERNALS:ALIEN-RECORD-TYPE (STRUCT SDL:SURFACE ...)))) > ; ==> > ; (SB-ALIEN-INTERNALS:%SAP-ALIEN > ; ALIEN '#<SB-ALIEN-INTERNALS:ALIEN-RECORD-TYPE (STRUCT SDL:SURFACE ...)) > ; note: unable to > ; optimize > ; because: > ; could not optimize away %SAP-ALIEN: forced to do runtime > ; allocation of alien-value structure Are you really worried about effeciency in this example, or just trying to get a clean compile? Because sdl:set-video-mode is going to take lots, lots more time than consing up a little ol' alien wrapper object on the heap. (the latter is what the warning is complaining about). On the sbcl-help list I'm trying to drum up popular support for getting this error message to be either shorter & less dire sounding, or possibly non-existant. However, so far I'm yelling into the wind, so if you'd care to lend your voice, it'd be appreciated. :) |