concurring in result.
I quite agree with the principal opinion in its holding that, when a petition in a declaratory judgment action discloses an actual controversy, the court has the duty to declare the governing law and should not dismiss the petition for failure to state a cause of action. The court has some discretion in deciding whether to entertain a declaratory judgment action, but a ruling based on discretion should be distinctly labeled, and there is no indication that the circuit court sought to exercise discretion. Thus the dismissal for failure to state a cause of action was erroneous.
Still, however, lawyers for defendants file motions to dismiss declaratory judgment actions, arguing that the plaintiff is not entitled to the declaration sought in the petition, and trial judges not infrequently sustain such motions. It seems clear that the trial judge in this ease intended to put the plaintiff out of court by dismissing the petition with prejudice.
The parties have briefed the merits, and neither side suggests that there are unresolved questions of fact. Under Rule 84.14 *193we are authorized to “give such judgment as the [circuit] court ought to give.” We are further admonished that we should “dispose finally of the case,” with the qualification, “unless justice otherwise requires.”
I would not establish an automatic rule that an erroneous dismissal of a declaratory judgment action for failure to state a cause of action requires reversal in all cases. I would allow the appellate court to consider and decide the merits, if persuaded that the case presents ripe questions of law.
In this case there are special circumstances which indicate that a reversal and remand would be a wise course, and so I concur in the judgment of reversal and remand.