Fix #362
This commit is contained in:
parent
974882fd74
commit
5832c0a538
|
@ -778,10 +778,10 @@ DSymbol*[] getSymbolsByTokenChain(T)(Scope* completionScope,
|
|||
// If the `symbols` array contains functions, and one of them returns
|
||||
// void and the others do not, this is a property function. For the
|
||||
// purposes of chaining auto-complete we want to ignore the one that
|
||||
// returns void.
|
||||
// returns void. This is a no-op if we are getting doc comments.
|
||||
void filterProperties() @nogc @safe
|
||||
{
|
||||
if (symbols.length == 0)
|
||||
if (symbols.length == 0 || completionType == CompletionType.ddoc)
|
||||
return;
|
||||
if (symbols[0].kind == CompletionKind.functionName
|
||||
|| symbols[0].qualifier == SymbolQualifier.func)
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
Sets or gets prop
|
|
@ -0,0 +1,13 @@
|
|||
struct Foo
|
||||
{
|
||||
/// Sets or gets prop
|
||||
void prop(int t);
|
||||
/// ditto
|
||||
int prop();
|
||||
}
|
||||
|
||||
void main(string[] args)
|
||||
{
|
||||
Foo f;
|
||||
f.prop
|
||||
}
|
|
@ -0,0 +1,5 @@
|
|||
set -e
|
||||
set -u
|
||||
|
||||
../../bin/dcd-client $1 file.d -d -c136 > actual.txt
|
||||
diff actual.txt expected.txt
|
Loading…
Reference in New Issue