Long before Donald Trump, birth tourism, and today’s debate over birthright citizenship, there was a son of Chinese immigrants named Wong Kim Ark.

And the story of Wong Kim Ark shows why many legal scholars think Trump probably won’t succeed in his plans, revealed Tuesday, to end the practice of bestowing U.S. citizenship to babies born on U.S. soil. Ark’s fight wound up being the basis of a little-known Supreme Court case that has a outsized effect on the debate over birthright citizenship.

Ark’s story starts in 1873, when he was born in San Francisco’s Chinatown neighborhood to Chinese parents. His parents were permanent residents but not U.S. citizens. They were in the U.S. to work. By the late 1800s, with big waves of immigrants arriving in the U.S. from China, California and the federal government passed a series of laws discouraging Chinese immigration, which politicians and labor leaders blamed for low wages.

That wound up being a problem for Ark. At age 21, he visited China. Upon his return by steamship a year later, port officials wouldn’t let him enter. They said he wasn’t a citizen and that the law forbade Chinese immigrants from entering the country. He sued.

At issue, then as now, is this wording from the 14th Amendment: “All persons born or naturalized in the United States, and subject to the jurisdiction thereof, are citizens of the United States and of the State wherein they reside.”

In a 6-2 decision, the Supreme Court in 1898 found that Ark was, indeed, a citizen and should be allowed in the country. It wasn’t exactly a period of racial enlightenment, either: Just two years earlier, the court ruled in Plessy v. Ferguson that racially segregated public facilities were legal.

But in reviewing Ark’s case, U.S. v. Wong Kim Ark, the court examined the plain meaning of the 14th Amendment and its legislative history and found no basis to conclude that Ark wasn’t a citizen:

To hold that the Fourteenth Amendment of the Constitution excludes from citizenship the children, born in the United States, of citizens or subjects of other countries would be to deny citizenship to thousands of persons of English, Scotch, Irish, German, or other European parentage who have always been considered and treated as citizens of the United States. … Whatever considerations, in the absence of a controlling provision of the Constitution, might influence the legislative or the executive branch of the Government to decline to admit persons of the Chinese race to the status of citizens of the United States, there are none that can constrain or permit the judiciary to refuse to give full effect to the peremptory and explicit language of the Fourteenth Amendment.

The court said its interpretation was consistent with British common law, in which people born in a British territory are subjects of the crown unless their parents are diplomats or part of a hostile occupying force.

There are some distinctions between Ark’s case and the modern debate over birthright citizenship. Most notably, his parents were in the U.S. legally, unlike illegal immigrants who give birth in the U.S. today and seem to be the target of Trump’s push to restrict citizenship. Some conservative legal scholars have said that the 14th Amendment is intended to apply only to children of citizens and legal residents.

Other legal scholars, though, dispute that argument. And they largely point to Ark’s story to do it.