+/**
+ * bytestring_byte - get a byte from a bytestring
+ * @s: bytestring
+ * @n: index
+ *
+ * Return the @n-th byte from @s. Aborts (via assert) if @n is out of
+ * range for the length of @s.
+ */
+static inline char bytestring_byte(struct bytestring s, size_t n)
+{
+ assert(n < s.len);
+ return s.ptr[n];
+}
+