Upon an indictment for robbery, the accused may be convicted of an assault with intent to rob, or of an assault, or of stealing.