[ET Trac] [Einstein Toolkit] #484: CCTK_CHECK_C_INLINE can define away the inline keyword
Einstein Toolkit
trac-noreply at einsteintoolkit.org
Wed Aug 3 17:30:28 CDT 2011
#484: CCTK_CHECK_C_INLINE can define away the inline keyword
---------------------+------------------------------------------------------
Reporter: rhaas | Owner:
Type: defect | Status: new
Priority: minor | Milestone:
Component: Cactus | Version:
Resolution: | Keywords:
---------------------+------------------------------------------------------
Comment (by eschnett):
GCC and many other compilers supported the inline keyword for a long time.
Unfortunately, ANSI C now standardised this in an incompatible manner,
generating essentially two incompatible dialects of C. In Cactus, we need
to decide which of these dialects we want to support. Historically, we of
course supported the inofficial one (since it was the only one that
existed).
I tried the C99 dialect some time ago (maybe one year ago?), and things
failed. I tested more thorns that just the standard ET thorns; in
particular, I included many external libraries as well.
Many compilers have options to switch behaviour; in other cases, we can
use autoconf. For example, gcc 4.6 (I believe) supports both dialects,
depending on the -std setting. IBM's xlc treats the keywords __inline and
__inline__ differently... PGI may have something similar.
Yes, this line 180 is wrong -- it should test HAVE_CCTK_C_INLINE instead.
--
Ticket URL: <https://trac.einsteintoolkit.org/ticket/484#comment:1>
Einstein Toolkit <http://einsteintoolkit.org>
The Einstein Toolkit
More information about the Trac
mailing list