Fixed #3585 (errors not recognized when class has extra specification)