1 USING: help.syntax help.markup kernel prettyprint sequences strings words math ;
4 ARTICLE: "ctags" "Ctags file"
5 { $emphasis "ctags" } " generates a index file of every factor word in ctags format as supported by vi and other editors. More information can be found at " { $url "http://en.wikipedia.org/wiki/Ctags" } "."
17 { $values { "path" "a pathname string" } }
18 { $description "Generates a index file in ctags format and stores in " { $snippet "path" } "." }
28 { $values { "seq" sequence }
29 { "path" "a pathname string" } }
30 { $description "Stores a " { $snippet "alist" } " in " { $snippet "path" } ". " { $snippet "alist" } " must be an association list with ctags format: key must be a valid word and value a sequence whose first element is a resource name and second element is a line number" }
33 "USING: kernel ctags ;"
34 "{ { if { \"resource:extra/unix/unix.factor\" 91 } } } \"tags\" ctags-write"
39 { $snippet "tags" } " file will contain a single line: if\\t/path/to/factor/extra/unix/unix.factor\\t91" } ;
42 { $values { "alist" "an association list" }
44 { $description "Converts an " { $snippet "alist" } " with ctag format (a word as key and a sequence whose first element is a resource name and a second element is a line number as value) in a " { $snippet "seq" } " of ctag strings." }
47 "USING: kernel ctags prettyprint ;"
48 "{ { if { \"resource:extra/unix/unix.factor\" 91 } } } ctag-strings ."
49 "{ \"if\\t/path/to/factor/extra/unix/unix.factor\\t91\" }"
54 { $values { "seq" sequence }
56 { $description "Outputs a string " { $snippet "str" } " in ctag format for sequence with two elements, first one must be a valid word and second one a sequence whose first element is a resource name and second element is a line number" }
59 "USING: kernel ctags prettyprint ;"
60 "{ if { \"resource:extra/unix/unix.factor\" 91 } } ctag ."
61 "\"if\\t/path/to/factor/extra/unix/unix.factor\\t91\""
66 { $values { "ctag" sequence }
68 { $description "Provides de line number " { $snippet "n" } " from a sequence in ctag format " }
71 "USING: kernel ctags prettyprint ;"
72 "{ if { \"resource:extra/unix/unix.factor\" 91 } } ctag-lineno ."
78 { $values { "ctag" sequence }
80 { $description "Provides a path string " { $snippet "path" } " from a sequence in ctag format" }
83 "USING: kernel ctags prettyprint ;"
84 "{ if { \"resource:extra/unix/unix.factor\" 91 } } ctag-path ."
85 "\"resource:extra/unix/unix.factor\""
90 { $values { "ctag" sequence }
92 { $description "Provides the " { $snippet "word" } " from a sequence in ctag format " }
95 "USING: kernel ctags prettyprint ;"
96 "{ if { \"resource:extra/unix/unix.factor\" 91 } } ctag-word ."