Try
#include <string.h>
#define __FILENAME__ (strrchr(__FILE__, "https://stackoverflow.com/") ? strrchr(__FILE__, "https://stackoverflow.com/") + 1 : __FILE__)
For Windows use ‘\\’ instead of “https://stackoverflow.com/”.
Try
#include <string.h>
#define __FILENAME__ (strrchr(__FILE__, "https://stackoverflow.com/") ? strrchr(__FILE__, "https://stackoverflow.com/") + 1 : __FILE__)
For Windows use ‘\\’ instead of “https://stackoverflow.com/”.