Fix use of "main" in gdb_index with C++
In commit
f283e80f (Fix use of "main" marker in gdb index), I changed
the DWARF reader to understand that the C language's "main" might
appear in the .gdb_index, and should not be ignored.
This week I realized that this same problem can affect C++ as well.
I'm not sure why I didn't consider this at the time.
This patch fixes the bug. It's somewhat of a hack, I guess, but also
at least understandable.
Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=33441