I already know that it's unsafe to naively link g++4.4 c++98 object files with g++4.7 c++11 object files, but I see mixed opinions on the web about g++4.8. While the object file formats are mutually compatible, libstdc++
isn't, and in bad ways.
Is it safe to blindly link a g++4.4 -std=gnu++98 object file against another object file compiled with g++4.8 with -std=c++11 or -std=gnu++11? If so, why is it safe when doing the same with g++4.7 wasn't; furthermore, does this mean that g++4.7 with -std=c++11 is incompatible with g++4.8 with -std=c++11?
Copyright Notice:Content Author:「Mr Fooz」,Reproduced under the CC 4.0 BY-SA copyright license with a link to the original source and this disclaimer.
Link to original article:https://stackoverflow.com/questions/22713479/are-g4-4-c98-object-files-compatible-with-g4-8-c11