The gemara concludes that if there would be a legitimate concern that a child will eat something not kosher that is handed to them, one may not hand it to them. The machlokes between the tana kama and r. yehuda whether one can hand a child a non-kosher live bug, boils down to an assumption as to what the child will do with it when it dies. The t.k. is concerned the child will eat it and therefore says you can't hand even a live non-kosher chagav to a child because it may die and he will eat it, but r. yehuda says that since it was his pet, he will mourn its death, not associate it with food and therefore he won't eat it.
Rashi points out that we pasken that when a child is eating something not kosher, it is not incumbent upon others to stop him (aside from a child who reaches chinuch in which case his father is obligated to stop him). Why then is it forbidden to give him a non-kosher chagav to play with? Rashi explains that since there is an issur d'oraysa to feed a child something not kosher, handing something not kosher to a child when he is likely to eat it is tantamount to feeding him issur. Rashi implies that placing not kosher food down in front of a child is an issur d'oraysa of לא תאכילום - להזהיר גדולים על הקטנים. However, the Ritva writes that one may not give the non-kosher item to a child because it is "like" feeding him. The language of the Ritva implies that it is not actually an issur d'oraysa, but since it is very close to actually feeding him, it is assur m'drabonon.
The gemara also says that if there is a concern that he will eat a live chagav, one may not even give a child a kosher chagav because eating it while it is alive is still an issur of בל תשקצו, which is a general issur against doing things that are disgusting. The source of this idea is a gemara in Makos 16b that if one drinks out of a horn that is used for blood letting they are in violation of בל תשקצו. We generally assume that this pasuk is merely an אסמכת for disgusting activities but would not be an issur d'oraysa.
Based on this assumption, the Mishneh L'melech (ma'achalos asuros perek 27) asks on the Rashba who says that the issur to feed a child an issur d'rabonon only applies to prohibitions of the Torah, not to Rabbinic prohibitions, provided that it is a need of the child (which is against the p'sak of the shulchan aruch o.c. 343 where the shulchan aruch explicitly writes that you can't even feed a child an issur d'rabonon. See Biur Halacha who cites R. Akiva Eiger who relies on the Rashba). According to the Rashba, why would the gemara assume that you can't give a child a chagav that is kosher, since even if he eats it, it is only an issur d'rabonon?
The Beis HaLevi (3:55:1) answers that even the Rashba only permits it when it is for the well being or benefit of the child, and we don't consider eating a chagav to qualify. It is not clear to me why a chagav which is apparently edible, would not be considered for the benefit of the child. R. Chaim Ozer (Achiezer 3:81:5) answers that the Rashba only permits other activities which aren't sourced in the Torah, just derived from the 3 places where the Torah warns adults not to feed issur to children (tu'mah, dam, and sheratzim). But by the 3 places where the Torah explicit writes לא תאכלום and we darshen לא תאכילום, even the Rashba admits that since it is עיקרו מן התורה we don't allow the feeding of an issur d'rabonon to a child. Since eating a live chagav is an issur d'rabonon based on בל תשקצו which is the la'av of eating sheratzim, we forbid even issurei d'rabonon.