-
Notifications
You must be signed in to change notification settings - Fork 9
rust html source code browser generator, rust source code navigator, possible component for IDE ? Example output - see rust compiler source & std libs:-
License
dobkeratops/rustfind
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Uses rust libsyntax to find symbol definitions and generates HTML view of source with links finds struct-defs, functions, methods, fields writes ast node def info into '.rfx' files in plaintext. Also spits out a graphviz dotfile with the static callgraph, modules as clusters. "make" to compile and run test program "make rustsrc" to generate HTML source for the main rust source tree at $(RUST_PATH)/src ./rustfind -h to display options ./rustfind cratename.rs sourcefile.rs:line:col ... compiles 'cratename.rs',then shows the location&definition referenced by sourcefile:line:col ./rustfind -j cratename.rs -- dump spans & node definition links as JSON ./rustfind -w cratename.rs -- creates HTML view of sourcecode roadmap [1] a commandline tool rustfind sourcefile.rs:LINE:COLUMN: --> definition.rs:LINE:col (to add add hoc navigation tools eg gedit external tools) [.1] CTAGS generation ?? [.1] interactive commandline tool (enter src/location/symbol-> dump location) [.2] possibly queries like "list all the functions that use this type, list all the impls' for this type.." [.3] links to Rustdoc ? [2] JSON / or other dump .. are there any formats IDE's read for their indexers? [3] options to dump/pretty print more context for the definitoon [4] an html hyperlinked source generator, like woboq? ... + popup type annotaions? [5] use components for IDE integration? example of callgraph output ![Screenshot](screenshot/callgraph2.png) Notes on sourcecode:- -------------------- -find_ast_node contains the node scanning -borrows code from rustdoc_ng -there might be a fair amoount of repition with the compiler internals eg ast node wrappers, this can be cleaned up.. -a lot here would factor out if ctxt had a node_id:span map Other:- ------- improved syntax highlighting rust.lang & required styles (for gtksourceview) included in scripts more ideas can ctags actually deal with overloaded symbols? could we write out an intermediate that editors can read for fast jump-to-def, with some dynamic context .. .rfx format: ------------ libname node_id source-file-name line col length kind [identifier] jdef nodeid libname def_node_id
About
rust html source code browser generator, rust source code navigator, possible component for IDE ? Example output - see rust compiler source & std libs:-
Resources
License
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published