Updated the tab-completion.
  Updated completion and input handlers.  (broken)

  This is the last work-in-progress commit of the day, the next
 commit will restore functionality.

  I'm doing two things here:

  * replacing readline with get_line, which operates on an
    std::string instead of a buffer.

  * Changing the completion code to work on tokens.

  This means that I don't need to split the input line into
 prefix/suffix/token twice:

  * Once in the completion code to look for matches.
  * Once in the readline loop to replace the token with the expanded
    reply.

  Reworking the input-reading into a function that operates on a
 std::string will help simplify the code and allow this to be done
 more easily.

  (Renaming the function allows both implementations to be compared
 until complete.)