brintos

brintos / llvm-project-archived public Read only

0
0
Text · 714 B · ce964a7 Raw
27 lines · c
1// RUN: %clang_cc1 -triple x86_64 -emit-llvm -disable-llvm-passes -o - %s | FileCheck %s2//3// Verifies that clang-generated *.inline are removed when shadowed by an4// external definition, even when that definition appears at the end of the5// file.6 7// CHECK-NOT: strlen.inline8 9extern unsigned long strlen(char const *s);10 11extern __inline __attribute__((__always_inline__)) __attribute__((__gnu_inline__)) unsigned long strlen(char const *s) {12  return 1;13}14 15static unsigned long chesterfield(char const *s) {16  return strlen(s);17}18static unsigned long (*_strlen)(char const *ptr);19 20unsigned long blutch(char const *s) {21  return chesterfield(s);22}23 24unsigned long strlen(char const *s) {25  return _strlen(s);26}27