I picked it up yesterday along with some vintage TF stuff, actually fits in a TF fist but I don't recognize it.
i couldn't find it off hand, but if it's a TF gun go here and search: http://www.transformerland.com/ if it's a gi joe gun uit'l be here: http://www.yojoe.com
the handle tells me it is not a transformers gun, because it has those groves in it, transformer guns normally don't, that is normally a sign of it being from an action figure, probably Gi Joe, or could be 1000's of other action figures too.
This piece is an X-Men gun. It looks like one of the blasters that came with the 6" version of Bishop. (The 10" ones have the barrels painted orange.) If it isn't Bishop's, then I suggest looking into characters from the gun-happy, Liefeldian X-Force sub-line.