This is a live mirror of the Perl 5 development currently hosted at
https://github.com/perl/perl5
https://perl5.git.perl.org
/
perl5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
4aaab43
)
Tweak the cBOOL() macro to avoid problems with the AIX compiler.
author
Nicholas Clark
<nick@ccl4.org>
Tue, 15 Nov 2011 18:44:18 +0000
(19:44 +0100)
committer
Steve Hay
<steve.m.hay@googlemail.com>
Fri, 18 Nov 2011 23:58:09 +0000
(23:58 +0000)
(cherry picked from commit
0cebf65582f924952bfee1472749d442d51e43e6
)
handy.h
patch
|
blob
|
blame
|
history
diff --git
a/handy.h
b/handy.h
index
2c2311a
..
8777644
100644
(file)
--- a/
handy.h
+++ b/
handy.h
@@
-115,9
+115,10
@@
Null SV pointer. (No longer available when C<PERL_CORE> is defined.)
/* a simple (bool) cast may not do the right thing: if bool is defined
* as char for example, then the cast from int is implementation-defined
+ * (bool)!!(cbool) in a ternary triggers a bug in xlc on AIX
*/
-#define cBOOL(cbool) ((
bool)!!(cbool)
)
+#define cBOOL(cbool) ((
cbool) ? (bool)1 : (bool)0
)
/* Try to figure out __func__ or __FUNCTION__ equivalent, if any.
* XXX Should really be a Configure probe, with HAS__FUNCTION__