31. A judgment of the Superior Court or the Court of Québec rendered in the course of a proceeding, including during a trial, is appealable as of right if it disallows an objection to evidence based on the duty of discretion of public servants or on professional secrecy.
Such a judgment may be appealed with leave of a judge of the Court of Appeal if the judge considers that it determines part of the dispute or causes irremediable prejudice to a party, including if it allows an objection to evidence.
The judgment must be appealed without delay. The appeal does not stay the proceeding unless a judge of the Court of Appeal so orders. If the judgment was rendered in the course of the trial, the appeal does not stay the trial; however, judgment on the merits cannot be rendered nor, if applicable, the evidence concerned heard until the decision on the appeal is rendered.
Any other judgment rendered in the course of a trial, except one that allows an objection to evidence, may only be challenged on an appeal against the judgment on the merits.