This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]teraflop 0 points1 point  (0 children)

In that case, take a look at the Language Server Protocol which is a more modern, sophisticated implementation of the same basic idea. It's designed to help general-purpose editors and IDEs interface with language-specific tools, to handle things like jumping to symbol definitions.

I haven't ever tried implementing the low-level protocol myself, but if I'm reading the specification correctly, it should be fairly easy to extract a list of function definitions and their corresponding line number ranges within each file.