Corporal punishment illegal – High court