This is actually a fluke, I discovered this through a friend, he told me to die during the "up, up and away" mission in the ones you have to do to heist Caligula's casino.
First you have to be the boyfriend of katie so when you die you don't lose you weapons
SecondDo the mission normally, ok when you're near the cargo chopper and have to take out the enemy choppers that try to kill you, leave the soldier beside the minigun alive, now man the minigun, and let the soldier kill you and when you wake up at the hospital you'll have a infinite minigun.
P.S. I don't know if this work on other weapons, but if you try and suceed let me know ok.