guile-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: bytevector seems to be missing in Guile


From: Wolf
Subject: Re: bytevector seems to be missing in Guile
Date: Sat, 7 Jan 2023 22:12:01 +0100

On 2023-01-07 12:07:31 -0800, Matt Wette wrote:
> On 1/7/23 8:34 AM, Sascha Ziemann wrote:
> > Is the procedure "bytevector" missing in Guile?
> > 
> > I tried this:
> > guile --r7rs -c '(write (bytevector 1 2 3))'
> > 
> > R7RS defines it on page 49.
> > 
> 
> maybe you need (import (rnrs bytevectors))

I'm far from expert, but it looks to me like (bytevector) in particular is not
provided by guile.

I think the way in guile is

    #vu8(1 2 3)

Or you could make it from list of integers:

    (use-modules (rnrs bytevectors))
    (u8-list->bytevector '(1 2 3))

W.

-- 
There are only two hard things in Computer Science:
cache invalidation, naming things and off-by-one errors.

Attachment: signature.asc
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]