#573 closed defect (fixed)
types.db: "allocate" can return false, not just pointers
| Reported by: | sjamaan | Owned by: | felix winkelmann | 
|---|---|---|---|
| Priority: | not urgent at all | Milestone: | 4.9.0 | 
| Component: | compiler | Version: | 4.6.x | 
| Keywords: | Cc: | ||
| Estimated difficulty: | 
Description
(allocate -1) => #f
But when I do (let ((x (allocate y))) (unless x (error "allocation problem"))) I get a compiler warning:
Warning: in toplevel procedure `freetds#make-CS_BINARY*': expected value of type boolean in conditional but were given a value of type `pointer' which is always true:
I think types.db needs a small tweak to accommodate null pointers.
Probably something like this:
(allocate (procedure allocate (fixnum) (or pointer boolean)))
Note: See
        TracTickets for help on using
        tickets.
    

Correct. Thanks.