mirror of
https://github.com/dlang-community/DCD.git
synced 2025-04-26 13:19:56 +03:00
Resolve ptr, array & aa in types, add typeOf field
typeOf field is new tab-delimited field in dcd-client output, so you no longer need to manually guess types / parse code. Calltips still yield the actual written type, but in case of "auto", the typeOf column may contain more useful info.
This commit is contained in:
parent
690d6254db
commit
22f65d51fe
19 changed files with 153 additions and 23 deletions
13
README.md
13
README.md
|
@ -175,13 +175,19 @@ a tab separated format:
|
|||
* definition: function or variable definition string or close approximation for information display purpose
|
||||
* symbol location: in which file (or `stdin`) & byte offset this symbol is defined. Separated with a space.
|
||||
* documentation: escaped documentation string of this symbol
|
||||
* typeOf: resolved type name of this symbol:
|
||||
<!-- the items in list are copied from messages.d -->
|
||||
* For variables, fields, globals, constants: resolved type or empty if unresolved.
|
||||
* For functions: resolved return type or empty if unresolved.
|
||||
* For constructors: may be struct/class name or empty in any case.
|
||||
* Otherwise (probably) empty.
|
||||
|
||||
#### Example `--extended` output
|
||||
|
||||
identifiers
|
||||
libraryFunction f Tuple!long libraryFunction(string s, string s2) stdin 190 foobar
|
||||
libraryFunction f int* libraryFunction(string s) stdin 99 Hello\nWorld
|
||||
libraryVariable v int libraryVariable stdin 56 My variable
|
||||
libraryFunction f int* libraryFunction(string s) stdin 99 Hello\nWorld int*
|
||||
libraryVariable v int libraryVariable stdin 56 My variable int
|
||||
libreTypes g stdin 298
|
||||
|
||||
#### Note
|
||||
|
@ -190,6 +196,9 @@ DCD's output will start with "identifiers" when completing at a left paren
|
|||
character if the keywords *pragma*, *scope*, *__traits*, *extern*, or *version*
|
||||
were just before the paren.
|
||||
|
||||
Types in the calltips and typeOf column may not be complete, e.g. missing
|
||||
template parameters or typeof expressions, etc.
|
||||
|
||||
### Parenthesis completion
|
||||
|
||||
When the first line of output is "calltips", the editor should display a function
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue