In Sweden there is not neccesarily a law against cannibalism... but usually things like this tend to fall under crimes like aggravated assault, manslaughter, murder, or something in Swedish called "Brott mot Griftefriden" ("Crimes against the Grifte-peace/the peace").
I am not sure how to translate the last word there... because I do not know what "Grifte" means, and I can not find any partcicular translations on the word. It might be a really old Swedish word, it might be another languages... old or not... word. To an extent it makes me think of the Swedish word "Gräva", which means "Dig" or "To dig"... but I might be compleatly wrong on that.
Anyway... this "Brott mot Griftefriden" law basicly says something like this:
"Whoever unlawfully moves, harms or "skymfligen"(*1) treats corpses or the deceased's ashes, open grave or otherwise do harm or mischief on the coffin, urn, grave, tomb or other place of rest of the deceased, is convicted of crimes against griftefrid to a fine or imprisonment not exceeding two years."
(*1): due to not really finding a good translation of this word I found some several synonyms to "Skymfligen" to give a basic idea of what it means: insultingly, offensively, disgracefully, sacrilegiously, heinously, dishonorably, etc. A "skymf" in Sweden means that something is an affront, insult, offence, and other such words.
So basicly it is a law that states that everything that has got to do with the deceased, be it's actual body, or it's remains, or the things surrounding it as in graves, coffins, urns, buildings, gravestones, etc, needs to be treated with repect and not be desecrated etc. There are probably exeptions of course, like autopsys, or if the person is an organ doner, and/or if they donated their body for science and such things. But I would asume there are very strict rules surrounding such things, so as to not break the "Griftefriden" law. This law does also cover things like ancient burial sites etc, so I would asume there are also certain kinds of exeptions for things like legal archeology etc.