Enhanced punishment for certain offences under Chapter XII or Chapter XVII after previous conviction