This is the mail archive of the
mailing list for the GCC project.
Re: GCC 5? (was Re: GCC 4.7.0RC: Mangled names in cc1)
Richard Guenther <email@example.com> skribis:
> 2012/3/19 Ludovic CourtÃs <firstname.lastname@example.org>:
>> In the example of name mangling, Iâd just have wrapped in âextern "C"â
>> all the headers listed in âPLUGIN_HEADERSâ in gcc/Makefile.in. ÂThe
>> rationale is that it simplifies plug-in maintenance, while not impeding
>> development work in 4.7.
> Well, that's _all_ headers. Basically.
Well, these headers get installed, and they get installed to be actually
used, donât they? :-)
> And exactly the problem. There will be never even API compatibility
> between major releases of GCC with the current plugin "API".
My experience is more encouraging: between 4.5 and 4.6, I was only hit
by a couple of tree.h declarations found in one and not the other.
When switching to 4.7, the main problem was mangled names, and all the
problems that making my code compilable with g++ entails. Other issues
were the removal of the âbuilt_in_declsâ array, and the new
âaffects_type_identityâ field of âattribute_specâ.
All this is summarized in the Autoconf macro I use :
dnl build_call_expr_loc_array -- not in GCC 4.5.x; appears in 4.6
dnl build_call_expr_loc_vec -- likewise
dnl build_array_ref -- present but undeclared in 4.6.1
dnl build_zero_cst -- not in GCC 4.5.x; appears in 4.6
dnl builtin_decl_explicit -- new in 4.7, replaces `built_in_decls'
dnl .affects_type_identity -- new field in 4.7
Then again, my plug-in is relatively small, and uses a small part of GCC.
Plug-ins with a larger API footprint may have more problems, of course.