According to the mode of proceeding in mandamus, under the new practice act, St. 1852, c. 312, § 38, no hearing on the merits is had on the application for the writ, and no preliminary order to the adverse party is issued; but upon any probable cause shown, the writ is issued as of course, in the alternative, so that the actual matters in controversy are to be heard and considered on the return of the writ of mandamus, and on the question, whether the provisional command expressed therein shall be made absolute.
It is conceded here, that at the time of the issuing of the mandamus and preliminary thereto, representatives of the opposite parties to the controversy appeared before the judge who granted the writ, and it was then arranged by mutual consent, that, instead of a return to be made by the majority of the board, comprising the mayor and aldermen, which is perhaps all which the writ would strictly call for, both the majority and *95minority of the board might, if they should see fit, make their respective answers and returns to the writ, it being understood that the board were divided on the subject; and it was further arranged and agreed, that they might annex to their returns any and all records, warrants, returns and other documents, tending to show the proceedings of the board of mayor and aldermen, the ward officers and other officers, respecting the said meeting of citizens and their acts and doings, so that the whole subject of controversy might at once be presented to this court for consideration. Accordingly we find the writ addressed not to the mayor and aldermen in the aggregate, but to the mayor and six aldermen by name.
Separate returns have accordingly been made by the mayor and two aldermen, constituting a minority of the whole board, and by the four other aldermen, constituting a majority of the board. The return of the minority states their readiness to sign the certificate of the votes and transmit it to the secretary of the Commonwealth. The answer and return of the majority proceeds, in obedience to the alternative command of the writ, to show cause why the same has not been obeyed by issuing the certificate therein mentioned, addressed to the secretary of the Commonwealth, and sets forth the causes of such refusal.
We are fully aware of the great weight and importance of the social and political, as well as the personal and private interests, involved in this controversy, and we have therefore given it all the consideration in our power since it has been heard. But we have understood it to be desired by all parties, that these questions should be considered and decided at as early a day as practicable; and considering how deeply it concerns the peace and harmony of these two great municipal corporations, and of all the respective members of both of them, that a question of this kind should be terminated by a speedy decision one way or the other; and what great trouble and confusion would ensue, in case the parties should proceed to act upon a statute, the validity of which is in question, and if it should be held invalid after acts have been done under it which would involve inextricable difficulty; we have therefore been *96the more ready to give it the earliest attention, and having come to an opinion, take this early opportunity to announce it.
A preliminary question arises, as to the nature and constitution of the board of mayor and aldermen of a city, whether, in the duty required of them, they are to act merely ministerially, or have a discretionary power to grant or withhold the certificate to the secretary of state, and whether, therefore, it is a proper case for issuing a mandamus. Without stopping to inquire into these subjects abstractly, it seems manifest that upon the terms of this act, there is no other point at which the inquiry can be raised, whether these proceedings under it are legal and valid, for the purpose of annexing the two corporations.
The act provides that it “ shall not take effect unless the inhabitants of Boston and Charlestown respectively, qualified by law to vote in city affairs,- shall accept the same at a meeting to be called for that purpose.” St. 1854, c. 433, § 7. The terms “ take effect,” if they stood alone, would seem to imply that it shall have no effect, that it shall not go into operation, until accepted. But if that were the meaning, no meeting could be held under it, or by force of it. And from its connection, we arc satisfied that this was not the intention of the legislature. It must mean, then, that the act shall not take effect, to accomplish its main purpose, to wit, the annexation, unless accepted; but in the mean time it will so far have effect, as to warrant meetings and all the other preliminary proceedings contemplated by it. But such being the legal construction, then no provision is made in the act for the time at which it is to go into operation, and therefore it is left to the operation of the general law, to go into operation in thirty days from its date.
But another consequence follows from holding that the words “ take effect ” mean take effect to accomplish the main object, by annexing the two corporations. When the returns are made to the secretary of the Commonwealth, the act requires that he shall immediately issue and publish his certificate, declaring the act to have been accepted according to law. Then, according to the terms of the act, it does take effect, the annexation is consummated, the corporation of Charlestown is merged, the *97two are united, the entire real and personal property of Charles-town becomes that of Boston, the treasurer of Charlestown is bound to pay over and account, all the officers of Charlestown cease to hold their functions, and all the consequences follow arising from the annexation.
Whatever may be the nature or quality of the act, which the mayor and aldermen of Charlestown are called upon to do, and the capacity in which they are required to act, the consequences alluded to may follow their doing or not doing the act in question, and these are of so important a character, that they insist that they are not obliged to do the act and make the required certificate, when they believe that act is inoperative and void.
Some of the causes stated in the return of the majority of the board, why they should not be required to certify the returns of the votes of the inhabitants, are founded on suggestions that the act itself, and of course the proceedings under it, are contrary to and incompatible with the Constitution of the United States, and of this commonwealth, and consequently are void.
It is conceded by the learned counsel for the prosecutors of this writ of mandamus, that if the act of the legislature, in its main scope and object, is unconstitutional, then nobody is bound to obey it, and the sooner it is declared void, and all officers and others are released from the danger of attempting to do official acts under a void law, the better and safer it will be for the community and for all parties. This concession however is to be taken with this qualification, that if the main objects and purposes of the act are constitutional, they may be carried into effect, although there may be isolated clauses, or separate or independent enactments, obnoxious to the charge of being in violation of the constitution.
Independently of this concession, we think it very clear, that if a law requiring officers and others to perform acts, which may affect the rights of others, as to arrest persons, or seize property, or the like, the officer may justify his acts under his warrant; with this limitation, that if the law be unconstitutional, it is void; though having the form, it has not the force *98of law; the provisions, professing to confer jurisdiction, give no jurisdiction; and the proceedings even of subordinate officers under it cannot be justified. Fisher v. McGirr, 1 Gray, 45, 46. Of course, therefore, whoever is called upon to do an official act, obnoxious to the charge of being in violation of the constitution, has a right to refuse obedience, if it be unconstitutional; but he does it at the peril of being able to show, whenever and wherever it may be necessary to justify his conduct, that it was unconstitutional. And it follows that when officers are called upon by due process of law, of which the writ of mandamus is one well known form, to do an act, or show some legal cause why they do not, it is a good answer to show that the legislative act, which they are required by the court to obey, is itself unconstitutional.
Whatever, therefore, the court might have considered their power and duty to be, in interfering by mandamus, to proceed or forbear proceeding, in regard to the duty of a board of mayor and aldermen, as returning and certifying officers, whether such duty be ministerial or otherwise, in a case not involving the constitutionality of an act of the legislature; we can have no doubt that it is within the scope of our authority and duty to entertain and decide the question, when such a board decline to do an act required of them by a statute, on the ground that the act is unconstitutional and void.
We proceed therefore to consider whether the act of annexation, on which this question arises, be or be not constitutional.
It is no doubt true, as has been argued by the learned counsel for the prosecutors of this writ, that the same act of legislation may be unconstitutional in some of its provisions, and yet constitutional in others. It was so decided in the case of Fisher v. McGirr, just cited, in which it was held that all that part of the act of 1852, respecting the manufacture and sale of spirituous liquors, which authorized a seizure of liquors, on the terms and in the manner there provided, was unconstitutional; and yet we are every term rendering judgments against persons for selling spirituous liquors, contrary to other provisions of the same statute. There is no inconsistency in this. Such act has all *99the forms of law, and has been passed and sanctioned by the duly constituted legislative department of the government; and if any part is unconstitutional, it is because it is not within the scope of legitimate legislative authority to pass it. Yet other parts of the same act may not be obnoxious to the same objection, and therefore have the full force of law, in the same manner as if these several enactments had been made by different statutes. But this must be taken with this limitation, that the parts, so held respectively constitutional and unconstitutional, must be wholly independent of each other. But if they are so mutually connected with and dependent on each other, as conditions, considerations or compensations for each other, as to warrant a belief that the legislature intended them as a whole, and that, if all could not be carried into effect, the legislature would not pass the residue independently, and some parts are unconstitutional, all the provisions which are thus dependent, conditional or connected, must fall with them.
The principal ground on which the respondents allege that the act of annexation is contrary to the constitution is, that the main scope and object of the act is to annex the city of Charlestown, with its territory, property and inhabitants, to the city of Boston, and to annul the charter of the city of Charles-town, whereas Boston and Charlestown are now separate municipal corporations, constitute several representative districts for the election of separate representatives to the general court, belong to distinct counties, constitute parts of distinct senatorial districts for the choice of senators in the general court, and constitute parts of distinct representative districts for the choice of representatives in the congress of the United States; and yet no adequate provision is made, in the act in question, for the exercise and security of the political and constitutional rights of the citizens of Charlestown, after the merger, which, by the act, is to take effect immediately, on the issue and publication of the certificate of the secretary of the Commonwealth that the act has been accepted.
Before proceeding to consider the objections separately, we are all of opinion, that if this act be unconstitutional at all *100it is not in any separate and independent enactments, but in the entire scope and purpose of the act. The object of the act is the annexation; the merger of one municipality, and the enlargement of the other. This must necessarily affect the municipal and political rights of the inhabitants of both, guaranteed as they are by the constitution. The legislature manifestly felt it to be their duty, in accomplishing this object, to make provision for the preservation of these constitutional rights; if this object is not effectually accomplished, we have no ground on which to infer that the legislature would have sanctioned such annexation and its consequences. The various provisions of the act, therefore, all providing for the consequences of such annexation, more or less immediate or remote, are connected and dependent; the different provisions of the act look to one object and its incidents, and are so connected with each other, that if its essential provisions are repugnant to the constitution, the entire act must be deemed unconstitutional and void.
It becomes then necessary to examine some of the specific objections to this act, as being unconstitutional; and the first we consider is, that clause in the first section, providing for the choice of representatives to the general court. That provision is that, “ for the purpose of electing representatives to the general court, the said territory [Charlestown] shall, until otherwise constitutionally provided, be and remain a distinct representative district, entitled to the same number of representatives, and subject to the same duties and obligations in relation to the choice of said representatives, as the said territory or the inhabitants thereof would have possessed by the laws of the Commonwealth, if this act had not been passed.” It is after-wards provided, that so long as said territory shall remain a distinct representative district, it shall not be annexed to any other wards of the city; and when an election is to be had, the mayor and aldermen shall issue their warrants for all meetings called for the election of senators and representatives in the territory so transferred, returns shall be made to them, and they shall certify the votes.
*101It appears to us that this is an attempt by law to create an anomalous representative district, incompatible with the provisions of the constitution. The right of sending representatives to the general court, under the constitution of Massachusetts, has been considered and adjudged to be a corporate right. By the original constitution of 1780, c. 1, § 3, art. 2, the right is established thus: “ And in order to provide for a representation of the citizens of this commonwealth, founded upon the principle of equality, every corporate town, containing one hundred and fifty ratable polls, may elect one representative,” with a provision for an increase in proportion, according to the number of ratable polls. To show that it is a corporate duty as well as right, a subsequent clause provides that “the house of representatives shall have power, from time to time, to impose fines upon such towns as shall neglect to choose and return members to the same, agreeably to this constitution.”
Towns have a right to determine, by a corporate vote, what number, within their constitutional limit, they will send. The right of members to their seats has been questioned and denied, because the presiding officers at the meetings for the election of representatives had declined to take a vote of the inhabitants upon the question whether they would send, or what number they would send. Opinions of the Justices, 7 Mass. 523, and 15 Mass. 537. Cases of Nantucket & Sharon, Mass. Election Cases, (ed. of 1852,) 195. Indeed, the great difficulty felt in establishing a city government, under the first constitution, was, that the power to choose representatives, to determine whether to send or not to send, and to fix the number, was in towns corporate. Now the marked and characteristic distinction between a town organization and that of a city is, that in the former, all the qualified inhabitants meet, deliberate, act and vote in their natural and personal capacities, in the exercise of their corporate powers; whereas under a city government this is all done by representatives. So formidable an objection was this considered, that it was not until after the adoption of the second article of amendment of the constitution in 1820, that any city was incorporated in Massachusetts, though the *102necessity of some representative government in Boston had become grievously felt.
That amendment vested the general court with full power and authority to erect city governments in any corporate town, having 12,000 inhabitants, to grant such powers, privileges and immunities, not repugnant to the constitution, as the general court should deem necessary or expedient for the regulation and government thereof, to prescribe the manner of calling and holding public meetings, in wards or otherwise, for the election of officers under the constitution, and the manner of returning votes given at such elections. The amendment still recognized the right to choose representatives to be a corporate right, but merely provided for the exercise of it in a manner adapted to the condition of a populous community, and a representative government, and where elections under the organization of a town government, in meetings of all the inhabitants, would be difficult, if not impracticable.
But if it were competent for the legislature, in its ordinary action, to constitute representative districts by law, composed of territory taken from towns and cities, without regard to the rights and powers of these municipal corporations, there would be no necessity for amending the constitution, to accomplish the same object, which has hardly been contended for, in the various discussions of the subject in the legislature, or in the conventions held for the amendment of the constitution.
The territory of Charlestown, after this act should take effect, would not be a corporation for the purpose of sending representatives, or for any other purpose; nor would the inhabitants be and remain a part of a preexisting corporation, with whose inhabitants they might still, by proper terms of reservation, have a right to vote. Such preexisting corporation would be merged and gone. If other difficulties could be got over, there is no provision in this act, to enable the inhabitants of this territory to consider and decide for themselves, whether they will choose representatives or not, and what number they will send. They are made dependent on another corporation, foreign to them for this purpose, perhaps actuated by a spirit of rivalry, *103or having interests adverse to their own, to call their meetings, to decide on the qualifications of voters, to receive the returns of their votes, and to certify the result. They are declared to be and remain a distinct representative district, entitled to the same number of representatives, and subject to the same duties and obligations in regard to the choice of said representatives, as they would have been, if this act'had not been passed; and yet no adequate provision is made, to enable them to perform these duties, or subject them to these obligations. The representatives, if chosen pursuant to the act, would represent no city or town, and no incorporated territory or body of inhabitants, and it is difficult to see how they could be representatives in the general court, conformably to the original constitution or any of its amendments.
In the opinion given by the judges of this court, published in 6 Cush. 578, the question proposed was, whether each town in the Commonwealth, after" the apportionment of representatives for ten years, and until the next apportionment, was a permanent representative district; or had the legislature power to annex a portion of one town to another, so that the inhabitants residing on such portion should have a right to vote, in the election of representatives to the general court, with the town to which such portion was annexed. The opinion expressed was, that though the case would be attended with some difficulties, it was competent for the legislature to change the boundaries of towns for general municipal purposes, provided the territory thus set off from one town to another, or the different portions of territory, of which any new town was composed, should, by proper provisions in the act, until the next decennial census and apportionment of representatives, be and remain a part of the town from which they were respectively taken, for the purpose of electing representatives. This was put on the ground, that such territory and its inhabitants being already part of a town constituting a representative district, the legislature might justly provide that they should temporarily retain that relation, for the special purpose of choosing representatives. But it was held in the same opinion, that the legislature had no constitutional *104power to create a new town, with a right to send a representa» tive, until the next decennial census. [S. P. 33 Maine, 587.]
Supposing that opinion to be correct, it affords no authority for the course of proceeding proposed to be pursued, by the act of annexation. In the case there supposed, there was a town, in and with which the inhabitants had formerly voted, where they might continue, without confusion or inconvenience, to exercise their full elective franchise, in the choice of representatives. But in the present case, the corporation under which they voted no longer exists; it has no organization, no officers, no faculty of acting and voting; as a corporation, it is merged and gone.
We do not doubt the power of the legislature to create and divide municipal corporations, cities, towns and districts, as expediency and the wants of the inhabitants may require, when it can be done without interfering with constitutional provisions. But we are of opinion that the attempt to create a representative district of a new and anomalous character, unknown to the constitution, with power to choose representatives who may assist in making laws for the whole people, is unconstitutional, and that this part of the act of annexation is void.
2. Many of the same considerations will apply to the provisions made for enabling the people of Charlestown, after the annexation, to enjoy their right of suffrage in the senatorial elections.
It is well known that counties are senatorial districts fixed by the constitution ; and in an opinion, already cited, given by the judges of this court in 1851, 6 Cush. 578, it was held that the legislature had the power to change the boundaries of counties, by setting off certain towns from one county to another, for all county purposes, other than the election of senators; but that counties having been declared senatorial districts by an amendment of the constitution in 1840, and made permanent, it was not competent for the legislature to alter them.
The provision on this subject in this act of annexation is this : “ Provided however that the territory so transferred shall, for the purpose of electing senators to the general court, continue *105to be and remain a part of the senatorial district of Middlesex, until otherwise constitutionally provided.” Then follows the provision, already cited, that the mayor and aldermen of Boston shall issue warrants for meetings, make returns, &c. These provisions are not so repugnant to the constitution, as those regarding representatives; and if they stood alone, we might hesitate in regarding the act as a whole unconstitutional, though we are inclined to the opinion that it would be so.
3. But there is another point, in which we are of opinion that the law is unconstitutional, and that is, an entire failure to provide any means by which the inhabitants of Charlestown, after the annexation, can participate at all in the election of representatives to congress.
A law of the United States, passed in 1850, requires each state to be divided into representative districts, in number equal to the number of representatives to which the State is entitled. The statute of this state, under which the whole state is now divided, places Charlestown in District No. 7; and divides the city of Boston for the purpose of these districts, placing six wards in one district, and six in another. St. 1852, c. 143.
After the annexation, the inhabitants of the territory now Charlestown, although it might still be considered as part of District No. 7, would have no right and no power to vote in that district, because the town of Charlestown, as an organized body, with its officers, would no longer exist, to call meetings and receive and certify votes; and no authority is conferred on the mayor and aldermen of Boston, or any other officer, to perform these duties. They could not vote with Boston, because Boston, as a municipal corporation, does not form a representative district, and its twelve wards are distributed and appropriated in other districts. No provision is made for the uniting of the two Charlestown wards with any corporation or organized body, for electing members of congress; the inhabitants therefore, for the time being, and for an indefinite term of time, would, in this respect, be wholly disfranchised. It is no answer to say, that this is a defect which may be amended by the legislature; it would depend wholly on the will of a future *106legislature, whether to amend it or not, whereas the act, within itself, should make provision for all the changes which it effects in the rights and in the condition of the inhabitants.
It may not be improper to remark that this act seems to have been hastily drawn, so that it is quite difficult, in many cases, to ascertain satisfactorily what was intended in many of the provisions. This conclusion seems to result from the consideration, that while some provision is made in other parts of the statute, though we think inadequate and unconstitutional, to secure to the citizens of Charlestown their right to participate in other elections, no allusion whatever is made to elections of representatives in congress.
An argument was suggested, on the part of one of the learned counsel for the prosecution of this writ, that the first six lines of the act, providing that the territory of Charlestown, with all the inhabitants and estates therein, is annexed to, and made a part of the city of Boston, was quite within the competency of the legislature, under their power to create, divide and alter municipal corporations, and therefore might be held constitutional, though the subsequent provisions of the act should be held unconstitutional.
But we think this argument will not bear examination. Suppose that these lines stood alone, and all the rest of the act had been omitted. It would have changed the bounds of a municipal corporation, during the ten years between one decennial census and another, without providing how the inhabitants annexed to such corporation should vote for representatives to the general court in the mean time. The inhabitants of Charles-town would immediately have become inhabitants of Boston for all purposes. It would have changed the lines of a constitutional senatorial district, which it has been held the legislature cannot do. It would have made no provision for the election of members of congress ; and it would have failed in errors of omission, as much as the existing provisions have exceeded the constitutional power of the legislature.
Several other objections were taken in the argument to this act of annexation and the proceedings under it, some of which, *107under other circumstances, we should have thought entitled to much consideration, especially that no adequate provision is made for the prosecution and punishment of offences, committed within the territory of Charlestown, prior to the time when that territory would be transferred from the jurisdiction of Middlesex to that of Suffolk. But we have thought it right, proceeding in this form, to confine our attention to the grounds on which this act is alleged to be unconstitutional. Having come to the conclusion, for the reasons before stated, that the act is incompatible with the letter and spirit of the constitution, in its important provisions, we are constrained to hold the act inoperative and void. The court are therefore of opinion that the reasons set forth in the answer of the majority of the board of aldermen, for not complying with the command contained in the alternative writ of mandamus, are sufficient and satisfactory, and that it is not the duty of the mayor and aldermen of the city of Charlestown to certify the votes, as by the said writ they were required to do, or show good cause for not doing.