Universal Ctags Support
The Silk compiler repository ships a Universal Ctags configuration for Silk at its root (.ctags).
What It Tags#
The bundled rules recognize:
fndeclarations (includingexport fn,export default fnwhen named, andasync/task-modified functions),letandvarbindings (includingexport let,export var, andlet mut),extdeclarations (includingexport ext),struct,enum,error,interface, andimpldeclarations,packagedeclarations.
These tags are regex-based and intentionally conservative; they do not perform semantic resolution or scope analysis.
Usage (Project-Local)#
To use the Silk rules in a single project:
- Copy the Silk
.ctagsfile (from the Silk compiler repository root) into your project root. - Run:
ctags -R
Universal Ctags will read .ctags automatically and tag *.slk files as Silk.
If your ctags binary is not Universal Ctags, install it first; Exuberant/etags do not support the same configuration format.
If you are working in the Silk compiler repository itself, .ctags is already present at the repository root; you can run ctags -R directly.
Usage (Global)#
To use the Silk rules across multiple projects:
- Copy the Silk
.ctagsrules (from the Silk compiler repository root) into your global config (for example~/.ctags.d/silk.ctags). - Run
ctags -Rin any Silk project.
If you already maintain a global ctags configuration, merge the Silk rules into it instead.
Source repository · Edit this page · View Markdown