This is the mail archive of the
guile@sourceware.cygnus.com
mailing list for the Guile project.
Non-R5RS behaviour of guile functions.
- To: Guile Mailing List <guile at sourceware dot cygnus dot com>
- Subject: Non-R5RS behaviour of guile functions.
- From: Dirk Herrmann <dirk at ida dot ing dot tu-bs dot de>
- Date: Wed, 26 Jan 2000 13:15:19 +0100 (MET)
Hi!
The following functions show a behaviour that is not defined according to
R5RS:
* arguments for string may only be characters. Guile also allows strings
and symbols.
* the argument for string-length, string-ref, substring and string-append
has to be a string, but guile also allows symbols.
I assume that this is considered as a bug?
Further, I realized that besides SCM_DEFER_INTS and SCM_ALLOW_INTS there
are macros SCM_REDEFER_INTS and SCM_REALLOW_INTS. This surprised me,
since I assumed that SCM_DEFER_INTS and SCM_ALLOW_INT could safely be
nested. A look into __scm.h showed that this is not the case and that you
would have to use the ...RE... version in order to guarantee safe nesting.
Can anybody explain the reason of this to me? Shouldn't users that use
guile to extend C applications be informed to only use the
...RE... versions, or wouldn't it even be better to make SCM_DEFER_INTS
and SCM_ALLOW_INTS use the safer version?
Best regards,
Dirk Herrmann