Larry's fix for buggy propagation of utf8-ness in join(); add test
[p5sagit/p5-mst-13.2.git] / pp.c
diff --git a/pp.c b/pp.c
index 4210bd6..a59664e 100644 (file)
--- a/pp.c
+++ b/pp.c
@@ -205,7 +205,7 @@ PP(pp_rv2gv)
                if (SvROK(sv))
                    goto wasref;
            }
-           if (!SvOK(sv)) {
+           if (!SvOK(sv) && sv != &PL_sv_undef) {
                /* If this is a 'my' scalar and flag is set then vivify 
                 * NI-S 1999/05/07
                 */ 
@@ -426,7 +426,7 @@ PP(pp_prototype)
                        seen_question = 1;
                        str[n++] = ';';
                    }
-                   else if (seen_question) 
+                   else if (n && str[0] == ';' && seen_question) 
                        goto set;       /* XXXX system, exec */
                    if ((oa & (OA_OPTIONAL - 1)) >= OA_AVREF 
                        && (oa & (OA_OPTIONAL - 1)) <= OA_HVREF) {
@@ -1199,7 +1199,7 @@ PP(pp_ncmp)
     {
       dPOPTOPnnrl;
       I32 value;
-#ifdef __osf__ /* XXX fix in 5.6.1 --jhi */
+#ifdef __osf__ /* XXX Configure probe for isnan and isnanl needed XXX */
 #if defined(USE_LONG_DOUBLE) && defined(HAS_LONG_DOUBLE)
 #define Perl_isnan isnanl
 #else
@@ -1398,7 +1398,7 @@ PP(pp_negate)
                    RETURN;
                }
                else if (SvUVX(sv) <= IV_MAX) {
-                   SETi(-SvUVX(sv));
+                   SETi(-SvIVX(sv));
                    RETURN;
                }
            }