This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Bring Pod::Simple up to 3.10
[perl5.git] / handy.h
diff --git a/handy.h b/handy.h
index 9e8f50a..9ec64e0 100644 (file)
--- a/handy.h
+++ b/handy.h
@@ -190,8 +190,13 @@ typedef U64TYPE U64;
 #               define INT64_C(c)      CAT2(c,L)
 #               define UINT64_C(c)     CAT2(c,UL)
 #           else
-#               define INT64_C(c)      ((I64TYPE)(c))
-#               define UINT64_C(c)     ((U64TYPE)(c))
+#               if defined(_WIN64) && defined(_MSC_VER)
+#                   define INT64_C(c)  CAT2(c,I64)
+#                   define UINT64_C(c) CAT2(c,UI64)
+#               else
+#                   define INT64_C(c)  ((I64TYPE)(c))
+#                   define UINT64_C(c) ((U64TYPE)(c))
+#               endif
 #           endif
 #       endif
 #   endif
@@ -557,7 +562,6 @@ US-ASCII (Basic Latin) range are viewed as not having any case.
 #define isDIGIT_uni(c)         is_uni_digit(c)
 #define isUPPER_uni(c)         is_uni_upper(c)
 #define isLOWER_uni(c)         is_uni_lower(c)
-#define isALNUMC_uni(c)                is_uni_alnumc(c)
 #define isASCII_uni(c)         is_uni_ascii(c)
 #define isCNTRL_uni(c)         is_uni_cntrl(c)
 #define isGRAPH_uni(c)         is_uni_graph(c)
@@ -579,7 +583,6 @@ US-ASCII (Basic Latin) range are viewed as not having any case.
 #define isDIGIT_LC_uvchr(c)    (c < 256 ? isDIGIT_LC(c) : is_uni_digit_lc(c))
 #define isUPPER_LC_uvchr(c)    (c < 256 ? isUPPER_LC(c) : is_uni_upper_lc(c))
 #define isLOWER_LC_uvchr(c)    (c < 256 ? isLOWER_LC(c) : is_uni_lower_lc(c))
-#define isALNUMC_LC_uvchr(c)   (c < 256 ? isALNUMC_LC(c) : is_uni_alnumc_lc(c))
 #define isCNTRL_LC_uvchr(c)    (c < 256 ? isCNTRL_LC(c) : is_uni_cntrl_lc(c))
 #define isGRAPH_LC_uvchr(c)    (c < 256 ? isGRAPH_LC(c) : is_uni_graph_lc(c))
 #define isPRINT_LC_uvchr(c)    (c < 256 ? isPRINT_LC(c) : is_uni_print_lc(c))
@@ -598,7 +601,6 @@ US-ASCII (Basic Latin) range are viewed as not having any case.
 #define isDIGIT_utf8(p)                is_utf8_digit(p)
 #define isUPPER_utf8(p)                is_utf8_upper(p)
 #define isLOWER_utf8(p)                is_utf8_lower(p)
-#define isALNUMC_utf8(p)       is_utf8_alnumc(p)
 #define isASCII_utf8(p)                is_utf8_ascii(p)
 #define isCNTRL_utf8(p)                is_utf8_cntrl(p)
 #define isGRAPH_utf8(p)                is_utf8_graph(p)
@@ -761,7 +763,7 @@ PoisonWith(0xEF) for catching access to freed memory.
  * which more importantly get the immediate calling environment (file and
  * line number, and C function name if available) passed in.  This info can
  * then be used for logging the calls, for which one gets a sample
- * implementation if PERL_MEM_LOG_STDERR is defined.
+ * implementation unless -DPERL_MEM_LOG_NOIMPL is also defined.
  *
  * Known problems:
  * - all memory allocs do not get logged, only those
@@ -783,6 +785,8 @@ PoisonWith(0xEF) for catching access to freed memory.
  *   (keyed by the allocation address?), and maintain that
  *   through reallocs and frees, but how to do that without
  *   any News() happening...?
+ * - lots of -Ddefines to get useful/controllable output
+ * - lots of ENV reads
  */
 
 PERL_EXPORT_C Malloc_t Perl_mem_log_alloc(const UV n, const UV typesize, const char *type_name, Malloc_t newalloc, const char *filename, const int linenumber, const char *funcname);
@@ -792,7 +796,7 @@ PERL_EXPORT_C Malloc_t Perl_mem_log_realloc(const UV n, const UV typesize, const
 PERL_EXPORT_C Malloc_t Perl_mem_log_free(Malloc_t oldalloc, const char *filename, const int linenumber, const char *funcname);
 
 # ifdef PERL_CORE
-#  ifdef PERL_MEM_LOG_STDERR
+#  ifndef PERL_MEM_LOG_NOIMPL
 enum mem_log_type {
   MLT_ALLOC,
   MLT_REALLOC,
@@ -903,6 +907,13 @@ void Perl_mem_log_del_sv(const SV *sv, const char *filename, const int linenumbe
 #define pTHX__VALUE
 #endif /* USE_ITHREADS */
 
+/* Perl_deprecate was not part of the public API, and did not have a deprecate()
+   shortcut macro defined without -DPERL_CORE. Neither codesearch.google.com nor
+   CPAN::Unpack show any users outside the core.  */
+#ifdef PERL_CORE
+#  define deprecate(s) Perl_ck_warner_d(aTHX_ packWARN(WARN_DEPRECATED), "Use of " s " is deprecated")
+#endif
+
 /*
  * Local variables:
  * c-indentation-style: bsd