<html>
    <head>
      <base href="http://llvm.org/bugs/" />
    </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 --- - Assertion `Method->isCanonicalDecl() && Overridden->isCanonicalDecl()'"
   href="http://llvm.org/bugs/show_bug.cgi?id=20412">20412</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Assertion `Method->isCanonicalDecl() && Overridden->isCanonicalDecl()'
          </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>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>Modules
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>biancacristinacristescu@gmail.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>dgregor@apple.com, llvmbugs@cs.uiuc.edu
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr></table>
      <p>
        <div>
        <pre>The files to repreduce the error:
$ cat module_Gdml.map 
module stdlib [system] {
    header "tuple"
 }

module libGdml {
  header "header.h"
    use stdlib
  export *
}
--------------------------------------------------------------------------------
]$ cat header.h 
#include "exception"
#include "tuple"
--------------------------------------------------------------------------------
$ cat tuple 
#include "exception"

class logic_error : public exception {};
--------------------------------------------------------------------------------
$ cat exception 
class exception
{
public:
  virtual ~exception();
};
--------------------------------------------------------------------------------

The command to reproduce the error:
'/home/cristina/llvm-proj/inst-deb/bin/clang -cc1 -triple
x86_64-unknown-linux-gnu -E -disable-free -mrelocation-model static
-mdisable-fp-elim -fmath-errno -masm-verbose -mconstructor-aliases
-munwind-tables -fuse-init-array -target-cpu x86-64 -target-linker-version
2.23.52.20130913 -v -resource-dir
/home/cristina/llvm-proj/inst-deb/bin/../lib/clang/3.5.0 -internal-isystem
/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../../include/c++/4.8 -internal-isystem
/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../../include/c++/4.8/x86_64-linux-gnu
-internal-isystem
/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../../include/c++/4.8/backward
-internal-isystem
/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../../include/x86_64-linux-gnu/c++/4.8
-internal-isystem /usr/local/include -internal-isystem
/home/cristina/llvm-proj/inst-deb/bin/../lib/clang/3.5.0/include
-internal-externc-isystem /usr/include/x86_64-linux-gnu
-internal-externc-isystem /include -internal-externc-isystem /usr/include
-std=c++11 -fdeprecated-macro -fdebug-compilation-dir
/home/cristina/llvm-sources/clang-tiered-pcm-reproducer -ferror-limit 19
-fmessage-length 0 -mstackrealign -fobjc-runtime=gcc -fcxx-exceptions
-fexceptions -fdiagnostics-show-option -x c++ -fcolor-diagnostics -x c++
-std=c++11 -I/home/cristina/root/objOptimizations/include -fmodules
-fno-modules-global-index -fdisable-module-hash -fmodule-maps -emit-module
/home/cristina/root/objOptimizations/include/module_Gdml.map
-fmodules-cache-path=/home/cristina/llvm-sources/clang-tiered-pcm-reproducer/pcm
-fmodule-name=libGdml'

The message and the backtrace:
clang: /home/cristina/llvm-proj/llvm/tools/clang/lib/AST/ASTContext.cpp:1225:
void clang::ASTContext::addOverriddenMethod(const clang::CXXMethodDecl *, const
clang::CXXMethodDecl *): Assertion `Method->isCanonicalDecl() &&
Overridden->isCanonicalDecl()' failed.
0  clang           0x0000000003e2b74e llvm::sys::PrintStackTrace(_IO_FILE*) +
46
1  clang           0x0000000003e2ba1b
2  clang           0x0000000003e2ceda
3  libpthread.so.0 0x00007fc4710acbb0
4  libc.so.6       0x00007fc4702e9f77 gsignal + 55
5  libc.so.6       0x00007fc4702ed5e8 abort + 328
6  libc.so.6       0x00007fc4702e2d43
7  libc.so.6       0x00007fc4702e2df2
8  clang           0x000000000225b652
clang::ASTContext::addOverriddenMethod(clang::CXXMethodDecl const*,
clang::CXXMethodDecl const*) + 114
9  clang           0x0000000000bfe104
clang::ASTDeclReader::VisitCXXMethodDecl(clang::CXXMethodDecl*) + 180
10 clang           0x0000000000bfe2df
clang::ASTDeclReader::VisitCXXDestructorDecl(clang::CXXDestructorDecl*) + 47
11 clang           0x0000000000bdfa81
12 clang           0x0000000000bdf40a clang::ASTDeclReader::Visit(clang::Decl*)
+ 42
13 clang           0x0000000000c0c7b8 clang::ASTReader::ReadDeclRecord(unsigned
int) + 3128
14 clang           0x0000000000b7cf08 clang::ASTReader::GetDecl(unsigned int) +
184
15 clang           0x0000000000bcc800
16 clang           0x0000000000b8ab96
17 clang           0x0000000000ceb4e5
18 clang           0x0000000000ceb299
clang::serialization::ModuleManager::visitDepthFirst(bool
(*)(clang::serialization::ModuleFile&, bool, void*), void*) + 217
19 clang           0x0000000000b8a9f0
clang::ASTReader::FindExternalLexicalDecls(clang::DeclContext const*, bool
(*)(clang::Decl::Kind), llvm::SmallVectorImpl<clang::Decl*>&) + 128
20 clang           0x0000000000b8ac4f non-virtual thunk to
clang::ASTReader::FindExternalLexicalDecls(clang::DeclContext const*, bool
(*)(clang::Decl::Kind), llvm::SmallVectorImpl<clang::Decl*>&) + 63
21 clang           0x000000000237bbcc
22 clang           0x000000000237b988
clang::DeclContext::LoadLexicalDeclsFromExternalStorage() const + 184
23 clang           0x000000000237c6cf clang::DeclContext::decls_begin() const +
47
24 clang           0x0000000000d2482c
25 clang           0x0000000001207e45
26 clang           0x0000000002485400
27 clang           0x0000000002485285
clang::ASTContext::getCurrentKeyFunction(clang::CXXRecordDecl const*) + 245
28 clang           0x00000000010bf214 clang::Sema::ActOnEndOfTranslationUnit()
+ 356
29 clang           0x0000000000fee5a5
clang::Parser::ParseTopLevelDecl(clang::OpaquePtr<clang::DeclGroupRef>&) + 565
30 clang           0x0000000000fe9c2d clang::ParseAST(clang::Sema&, bool, bool)
+ 557
31 clang           0x00000000009b9c2e clang::ASTFrontendAction::ExecuteAction()
+ 334
32 clang           0x00000000009b9488 clang::FrontendAction::Execute() + 120
33 clang           0x0000000000978ae1
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 785
34 clang           0x000000000092f34e
clang::ExecuteCompilerInvocation(clang::CompilerInstance*) + 1038
35 clang           0x0000000000917fae cc1_main(char const**, char const**, char
const*, void*) + 702
36 clang           0x0000000000927a17 main + 807
37 libc.so.6       0x00007fc4702d4de5 __libc_start_main + 245
38 clang           0x0000000000917c24
Stack dump:
0.    Program arguments: /home/cristina/llvm-proj/inst-deb/bin/clang -cc1
-triple x86_64-unknown-linux-gnu -E -disable-free -mrelocation-model static
-mdisable-fp-elim -fmath-errno -masm-verbose -mconstructor-aliases
-munwind-tables -fuse-init-array -target-cpu x86-64 -target-linker-version
2.23.52.20130913 -v -resource-dir
/home/cristina/llvm-proj/inst-deb/bin/../lib/clang/3.5.0 -internal-isystem
/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../../include/c++/4.8 -internal-isystem
/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../../include/c++/4.8/x86_64-linux-gnu
-internal-isystem
/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../../include/c++/4.8/backward
-internal-isystem
/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../../include/x86_64-linux-gnu/c++/4.8
-internal-isystem /usr/local/include -internal-isystem
/home/cristina/llvm-proj/inst-deb/bin/../lib/clang/3.5.0/include
-internal-externc-isystem /usr/include/x86_64-linux-gnu
-internal-externc-isystem /include -internal-externc-isystem /usr/include
-std=c++11 -fdeprecated-macro -fdebug-compilation-dir
/home/cristina/llvm-sources/clang-tiered-pcm-reproducer -ferror-limit 19
-fmessage-length 0 -mstackrealign -fobjc-runtime=gcc -fcxx-exceptions
-fexceptions -fdiagnostics-show-option -x c++ -fcolor-diagnostics -x c++
-std=c++11 -I/home/cristina/root/objOptimizations/include -fmodules
-fno-modules-global-index -fdisable-module-hash -fmodule-maps -emit-module
/home/cristina/root/objOptimizations/include/module_Gdml.map
-fmodules-cache-path=/home/cristina/llvm-sources/clang-tiered-pcm-reproducer/pcm
-fmodule-name=libGdml 
1.    <eof> parser at end of file
Aborted</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>