Fuzzing discovered that the test case below, when given as input to clang -fno-crash-diagnostics -std=c++11 -xc++ -c -emit-llvm causes this assertion failure: clang-3.6: tools/clang/lib/Sema/SemaLookup.cpp:1140: bool clang::Sema::CppLookupName(clang::LookupResult&, clang::Scope*): Assertion `Ctx->isFileContext() && "We should have been looking only at file context here already."' failed. Test case: -------------------------------------------------- class { template <typename I, I::(((; namespace { o --------------------------------------------------