Massachusetts voters yesterday gave the green light for ill people to ease their pain, but rejected a measure that would have let them end it altogether.

The state's medical marijuana initiative passed by 63 percent, not a shock to supporters who were confident yesterday the state would adopt the law.

"It's going to win because people value compassion more than they value fear, especially unreasonable fear," said Bill Downing, treasurer of the Massachusetts Cannabis Reform Coalition, which endorsed the initiative.

"For many decades the government has created an atmosphere of reefer madness. As people become aware that cannabis is the safest therapeutic substance known to man, they will start to lose their fear."

Medical marijuana has been used to treat patients suffering from cancer, Alzheimer's disease, HIV/AIDS and glaucoma. All New England states but New Hampshire now have legalized it in some form.

The Death with Dignity measure, however, failed, with 51 percent of voters rejecting it.

This law would have allowed terminally ill patients to get prescriptions for lethal medications.

The patients must have been given six months or less to live, and must be considered mentally capable to make the life-ending decision.

Just hours before polls closed, one of the initiative's opponents said he was "cautiously optimistic" it would fail.

"We think that a lot of people have had time to carefully consider this bill, and have seen that it is badly written and flawed, and would be dangerous for the state," said John Kelly, director of Second Thoughts, a group of Massachusetts residents with disabilities that oppose assisted suicide.

Opponents have said that if approved, the law would be a recipe for elder abuse, and while supporters of the measure argue it would give control to terminally ill patients, Kelly said the law could pressure ill people into ending their own lives.

"When people feel a burden because they’re spending money on their health care bills, this will set up a situation where people feel they need to die," he said.

Oregon enacted a similar law in 1997, and Washington in 2009.

The Right to Repair bill was also approved last night 85 percent, requiring auto makers to give owners access to the same diagnostic and repair information that dealers and repair facilities have.