LANG HOOKS

Paul Brook paul@nowt.org
Wed Dec 3 00:50:00 GMT 2003


On Tuesday 02 December 2003 7:28 pm, gnu c wrote:
> Hi there,
> I am trying to make new frontend to GNU CC 3.3.2 (just simple frontend
> for demo purposes). I have some problems with LANG_HOOKS. As I have read
> in sources of other frontend, I need to define several LANG_HOOKS and
> then:
>
> const struct lang_hooks lang_hooks = LANG_HOOKS_INITIALIZER;
>
> is needed. Doing so I get uggly error message from compiler:

Looks like you still need to define some of the lang hooks, or you've 
defined some hooks with incorrect prototypes. The defaults do not provide 
all the required hooks. The existing frontents are probably the best place 
to look to figure out what you need.

N.B. You'll probably find it much easier targeting a new frontend at the 
tree-ssa branch than 3.3. Speaking from experience the interface to 
frontends is much cleaner there.

Paul



More information about the Gcc mailing list