31 lines · cpp
1// RUN: %clang_cc1 -mllvm -emptyline-comment-coverage=false -triple %itanium_abi_triple -fprofile-instrument=clang -fcoverage-mapping -dump-coverage-mapping -emit-llvm-only %s | FileCheck %s2 3// PR399424 5class a;6template <class b> a &operator<<(b &, const char *);7int c;8#define d(l) l(__FILE__, __LINE__, c)9#define COMPACT_GOOGLE_LOG_ERROR d(e)10#define f(g, cond) cond ? (void)0 : h() & g11#define i(j) COMPACT_GOOGLE_LOG_##j.g()12#define k(j) f(i(j), 0)13class e {14public:15 e(const char *, int, int);16 a &g();17};18class h {19public:20 void operator&(a &);21};22void use_str(const char *);23 24#define m(func) \25 use_str(#func); \26 k(ERROR) << #func; \27 return 0; // CHECK: File 1, [[@LINE-1]]:4 -> [[@LINE-1]]:16 = (#0 - #1)28int main() {29 m(asdf);30}31