I don't think this is supposed to happen. The two guns don't have the same condition, and the name didn't say (2) behind it as it should when things stack. I dropped and picked up both pistols and it keeps happening.
Which pistol I can see in my inventory and actually use depends on the order in which I picked them up: The first one I pick up is the one that appears in my inventory. The second won't appear until I drop the first one.
Has anyone seen this happen? I've never had 10mm pistols or other weapons stack like this before.