summaryrefslogtreecommitdiff
path: root/src/common.lisp
diff options
context:
space:
mode:
Diffstat (limited to 'src/common.lisp')
-rw-r--r--src/common.lisp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/common.lisp b/src/common.lisp
new file mode 100644
index 0000000..3f078ff
--- /dev/null
+++ b/src/common.lisp
@@ -0,0 +1,10 @@
+(in-package :eris)
+
+(defun subseq-shared (array start)
+ (make-array (- (length array) start)
+ :element-type (array-element-type array)
+ :displaced-to array
+ :displaced-index-offset start))
+
+(defmacro make-octets (len &key (element 0))
+ `(make-array ,len :element-type '(unsigned-byte 8) :initial-element ,element))