3. Magistrates' powers of detention for short periods.

Where a magistrates' court1 that has power to commit to prison a person convicted of an offence, or would have that power but for the statutory provisions relating to the restrictions on the power to impose imprisonment for default2 or the supervision of pending payments3, it may order him to be detained within the precincts of the courthouse or at any police station until such hour, not later than 8 o'clock in the evening of the day on which the order is made4, as the court may direct, and, if it does so, must not, where it has power