<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 - Invalid compiler error: bug.cpp:38:88: error: 'Header' does not refer to a value"
   href="https://bugs.llvm.org/show_bug.cgi?id=33723">33723</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Invalid compiler error: bug.cpp:38:88: error: 'Header' does not refer to a value
          </td>
        </tr>

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

        <tr>
          <th>Version</th>
          <td>3.6
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>Other
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Linux
          </td>
        </tr>

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

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

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

        <tr>
          <th>Component</th>
          <td>Frontend
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>zosrothko@orange.fr
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="attachment.cgi?id=18768" name="attach_18768" title="The c++ source code">attachment 18768</a> <a href="attachment.cgi?id=18768&action=edit" title="The c++ source code">[details]</a></span>
The c++ source code

Hi
>From my understanding, the bug.cpp source code joined as attachment should
compile without any error as gcc-5.4.0 compiles it without error.

Below the clang compiler's log
fandre@ubuntu-trusty-64:/mnt/shared/poco-c++11/Net$ clang++-3.6 -stdlib=libc++
bug.cpp -std=c++11
bug.cpp:39:88: error: 'Header' does not refer to a value
 typedef poco_static_assert_test<sizeof(POCO_STATIC_ASSERTION_FAILURE<(bool)
(offsetof(Header, code) == 0x01)>)> poco_static_assert...
                                                                               
       ^
bug.cpp:28:9: note: declared here
 struct Header
        ^
bug.cpp:39:96: error: use of undeclared identifier 'code'
 typedef poco_static_assert_test<sizeof(POCO_STATIC_ASSERTION_FAILURE<(bool)
(offsetof(Header, code) == 0x01)>)> poco_static_assert...
                                                                               
               ^
bug.cpp:39:111: error: type name requires a specifier or qualifier
 typedef poco_static_assert_test<sizeof(POCO_STATIC_ASSERTION_FAILURE<(bool)
(offsetof(Header, code) == 0x01)>)> poco_static_assert...
                                                                               
                              ^
bug.cpp:40:88: error: 'Header' does not refer to a value
 typedef poco_static_assert_test<sizeof(POCO_STATIC_ASSERTION_FAILURE<(bool)
(offsetof(Header, checksum) == 0x02)>)> poco_static_as...
                                                                               
       ^
bug.cpp:28:9: note: declared here
 struct Header


Below the gcc-5.4.1 log
fandre@ubuntu-trusty-64:/mnt/shared/poco-c++11/Net$ g++ bug.cpp -std=c++11 -c
fandre@ubuntu-trusty-64:/mnt/shared/poco-c++11/Net$
fandre@ubuntu-trusty-64:/mnt/shared/poco-c++11/Net$ g++ --version
g++ (Ubuntu 5.4.1-2ubuntu1~14.04) 5.4.1 20160904
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

fandre@ubuntu-trusty-64:/mnt/shared/poco-c++11/Net$ clang-3.6 --version
Ubuntu clang version 3.6.0-2ubuntu1~trusty1 (tags/RELEASE_360/final) (based on
LLVM 3.6.0)
Target: x86_64-pc-linux-gnu
Thread model: posix</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>