[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Beginner question: where is defstruct?
From: |
Josef Wolf |
Subject: |
Re: Beginner question: where is defstruct? |
Date: |
Thu, 11 Oct 2007 11:36:38 +0200 |
User-agent: |
Mutt/1.5.9i |
On Wed, Oct 10, 2007 at 06:21:25PM +0200, Ludovic Courtès wrote:
> Josef Wolf <address@hidden> writes:
> > In guile's info page, all I can find is chapter 22.5, but this seems
> > to describe something much more general than what defstruct would do.
> `defstruct' as described in this document is something specific to some
> Scheme implementation. The chapter you saw in Guile's manual is another
> non-portable way to define structures, in Guile this time.
>
> The most portable way to define structures is to use SRFI-9:
>
> http://srfi.schemers.org/srfi-9/srfi-9.html
>
> It is available in Guile using "(use-modules (srfi srfi-9))" or
> "(require-extension (srfi 9))" (the latter being the portable way to get
> the portable "structures" :-)).
Thanks for the explanation, Ludovic! I'll go and try to read/understand
srfi-9.
BTW: Why do people teach newbies non-portable things in their tutorials?