Make the linking of uses more robust.

Authored by zwabel on Jul 3 2016, 2:26 PM.

Description

Make the linking of uses more robust.

Normally, uses are created based on indirect declaration IDs
which are more flexible w.r.t. reparsing. However, they
need to be resolved in context, and if the top-context they
are resolved from doesn't directly include the top-context of
the used declaration, the resolution fails and zero is returned.

For such uses which would be un-resolvable, use direct
index-based declaration IDs instead of indirect IDs.

Also search for such direct references in Declaration::hasUses,
Declaration::uses, etc.

Details

Committed
zwabelJul 3 2016, 2:26 PM
Parents
R32:7e008924bcb6: Revert "Remove workaround that sends random events to the menu bar"
Branches
Unknown
Tags
Unknown