It has been described as unconstitutional and a wasted effort, but the Conservative government's new prostitution bill includes a preamble decrying prostitution that, some argue, could make parts of the law constitutionally sound. But that doesn't mean, of course, that it won't result in a lengthy and expensive legal battle.

OTTAWA — Mere minutes after Justice Minister Peter MacKay finished introducing his "Protection of Communities and Exploited Persons Act" on Wednesday, Robyn Maynard, a Montreal-based advocate for sex workers, was on the phone denouncing the prostitution bill.

"There is no way this is going to stand up to a Charter challenge," she told The Huffington Post Canada.

The federal government failed to live up to the expectation of the Supreme Court's ruling last December in the Bedford decision, Maynard said. In a 9-0 judgment, the country's top court found that three of Canada's laws dealing with prostitution violated the Charter of Rights and Freedoms. They ruled that the laws were too broad, disproportionate in their effect, and put prostitutes' lives at risk. Now, Maynard argued, MacKay's bill is doing the same thing again.

"It is just creating the exact same problems that just got declared unconstitutional," she said. "They are putting sex workers' lives at risks."

In the hours that followed, several political scientists, legal experts and journalists predicted the law would be successfully challenged in the courts.

"If this new prostitution law is constitutional, I'm a banana," National Post columnist John Ivison tweeted.

Pivot, a legal society that advocates for the decriminalization of prostitution, argued that the new ban on buying sex and advertising sexual services breached section 2 of the Charter, which deals with freedom of expression and association, as well as section 7, which relates to the right to life, liberty and security of the person. Just like the prostitution laws that were struck down, the new bill would displace sex workers, block their ability to screen clients for safety and create a less safe working environment, Pivot wrote on its website. It pledged to challenge the law.

But not everyone agrees that the new bill is unconstitutional.

University of British Columbia law professor Janine Benedet told HuffPost that, for the first time, the law includes a preamble that will guide the court if the new legislation is appealed. MacKay's bill will be judged against a different objective and different criteria than the public nuisance laws that the top court struck down in the Bedford decision, she said.

The new preamble notes that Parliament is concerned with the exploitation of sex workers, the violence they face, and the social harms caused by the commodification of sexual activity. For the first time, Parliament explicitly says it wants to discourage prostitution by reducing the demand.

"That’s surely a valid objective," she said. "And to therefore prohibit the purchase [of sex] is entirely consistent with that objective, so I see no reason why that part of the bill shouldn't be constitutional — unless we believe that the Charter actually gives people the right to to buy women as prostitutes, which I don’t think it does."

Benedet opposes the government's decision to criminalize prostitutes — those found in a public space where people under the age of 18 might be present.

"We don’t criminalize the victims of assault or sexual assault and we should not criminalize the victims of prostitution," she said, referring to women who turned to prostitution because they are destitute and on the street.

"The only goal that it advances is a kind of nuisance-based, community harm-based goal," she added. "That is what got [the federal government] into trouble before, and I don't think it ought to be part of this bill."

A senior government official told HuffPost that the Conservative government is of the view that its bill would survive a Charter challenge and that the unusual preamble will "signal to the court the objectives of the bill."

"In the preamble, … prostitution is obviously seen in a fundamentally different way then it was seen before," the official said. "Today, it is not a criminal activity; it will now be a criminal activity."

"When you criminalize purchasing sexual services, you're saying that every time prostitution takes place, an illegal activity has occurred. The legislation is saying that prostitution itself is illegal," another official said.

Under the new law, sex workers might have a harder time proving that a law designed to protect them is actually hurting them, said University of Saskatchewan College of Law professor Michael Plaxton.

"The [Supreme Court's] decision in Bedford was premised on the idea that sex workers were engaged in a lawful activity, and that the legislation was preventing them from taking steps to protect themselves," he told HuffPost in an email.

"If sex work was an unlawful activity, then sex workers would have a difficult time arguing that Parliament has a responsibility to make them safe while engaging in it."

The goal of the federal government's legislation is to limit not just the physical harm to sex workers but also the social harm that sexual objectification causes women and sex workers, he said. "Harm results whenever people engage in sex work — whether physical injury is caused or not — simply because it reinforces pernicious values, especially when others can see sex work practised and treated as legitimate."

"Given that sort of objective," he said, "it is more difficult to say that isolating sex workers, with communication and advertising restrictions, is arbitrary."

University of Waterloo political scientist Emmett Macfarlane argued, however, that the bill does not impose a blanket ban on prostitution. Based on what the court said, the bill might be less problematic from a constitutional standpoint if the federal government had criminalized prostitution, he suggested.

"But that's not what this new bill does. From the perspective of the sex worker, it is still a lawful activity upon which the government is imposing restrictions," he said. "If they want to 'criminalize prostitution,' then they should just criminalize prostitution."

Macfarlane believes MacKay's bill replicates a lot of the harms the top court was concerned with when it voided the original laws. The restrictions on advertising and the revived provisions on communicating in public have the exact same effect that the old provisions did in forcing sex workers underground, making it more difficult for them to vet clients and meet in a safe location of their choosing, he said. "This bill has the effect of increasing the risks that sex workers have in conducting their business."

"I cannot see a court concluding that this bill has the balance right," Macfarlane said. "The bill is far too draconian to meet the constitutional standards that the court outlined."

The preamble might shift the court's analysis a little bit and make it harder for justices to conclude that the laws are arbitrary, he said, but it won't affect considerations about whether the impact of the law is grossly disproportionate.

"On that, I don't see how a preamble or the government's intentions matter, to be frank. If the harm outweighs the benefit of the law, and if, in essence, the selling of sex is still a lawful activity but all these other aspects of the law just make it a more dangerous way to conduct that activity, then the government is going to lose again."