[plt-scheme] Side effect requiring rnrs/base-6?

From: Jens Axel Søgaard (jensaxel at soegaard.net)
Date: Wed Sep 16 13:59:30 EDT 2009

2009/9/16 Jens Axel Søgaard <jensaxel at soegaard.net>:
> [sent privately too by accident]
>
> 2009/9/16 Ganesh Gunasegaran <ganesh.gunas at gmail.com>:
>> Hi All,
>>
>> I am very new to Scheme
>>
>> What is wrong with the following code?
>>
>> --------------------------------------------------------------------------------------------------------------------------------
>> #lang scheme
>> (require rnrs/base-6)

One more thing:

Since the entire rnrs/base-6 is required some functions from "scheme"
such as car, cdr, cons are shadowed by their bindings in rnrs/base-6.
In particular in rnrs the identifier car is bound to the same value
as the identifier mcar is bound to in "scheme'. That is, after the
require line, when you write "car" you are actually calling "mcar".

This might we somewhat confusing, for new Scheme users, so
here is a practical advise:

Stick either to the "scheme" language, and if you need a particular
function from rnrs use the documentation to figure out, what
is called in PLT Scheme (in 99% of the cases the names
are the same).

-- 
Jens Axel Søgaard


Posted on the users mailing list.