// RUN: %clang_cc1 -triple i386-pc-linux -emit-llvm %s -o - | FileCheck -check-prefix GCABI %s
// RUN: %clang_cc1 -emit-llvm %s -o - -DMS_ABI -triple=i386-pc-win32 | FileCheck -check-prefix MSABI %s
// Test that it's OK to have multiple function declarations with the default CC
// both mentioned explicitly and implied.
void ;
void __cdecl ;
void __cdecl
// GCABI-LABEL: define{{.*}} void @_Z3foov()
// MSABI: define dso_local void @"?foo@@YAXXZ"
void __cdecl ;
void ;
void
// GCABI-LABEL: define{{.*}} void @_Z3barv()
// MSABI: define dso_local void @"?bar@@YAXXZ"
// Test that it's OK to mark either the method declaration or method definition
// with a default CC explicitly.
;
void METHOD_CC
// GCABI-LABEL: define{{.*}} void @_ZN1A3bazEv
// MSABI: define dso_local x86_thiscallcc void @"?baz@A@@QAEXXZ"
void
// GCABI-LABEL: define{{.*}} void @_ZN1A3quxEv
// MSABI: define dso_local x86_thiscallcc void @"?qux@A@@QAEXXZ"
void __cdecl
// GCABI-LABEL: define{{.*}} void @_Z10static_bazv
// MSABI: define dso_local void @"?static_baz@@YAXXZ"
void
// GCABI-LABEL: define{{.*}} void @_Z10static_quxv
// MSABI: define dso_local void @"?static_qux@@YAXXZ"