cffi gets stuck in a loop when returning a struct containing a slot with a typedef of a bitfield
Bug #1474631 reported by
3b
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
CFFI |
New
|
Undecided
|
Unassigned |
Bug Description
(cffi:defbitfield foo-)
(cffi:defctype foo foo-)
(cffi:defcstruct sfoo
(foo foo))
(cffi:defcfun foo (:struct sfoo))
(foo)
;; doesn't return, expected error about undefined function
apparently caused by LIBFFI-TYPE-POINTER calling FOLLOW-TYPEDEF on an ENHANCED-TYPEDEF expecting to get back the referenced type, but instead getting back the original type because FOLLOR-TYPEDEF checks for (eq (type-of type) 'foreign-typedef) rather than TYPEP
v0.15, sbcl linux/windows
To post a comment you must log in.
actually, doesn't work on bitfields without the typedef as well, since they are also subclasses of FOREIGN-TYPEDEF.