<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - clang-cl incorrectly defines __cpp_rtti when /GR- is specified"
   href="https://bugs.llvm.org/show_bug.cgi?id=46230">46230</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>clang-cl incorrectly defines __cpp_rtti when /GR- is specified
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>clang
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>trunk
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Windows NT
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>enhancement
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Driver
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedclangbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>zufuliu@163.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org, neeilans@live.com, richard-llvm@metafoo.co.uk
          </td>
        </tr></table>
      <p>
        <div>
        <pre>// test-rtti.cpp
#ifdef __cpp_rtti
#warning __cpp_rtti defined
#endif
#ifdef _CPPRTTI
#warning _CPPRTTI defined
#endif

tested llvm 10, and 693ff89f47ffe1f357ddd3a5112cd90eb8b3e2d1

clang-cl -c /GR- test-rtti.cpp
test-rtti.cpp(2,2): warning: __cpp_rtti defined [-W#warnings]
#warning __cpp_rtti defined
 ^
1 warning generated.

clang-cl -c /GR test-rtti.cpp
test-rtti.cpp(2,2): warning: __cpp_rtti defined [-W#warnings]
#warning __cpp_rtti defined
 ^
test-rtti.cpp(5,2): warning: _CPPRTTI defined [-W#warnings]
#warning _CPPRTTI defined
 ^
2 warnings generated.

clang -c -frtti test-rtti.cpp
test-rtti.cpp:2:2: warning: __cpp_rtti defined [-W#warnings]
#warning __cpp_rtti defined
 ^
test-rtti.cpp:5:2: warning: _CPPRTTI defined [-W#warnings]
#warning _CPPRTTI defined
 ^
2 warnings generated.

clang -c -fno-rtti test-rtti.cpp
// expected, neither is defined.</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>