[Top][All Lists]

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

Re: [Chicken-users] [Q] Can I make port on byte array?

From: Christian Kellermann
Subject: Re: [Chicken-users] [Q] Can I make port on byte array?
Date: Wed, 07 Oct 2015 11:14:59 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

Hey Sungjin Chun!

Sungjin Chun <address@hidden> writes:
> In Common Lisp, I can make a stream on byte array and can write
> values on them, in Scheme, I think the equivalent stuff is port and
> I'd like to write values on byte array using port.
> Can anyone help me on finding documents or samples?

The things you may want are srfi-4 vectors:

Usually one sets values with set! and vector-ref! or any of the setters:

Maybe you can write up the desired behaviour in CL and we translate it
to scheme?

If you want to read from a port and put the stuff you read from it into
a vector you might want to use read-u8vector or read-u8vector!.

Kind regards,


May you be peaceful, may you live in safety, may you be free from
suffering, and may you live with ease.

reply via email to

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