1 ;;;; bit-vector hacking utilities, potentially implementation-dependent
4 ;;;; This software is part of the SBCL system. See the README file for
7 ;;;; This software is derived from the CMU CL system, which was
8 ;;;; written at Carnegie Mellon University and released into the
9 ;;;; public domain. The software is in the public domain and is
10 ;;;; provided with absolutely no warranty. See the COPYING and CREDITS
11 ;;;; files for more information.
16 (declaim (inline clear-bit-vector set-bit-vector bit-vector-replace
19 ;;; Clear a SIMPLE-BIT-VECTOR to zeros.
20 (defun clear-bit-vector (vec)
21 (declare (type simple-bit-vector vec))
24 ;;; Fill a bit vector with ones.
25 (defun set-bit-vector (vec)
26 (declare (type simple-bit-vector vec))
29 ;;; Replace the bits in To with the bits in From.
30 (defun bit-vector-replace (to from)
31 (declare (type simple-bit-vector to from))
34 ;;; Copy a bit-vector.
35 (defun bit-vector-copy (vec)
36 (declare (type simple-bit-vector vec))