guile-user
[Top][All Lists]
Advanced

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

Re: Guile, C++, and Mac OS X 10.4 (powerpc)


From: Ludovic Courtès
Subject: Re: Guile, C++, and Mac OS X 10.4 (powerpc)
Date: Wed, 18 Aug 2010 15:49:27 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux)

Hi,

Hans Aberg <address@hidden> writes:

> On 28 Jul 2010, at 21:49, Mike Solomon wrote:
>
>> Hey guile users,
>>    Trying to compile the simple example bessel.c from
>> Writing-Guile-Extensions.html (renamed bessel.cc because I'm using
>> g+
>> +), I
>> encountered the following error:
>>
>> bessel.cc: In function 'void init_bessel()':
>> bessel.cc:13: error: invalid conversion from 'scm_unused_struct*
>> (*)(scm_unused_struct*)' to 'scm_unused_struct* (*)(...)'
>> bessel.cc:13: error:   initializing argument 5 of 'scm_unused_struct*
>> scm_c_define_gsubr(const char*, int, int, int, scm_unused_struct*
>> (*)
>> (...))'
>
> The SCM type is a pointer to an undefined C type - C hack, which
> clashes with C++. Clever in C, but bad for C++ users.

I don’t think that this is the cause of the problem.

The problem instead stems from use of function declarators with empty
parenthesis, which is also an obsolescent C feature, as discussed here:

  http://savannah.gnu.org/bugs/?23681

I fixed a few of these in Guile 1.9, but not all of them, and not
‘scm_c_define_gsubr’ in particular.

I would appreciate patches in this area.  :-)

Thanks,
Ludo’.




reply via email to

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