chicken-hackers
[Top][All Lists]
Advanced

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

[Chicken-hackers] Including chicken.h fails for C++11


From: Izaak
Subject: [Chicken-hackers] Including chicken.h fails for C++11
Date: Wed, 14 Jan 2015 16:17:00 +0300

Hi,

I realize that Chicken is a C library, but when using it in C++11, I get a 
compilation error because of mismatched math function declarations, for example:
   /usr/local/include/chicken/chicken.h:1036:27: error: declaration of ‘double 
trunc(double)’ has a different exception specifier
 extern double trunc(double);

That was from gcc 4.9.1. I have attached full error output.

Adding throw() to the definitions in chicken.h fixed it, although that will 
obviously break if I use it as a C library. So, you might want to add some 
extra guards in the header file for C++11 compilation in the next release.

-- 
Izaak

Attachment: chicken.h-error.txt
Description: Text document


reply via email to

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