Maybe the consequences are not as serious as you were led to believe.
When you were a kid and you started chewing gum, your parents probably told you not to swallow it because it was going to stay in your stomach for years. But surely among those beliefs as a child you came to think that if you ate the bones of some fruit, they would begin to germinate in your stomach.
Just like those examples, there are many other myths. However, chewing gum will not stay in the stomach for more than a week. It is true that it is made with a non-digestible synthetic substance, but the stomach periodically empties its contents into the small intestine, so it will then go to the colon and pass to the stool.
In conclusion: nothing happens if you occasionally swallow the gum by accident, but be careful, as you could have intestinal problems if the action is repeated frequently.