Changeset 8641


Ignore:
Timestamp:
Mar 3, 2008, 7:57:47 AM (12 years ago)
Author:
gb
Message:

INSTALL-STANDARD-FOREIGN-TYPES: size of long may not be :BITS-PER-WORD
if :BITS-PER-LONG attribute is defined (win64).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/win64/lib/foreign-types.lisp

    r8541 r8641  
    17171717(defun install-standard-foreign-types (ftd)
    17181718  (let* ((*target-ftd* ftd)
    1719          (natural-word-size (getf (ftd-attributes ftd) :bits-per-word)))
     1719         (natural-word-size (getf (ftd-attributes ftd) :bits-per-word))
     1720         (long-word-size (or (getf (ftd-attributes ftd) :bits-per-long)
     1721                             natural-word-size)))
    17201722
    17211723    (def-foreign-type-translator signed (&optional (bits 32))
     
    18361838    (def-foreign-type address (* :void))
    18371839    (let* ((signed-long-type (parse-foreign-type
    1838                               `(:signed ,natural-word-size)))
     1840                              `(:signed ,long-word-size)))
    18391841           (unsigned-long-type (parse-foreign-type
    1840                                 `(:unsigned ,natural-word-size))))
     1842                                `(:unsigned ,long-word-size))))
    18411843      (%def-foreign-type :long signed-long-type ftd)
    18421844      (%def-foreign-type :signed-long signed-long-type ftd)
Note: See TracChangeset for help on using the changeset viewer.