预定义符号,__FILE__, __LINE__, __DATE__, __TIME__, __STDC__

#include 
#define DEBUG_PRINT printf("Filename:%s Line: %d \
        Compiled Date and Time: %s %s, \
        ANSI is %s used\n",  __FILE__, __LINE__, \
        used__DATE__, __TIME__, __STDC__ == 1 ? "\b" : "not")
        //"\b" Backpace to replace the blank before "used"


int main ()
{
    
    DEBUG_PRINT;


    return 0;
}

你可能感兴趣的:(C,Language)