It is contrary to the law when the acts by which the custom was introduced were forbidden by law. There is nothing repugnant in the notion of a lawful custom being introduced by wrongful acts, for when the custom is formed the acts cease to be forbidden, because the contrary law has in fact ceased to exist.
3. In order that a custom may have the force of law it must be reasonable and it must fulfil certain other conditions.
A custom will be reasonable if it is not against the natural or divine law, against which no custom can prevail, nor furnishes the occasion nor is an incentive to sin, nor is pernicious and hurtful to the common good. Inasmuch as custom has the force of law, it cannot be introduced by individuals or by private families, for whom precepts may be given but laws cannot be made.
It must be introduced by the repeated acts of the greater portion of a community or corporate body which is capable of being the subject of law. How many acts are required to form a custom depends much on the matter, and must be left to the prudent judgement of experts.
The acts by which the custom is introduced must be voluntary, not the product of ignorance or mistake, and unless the tacit consent of the legislator is given before, they must continue for a long time that is, forty years (Can. 27).
4. As custom depends on the will of the ecclesiastical superior, he may refuse to admit or he may abrogate a custom.
The clause " Notwithstanding any custom to the contrary," which frequently occurs in pontifical legislation, merely annuls general customs to the contrary, not special ones nor immemorial customs, nor those of a hundred years' duration. These require special mention in papal but not in episcopal legislation. The reason of the difference lies in the fact that the Pope may easily be unaware of local customs, and he does not annul what he does not know. But a Bishop is presumed to know the customs of his diocese, and if he makes a law which is against a custom he thereby abrogates the latter.
Only a reasonable custom which is immemorial or of a hundred years' duration can prevail against a law which contains a clause forbidding future customs to the contrary (Can. 27). If, however, a law reprobate contrary customs as abuses, they cannot be introduced as long as the circumstances remain the same. Such customs would be unreasonable, and could not have the consent of the legislator.