Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Doctree – First-class library docs tool (github.com/sourcegraph)
1 point by tsujp on April 20, 2022 | hide | past | favorite | 1 comment


does it work already?

I kinda had a similar idea also using tree-sitter. what I found was that

tree-sitter's parse tree output is very verbose, containing lots of stuff that is useless for doc generation.

I wasn't able to find a good way to prune and clean up the parse trees into AST at scale (to support multiple languages).

Another difficulty I found was handling c preprocessor. It will make cpp/c language look very different. Tree-sitter can't deal with it properly.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: