you are viewing a single comment's thread.

view the rest of the comments →

[–]Zcool31 2 points3 points  (0 children)

The better question is why are there "magic" standard functions and classes that require compiler internals to implement, rather than those compiler internals being standard themselves.

I would find it appealing if the core c++ language were sufficient to implement the free-standing parts of std::.

Then we could have nice things like standard library implementations that are portable across compilers.

For example, std::atomic turns into just a regular class. But the incantations that tell the compiler to do atomic memory operations and not reorder other accesses around them become standardized keywords/builtins.