Does Henry Higgins hold the key to settling the same-sex marriage debate? Not quite. But in the wake of the Supreme Court decision declaring a constitutional right to same-sex marriage, it’s well worth considering what Higgins has to tell us.

In “My Fair Lady,” Professor Higgins sings a song called “Why Can’t a Woman Be Like a Man?” It’s an amusing account of his misogyny. But by the end of the story, the professor has learned a great lesson: not only can’t women be like men — or men like women either — it’s a very good thing for both that they can’t.

This lesson has a name: complementarity. It needs to be relearned now in the midst of widespread confusion about marriage.

Complementarity is what Jesus is talking about in his well known words about marriage in the 19th chapter of Matthew’s gospel. Some Pharisees ask him if a man can divorce his wife. Jesus says no. And then he says this:

“Have you not read that the Creator, from the beginning, made them male and female, and said, ‘For this cause a man shall leave his father and mother, and cleave to his wife, and the two shall become one flesh’? Therefore now they are no longer two but one flesh. What therefore God has joined together, let no man put asunder” (Matthew 19:4-6).

“They are no longer two but one flesh” — that’s complementarity. It includes all dimensions of the man-woman relationship in marriage — physical, psychological and spiritual.

Pope Francis has referred to this special relationship many times. A few weeks ago, speaking to Puerto Rican bishops making their ad limina visits to Rome, he called it “the crown of the divine creation” while warning that today it is “being questioned by gender ideology.”

Note that reference to gender ideology — also called gender theory. This way of thinking now stands as the principal intellectual source of opposition to the traditional understanding of marriage and of support for same-sex marriage.

The central idea driving various versions of gender theory concerns the part played by culture in shaping individuals’ understanding of their sexual identity and gender roles. Obviously this isn’t all wrong — culture does play an important part in forming our thinking about these things.

But gender theory goes wrong in suggesting that gender and gender roles are little more than social constructs that can be shaped and re-shaped according to individual preference and better ideas. Hence much of the current frenzy over the “transgender” phenomenon. Hence the willingness of five Supreme Court justices to scrap millennia of human wisdom and say that men can marry men and women can marry women.

Yet man-woman complementarity is and will remain a fact lying at the heart of marriages that deserve the name. It is expressed most powerfully in the begetting of a child, in whom, it might be said, something of both father and mother becomes incarnate in the person of a unique new human being.

As Justice Alito remarked in his dissent in the same-sex marriage case, marriage has always been and will remain “inextricably linked to the one thing that only an opposite-sex couple can do: procreate.”

Henry Higgins doesn’t say all that, of course. But by the end of “My Fair Lady” he is definitely on the right track. Here’s hoping a deeply confused society gets back on track on the subject of marriage before too much more harm is done. But it can only do that by following the sign reading “This Way to Complementarity.”