Using C++ within a backend?

Gabriel Dos Reis gdr@integrable-solutions.net
Tue Apr 15 13:24:00 GMT 2003


Alexandre Courbot <Alexandre.Courbot@lifl.fr> writes:

[...]

| Problem is, g++ (3.2.3 here) doesn't seem to like gcc's include files. 
| Whenever I include rtl.h for instance, I get:
| 
| ../../gcc-3.2.2-camille/gcc/rtl.h:109: declaration of 
| `rtx_def*rtunion_def::rtx
|    '
| config.h:8: changes meaning of `rtx' from `typedef struct rtx_def*rtx'
| ../../gcc-3.2.2-camille/gcc/rtl.h:110: declaration of `
|    rtvec_def*rtunion_def::rtvec'
| config.h:10: changes meaning of `rtvec' from `typedef struct rtvec_def*rtvec'
| 
| Effectively, line 109 of rtl.h is
|   rtx rtx;
| 
| Which I understand cause problems to g++.

It would be probably better if we could avoid such constructs in GCC
sources.  However, such a chaneg won't be practical for 3.2.3, 3.3.0.
Maybe a project for 3.4 or 3.5.

-- Gaby



More information about the Gcc mailing list