dictionary: refactor the pronunciation logic into dictionary::pronounce.