Should the Senate pass the legislation, Maryland would become the eighth state to approve same-sex marriage. But the law would not go into effect until Jan. 1 — and both sides expect it to be on the November ballot as a referendum, where state voters could defeat it.