On Sat, 15 Jul 2023 at 14:02, gkourtis--- via Gcc-help <gcc-help@xxxxxxxxxxx> wrote: > > I think there is some sort of bug !!! > > When I compile throught gcc __seg_gs is visible, while if I use g++ it > is not !!! > > Should it be like that ? Enclosing code in extern "C" does not magically change the compiler to be a C compiler, it just tells the C++ compiler to use C-style symbol names and calling conventions for functions. It doesn't mean you can use features that are not supported by the C++ compiler, because you're still just compiling C++ code.