Community
Participate
Working Groups
Parameter hints are determined based on a prefix rather than a full name. Example: void foo(int i); void fool(int i, int j); void bar() { foo(//get parameter hints here Expected: Parameter hint popup "int i" Actual: Two possible parameter hints "foo(int i) void" and "fool(int i,int j) void" Both of these should only be valid for a code completion before the left parenthesis.
Created attachment 58482 [details] proposed patch - Changes to IASTName interface: - Removed resolvePrefix() - IBinding[] - Added getCompletionContext() - IASTCompletionContext - Changes to IASTCompletionContext interface: - Removed resolvePrefix(IASTName n) - IBinding[] - Added findBindings(IASTName n, boolean isPrefix) - IBinding[] All implementations of IASTCompletionContext have been changed to support finding bindings that start with given name as a prefix or bindings whose name matches the given name exactly. The DOMCompletionProposalComputer decides how to find the bindings based on the content assist context. This patch also contains a small test suite for parameter hints.
Patch looks good! I adjusted two tests for a trivial difference (no more trailing spaces), but I'll do some more interactive testing...
Committed to HEAD. Thanks, Bryan!