Created
February 11, 2014 14:31
-
-
Save wanabe/8935856 to your computer and use it in GitHub Desktop.
count function in-out
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #define COUNT_INOUT(type, ret, name, _args, args_raw) \ | |
| static int name##_count;\ | |
| type inline __##name _args;\ | |
| type name _args {\ | |
| int aaaa = ++name##_count;\ | |
| fprintf(stderr, "" #name " >> %06i\n", aaaa);fflush(stderr);\ | |
| ret retval = __##name args_raw;\ | |
| fprintf(stderr, "" #name " << %06i\n", aaaa);fflush(stderr);\ | |
| return retval;\ | |
| }\ | |
| type inline __##name _args |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment