Use source index to get completions from current package

NOTE: This could use some review as I'm not fully aware of the most 'idiomatic' ways of generating R objects / lists from C++ code.

This PR generates autocompletions from the source index when working on a package project.
Do we get this line of code back anywhere else or is it okay to remove it?