Hi again,
This may seem like a strange question, but I'm confused about the use of
set!.It may be a holdover from my pre-scheme days, but it seems I
should be declaring a variable before using it with set!. In other
words, I would use:
(let
((x 0))
before setting x
William Ramsay scripsit:
This may seem like a strange question, but I'm confused about the use
of set!. It may be a holdover from my pre-scheme days, but it seems
I should be declaring a variable before using it with set!.
A Scheme implementation is allowed to either let you set! variables
On Thu, Feb 26, 2009 at 3:12 PM, William Ramsay ramsa...@comcast.net wrote:
This may seem like a strange question, but I'm confused about the use of
set!. It may be a holdover from my pre-scheme days, but it seems I should
be declaring a variable before using it with set!
William,
Check
2009-02-26 William Ramsay ramsa...@comcast.net:
[...]
But it appears that set! itself declares the variable and the let is not
needed.
[...]
And if set! does declare a variable what is it's scope?
[...]
Hello,
if I'm not mistaken, using set! on a variable that hasn't been
declared is
On Thu, Feb 26, 2009 at 3:46 PM, Jim Ursetto zbignie...@gmail.com wrote:
You might prefer, for style or portability, to have a dummy definition
at toplevel, such as (define foo #f) or just (define foo), prior to
performing the set!.
Whoops. To be clear, (define foo) is a Chicken extension.