Prime Minister Stephen Harper had kind words for outgoing Ontario Premier Dalton McGuinty on Wednesday and said he hopes that their "great partnership" will continue with a new leader.

"I hope that with the new premier we will continue the close working relationship that Dalton and I have had over the past several years," Harper said from a Toyota plant in Cambridge, Ont., where he and McGuinty were announcing $34 million in joint funding for an Ontario-built hybrid car.

Asked by a reporter what he hoped for from the new premier, who will be chosen this weekend in Toronto, Harper waxed philosopical about political differences. All politicians share similar challenges, opportunities, problems and limitations, he said.

"I think it has been shown over the past several years that when governments work together and particularly work together on the economy, the results are much better," he said.

Harper said it's been "a great partnership and I hope it continues."

McGuinty returned the affection in kind, saying the province and the federal government had worked together on such issues as the Harmonized Sales Tax and greater representation for Ontario in the House of Commons.

"I'm proud of the fact that we have found common ground," he said.

The kind words belie the sometimes rocky relationship between the two governments. Last year, for example, Ontario Finance Minister Dwight Duncan called the federal budget "penny wise and pound foolish." Federal Finance Minister Jim Flaherty responded by calling Ontario's government "sad" and "badly mismanaged."

McGuinty stepping down without regrets

McGuinty, who will keep his seat in Ottawa South, expressed no regrets as he fielded questions from the media.

He said he was looking forward to the leadership convention, that promised protests by teachers were an expression of "the health and vitality of our democracy," and that the $11.9-billion deficit was necessary for the auto sector, job retraining programs and improved infrastructure.

"We did the right things at the right time," he said.

McGuinty announced that he would be stepping down as leader of the Ontario Liberals last October. However, he agreed to stay on until the party picks a new leader.