A man's affair with another man constitutes adultery and is grounds for divorce, a British Columbia Supreme Court judge ruled.

In granting the divorce Tuesday, Justice Nicole J. Garson (search) said she was persuaded that she had the authority to make a change in the legal definition of adultery, which under previous Canadian court rulings has been considered voluntary extramarital sex between a spouse and someone of the opposite gender.

Garson also granted a Canadian Justice Department's (search) request to ban publication of the couple's name and referred to the case as P. versus P.

The woman, 44, filed for divorce in October.

Christian Girouard (search), a federal government spokesman, said the department intervened to ensure that the Divorce Act would be interpreted in accordance with the Charter of Rights and Freedoms and to reflect same-sex marriage legislation.

Canada legalized same-sex marriages nationwide in July. Gay marriages were first allowed in two provinces, Ontario and British Columbia, in 2003.