brintos

brintos / llvm-project-archived public Read only

0
0
Text · 412 B · a9a2b79 Raw
15 lines · cpp
1// RUN: %clang_cc1 -std=c++17 -fsyntax-only %s2 3// Verify that ASTContext::getFunctionTypeWithExceptionSpec (called through4// ASTContext::hasSameFunctionTypeIgnoringExceptionSpec from5// ExprEvaluatorBase::handleCallExpr in lib/AST/ExprConstant.cpp) does not crash6// for a type alias.7 8constexpr int f() noexcept { return 0; }9 10using F = int();11 12constexpr int g(F * p) { return p(); }13 14constexpr int n = g(f);15