Community
Participate
Working Groups
In the following code: struct S { void foo(); }; template <typename F> void f(F); int main() { f(&S:: /* invoke content-assist here */ ); } when content-assist is invoked at the indicated location, the non-static member function 'foo' is not listed among the completion results. If 'foo' is made static, then it is listed. I think non-member functions should be listed as well, because they are valid arguments to some functions (in particular, things like std::bind() and std::mem_fn()).
Sorry, I meant "I think *non-static* member functions should be listed as well..."
New Gerrit change created: https://git.eclipse.org/r/87007
Static fields are also not shown in this context, but should be. The patch in comment 2 fixes the issue for both methods and fields.
Gerrit change https://git.eclipse.org/r/87007 was merged to [master]. Commit: http://git.eclipse.org/c/cdt/org.eclipse.cdt.git/commit/?id=1628d11e7eb680ea4e5a687ef36b88fcd7194017
Fixed for 9.3.
Mentioned in the 9.3 N&N: https://wiki.eclipse.org/CDT/User/NewIn93#Completion_of_member_functions_when_taking_the_address
This change introduced a regression where completing the method name in an out-of-line method definition would no longer emit parentheses.
New Gerrit change created: https://git.eclipse.org/r/89484
(In reply to Nathan Ridge from comment #7) > This change introduced a regression where completing the method name in an > out-of-line method definition would no longer emit parentheses. Fixed by the patch from comment 8.
Gerrit change https://git.eclipse.org/r/89484 was merged to [master]. Commit: http://git.eclipse.org/c/cdt/org.eclipse.cdt.git/commit/?id=a90caec05e89b18927c4243d0e95d8f334932dac
*** Bug 515803 has been marked as a duplicate of this bug. ***