This is the xsubseq Reference Manual, version 0.1, generated automatically by Declt version 4.0 beta 2 "William Riker" on Sun Sep 15 07:09:33 2024 GMT+0.
The main system appears first, followed by any subsystem dependency.
xsubseq
Efficient way to manage "subseq"s in Common Lisp
Eitaro Fukamachi
BSD 2-Clause
# XSubseq
XSubseq provides functions to be able to handle "subseq"s more effieiently. As Common Lisp’s ‘subseq‘ copies the data every time, "subseq" and "concatenate" code is very inefficient like the following code.
“‘common-lisp
(let ((result (make-array 0 :element-type ’(unsigned-byte 8))))
(lambda (data start end)
(setf result (concatenate ’(simple-array (unsigned-byte 8) (*))
result
(subseq data start end)))
result))
“‘
XSubseq delays the copying until it is actually needed.
## Usage
“‘common-lisp
(defvar *data1* #(1 2 3))
(defvar *data2* #(4 5 6))
(xsubseq *data1* 0 1)
;=> #S(XSUBSEQ:XSUBSEQ :DATA #(1 2 3) :START 0 :END 1 :LEN 1)
(xnconc (xsubseq *data1* 0 1)
(xsubseq *data2* 2))
;=> #S(XSUBSEQ:CONCATENATED-XSUBSEQS
; :LEN 2
; :LAST (#S(XSUBSEQ:XSUBSEQ :DATA #(4 5 6) :START 2 :END 3 :LEN 1))
; :CHILDREN (#S(XSUBSEQ:XSUBSEQ :DATA #(1 2 3) :START 0 :END 1 :LEN 1)
; #S(XSUBSEQ:XSUBSEQ :DATA #(4 5 6) :START 2 :END 3 :LEN 1)))
(coerce-to-sequence
(xnconc (xsubseq *data1* 0 1)
(xsubseq *data2* 2)))
;=> #(1 6)
(with-xsubseqs (result)
(xnconcf result (xsubseq *data1* 0 1))
(xnconcf result (xsubseq *data2* 2)))
;=> #(1 6)
“‘
## Installation
“‘common-lisp
(ql:quickload :xsubseq)
“‘
## Author
* Eitaro Fukamachi (e.arrows@gmail.com)
## Copyright
Copyright (c) 2014 Eitaro Fukamachi (e.arrows@gmail.com)
## License
Licensed under the BSD 2-Clause License.
0.1
sb-cltl2
(system).
src
(module).
Modules are listed depth-first from the system components tree.
Files are sorted by type and then listed depth-first from the systems components trees.
xsubseq/src/xsubseq.lisp
src
(module).
coerce-to-sequence
(compiler macro).
coerce-to-sequence
(function).
coerce-to-string
(compiler macro).
coerce-to-string
(function).
concatenated-xsubseqs
(structure).
make-concatenated-xsubseqs
(function).
null-concatenated-xsubseqs
(structure).
octets-concatenated-xsubseqs
(structure).
octets-xsubseq
(structure).
string-concatenated-xsubseqs
(structure).
string-xsubseq
(structure).
with-xsubseqs
(macro).
xlength
(function).
xnconc
(function).
xnconcf
(macro).
xsubseq
(compiler macro).
xsubseq
(function).
xsubseq
(structure).
%make-concatenated-xsubseqs
(function).
%xnconc2
(function).
concatenated-xsubseqs-children
(reader).
(setf concatenated-xsubseqs-children)
(writer).
concatenated-xsubseqs-last
(reader).
(setf concatenated-xsubseqs-last)
(writer).
concatenated-xsubseqs-len
(reader).
(setf concatenated-xsubseqs-len)
(writer).
concatenated-xsubseqs-p
(function).
concatenated-xsubseqs-to-sequence
(function).
copy-concatenated-xsubseqs
(function).
copy-null-concatenated-xsubseqs
(function).
copy-octets-concatenated-xsubseqs
(function).
copy-octets-xsubseq
(function).
copy-string-concatenated-xsubseqs
(function).
copy-string-xsubseq
(function).
copy-xsubseq
(function).
make-null-concatenated-xsubseqs
(function).
make-octets-concatenated-xsubseqs
(function).
make-octets-xsubseq
(function).
make-string-concatenated-xsubseqs
(function).
make-string-xsubseq
(function).
make-xsubseq
(function).
null-concatenated-xsubseqs-children
(function).
(setf null-concatenated-xsubseqs-children)
(function).
null-concatenated-xsubseqs-last
(function).
(setf null-concatenated-xsubseqs-last)
(function).
null-concatenated-xsubseqs-len
(function).
(setf null-concatenated-xsubseqs-len)
(function).
null-concatenated-xsubseqs-p
(function).
octets
(type).
octets-concatenated-xsubseqs-children
(function).
(setf octets-concatenated-xsubseqs-children)
(function).
octets-concatenated-xsubseqs-last
(function).
(setf octets-concatenated-xsubseqs-last)
(function).
octets-concatenated-xsubseqs-len
(function).
(setf octets-concatenated-xsubseqs-len)
(function).
octets-concatenated-xsubseqs-p
(function).
octets-concatenated-xsubseqs-to-sequence
(function).
octets-concatenated-xsubseqs-to-string
(function).
octets-xsubseq-data
(function).
(setf octets-xsubseq-data)
(function).
octets-xsubseq-end
(function).
(setf octets-xsubseq-end)
(function).
octets-xsubseq-len
(function).
(setf octets-xsubseq-len)
(function).
octets-xsubseq-p
(function).
octets-xsubseq-start
(function).
(setf octets-xsubseq-start)
(function).
octets-xsubseq-to-string
(function).
string-concatenated-xsubseqs-children
(function).
(setf string-concatenated-xsubseqs-children)
(function).
string-concatenated-xsubseqs-last
(function).
(setf string-concatenated-xsubseqs-last)
(function).
string-concatenated-xsubseqs-len
(function).
(setf string-concatenated-xsubseqs-len)
(function).
string-concatenated-xsubseqs-p
(function).
string-concatenated-xsubseqs-to-sequence
(function).
string-xsubseq-data
(function).
(setf string-xsubseq-data)
(function).
string-xsubseq-end
(function).
(setf string-xsubseq-end)
(function).
string-xsubseq-len
(function).
(setf string-xsubseq-len)
(function).
string-xsubseq-p
(function).
string-xsubseq-start
(function).
(setf string-xsubseq-start)
(function).
xsubseq-data
(reader).
(setf xsubseq-data)
(writer).
xsubseq-end
(reader).
(setf xsubseq-end)
(writer).
xsubseq-len
(reader).
(setf xsubseq-len)
(writer).
xsubseq-p
(function).
xsubseq-start
(reader).
(setf xsubseq-start)
(writer).
xsubseq-to-sequence
(function).
Packages are listed by definition order.
xsubseq
common-lisp
.
coerce-to-sequence
(compiler macro).
coerce-to-sequence
(function).
coerce-to-string
(compiler macro).
coerce-to-string
(function).
concatenated-xsubseqs
(structure).
make-concatenated-xsubseqs
(function).
null-concatenated-xsubseqs
(structure).
octets-concatenated-xsubseqs
(structure).
octets-xsubseq
(structure).
string-concatenated-xsubseqs
(structure).
string-xsubseq
(structure).
with-xsubseqs
(macro).
xlength
(function).
xnconc
(function).
xnconcf
(macro).
xsubseq
(compiler macro).
xsubseq
(function).
xsubseq
(structure).
%make-concatenated-xsubseqs
(function).
%xnconc2
(function).
concatenated-xsubseqs-children
(reader).
(setf concatenated-xsubseqs-children)
(writer).
concatenated-xsubseqs-last
(reader).
(setf concatenated-xsubseqs-last)
(writer).
concatenated-xsubseqs-len
(reader).
(setf concatenated-xsubseqs-len)
(writer).
concatenated-xsubseqs-p
(function).
concatenated-xsubseqs-to-sequence
(function).
copy-concatenated-xsubseqs
(function).
copy-null-concatenated-xsubseqs
(function).
copy-octets-concatenated-xsubseqs
(function).
copy-octets-xsubseq
(function).
copy-string-concatenated-xsubseqs
(function).
copy-string-xsubseq
(function).
copy-xsubseq
(function).
make-null-concatenated-xsubseqs
(function).
make-octets-concatenated-xsubseqs
(function).
make-octets-xsubseq
(function).
make-string-concatenated-xsubseqs
(function).
make-string-xsubseq
(function).
make-xsubseq
(function).
null-concatenated-xsubseqs-children
(function).
(setf null-concatenated-xsubseqs-children)
(function).
null-concatenated-xsubseqs-last
(function).
(setf null-concatenated-xsubseqs-last)
(function).
null-concatenated-xsubseqs-len
(function).
(setf null-concatenated-xsubseqs-len)
(function).
null-concatenated-xsubseqs-p
(function).
octets
(type).
octets-concatenated-xsubseqs-children
(function).
(setf octets-concatenated-xsubseqs-children)
(function).
octets-concatenated-xsubseqs-last
(function).
(setf octets-concatenated-xsubseqs-last)
(function).
octets-concatenated-xsubseqs-len
(function).
(setf octets-concatenated-xsubseqs-len)
(function).
octets-concatenated-xsubseqs-p
(function).
octets-concatenated-xsubseqs-to-sequence
(function).
octets-concatenated-xsubseqs-to-string
(function).
octets-xsubseq-data
(function).
(setf octets-xsubseq-data)
(function).
octets-xsubseq-end
(function).
(setf octets-xsubseq-end)
(function).
octets-xsubseq-len
(function).
(setf octets-xsubseq-len)
(function).
octets-xsubseq-p
(function).
octets-xsubseq-start
(function).
(setf octets-xsubseq-start)
(function).
octets-xsubseq-to-string
(function).
string-concatenated-xsubseqs-children
(function).
(setf string-concatenated-xsubseqs-children)
(function).
string-concatenated-xsubseqs-last
(function).
(setf string-concatenated-xsubseqs-last)
(function).
string-concatenated-xsubseqs-len
(function).
(setf string-concatenated-xsubseqs-len)
(function).
string-concatenated-xsubseqs-p
(function).
string-concatenated-xsubseqs-to-sequence
(function).
string-xsubseq-data
(function).
(setf string-xsubseq-data)
(function).
string-xsubseq-end
(function).
(setf string-xsubseq-end)
(function).
string-xsubseq-len
(function).
(setf string-xsubseq-len)
(function).
string-xsubseq-p
(function).
string-xsubseq-start
(function).
(setf string-xsubseq-start)
(function).
xsubseq-data
(reader).
(setf xsubseq-data)
(writer).
xsubseq-end
(reader).
(setf xsubseq-end)
(writer).
xsubseq-len
(reader).
(setf xsubseq-len)
(writer).
xsubseq-p
(function).
xsubseq-start
(reader).
(setf xsubseq-start)
(writer).
xsubseq-to-sequence
(function).
Definitions are sorted by export status, category, package, and then by lexicographic order.
last
.
len
.
data
.
end
.
len
.
Jump to: | %
(
C F M N O S W X |
---|
Jump to: | %
(
C F M N O S W X |
---|
Jump to: | C D E L S |
---|
Jump to: | C D E L S |
---|
Jump to: | C F M N O P S T X |
---|
Jump to: | C F M N O P S T X |
---|