You have to consider not just the damage per mag but the DPS as well. As the Longarms have the second slowest fire rate in the game. Only beating the Railgun by 10 rpm
Comparing the Longarm 8 and the EM Rifle 8:
The EM Rifle 8 deals 22,907 per shot/mag at its base level
The Longarm 8 deals 8,023/40,115 per shot/mag at 4* Lvl 6 (The closest I have to 5*, so you could consider a 5% increase in damage from my calculations here)
Though on paper the Longarm looks like it is far more effective, its fire rate of 60 rpm means you will only get one of those shots per second, which makes its competition far more effective at catching other snipers as it deals its double damage twice as often as the longarms apply overheat.
Additionally, the low fire rate means that to get all of your shots, and to get the weapon reloaded takes 17 seconds without implants, for a DPS of 2,359 assuming no overheat.
The EM Rifles take ~2 seconds to fire their shot after the fire button is pressed, leading for a total of 7.3 seconds to fully reload, or a total of 3,138 DPS assuming you low-roll.
This makes the EM Rifles still better at killing Surges and Killshots on reaction, with the Railguns being the only real competition for that spot in theory due to the latter having no shot delay and double the damage per shot of the Longarms.