Did anybody consider adding a language pragma to C++?

Interesting question.

Did anybody consider adding a language pragma to C++?

From the article:

For people who don't know, language pragmas are the way that ghc (Glasgow Haskell Compiler) allows you to turn on and off language features. In C++, this would mean that I can write something like:

#language <no_c_style_cast>

And that would disable C-style cast for that source file. Don't you think that it would be useful to standardize this to allow people to willingly disable some old legacy C++ features in newer code?

Add a Comment

Comments are closed.

Comments (0)

There are currently no comments on this entry.