A letter dated yesterday from Lynch says Rhode Island prohibits discrimination based on sexual orientation and also extends benefits such as health insurance to domestic partners of state employees.

And because there’s no Rhode Island law banning gay marriage — Lynch says there’s no reason to deny recognition of same-sex unions performed in Massachusetts.

Massachusetts is the only state where gay marriage is legal.

Lynch spokesman Michael Healey says the opinion is not binding, but a staff attorney for Gay and Lesbian Advocates and Defenders says she expects most government agencies in Rhode Island to heed the legal advice of the state’s top lawyer.