diff options
author | Nicholas Clark <nick@ccl4.org> | 2006-02-04 11:10:52 +0000 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2006-02-04 11:10:52 +0000 |
commit | 78db725db76314f0edb7f2ab8770841118d8ad2e (patch) | |
tree | e61ef30d8a076f918b29c97aaeb79e59a640c76a /warnings.pl | |
parent | e8121b0d0efcf7b0d99f3775e307861be34d07a2 (diff) | |
download | perl-78db725db76314f0edb7f2ab8770841118d8ad2e.tar.gz |
warnings.h does some evil(*) pointer arithmetic on (SV *)0, so a
simple replace of Nullsv with NULL turns out to be a bad idea.
* Technically undefined behaviour, I believe.
p4raw-id: //depot/perl@27078
Diffstat (limited to 'warnings.pl')
-rw-r--r-- | warnings.pl | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/warnings.pl b/warnings.pl index e8971d852b..126597291a 100644 --- a/warnings.pl +++ b/warnings.pl @@ -277,8 +277,8 @@ print WARN <<'EOM' ; #define G_WARN_ALL_MASK (G_WARN_ALL_ON|G_WARN_ALL_OFF) #define pWARN_STD NULL -#define pWARN_ALL (NULL+1) /* use warnings 'all' */ -#define pWARN_NONE (NULL+2) /* no warnings 'all' */ +#define pWARN_ALL (((SV*)0)+1) /* use warnings 'all' */ +#define pWARN_NONE (((SV*)0)+2) /* no warnings 'all' */ #define specialWARN(x) ((x) == pWARN_STD || (x) == pWARN_ALL || \ (x) == pWARN_NONE) |