emacsautocompleteicicles

In emacs, make dabbrev-expand only do partial completions like minibuffer-expand?


Currently, in C-mode, if I start typing a word such as:

namespace_module_

dabbrev-expand will cycle through a million full completions of this identifier...

namespace_module_typea_foo <TAB>
namespace_module_typea_bar <TAB>
namespace_module_typea_goo_start <TAB>
...

With many possible words, it is tedious to navigate through all of these. However, minibuffer completion seems to work differently. It only completes until the first difference among the possible matches. It would have completed to (assuming there were no other matches to something like typeb_, etc):

namespace_module_typea_

At this point, I need only type one character to remove the ambiguity, and it is very likely that autocompletion's next guess will be correct. Is it possible to use this completion mode in-buffer with dabbrev-expand? Or hippie-expand? Or even icicles? I've not been able to find anything.


Solution

  • Have you tried dabbrev-completion (bound to C-M-/ by default)? It should do just what you're asking.