brintos

brintos / llvm-project-archived public Read only

0
0
Text · 558 B · aa38790 Raw
18 lines · cpp
1// RUN: %clang_cc1 -pedantic-errors -std=c++11 -emit-pch %s -o %t-cxx112// RUN: %clang_cc1 -pedantic-errors -std=c++11 -include-pch %t-cxx11 -verify %s3 4#ifndef HEADER_INCLUDED5 6#define HEADER_INCLUDED7typedef auto f() -> int;8typedef int g();9 10#else11 12typedef void f; // expected-error {{typedef redefinition with different types ('void' vs 'auto () -> int')}}13                // expected-note@7 {{here}}14typedef void g; // expected-error {{typedef redefinition with different types ('void' vs 'int ()')}}15                // expected-note@8 {{here}}16 17#endif18