[Top][All Lists]

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

Re: define anywhere

From: Dr. Arne Babenhauserheide
Subject: Re: define anywhere
Date: Sat, 05 Jun 2021 10:50:29 +0200
User-agent: mu4e 1.4.15; emacs 28.0.50

Taylan Kammer <> writes:

> On 05.06.2021 00:27, Damien Mattei wrote:
>> hello,
>> i'm was considering that i want to be able to define a variable anywhere in
>> code, the way Python do. Few scheme can do that (Bigloo i know)
>> ( the list here is not exact:
>> )
>>  is it possible in guile to do it? i do not know, so could it be added to
>> the language specification for future release?
>> regards,
>> Damien
> It's possible since 3.0, see here:

It is currently possible almost anywhere:


(define (a) (when #f #t) (define a 'b) a)

Does not work:

(define (a) (when #t (define a 'b) a))

Best wishes,
Unpolitisch sein
heißt politisch sein
ohne es zu merken

Attachment: signature.asc
Description: PGP signature

reply via email to

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