summaryrefslogtreecommitdiffstats
path: root/ctags.rust
diff options
context:
space:
mode:
authorAndrew Gallant <jamslam@gmail.com>2016-02-27 11:07:26 -0500
committerAndrew Gallant <jamslam@gmail.com>2016-02-27 11:07:26 -0500
commit9d1e619ff359b6e609b02f01e36952e603104bc6 (patch)
treea97a9dd0cbbd0978e92971805431ea4f5c018808 /ctags.rust
initial commit
Diffstat (limited to 'ctags.rust')
-rw-r--r--ctags.rust11
1 files changed, 11 insertions, 0 deletions
diff --git a/ctags.rust b/ctags.rust
new file mode 100644
index 00000000..b42edf75
--- /dev/null
+++ b/ctags.rust
@@ -0,0 +1,11 @@
+--langdef=Rust
+--langmap=Rust:.rs
+--regex-Rust=/^[ \t]*(#\[[^\]]\][ \t]*)*(pub[ \t]+)?(extern[ \t]+)?("[^"]+"[ \t]+)?(unsafe[ \t]+)?fn[ \t]+([a-zA-Z0-9_]+)/\6/f,functions,function definitions/
+--regex-Rust=/^[ \t]*(pub[ \t]+)?type[ \t]+([a-zA-Z0-9_]+)/\2/T,types,type definitions/
+--regex-Rust=/^[ \t]*(pub[ \t]+)?enum[ \t]+([a-zA-Z0-9_]+)/\2/g,enum,enumeration names/
+--regex-Rust=/^[ \t]*(pub[ \t]+)?struct[ \t]+([a-zA-Z0-9_]+)/\2/s,structure names/
+--regex-Rust=/^[ \t]*(pub[ \t]+)?mod[ \t]+([a-zA-Z0-9_]+)/\2/m,modules,module names/
+--regex-Rust=/^[ \t]*(pub[ \t]+)?static[ \t]+([a-zA-Z0-9_]+)/\2/c,consts,static constants/
+--regex-Rust=/^[ \t]*(pub[ \t]+)?trait[ \t]+([a-zA-Z0-9_]+)/\2/t,traits,traits/
+--regex-Rust=/^[ \t]*(pub[ \t]+)?impl([ \t\n]+<.*>)?[ \t]+([a-zA-Z0-9_]+)/\3/i,impls,trait implementations/
+--regex-Rust=/^[ \t]*macro_rules![ \t]+([a-zA-Z0-9_]+)/\1/d,macros,macro definitions/