Bug 525739 - Have Open Declaration find potentially-matching definitions for a declaration

The implementation strategy is as follows:

  - Implement an option to find potential matches during an AST
    definition search.

  - Store names that resolve to ProblemBindings in the index,
    as references for the candidate bindings, annotated as being
    potential matches.

  - Add an option to Index.findNames() to include potential matches.

  - Use the added options for the index and AST searches in
    OpenDeclarationsJob, prioritizing them accordingly (e.g. exact index
    matches take precedence over potential AST matches, but if there
    are no exact matches, potential matches from the AST and the index
    are combined).

Change-Id: I19f5c58820eb3ec79a31652d69fd5b86acaba115
15 files changed