Section 52. In all civil proceedings which are not governed by the Massachusetts Rules of Civil Procedure or by the District-Municipal Courts Rules of Civil Procedure, the court may allow a party to whose pleadings a demurrer has been filed to amend, upon terms, within such time as it orders.