Brendon Costa wrote: > Hi all, > > I understand that all template functions in GCC should have vague > linkage and thus may be exported into numerous translation units where > they are used. I have been attempting to use a few different macros on > both an instanciated template functions FUNCTION_DECL node and a normal > functions FUNCTION_DECL node to see what the results are. I have tried: > > DECL_WEAK(fndecl) > DECL_ONE_ONLY(fndecl) > DECL_COMDAT(fndecl) > DECL_DEFER_OUTPUT(fndecl) > DECL_REPO_AVAILABLE_P(fndecl) > IDENTIFIER_REPO_CHOSEN(DECL_ASSEMBLER_NAME(fndecl)) > > and ALL of these macros are returning false for both the FUNCTION_DECL > nodes. Is there any macro i can use to determine if a FUNCTION_DECL node > has vague linkage? Or do i need to just assume that it is the sace for a > template function?
I forgot to mention that i also looked at the DECL_LINKONCE_P() macro as mentioned in the GCC internals documentation. However it has not yet been implemented. This macro could help me i think. I dont know enough about GCC to write this macro myself. Is there anyone willing to implement this? I am willing to help in some way, I just dont know where to start. Thanks, Brendon.