Wherever in the general laws or in any public law reference is made to a senator from any city or town, or to the election of a senator from any city or town, the reference shall mean and be deemed to refer to a senator from a senatorial district, or the election of a senator from a senatorial district, as the context may require.