Hi Ludovic, Le 11/01/2023 à 16:00, Ludovic Courtès a écrit : > +@node Bytevector Slices > +@subsubsection Bytevector Slices > + > +@cindex subset, of a bytevector > +@cindex slice, of a bytevector > +@cindex slice, of a uniform vector > +As an extension to the R6RS specification, the @code{(rnrs bytevectors > +gnu)} module provides the @code{bytevector-slice} procedure, which > +returns a bytevector aliasing part of an existing bytevector. > + > +@deffn {Scheme Procedure} bytevector-slice @var{bv} @var{offset} [@var{size}] > +@deffnx {C Function} scm_bytevector_slice (@var{bv}, @var{offset}, @var{size}) > +Return the slice of @var{bv} starting at @var{offset} and counting > +@var{size} bytes. When @var{size} is omitted, the slice covers all > +of @var{bv} starting from @var{offset}. The returned slice shares > +storage with @var{bv}: changes to the slice are visible in @var{bv} > +and vice-versa. What do you think about making it more similar to substrings? There the 'substring' procedure makes a copy-on-write substring, and you have substring/shared if you really want shared mutation. Would something like this be meaningful / feasible / useful for bytevectors? Best, Jean