Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
# define ALog(format, ...) NSLog((@"%s [L%d] " format), __PRETTY_FUNCTION__, __LINE__, ##__VA_ARGS__);
# ifdef DEBUG
# define DLog(format, ...) ALog(format, ##__VA_ARGS__);
# else
# define DLog(...)
# endif
@favormm

This comment has been minimized.

Copy link

@favormm favormm commented Sep 26, 2013

NSString *test = @"test";
DLog(test);

This code are not work.

@mdziadkowiec

This comment has been minimized.

Copy link

@mdziadkowiec mdziadkowiec commented Sep 29, 2013

You should use:
NSString *test = @"test";
DLog(@"test = %@", test);

First argument is format.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment