I don't know how relavent this question is to this forum. But I thougt you guys might have ideas on what I have to ask. I am trying to develop a tool that will translate all the source code files (C source files) to it's equivalant HTML file(s) in a source tree. In these HTML files, each function call will have a link to it's funtion definition and any variable types will have linkes to it's type defition.
To do this I have to identify each function definition and variable definition. For this , I have tokenized (I've already written the tokenizer) the source file and try to identify function definition patterns. I am trying to use a state machine. But it seems that this process is difficult. Is there a better way to identify function definitions ?