Skip to content

Commit 5a1873d

Browse files
committed
Merge branch 'baagaard/feature-journal-func'
* baagaard/feature-journal-func: Fix preprocessor code for detecting name of function.
2 parents 99e969a + 1a29106 commit 5a1873d

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

journal/macros.h

+10-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,16 @@
2121
* __HERE__ has to be a preprocessor macro
2222
*/
2323

24-
#if defined(HAVE__FUNC__)
24+
#undef __FUNCTION__
25+
#if defined(__FUNCTION_NAME__)
26+
#define __FUNCTION__ __FUNCTION_NAME__
27+
#else
28+
#if defined(__func__)
29+
#define __FUNCTION__ __func__
30+
#endif
31+
#endif
32+
33+
#if defined(__FUNCTION__)
2534
#define __HERE__ __FILE__,__LINE__,__FUNCTION__
2635
#define __HERE_ARGS__ filename, lineno, funcname
2736
#define __HERE_DECL__ const char * filename, long lineno, const char * funcname

setup.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
setup(
1616

1717
name = 'pythia',
18-
version = '0.8.1.17',
18+
version = '0.8.1.18',
1919

2020
scripts = ['bin/idd.py', 'bin/ipad.py', 'bin/journald.py'],
2121

0 commit comments

Comments
 (0)