blob: c940b16cdc3a0bfa2d0476e90c903040ea85a574 [file] [log] [blame]
Jean-Daniel Dupas1acbe5e2012-01-24 22:32:46 +00001// RUN: %clang_cc1 -x objective-c %s -fsyntax-only -verify
2
3#include <stdarg.h>
4
5void f1(id arg) {
Jean-Daniel Dupas5faf5d32012-01-27 23:21:02 +00006 NSLog(@"%@", arg); // expected-warning {{implicitly declaring library function 'NSLog' with type 'void (id, ...)'}} \
Jean-Daniel Dupas1acbe5e2012-01-24 22:32:46 +00007 // expected-note {{please include the header <Foundation/NSObjCRuntime.h> or explicitly provide a declaration for 'NSLog'}}
8}
9
10void f2(id str, va_list args) {
Jean-Daniel Dupas5faf5d32012-01-27 23:21:02 +000011 NSLogv(@"%@", args); // expected-warning {{implicitly declaring library function 'NSLogv' with type }} \
Jean-Daniel Dupas1acbe5e2012-01-24 22:32:46 +000012 // expected-note {{please include the header <Foundation/NSObjCRuntime.h> or explicitly provide a declaration for 'NSLogv'}}
13}