Re: [pygccxml-development] code_repository package
Brought to you by:
mbaas,
roman_yakovenko
From: Matthias B. <ba...@ir...> - 2006-09-19 14:22:33
|
Roman Yakovenko wrote: >> How do I influence whether a file is considered a system header or not? > > In creator_t, you add your header file using add_system_header API I suppose the header should only be created when it is required, right? I want to use it for the class that can acquire/release the Python GIL (as you have suggested earlier). So the actual decision whether the header is required or not is done by the code creator (mem_fun_v_transformed_wrapper_t). What is your recommendation how the code in creator_t (this is visit_member_function(), right?) will know about this decision? Just to see if the file gets written or not I called add_system_header() and adopt_creator() on every call to visit_member_function(), but then I get a huge list of identical include statements in the generated files. What I would actually like to do is to add the "include" code creator to the associated_decl_creators list of the corresponding class so that the include only shows up in the file where it is needed. But how can I check whether the file was already included or not? I wonder why there is no specific API for managing include files that handles all those stuff? It appears to me that this would be quite a useful thing to have. - Matthias - |