This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Clone all shared string PVs as shared string PVs (now that we can do
[perl5.git] / gv.h
diff --git a/gv.h b/gv.h
index 7db4ba0..c020510 100644 (file)
--- a/gv.h
+++ b/gv.h
@@ -1,6 +1,7 @@
 /*    gv.h
  *
- *    Copyright (c) 1991-2002, Larry Wall
+ *    Copyright (C) 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
+ *    2000, 2001, 2002, 2003, 2004, 2005, by Larry Wall and others
  *
  *    You may distribute under the terms of either the GNU General Public
  *    License or the Artistic License, as specified in the README file.
@@ -42,7 +43,7 @@ Return the SV from the GV.
 
 #define GvSV(gv)       (GvGP(gv)->gp_sv)
 #define GvREFCNT(gv)   (GvGP(gv)->gp_refcnt)
-#define GvIO(gv)       ((gv) && SvTYPE((SV*)gv) == SVt_PVGV ? GvIOp(gv) : 0)
+#define GvIO(gv)       ((gv) && SvTYPE((SV*)gv) == SVt_PVGV && GvGP(gv) ? GvIOp(gv) : 0)
 #define GvIOp(gv)      (GvGP(gv)->gp_io)
 #define GvIOn(gv)      (GvIO(gv) ? GvIOp(gv) : GvIOp(gv_IOadd(gv)))
 
@@ -152,3 +153,8 @@ Return the SV from the GV.
 #define GV_ADDWARN     0x04    /* add, but warn if symbol wasn't already there */
 #define GV_ADDINEVAL   0x08    /* add, as though we're doing so within an eval */
 #define GV_NOINIT      0x10    /* add, but don't init symbol, if type != PVGV */
+/*      SVf_UTF8 (more accurately the return value from SvUTF8) is also valid
+       as a flag to gv_fetch_pvn_flags, so ensure it lies outside this range.
+*/
+#define gv_fullname3(sv,gv,prefix) gv_fullname4(sv,gv,prefix,TRUE)
+#define gv_efullname3(sv,gv,prefix) gv_efullname4(sv,gv,prefix,TRUE)