Canada's Supreme Court has rejected the federal government's effort to have former Guantanamo Bay prisoner Omar Khadr declared an adult offender.

The Toronto-born Khadr, released on bail in Canada last week, spent 10 years in the U.S. prison at Guantanamo Bay, Cuba. Since 2012 he had been held in Canada, serving out an eight-year sentence handed down by a U.S. military commission in 2010.

He was convicted of war crimes, including throwing a grenade when he was 15 years old that killed a U.S. soldier in Afghanistan during a 2002 firefight.

The government argued his sentence should be an adult sentence. The decision will only affect Khadr if he goes back to jail.

Khadr was once the youngest detainee at Guantanamo, arriving there at age 15. He is now 28.