(vector-set! (block-content block) offset value) #t))) ;; Return the item at slot OFFSET. (define-inlinable (block-ref content offset) (vector-ref content offset)) ;; Return the offset of the next item in the hash bucket, after the one ;; at OFFSET. (define-inlinable (block-hash-table-next-offset content size offset) (vector-ref content (+ size size offset))) ;; Save the offset of the next item in the hash bucket, after the one ;; at OFFSET. (define-inlinable (block-hash-table-set-next-offset! content size offset next-offset) (vector-set! content (+ size size offset) next-offset)) ;; Returns the index of the last entry stored in CONTENT with ;; SIZE-modulo hash value KHASH. (define-inlinable (block-hash-table-ref content size khash) (vector-ref content (+ size khash))) (define-inlinable (block-hash-table-set! content size khash offset) (vector-set! content (+ size khash) offset)) ;; Add hash table information for the item recently added at OFFSET, ;; with SIZE-modulo hash KHASH. (define-inlinable (block-hash-table-add! content size khash offset) (block-hash-table-set-next-offset! content size offset (block-hash-table-ref content size khash)) (block-hash-table-set! content size khash offset)) (define block-null ;; The null block. (make-block #f 0 0 #f))