How to design a good API for autocompletion, based on experience with YouCompleteMe: https://github.com/rust-lang/rfcs/pull/1317#issuecomment-150877801