<i id='LHGPN'><tr id='LHGPN'><dt id='LHGPN'><q id='LHGPN'><span id='LHGPN'><b id='LHGPN'><form id='LHGPN'><ins id='LHGPN'></ins><ul id='LHGPN'></ul><sub id='LHGPN'></sub></form><legend id='LHGPN'></legend><bdo id='LHGPN'><pre id='LHGPN'><center id='LHGPN'></center></pre></bdo></b><th id='LHGPN'></th></span></q></dt></tr></i><div id='LHGPN'><tfoot id='LHGPN'></tfoot><dl id='LHGPN'><fieldset id='LHGPN'></fieldset></dl></div>

    <legend id='LHGPN'><style id='LHGPN'><dir id='LHGPN'><q id='LHGPN'></q></dir></style></legend>
    • <bdo id='LHGPN'></bdo><ul id='LHGPN'></ul>

        <small id='LHGPN'></small><noframes id='LHGPN'>

      1. <tfoot id='LHGPN'></tfoot>

        C++ 中何时引入了“and"和“or"替代标记?

        时间:2023-08-26
          <bdo id='nU2k6'></bdo><ul id='nU2k6'></ul>

          <small id='nU2k6'></small><noframes id='nU2k6'>

          <legend id='nU2k6'><style id='nU2k6'><dir id='nU2k6'><q id='nU2k6'></q></dir></style></legend>

                  <tbody id='nU2k6'></tbody>
              • <tfoot id='nU2k6'></tfoot>

                1. <i id='nU2k6'><tr id='nU2k6'><dt id='nU2k6'><q id='nU2k6'><span id='nU2k6'><b id='nU2k6'><form id='nU2k6'><ins id='nU2k6'></ins><ul id='nU2k6'></ul><sub id='nU2k6'></sub></form><legend id='nU2k6'></legend><bdo id='nU2k6'><pre id='nU2k6'><center id='nU2k6'></center></pre></bdo></b><th id='nU2k6'></th></span></q></dt></tr></i><div id='nU2k6'><tfoot id='nU2k6'></tfoot><dl id='nU2k6'><fieldset id='nU2k6'></fieldset></dl></div>

                  本文介绍了C++ 中何时引入了“and"和“or"替代标记?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  我刚刚从 Reddit 上读到了这篇不错的文章.

                  I've just read this nice piece from Reddit.

                  他们提到 andor&&||

                  They mention and and or being "Alternative Tokens" to && and ||

                  直到现在我才真正意识到这些.当然,每个人都知道二图和三图,但是?从何时起?这是标准的最新补充吗?

                  I was really unaware of these until now. Of course, everybody knows about the di-graphs and tri-graphs, but and and or? Since when? Is this a recent addition to the standard?

                  我刚刚使用 Visual C++ 2008 对其进行了检查,它似乎除了语法错误之外没有将这些识别为任何其他内容.怎么回事?

                  I've just checked it with Visual C++ 2008 and it doesn't seem to recognize these as anything other than a syntax error. What's going on?

                  推荐答案

                  MSVC 仅在您使用 /Za 选项禁用扩展时才支持它们作为关键字;至少在 VC7.1 (VS2003) 中确实如此.

                  MSVC supports them as keywords only if you use the /Za option to disable extensions; this is true from at least VC7.1 (VS2003).

                  您可以通过包含 iso646.h 将它们支持为宏.

                  You can get them supported as macros by including iso646.h.

                  我的猜测是,他们认为默认使用关键字会破坏太多现有代码(如果他们是对的,我不会感到惊讶).

                  My guess is they believe that making them keywords by default would break too much existing code (and I wouldn't be surprised if they are right).

                  几周前在 SO 某处的某个问题中讨论了这一点,但我无法通过 SO 的搜索或 Google 找到该死的东西.

                  This was discussed in a question a couple weeks ago somewhere here on SO, but I can't get SO's search or Google to find the damn thing.

                  这篇关于C++ 中何时引入了“and"和“or"替代标记?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  上一篇:C++ 是上下文无关的还是上下文敏感的? 下一篇:以零开头的数字有什么特别之处?

                  相关文章

                  <tfoot id='mg11s'></tfoot>

                  <legend id='mg11s'><style id='mg11s'><dir id='mg11s'><q id='mg11s'></q></dir></style></legend>

                  <small id='mg11s'></small><noframes id='mg11s'>

                    <i id='mg11s'><tr id='mg11s'><dt id='mg11s'><q id='mg11s'><span id='mg11s'><b id='mg11s'><form id='mg11s'><ins id='mg11s'></ins><ul id='mg11s'></ul><sub id='mg11s'></sub></form><legend id='mg11s'></legend><bdo id='mg11s'><pre id='mg11s'><center id='mg11s'></center></pre></bdo></b><th id='mg11s'></th></span></q></dt></tr></i><div id='mg11s'><tfoot id='mg11s'></tfoot><dl id='mg11s'><fieldset id='mg11s'></fieldset></dl></div>
                      • <bdo id='mg11s'></bdo><ul id='mg11s'></ul>