dmdtags 1.0.0: an accurate tag generator for D source code
Виталий Фадеев
vital.fadeev at gmail.com
Sat Aug 28 03:41:47 UTC 2021
On Friday, 27 August 2021 at 21:38:58 UTC, Paul Backus wrote:
> `dmdtags` is a tags file generator for D source code that uses
> the DMD compiler frontend for accurate parsing.
>
> This release supports 100%-accurate parsing of arbitrary D code
> (tested on DMD and Phobos sources), as well as the most
> commonly-used command line options, `-R`, `-o`, and `-a`. The
> generated tags file has been tested for compatibility with Vim
> and is compliant with the [POSIX standard for `ctags`][posix],
> so any editor with `ctags` support should be able to use it.
>
> [posix]:
> https://pubs.opengroup.org/onlinepubs/9699919799/utilities/ctags.html
>
> ### What?
>
> A _tags file_ is a lightweight plain-text index of the symbols
> in a project. Editors that support tags files, such as Vim and
> Emacs, can use this index to help with things like project
> navigation and tab completion.
>
> A _tags file generator_ is, as you might expect, a program that
> reads source code and generates a tags file with entries for
> the symbols in that code.
>
> ### Why?
>
> [`universal-ctags`][uctags], the current most-popular and
> best-maintained tags file generator, claims support for many
> programming languages, including D. However, its D parser is
> not well-maintained, and it often excludes large numbers of
> symbols from its output due to parsing failures.
>
> Because `dmdtags` uses the DMD frontend for parsing, its
> results will always be accurate and up-to-date. For pure D
> projects, it can be used as a replacement for
> `universal-ctags`. For mixed-language projects, it can be used
> together with other tag generators with the `--append` option.
>
> [uctags]: https://ctags.io
>
> ### Where?
>
> * On Github: https://github.com/pbackus/dmdtags
> * On Dub: https://code.dlang.org/packages/dmdtags
```
# dmdtags -R ./source/ -o -
!_TAG_FILE_SORTED 1 /0=unsorted, 1=sorted, 2=foldcase/
App ./source/ui/app.d 13;" T
App ./source/ui/app.d 15;" a
App ./source/ui/app.d 19;" T
App ./source/ui/app.d 21;" s
__ctor ./source/ui/app.d 27;" f
__ctor ./source/ui/app.d 30;" f
_result ./source/ui/app.d 23;" v
app ./source/ui/app.d 1;" M
defaultEventLoop ./source/ui/app.d 48;" f
defaultInitFunc ./source/ui/app.d 62;" T
defaultInitFunc ./source/ui/app.d 62;" f
window ./source/ui/app.d 26;" v
```
Perfecto!
i can use it in Sublime Text editor...
Need to thinks, how it will be implemented...
More information about the Digitalmars-d-announce
mailing list