objective c - iOS: CocoaLumberjack: implicit declaration of function is invalid in c99 -


i'm trying implement cocoalumberjack on app framework i'm having issues. here implementation on appdelegate.h:

#import "appdelegate.h" #import <cocoalumberjack/cocoalumberjack.h> - (bool)application:(uiapplication *)application didfinishlaunchingwithoptions:(nsdictionary *)launchoptions {     [ddlog addlogger:[ddasllogger sharedinstance]];     [ddlog addlogger:[ddttylogger sharedinstance]];     ddfilelogger *filelogger = [[ddfilelogger alloc] init];     filelogger.maximumfilesize = 1024 * 1024;     filelogger.rollingfrequency = 60 * 60 * 24; // 24 hour rolling     filelogger.logfilemanager.maximumnumberoflogfiles = 7;     [ddlog addlogger:filelogger];     ddlogwarn(@"blablabla");     ddlogerror(@"broken sprocket detected!");     ddlogverbose(@"user selected file:%@ withsize:%u", @"temp/test/log.txt", 100000);     return yes; } 

in app delegate has no issues. in viewcontroller:

- (void)viewdidload {     [super viewdidload];      ddlogerror(@"something when wrong!!!"); // <-- implicit declaration of function invalid in c99 } 

implicit declaration of function invalid in c99 of knows wrong or work around error?

i'll appreciate help.

add following lines:

#define log_level_def ddloglevel #import <cocoalumberjack/cocoalumberjack.h> 

see access , configure framework section of getting started documentation.


Comments

Popular posts from this blog

How to put a lock and transaction on table using spring 4 or above using jdbcTemplate and annotations like @Transactional? -

c# - Update a combobox from a presenter (MVP) -

How to understand 2 main() functions after using uftrace to profile the C++ program? -