redefine_extname.cpp revision b6d6993e6e6d3daf4d9876794254d20a134e37c2
1// RUN: %clang_cc1 -triple=i386-pc-solaris2.11 -w -emit-llvm %s -o - | FileCheck %s
2
3extern "C" {
4  struct statvfs64 {
5    int f;
6  };
7#pragma redefine_extname statvfs64 statvfs
8  int statvfs64(struct statvfs64 *);
9}
10
11void foo() {
12  struct statvfs64 st;
13  statvfs64(&st);
14// Check that even if there is a structure with redefined name before the
15// pragma, subsequent function name redefined properly. PR5172, Comment 11.
16// CHECK:  call i32 @statvfs(%struct.statvfs64* %st)
17}
18
19