1*f4a2713aSLionel Sambuc // RUN: %clang_cc1 %s -verify -fsyntax-only -pedantic 2*f4a2713aSLionel Sambuc // RUN: %clang_cc1 %s -verify -fsyntax-only -x c++ -pedantic 3*f4a2713aSLionel Sambuc 4*f4a2713aSLionel Sambuc // This file contains UTF-8; please do not fix! 5*f4a2713aSLionel Sambuc 6*f4a2713aSLionel Sambuc 7*f4a2713aSLionel Sambuc extern void \u00FCber(int); 8*f4a2713aSLionel Sambuc extern void \U000000FCber(int); // redeclaration, no warning 9*f4a2713aSLionel Sambuc #ifdef __cplusplus 10*f4a2713aSLionel Sambuc // expected-note@-2 + {{candidate function not viable}} 11*f4a2713aSLionel Sambuc #else 12*f4a2713aSLionel Sambuc // expected-note@-4 + {{declared here}} 13*f4a2713aSLionel Sambuc #endif 14*f4a2713aSLionel Sambuc goodCalls()15*f4a2713aSLionel Sambucvoid goodCalls() { 16*f4a2713aSLionel Sambuc \u00FCber(0); 17*f4a2713aSLionel Sambuc \u00fcber(1); 18*f4a2713aSLionel Sambuc über(2); 19*f4a2713aSLionel Sambuc \U000000FCber(3); 20*f4a2713aSLionel Sambuc } 21*f4a2713aSLionel Sambuc badCalls()22*f4a2713aSLionel Sambucvoid badCalls() { 23*f4a2713aSLionel Sambuc \u00FCber(0.5); // expected-warning{{implicit conversion from 'double' to 'int'}} 24*f4a2713aSLionel Sambuc \u00fcber = 0; // expected-error{{non-object type 'void (int)' is not assignable}} 25*f4a2713aSLionel Sambuc 26*f4a2713aSLionel Sambuc über(1, 2); 27*f4a2713aSLionel Sambuc \U000000FCber(); 28*f4a2713aSLionel Sambuc #ifdef __cplusplus 29*f4a2713aSLionel Sambuc // expected-error@-3 {{no matching function}} 30*f4a2713aSLionel Sambuc // expected-error@-3 {{no matching function}} 31*f4a2713aSLionel Sambuc #else 32*f4a2713aSLionel Sambuc // expected-error@-6 {{too many arguments to function call, expected 1, have 2}} 33*f4a2713aSLionel Sambuc // expected-error@-6 {{too few arguments to function call, expected 1, have 0}} 34*f4a2713aSLionel Sambuc #endif 35*f4a2713aSLionel Sambuc } 36