Reworked resolve phase to allow virtual tags.