Files
clang-p2996/clang/test/CodeGenCXX/forward-enum.cpp
Douglas Gregor 4f283c8b20 For the purposes of building LLVM types, a forward-declared
enumeration type with a fixed underlying type is complete. Fixes
<rdar://problem/10916155>.

llvm-svn: 151403
2012-02-24 22:40:36 +00:00

12 lines
273 B
C++

// RUN: %clang_cc1 -std=c++11 -triple x86_64-apple-darwin11.0.0 -emit-llvm -o - %s | FileCheck %s
enum MyEnum : char;
void bar(MyEnum value) { }
// CHECK: define void @_Z3foo6MyEnum
void foo(MyEnum value)
{
// CHECK: call void @_Z3bar6MyEnum(i8 signext
bar(value);
}