New shiny models
[p5sagit/p5-mst-13.2.git] / toke.c
diff --git a/toke.c b/toke.c
index f5aa5d1..5c24cca 100644 (file)
--- a/toke.c
+++ b/toke.c
@@ -1793,7 +1793,7 @@ S_scan_const(pTHX_ char *start)
     const char * const leaveit = /* set of acceptably-backslashed characters */
        (const char *)
        (PL_lex_inpat
-        ? "\\.^$@AGZdDwWsSbBpPXC+*?|()-Nnrtfeaxcz0123456789[{]} \t\n\r\f\v#"
+        ? "\\.^$@AGZdDwWsSbBpPXC+*?|()-Nnrktfeaxcz0123456789[{]} \t\n\r\f\v#"
         : "");
 
     if (PL_lex_inwhat == OP_TRANS && PL_sublex_info.sub_op) {
@@ -2193,8 +2193,8 @@ S_scan_const(pTHX_ char *start)
                        s += 3;
                        len = e - s;
                        uv = grok_hex(s, &len, &flags, NULL);
-                       if ( len != e - s ) {
-                           uv=0xFFFD;
+                       if ( e > s && len != (STRLEN)(e - s) ) {
+                           uv = 0xFFFD;
                        }
                        s = e + 1;
                        goto NUM_ESCAPE_INSERT;