Are there any long-term side-effects of general anesthesia, such as memory loss or dementia?

Possible. Very rare but I have seen patients where this has happened - get a consult with aneurologist.
Yes. This happens infrequently and most patients aren't specifically warned about the dangers of this occurring, even though they have to sign an informed consent prior to surgery. When memory problems occur, they are more likely to be short-term memory problems, not so much long-term. Signs of this are frequent repetitions of things already said, or frequent questions about things just answered.