ELMONT, N.Y. — When a police officer in this Long Island suburb found a marijuana cigarette in Jerry Lemaine’s pocket one night in January 2007, a Legal Aid lawyer counseled him to plead guilty. Under state statutes, the penalty was only a $100 fine, and though Mr. Lemaine had been caught with a small amount of marijuana years earlier as a teenager, that case had been dismissed.

But Mr. Lemaine, a legal permanent resident, soon discovered that his quick guilty plea had dire consequences. Immigration authorities flew him in shackles to Texas, where he spent three years behind bars, including 10 months in solitary confinement, as he fought deportation to Haiti, the country he had left at age 3.

Under federal rulings that prevailed in Texas, Mr. Lemaine had lost the legal opportunity that rulings in New York would have allowed: to have an immigration judge weigh his offenses, including earlier misdemeanors resolved without jail time, against other aspects of his life, like his nursing studies at Hunter Business School; his care for his little sister, a United States citizen with a brain disorder; and the help he gave his divorced mother, who had worked double shifts to move the family out of a dangerous Brooklyn neighborhood.

Now Mr. Lemaine, 28, is among thousands of noncitizens whose fate may hinge on a case to be argued on Wednesday before the United States Supreme Court, in a challenge to the way the government interprets immigration laws about drug-related convictions. The government maintains that for deportation purposes, two convictions for drug possession add up to the equivalent of drug trafficking, an “aggravated felony” that requires expulsion and prohibits immigration courts from granting exceptions based on individual life circumstances.