How to reproduce
1. Place a chest minecart
2. Light TNT next to it
3. Use the number keys to continually swap an item in the cart with your inventory
4. When the TNT blows up, there is a chance one of the items will be converted into the other. This is just a client-side ghost item though.
In survival the bugged item(s) return to normal when you try to stack them.
[media]