Fix weird annotation behaviour.
Changed duplicate definitions condition to return all duplicate definitions.