Changeset 39722 in project


Ignore:
Timestamp:
03/16/21 17:47:02 (5 weeks ago)
Author:
Kon Lovett
Message:

fix queue predicate arg, fix generic proc define

File:
1 edited

Legend:

Unmodified
Added
Removed
  • release/5/mailbox/trunk/inline-queue.scm

    r39721 r39722  
    2121
    2222(define-inline (%queue-unlimited-limit q) most-positive-fixnum)
     23
     24(define-inline (%queue-unlimited-room q) (%queue-unlimited-limit q))
    2325
    2426(define-inline (%queue-unlimited-limit-set! q v)
     
    9799  (%->boolean (%queue-unlimited-cursor-prev-pair c)) )
    98100
    99 (define (%queue-unlimited-cursor-unwound? q c)
     101(define-inline (%queue-unlimited-cursor-unwound? q c)
    100102  (null? (%queue-unlimited-cursor-next-pair c)) )
    101103
     
    201203  (error '%queue-limited-cursor-winding? "unsupported" q c) )
    202204
    203 (define (%queue-limited-cursor-unwound? q c)
     205(define-inline (%queue-limited-cursor-unwound? q c)
    204206  (error '%queue-limited-cursor-unwound? "unsupported" q c) )
    205207
     
    267269  (error '%queue-unbuffered-cursor-winding? "unsupported" q c) )
    268270
    269 (define (%queue-unbuffered-cursor-unwound? q c)
     271(define-inline (%queue-unbuffered-cursor-unwound? q c)
    270272  (error '%queue-unbuffered-cursor-unwound? "unsupported" q c) )
    271273
     
    300302(define-inline (%queue? x)
    301303  (or
    302     (%queue-unlimited? q)
    303     (%queue-limited? q)
    304     (%queue-unbuffered? q) ) )
    305 
    306 (define (%queue-limit q)
     304    (%queue-unlimited? x)
     305    (%queue-limited? x)
     306    (%queue-unbuffered? x) ) )
     307
     308(define-inline (%queue-limit q)
    307309  (cond
    308310    ((%queue-unlimited? q)  (%queue-unlimited-limit q))
     
    310312    (else                   (%queue-unbuffered-limit q)) ) )
    311313
    312 (define (%queue-limit-set! q v)
     314(define-inline (%queue-limit-set! q v)
    313315  (cond
    314316    ((%queue-unlimited? q)  (%queue-unlimited-limit-set! q v))
     
    316318    (else                   (%queue-unbuffered-limit-set! q v)) ) )
    317319
    318 (define (%queue-count q)
     320(define-inline (%queue-count q)
    319321  (cond
    320322    ((%queue-unlimited? q)  (%queue-unlimited-count q))
     
    322324    (else                   (%queue-unbuffered-count q)) ) )
    323325
    324 (define (%queue-count-set! q v)
     326(define-inline (%queue-count-set! q v)
    325327  (cond
    326328    ((%queue-unlimited? q)  (%queue-unlimited-count-set! q v))
     
    427429    (else                   (%queue-unbuffered-cursor-winding? q c)) ) )
    428430
    429 (define (%queue-cursor-unwound? q c)
     431(define-inline (%queue-cursor-unwound? q c)
    430432  (cond
    431433    ((%queue-unlimited? q)  (%queue-unlimited-cursor-unwound? q c))
Note: See TracChangeset for help on using the changeset viewer.