This is the mail archive of the
guile@sourceware.cygnus.com
mailing list for the Guile project.
Re: deeper constification
- To: dirk at ida dot ing dot tu-bs dot de
- Subject: Re: deeper constification
- From: Clark McGrew <mcgrew at ale dot physics dot sunysb dot edu>
- Date: Thu, 30 Mar 2000 09:36:00 -0500
- CC: mlivshin at bigfoot dot com, guile at sourceware dot cygnus dot com
- References: <Pine.LNX.4.21.0003301135130.20677-100000@marvin.ida.ing.tu-bs.de>
- Reply-to: clark dot mcgrew at sunysb dot edu
>>>>> "Dirk" == Dirk Herrmann <dirk@ida.ing.tu-bs.de> writes:
Dirk> On 29 Mar 2000, Michael Livshin wrote:
>> should it be:
>>
>> SCM_VECTOR_REF/SCM_VECTOR_SET
>>
>> or
>>
>> SCM_VELT/SCM_SET_VELT
>>
Dirk> If SCM_VECTOR_REF/SET will actually perform the equivalent
Dirk> to vector-ref and vector-set!, then I'm in favor of these.
Dirk> Otherwise, the names should be different in order to avoid
Dirk> confusion.
Dirk> Although these names do not match the suggested style to put
Dirk> the SET at the front of the identifier it may be better to
Dirk> keep them aligned to the scheme level names.
Isn't it better for all macros to be consistent? If want do to a
"vector-set!" from C the naming convention suggests vector_set_x, but
I should probably use the macro. The naming convention for macros
would suggest SCM_VECTOR_ELEMENT and SCM_SET_VECTOR_ELEMENT which is a
bit verbose. I think SCM_VECTOR_REF and SCM_VECTOR_SET break the
convention twice.
Cheers,
Clark