President Barack Obama said same-sex couples have a strong case for marriage equality after hearings in the Supreme Court this week.

In an interview with Univision on Wednesday, Obama declined to say which way he thought the high court might rule, but hearkened back to his constitutional law background indicating he is optimistic.

“I never predict what the court will do,” Obama said. “But I used to teach constitutional law, and there is certainly a strong basis for determining that in this age, given what we now know, given the changes that have been taking place in the states around the country, same-sex couples should be treated fairly and have the same rights benefits, be able to transfer property, all the rights and recognitions that heterosexual couples do.”

The Supreme Court on Wednesday heard a case challenging the Defense of Marriage Act, which denies legally married gay and lesbian couples federal benefits available to heterosexual married couples, including tax and Social Security benefits.

The court heard a arguments for and against California’s Proposition 8 gay marriage ban Tuesday.