/usr/share/perl/5.22.1/pod/perl5140delta.pod is in perl-doc 5.22.1-9ubuntu0.6.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658 2659 2660 2661 2662 2663 2664 2665 2666 2667 2668 2669 2670 2671 2672 2673 2674 2675 2676 2677 2678 2679 2680 2681 2682 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 2704 2705 2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 2727 2728 2729 2730 2731 2732 2733 2734 2735 2736 2737 2738 2739 2740 2741 2742 2743 2744 2745 2746 2747 2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 2836 2837 2838 2839 2840 2841 2842 2843 2844 2845 2846 2847 2848 2849 2850 2851 2852 2853 2854 2855 2856 2857 2858 2859 2860 2861 2862 2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888 2889 2890 2891 2892 2893 2894 2895 2896 2897 2898 2899 2900 2901 2902 2903 2904 2905 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 2994 2995 2996 2997 2998 2999 3000 3001 3002 3003 3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 3029 3030 3031 3032 3033 3034 3035 3036 3037 3038 3039 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050 3051 3052 3053 3054 3055 3056 3057 3058 3059 3060 3061 3062 3063 3064 3065 3066 3067 3068 3069 3070 3071 3072 3073 3074 3075 3076 3077 3078 3079 3080 3081 3082 3083 3084 3085 3086 3087 3088 3089 3090 3091 3092 3093 3094 3095 3096 3097 3098 3099 3100 3101 3102 3103 3104 3105 3106 3107 3108 3109 3110 3111 3112 3113 3114 3115 3116 3117 3118 3119 3120 3121 3122 3123 3124 3125 3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140 3141 3142 3143 3144 3145 3146 3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 3161 3162 3163 3164 3165 3166 3167 3168 3169 3170 3171 3172 3173 3174 3175 3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 3188 3189 3190 3191 3192 3193 3194 3195 3196 3197 3198 3199 3200 3201 3202 3203 3204 3205 3206 3207 3208 3209 3210 3211 3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 3317 3318 3319 3320 3321 3322 3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 3412 3413 3414 3415 3416 3417 3418 3419 3420 3421 3422 3423 3424 3425 3426 3427 3428 3429 3430 3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 3443 3444 3445 3446 3447 3448 3449 3450 3451 3452 3453 3454 3455 3456 3457 3458 3459 3460 3461 3462 3463 3464 3465 3466 3467 3468 3469 3470 3471 3472 3473 3474 3475 3476 3477 3478 3479 3480 3481 3482 3483 3484 3485 3486 3487 3488 3489 3490 3491 3492 3493 3494 3495 3496 3497 3498 3499 3500 3501 3502 3503 3504 3505 3506 3507 3508 3509 3510 3511 3512 3513 3514 3515 3516 3517 3518 3519 3520 3521 3522 3523 3524 3525 3526 3527 3528 3529 3530 3531 3532 3533 3534 3535 3536 3537 3538 3539 3540 3541 3542 3543 3544 3545 3546 3547 3548 3549 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 3586 3587 3588 3589 3590 3591 3592 3593 3594 3595 3596 3597 3598 3599 3600 3601 3602 3603 3604 3605 3606 3607 3608 3609 3610 3611 3612 3613 3614 3615 3616 3617 3618 3619 3620 3621 3622 3623 3624 3625 3626 3627 3628 3629 3630 3631 3632 3633 3634 3635 3636 3637 3638 3639 3640 3641 3642 3643 3644 3645 3646 3647 3648 3649 3650 3651 3652 3653 3654 3655 3656 3657 3658 3659 3660 3661 3662 3663 3664 3665 3666 3667 3668 3669 3670 3671 3672 3673 3674 3675 3676 3677 3678 3679 3680 3681 3682 3683 3684 3685 3686 3687 3688 3689 3690 3691 3692 3693 3694 3695 3696 3697 3698 3699 3700 3701 3702 3703 3704 3705 3706 3707 3708 3709 3710 3711 3712 3713 3714 3715 3716 3717 3718 3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736 3737 3738 3739 3740 3741 3742 3743 3744 3745 3746 3747 3748 3749 3750 3751 3752 3753 3754 3755 3756 3757 3758 3759 3760 3761 3762 3763 3764 3765 3766 3767 3768 3769 3770 3771 3772 3773 3774 3775 3776 3777 3778 3779 3780 3781 3782 3783 3784 3785 3786 3787 3788 3789 3790 3791 3792 3793 3794 3795 3796 3797 3798 3799 3800 3801 3802 3803 3804 3805 3806 3807 3808 3809 3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823 3824 3825 3826 3827 3828 3829 3830 3831 3832 3833 3834 3835 3836 3837 3838 3839 3840 3841 3842 3843 3844 3845 3846 3847 3848 3849 3850 3851 3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868 3869 3870 3871 3872 3873 3874 3875 3876 3877 3878 3879 3880 3881 3882 3883 3884 3885 3886 3887 3888 3889 3890 3891 3892 3893 3894 3895 3896 3897 3898 3899 3900 3901 3902 3903 3904 3905 3906 3907 3908 3909 3910 3911 3912 3913 3914 3915 3916 3917 3918 3919 3920 3921 3922 3923 3924 3925 3926 3927 3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 3938 3939 3940 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 3972 3973 3974 3975 3976 3977 3978 3979 3980 3981 3982 3983 3984 3985 3986 3987 3988 3989 3990 3991 3992 3993 3994 3995 3996 3997 3998 3999 4000 4001 4002 4003 4004 4005 4006 4007 4008 4009 4010 4011 4012 4013 4014 4015 4016 4017 4018 4019 4020 4021 4022 4023 4024 4025 4026 4027 4028 4029 4030 4031 4032 4033 4034 4035 4036 4037 4038 4039 4040 4041 4042 4043 4044 4045 4046 4047 4048 4049 4050 4051 4052 4053 4054 4055 4056 4057 4058 4059 4060 4061 4062 4063 4064 4065 4066 4067 4068 4069 4070 4071 4072 4073 4074 4075 4076 4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 4123 4124 4125 4126 4127 4128 4129 4130 4131 4132 4133 4134 4135 4136 4137 4138 4139 4140 4141 4142 4143 4144 4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192 4193 4194 4195 4196 4197 4198 4199 4200 4201 4202 4203 4204 4205 4206 4207 4208 4209 4210 4211 4212 4213 4214 4215 4216 4217 4218 4219 4220 4221 4222 4223 4224 4225 4226 4227 4228 4229 4230 4231 4232 4233 4234 4235 4236 4237 4238 4239 4240 4241 4242 4243 4244 4245 4246 4247 4248 4249 4250 4251 4252 4253 4254 4255 4256 4257 4258 4259 4260 4261 4262 4263 4264 4265 4266 4267 4268 4269 4270 4271 4272 4273 4274 4275 4276 4277 4278 4279 4280 4281 4282 4283 4284 4285 4286 4287 4288 4289 4290 4291 4292 4293 4294 4295 4296 4297 4298 4299 4300 4301 4302 4303 4304 4305 4306 4307 4308 4309 4310 4311 4312 4313 4314 4315 4316 4317 4318 4319 4320 4321 4322 4323 4324 4325 4326 4327 4328 4329 4330 4331 4332 4333 4334 4335 4336 4337 4338 4339 4340 4341 4342 4343 4344 4345 4346 4347 4348 4349 4350 4351 4352 4353 4354 4355 4356 4357 4358 4359 4360 4361 4362 4363 4364 4365 4366 4367 4368 4369 4370 4371 4372 4373 4374 4375 4376 4377 4378 4379 4380 4381 4382 4383 4384 4385 4386 4387 4388 4389 4390 4391 4392 4393 4394 4395 4396 4397 4398 4399 4400 4401 4402 4403 4404 4405 4406 4407 4408 4409 4410 4411 4412 4413 4414 4415 4416 4417 4418 4419 4420 4421 4422 4423 4424 4425 4426 4427 4428 4429 4430 4431 4432 4433 4434 4435 4436 4437 4438 4439 4440 4441 4442 4443 4444 4445 4446 4447 4448 4449 4450 4451 4452 4453 4454 4455 4456 4457 4458 4459 4460 4461 4462 4463 4464 4465 4466 4467 4468 4469 4470 4471 4472 4473 4474 4475 4476 4477 4478 4479 4480 4481 4482 4483 4484 4485 4486 4487 4488 4489 4490 4491 4492 4493 4494 4495 4496 4497 4498 4499 4500 4501 4502 4503 4504 4505 4506 4507 4508 4509 4510 4511 4512 4513 4514 4515 4516 4517 4518 4519 4520 4521 4522 4523 4524 4525 4526 4527 4528 4529 4530 4531 4532 4533 4534 4535 4536 4537 4538 4539 4540 4541 4542 4543 4544 4545 4546 4547 4548 4549 4550 4551 4552 4553 4554 4555 4556 4557 4558 4559 4560 4561 4562 4563 4564 4565 4566 4567 4568 4569 4570 4571 4572 4573 4574 4575 4576 4577 4578 4579 4580 4581 4582 4583 4584 4585 4586 4587 4588 4589 4590 | =encoding utf8
=head1 NAME
perl5140delta - what is new for perl v5.14.0
=head1 DESCRIPTION
This document describes differences between the 5.12.0 release and
the 5.14.0 release.
If you are upgrading from an earlier release such as 5.10.0, first read
L<perl5120delta>, which describes differences between 5.10.0 and
5.12.0.
Some of the bug fixes in this release have been backported to subsequent
releases of 5.12.x. Those are indicated with the 5.12.x version in
parentheses.
=head1 Notice
As described in L<perlpolicy>, the release of Perl 5.14.0 marks the
official end of support for Perl 5.10. Users of Perl 5.10 or earlier
should consider upgrading to a more recent release of Perl.
=head1 Core Enhancements
=head2 Unicode
=head3 Unicode Version 6.0 is now supported (mostly)
Perl comes with the Unicode 6.0 data base updated with
L<Corrigendum #8|http://www.unicode.org/versions/corrigendum8.html>,
with one exception noted below.
See L<http://unicode.org/versions/Unicode6.0.0/> for details on the new
release. Perl does not support any Unicode provisional properties,
including the new ones for this release.
Unicode 6.0 has chosen to use the name C<BELL> for the character at U+1F514,
which is a symbol that looks like a bell, and is used in Japanese cell
phones. This conflicts with the long-standing Perl usage of having
C<BELL> mean the ASCII C<BEL> character, U+0007. In Perl 5.14,
C<\N{BELL}> continues to mean U+0007, but its use generates a
deprecation warning message unless such warnings are turned off. The
new name for U+0007 in Perl is C<ALERT>, which corresponds nicely
with the existing shorthand sequence for it, C<"\a">. C<\N{BEL}>
means U+0007, with no warning given. The character at U+1F514 has no
name in 5.14, but can be referred to by C<\N{U+1F514}>.
In Perl 5.16, C<\N{BELL}> will refer to U+1F514; all code
that uses C<\N{BELL}> should be converted to use C<\N{ALERT}>,
C<\N{BEL}>, or C<"\a"> before upgrading.
=head3 Full functionality for C<use feature 'unicode_strings'>
This release provides full functionality for C<use feature
'unicode_strings'>. Under its scope, all string operations executed and
regular expressions compiled (even if executed outside its scope) have
Unicode semantics. See L<feature/"the 'unicode_strings' feature">.
However, see L</Inverted bracketed character classes and multi-character folds>,
below.
This feature avoids most forms of the "Unicode Bug" (see
L<perlunicode/The "Unicode Bug"> for details). If there is any
possibility that your code will process Unicode strings, you are
I<strongly> encouraged to use this subpragma to avoid nasty surprises.
=head3 C<\N{I<NAME>}> and C<charnames> enhancements
=over
=item *
C<\N{I<NAME>}> and C<charnames::vianame> now know about the abbreviated
character names listed by Unicode, such as NBSP, SHY, LRO, ZWJ, etc.; all
customary abbreviations for the C0 and C1 control characters (such as
ACK, BEL, CAN, etc.); and a few new variants of some C1 full names that
are in common usage.
=item *
Unicode has several I<named character sequences>, in which particular sequences
of code points are given names. C<\N{I<NAME>}> now recognizes these.
=item *
C<\N{I<NAME>}>, C<charnames::vianame>, and C<charnames::viacode>
now know about every character in Unicode. In earlier releases of
Perl, they didn't know about the Hangul syllables nor several
CJK (Chinese/Japanese/Korean) characters.
=item *
It is now possible to override Perl's abbreviations with your own custom aliases.
=item *
You can now create a custom alias of the ordinal of a
character, known by C<\N{I<NAME>}>, C<charnames::vianame()>, and
C<charnames::viacode()>. Previously, aliases had to be to official
Unicode character names. This made it impossible to create an alias for
unnamed code points, such as those reserved for private
use.
=item *
The new function charnames::string_vianame() is a run-time version
of C<\N{I<NAME>}}>, returning the string of characters whose Unicode
name is its parameter. It can handle Unicode named character
sequences, whereas the pre-existing charnames::vianame() cannot,
as the latter returns a single code point.
=back
See L<charnames> for details on all these changes.
=head3 New warnings categories for problematic (non-)Unicode code points.
Three new warnings subcategories of "utf8" have been added. These
allow you to turn off some "utf8" warnings, while allowing
other warnings to remain on. The three categories are:
C<surrogate> when UTF-16 surrogates are encountered;
C<nonchar> when Unicode non-character code points are encountered;
and C<non_unicode> when code points above the legal Unicode
maximum of 0x10FFFF are encountered.
=head3 Any unsigned value can be encoded as a character
With this release, Perl is adopting a model that any unsigned value
can be treated as a code point and encoded internally (as utf8)
without warnings, not just the code points that are legal in Unicode.
However, unless utf8 or the corresponding sub-category (see previous
item) of lexical warnings have been explicitly turned off, outputting
or executing a Unicode-defined operation such as upper-casing
on such a code point generates a warning. Attempting to input these
using strict rules (such as with the C<:encoding(UTF-8)> layer)
will continue to fail. Prior to this release, handling was
inconsistent and in places, incorrect.
Unicode non-characters, some of which previously were erroneously
considered illegal in places by Perl, contrary to the Unicode Standard,
are now always legal internally. Inputting or outputting them
works the same as with the non-legal Unicode code points, because the Unicode
Standard says they are (only) illegal for "open interchange".
=head3 Unicode database files not installed
The Unicode database files are no longer installed with Perl. This
doesn't affect any functionality in Perl and saves significant disk
space. If you need these files, you can download them from
L<http://www.unicode.org/Public/zipped/6.0.0/>.
=head2 Regular Expressions
=head3 C<(?^...)> construct signifies default modifiers
An ASCII caret C<"^"> immediately following a C<"(?"> in a regular
expression now means that the subexpression does not inherit surrounding
modifiers such as C</i>, but reverts to the Perl defaults. Any modifiers
following the caret override the defaults.
Stringification of regular expressions now uses this notation.
For example, C<qr/hlagh/i> would previously be stringified as
C<(?i-xsm:hlagh)>, but now it's stringified as C<(?^i:hlagh)>.
The main purpose of this change is to allow tests that rely on the
stringification I<not> to have to change whenever new modifiers are added.
See L<perlre/Extended Patterns>.
This change is likely to break code that compares stringified regular
expressions with fixed strings containing C<?-xism>.
=head3 C</d>, C</l>, C</u>, and C</a> modifiers
Four new regular expression modifiers have been added. These are mutually
exclusive: one only can be turned on at a time.
=over
=item *
The C</l> modifier says to compile the regular expression as if it were
in the scope of C<use locale>, even if it is not.
=item *
The C</u> modifier says to compile the regular expression as if it were
in the scope of a C<use feature 'unicode_strings'> pragma.
=item *
The C</d> (default) modifier is used to override any C<use locale> and
C<use feature 'unicode_strings'> pragmas in effect at the time
of compiling the regular expression.
=item *
The C</a> regular expression modifier restricts C<\s>, C<\d> and C<\w> and
the POSIX (C<[[:posix:]]>) character classes to the ASCII range. Their
complements and C<\b> and C<\B> are correspondingly
affected. Otherwise, C</a> behaves like the C</u> modifier, in that
case-insensitive matching uses Unicode semantics.
If the C</a> modifier is repeated, then additionally in case-insensitive
matching, no ASCII character can match a non-ASCII character.
For example,
"k" =~ /\N{KELVIN SIGN}/ai
"\xDF" =~ /ss/ai
match but
"k" =~ /\N{KELVIN SIGN}/aai
"\xDF" =~ /ss/aai
do not match.
=back
See L<perlre/Modifiers> for more detail.
=head3 Non-destructive substitution
The substitution (C<s///>) and transliteration
(C<y///>) operators now support an C</r> option that
copies the input variable, carries out the substitution on
the copy, and returns the result. The original remains unmodified.
my $old = "cat";
my $new = $old =~ s/cat/dog/r;
# $old is "cat" and $new is "dog"
This is particularly useful with C<map>. See L<perlop> for more examples.
=head3 Re-entrant regular expression engine
It is now safe to use regular expressions within C<(?{...})> and
C<(??{...})> code blocks inside regular expressions.
These blocks are still experimental, however, and still have problems with
lexical (C<my>) variables and abnormal exiting.
=head3 C<use re '/flags'>
The C<re> pragma now has the ability to turn on regular expression flags
till the end of the lexical scope:
use re "/x";
"foo" =~ / (.+) /; # /x implied
See L<re/"'/flags' mode"> for details.
=head3 \o{...} for octals
There is a new octal escape sequence, C<"\o">, in doublequote-like
contexts. This construct allows large octal ordinals beyond the
current max of 0777 to be represented. It also allows you to specify a
character in octal which can safely be concatenated with other regex
snippets and which won't be confused with being a backreference to
a regex capture group. See L<perlre/Capture groups>.
=head3 Add C<\p{Titlecase}> as a synonym for C<\p{Title}>
This synonym is added for symmetry with the Unicode property names
C<\p{Uppercase}> and C<\p{Lowercase}>.
=head3 Regular expression debugging output improvement
Regular expression debugging output (turned on by C<use re 'debug'>) now
uses hexadecimal when escaping non-ASCII characters, instead of octal.
=head3 Return value of C<delete $+{...}>
Custom regular expression engines can now determine the return value of
C<delete> on an entry of C<%+> or C<%->.
=head2 Syntactical Enhancements
=head3 Array and hash container functions accept references
B<Warning:> This feature is considered experimental, as the exact behaviour
may change in a future version of Perl.
All builtin functions that operate directly on array or hash
containers now also accept unblessed hard references to arrays
or hashes:
|----------------------------+---------------------------|
| Traditional syntax | Terse syntax |
|----------------------------+---------------------------|
| push @$arrayref, @stuff | push $arrayref, @stuff |
| unshift @$arrayref, @stuff | unshift $arrayref, @stuff |
| pop @$arrayref | pop $arrayref |
| shift @$arrayref | shift $arrayref |
| splice @$arrayref, 0, 2 | splice $arrayref, 0, 2 |
| keys %$hashref | keys $hashref |
| keys @$arrayref | keys $arrayref |
| values %$hashref | values $hashref |
| values @$arrayref | values $arrayref |
| ($k,$v) = each %$hashref | ($k,$v) = each $hashref |
| ($k,$v) = each @$arrayref | ($k,$v) = each $arrayref |
|----------------------------+---------------------------|
This allows these builtin functions to act on long dereferencing chains
or on the return value of subroutines without needing to wrap them in
C<@{}> or C<%{}>:
push @{$obj->tags}, $new_tag; # old way
push $obj->tags, $new_tag; # new way
for ( keys %{$hoh->{genres}{artists}} ) {...} # old way
for ( keys $hoh->{genres}{artists} ) {...} # new way
=head3 Single term prototype
The C<+> prototype is a special alternative to C<$> that acts like
C<\[@%]> when given a literal array or hash variable, but will otherwise
force scalar context on the argument. See L<perlsub/Prototypes>.
=head3 C<package> block syntax
A package declaration can now contain a code block, in which case the
declaration is in scope inside that block only. So C<package Foo { ... }>
is precisely equivalent to C<{ package Foo; ... }>. It also works with
a version number in the declaration, as in C<package Foo 1.2 { ... }>,
which is its most attractive feature. See L<perlfunc>.
=head3 Statement labels can appear in more places
Statement labels can now occur before any type of statement or declaration,
such as C<package>.
=head3 Stacked labels
Multiple statement labels can now appear before a single statement.
=head3 Uppercase X/B allowed in hexadecimal/binary literals
Literals may now use either upper case C<0X...> or C<0B...> prefixes,
in addition to the already supported C<0x...> and C<0b...>
syntax [perl #76296].
C, Ruby, Python, and PHP already support this syntax, and it makes
Perl more internally consistent: a round-trip with C<eval sprintf
"%#X", 0x10> now returns C<16>, just like C<eval sprintf "%#x", 0x10>.
=head3 Overridable tie functions
C<tie>, C<tied> and C<untie> can now be overridden [perl #75902].
=head2 Exception Handling
To make them more reliable and consistent, several changes have been made
to how C<die>, C<warn>, and C<$@> behave.
=over
=item *
When an exception is thrown inside an C<eval>, the exception is no
longer at risk of being clobbered by destructor code running during unwinding.
Previously, the exception was written into C<$@>
early in the throwing process, and would be overwritten if C<eval> was
used internally in the destructor for an object that had to be freed
while exiting from the outer C<eval>. Now the exception is written
into C<$@> last thing before exiting the outer C<eval>, so the code
running immediately thereafter can rely on the value in C<$@> correctly
corresponding to that C<eval>. (C<$@> is still also set before exiting the
C<eval>, for the sake of destructors that rely on this.)
Likewise, a C<local $@> inside an C<eval> no longer clobbers any
exception thrown in its scope. Previously, the restoration of C<$@> upon
unwinding would overwrite any exception being thrown. Now the exception
gets to the C<eval> anyway. So C<local $@> is safe before a C<die>.
Exceptions thrown from object destructors no longer modify the C<$@>
of the surrounding context. (If the surrounding context was exception
unwinding, this used to be another way to clobber the exception being
thrown.) Previously such an exception was
sometimes emitted as a warning, and then either was
string-appended to the surrounding C<$@> or completely replaced the
surrounding C<$@>, depending on whether that exception and the surrounding
C<$@> were strings or objects. Now, an exception in this situation is
always emitted as a warning, leaving the surrounding C<$@> untouched.
In addition to object destructors, this also affects any function call
run by XS code using the C<G_KEEPERR> flag.
=item *
Warnings for C<warn> can now be objects in the same way as exceptions
for C<die>. If an object-based warning gets the default handling
of writing to standard error, it is stringified as before with the
filename and line number appended. But a C<$SIG{__WARN__}> handler now
receives an object-based warning as an object, where previously it
was passed the result of stringifying the object.
=back
=head2 Other Enhancements
=head3 Assignment to C<$0> sets the legacy process name with prctl() on Linux
On Linux the legacy process name is now set with L<prctl(2)>, in
addition to altering the POSIX name via C<argv[0]>, as Perl has done
since version 4.000. Now system utilities that read the legacy process
name such as I<ps>, I<top>, and I<killall> recognize the name you set when
assigning to C<$0>. The string you supply is truncated at 16 bytes;
this limitation is imposed by Linux.
=head3 srand() now returns the seed
This allows programs that need to have repeatable results not to have to come
up with their own seed-generating mechanism. Instead, they can use srand()
and stash the return value for future use. One example is a test program with
too many combinations to test comprehensively in the time available for
each run. It can test a random subset each time and, should there be a failure,
log the seed used for that run so this can later be used to produce the same results.
=head3 printf-like functions understand post-1980 size modifiers
Perl's printf and sprintf operators, and Perl's internal printf replacement
function, now understand the C90 size modifiers "hh" (C<char>), "z"
(C<size_t>), and "t" (C<ptrdiff_t>). Also, when compiled with a C99
compiler, Perl now understands the size modifier "j" (C<intmax_t>)
(but this is not portable).
So, for example, on any modern machine, C<sprintf("%hhd", 257)> returns "1".
=head3 New global variable C<${^GLOBAL_PHASE}>
A new global variable, C<${^GLOBAL_PHASE}>, has been added to allow
introspection of the current phase of the Perl interpreter. It's explained in
detail in L<perlvar/"${^GLOBAL_PHASE}"> and in
L<perlmod/"BEGIN, UNITCHECK, CHECK, INIT and END">.
=head3 C<-d:-foo> calls C<Devel::foo::unimport>
The syntax B<-d:foo> was extended in 5.6.1 to make B<-d:foo=bar>
equivalent to B<-MDevel::foo=bar>, which expands
internally to C<use Devel::foo 'bar'>.
Perl now allows prefixing the module name with B<->, with the same
semantics as B<-M>; that is:
=over 4
=item C<-d:-foo>
Equivalent to B<-M-Devel::foo>: expands to
C<no Devel::foo> and calls C<< Devel::foo->unimport() >>
if that method exists.
=item C<-d:-foo=bar>
Equivalent to B<-M-Devel::foo=bar>: expands to C<no Devel::foo 'bar'>,
and calls C<< Devel::foo->unimport("bar") >> if that method exists.
=back
This is particularly useful for suppressing the default actions of a
C<Devel::*> module's C<import> method whilst still loading it for debugging.
=head3 Filehandle method calls load L<IO::File> on demand
When a method call on a filehandle would die because the method cannot
be resolved and L<IO::File> has not been loaded, Perl now loads L<IO::File>
via C<require> and attempts method resolution again:
open my $fh, ">", $file;
$fh->binmode(":raw"); # loads IO::File and succeeds
This also works for globs like C<STDOUT>, C<STDERR>, and C<STDIN>:
STDOUT->autoflush(1);
Because this on-demand load happens only if method resolution fails, the
legacy approach of manually loading an L<IO::File> parent class for partial
method support still works as expected:
use IO::Handle;
open my $fh, ">", $file;
$fh->autoflush(1); # IO::File not loaded
=head3 Improved IPv6 support
The C<Socket> module provides new affordances for IPv6,
including implementations of the C<Socket::getaddrinfo()> and
C<Socket::getnameinfo()> functions, along with related constants and a
handful of new functions. See L<Socket>.
=head3 DTrace probes now include package name
The C<DTrace> probes now include an additional argument, C<arg3>, which contains
the package the subroutine being entered or left was compiled in.
For example, using the following DTrace script:
perl$target:::sub-entry
{
printf("%s::%s\n", copyinstr(arg0), copyinstr(arg3));
}
and then running:
$ perl -e 'sub test { }; test'
C<DTrace> will print:
main::test
=head2 New C APIs
See L</Internal Changes>.
=head1 Security
=head2 User-defined regular expression properties
L<perlunicode/"User-Defined Character Properties"> documented that you can
create custom properties by defining subroutines whose names begin with
"In" or "Is". However, Perl did not actually enforce that naming
restriction, so C<\p{foo::bar}> could call foo::bar() if it existed. The documented
convention is now enforced.
Also, Perl no longer allows tainted regular expressions to invoke a
user-defined property. It simply dies instead [perl #82616].
=head1 Incompatible Changes
Perl 5.14.0 is not binary-compatible with any previous stable release.
In addition to the sections that follow, see L</C API Changes>.
=head2 Regular Expressions and String Escapes
=head3 Inverted bracketed character classes and multi-character folds
Some characters match a sequence of two or three characters in C</i>
regular expression matching under Unicode rules. One example is
C<LATIN SMALL LETTER SHARP S> which matches the sequence C<ss>.
'ss' =~ /\A[\N{LATIN SMALL LETTER SHARP S}]\z/i # Matches
This, however, can lead to very counter-intuitive results, especially
when inverted. Because of this, Perl 5.14 does not use multi-character C</i>
matching in inverted character classes.
'ss' =~ /\A[^\N{LATIN SMALL LETTER SHARP S}]+\z/i # ???
This should match any sequences of characters that aren't the C<SHARP S>
nor what C<SHARP S> matches under C</i>. C<"s"> isn't C<SHARP S>, but
Unicode says that C<"ss"> is what C<SHARP S> matches under C</i>. So
which one "wins"? Do you fail the match because the string has C<ss> or
accept it because it has an C<s> followed by another C<s>?
Earlier releases of Perl did allow this multi-character matching,
but due to bugs, it mostly did not work.
=head3 \400-\777
In certain circumstances, C<\400>-C<\777> in regexes have behaved
differently than they behave in all other doublequote-like contexts.
Since 5.10.1, Perl has issued a deprecation warning when this happens.
Now, these literals behave the same in all doublequote-like contexts,
namely to be equivalent to C<\x{100}>-C<\x{1FF}>, with no deprecation
warning.
Use of C<\400>-C<\777> in the command-line option B<-0> retain their
conventional meaning. They slurp whole input files; previously, this
was documented only for B<-0777>.
Because of various ambiguities, you should use the new
C<\o{...}> construct to represent characters in octal instead.
=head3 Most C<\p{}> properties are now immune to case-insensitive matching
For most Unicode properties, it doesn't make sense to have them match
differently under C</i> case-insensitive matching. Doing so can lead
to unexpected results and potential security holes. For example
m/\p{ASCII_Hex_Digit}+/i
could previously match non-ASCII characters because of the Unicode
matching rules (although there were several bugs with this). Now
matching under C</i> gives the same results as non-C</i> matching except
for those few properties where people have come to expect differences,
namely the ones where casing is an integral part of their meaning, such
as C<m/\p{Uppercase}/i> and C<m/\p{Lowercase}/i>, both of which match
the same code points as matched by C<m/\p{Cased}/i>.
Details are in L<perlrecharclass/Unicode Properties>.
User-defined property handlers that need to match differently under C</i>
must be changed to read the new boolean parameter passed to them, which
is non-zero if case-insensitive matching is in effect and 0 otherwise.
See L<perlunicode/User-Defined Character Properties>.
=head3 \p{} implies Unicode semantics
Specifying a Unicode property in the pattern indicates
that the pattern is meant for matching according to Unicode rules, the way
C<\N{I<NAME>}> does.
=head3 Regular expressions retain their localeness when interpolated
Regular expressions compiled under C<use locale> now retain this when
interpolated into a new regular expression compiled outside a
C<use locale>, and vice-versa.
Previously, one regular expression interpolated into another inherited
the localeness of the surrounding regex, losing whatever state it
originally had. This is considered a bug fix, but may trip up code that
has come to rely on the incorrect behaviour.
=head3 Stringification of regexes has changed
Default regular expression modifiers are now notated using
C<(?^...)>. Code relying on the old stringification will fail.
This is so that when new modifiers are added, such code won't
have to keep changing each time this happens, because the stringification
will automatically incorporate the new modifiers.
Code that needs to work properly with both old- and new-style regexes
can avoid the whole issue by using (for perls since 5.9.5; see L<re>):
use re qw(regexp_pattern);
my ($pat, $mods) = regexp_pattern($re_ref);
If the actual stringification is important or older Perls need to be
supported, you can use something like the following:
# Accept both old and new-style stringification
my $modifiers = (qr/foobar/ =~ /\Q(?^/) ? "^" : "-xism";
And then use C<$modifiers> instead of C<-xism>.
=head3 Run-time code blocks in regular expressions inherit pragmata
Code blocks in regular expressions (C<(?{...})> and C<(??{...})>) previously
did not inherit pragmata (strict, warnings, etc.) if the regular expression
was compiled at run time as happens in cases like these two:
use re "eval";
$foo =~ $bar; # when $bar contains (?{...})
$foo =~ /$bar(?{ $finished = 1 })/;
This bug has now been fixed, but code that relied on the buggy behaviour
may need to be fixed to account for the correct behaviour.
=head2 Stashes and Package Variables
=head3 Localised tied hashes and arrays are no longed tied
In the following:
tie @a, ...;
{
local @a;
# here, @a is a now a new, untied array
}
# here, @a refers again to the old, tied array
Earlier versions of Perl incorrectly tied the new local array. This has
now been fixed. This fix could however potentially cause a change in
behaviour of some code.
=head3 Stashes are now always defined
C<defined %Foo::> now always returns true, even when no symbols have yet been
defined in that package.
This is a side-effect of removing a special-case kludge in the tokeniser,
added for 5.10.0, to hide side-effects of changes to the internal storage of
hashes. The fix drastically reduces hashes' memory overhead.
Calling defined on a stash has been deprecated since 5.6.0, warned on
lexicals since 5.6.0, and warned for stashes and other package
variables since 5.12.0. C<defined %hash> has always exposed an
implementation detail: emptying a hash by deleting all entries from it does
not make C<defined %hash> false. Hence C<defined %hash> is not valid code to
determine whether an arbitrary hash is empty. Instead, use the behaviour
of an empty C<%hash> always returning false in scalar context.
=head3 Clearing stashes
Stash list assignment C<%foo:: = ()> used to make the stash temporarily
anonymous while it was being emptied. Consequently, any of its
subroutines referenced elsewhere would become anonymous, showing up as
"(unknown)" in C<caller>. They now retain their package names such that
C<caller> returns the original sub name if there is still a reference
to its typeglob and "foo::__ANON__" otherwise [perl #79208].
=head3 Dereferencing typeglobs
If you assign a typeglob to a scalar variable:
$glob = *foo;
the glob that is copied to C<$glob> is marked with a special flag
indicating that the glob is just a copy. This allows subsequent
assignments to C<$glob> to overwrite the glob. The original glob,
however, is immutable.
Some Perl operators did not distinguish between these two types of globs.
This would result in strange behaviour in edge cases: C<untie $scalar>
would not untie the scalar if the last thing assigned to it was a glob
(because it treated it as C<untie *$scalar>, which unties a handle).
Assignment to a glob slot (such as C<*$glob = \@some_array>) would simply
assign C<\@some_array> to C<$glob>.
To fix this, the C<*{}> operator (including its C<*foo> and C<*$foo> forms)
has been modified to make a new immutable glob if its operand is a glob
copy. This allows operators that make a distinction between globs and
scalars to be modified to treat only immutable globs as globs. (C<tie>,
C<tied> and C<untie> have been left as they are for compatibility's sake,
but will warn. See L</Deprecations>.)
This causes an incompatible change in code that assigns a glob to the
return value of C<*{}> when that operator was passed a glob copy. Take the
following code, for instance:
$glob = *foo;
*$glob = *bar;
The C<*$glob> on the second line returns a new immutable glob. That new
glob is made an alias to C<*bar>. Then it is discarded. So the second
assignment has no effect.
See L<http://rt.perl.org/rt3/Public/Bug/Display.html?id=77810> for
more detail.
=head3 Magic variables outside the main package
In previous versions of Perl, magic variables like C<$!>, C<%SIG>, etc. would
"leak" into other packages. So C<%foo::SIG> could be used to access signals,
C<${"foo::!"}> (with strict mode off) to access C's C<errno>, etc.
This was a bug, or an "unintentional" feature, which caused various ill effects,
such as signal handlers being wiped when modules were loaded, etc.
This has been fixed (or the feature has been removed, depending on how you see
it).
=head3 local($_) strips all magic from $_
local() on scalar variables gives them a new value but keeps all
their magic intact. This has proven problematic for the default
scalar variable $_, where L<perlsub> recommends that any subroutine
that assigns to $_ should first localize it. This would throw an
exception if $_ is aliased to a read-only variable, and could in general have
various unintentional side-effects.
Therefore, as an exception to the general rule, local($_) will not
only assign a new value to $_, but also remove all existing magic from
it as well.
=head3 Parsing of package and variable names
Parsing the names of packages and package variables has changed:
multiple adjacent pairs of colons, as in C<foo::::bar>, are now all
treated as package separators.
Regardless of this change, the exact parsing of package separators has
never been guaranteed and is subject to change in future Perl versions.
=head2 Changes to Syntax or to Perl Operators
=head3 C<given> return values
C<given> blocks now return the last evaluated
expression, or an empty list if the block was exited by C<break>. Thus you
can now write:
my $type = do {
given ($num) {
break when undef;
"integer" when /^[+-]?[0-9]+$/;
"float" when /^[+-]?[0-9]+(?:\.[0-9]+)?$/;
"unknown";
}
};
See L<perlsyn/Return value> for details.
=head3 Change in parsing of certain prototypes
Functions declared with the following prototypes now behave correctly as unary
functions:
*
\$ \% \@ \* \&
\[...]
;$ ;*
;\$ ;\% etc.
;\[...]
Due to this bug fix [perl #75904], functions
using the C<(*)>, C<(;$)> and C<(;*)> prototypes
are parsed with higher precedence than before. So
in the following example:
sub foo(;$);
foo $a < $b;
the second line is now parsed correctly as C<< foo($a) < $b >>, rather than
C<< foo($a < $b) >>. This happens when one of these operators is used in
an unparenthesised argument:
< > <= >= lt gt le ge
== != <=> eq ne cmp ~~
&
| ^
&&
|| //
.. ...
?:
= += -= *= etc.
, =>
=head3 Smart-matching against array slices
Previously, the following code resulted in a successful match:
my @a = qw(a y0 z);
my @b = qw(a x0 z);
@a[0 .. $#b] ~~ @b;
This odd behaviour has now been fixed [perl #77468].
=head3 Negation treats strings differently from before
The unary negation operator, C<->, now treats strings that look like numbers
as numbers [perl #57706].
=head3 Negative zero
Negative zero (-0.0), when converted to a string, now becomes "0" on all
platforms. It used to become "-0" on some, but "0" on others.
If you still need to determine whether a zero is negative, use
C<sprintf("%g", $zero) =~ /^-/> or the L<Data::Float> module on CPAN.
=head3 C<:=> is now a syntax error
Previously C<my $pi := 4> was exactly equivalent to C<my $pi : = 4>,
with the C<:> being treated as the start of an attribute list, ending before
the C<=>. The use of C<:=> to mean C<: => was deprecated in 5.12.0, and is
now a syntax error. This allows future use of C<:=> as a new token.
Outside the core's tests for it, we find no Perl 5 code on CPAN
using this construction, so we believe that this change will have
little impact on real-world codebases.
If it is absolutely necessary to have empty attribute lists (for example,
because of a code generator), simply avoid the error by adding a space before
the C<=>.
=head3 Change in the parsing of identifiers
Characters outside the Unicode "XIDStart" set are no longer allowed at the
beginning of an identifier. This means that certain accents and marks
that normally follow an alphabetic character may no longer be the first
character of an identifier.
=head2 Threads and Processes
=head3 Directory handles not copied to threads
On systems other than Windows that do not have
a C<fchdir> function, newly-created threads no
longer inherit directory handles from their parent threads. Such programs
would usually have crashed anyway [perl #75154].
=head3 C<close> on shared pipes
To avoid deadlocks, the C<close> function no longer waits for the
child process to exit if the underlying file descriptor is still
in use by another thread. It returns true in such cases.
=head3 fork() emulation will not wait for signalled children
On Windows parent processes would not terminate until all forked
children had terminated first. However, C<kill("KILL", ...)> is
inherently unstable on pseudo-processes, and C<kill("TERM", ...)>
might not get delivered if the child is blocked in a system call.
To avoid the deadlock and still provide a safe mechanism to terminate
the hosting process, Perl now no longer waits for children that
have been sent a SIGTERM signal. It is up to the parent process to
waitpid() for these children if child-cleanup processing must be
allowed to finish. However, it is also then the responsibility of the
parent to avoid the deadlock by making sure the child process
can't be blocked on I/O.
See L<perlfork> for more information about the fork() emulation on
Windows.
=head2 Configuration
=head3 Naming fixes in Policy_sh.SH may invalidate Policy.sh
Several long-standing typos and naming confusions in F<Policy_sh.SH> have
been fixed, standardizing on the variable names used in F<config.sh>.
This will change the behaviour of F<Policy.sh> if you happen to have been
accidentally relying on its incorrect behaviour.
=head3 Perl source code is read in text mode on Windows
Perl scripts used to be read in binary mode on Windows for the benefit
of the L<ByteLoader> module (which is no longer part of core Perl). This
had the side-effect of breaking various operations on the C<DATA> filehandle,
including seek()/tell(), and even simply reading from C<DATA> after filehandles
have been flushed by a call to system(), backticks, fork() etc.
The default build options for Windows have been changed to read Perl source
code on Windows in text mode now. L<ByteLoader> will (hopefully) be updated on
CPAN to automatically handle this situation [perl #28106].
=head1 Deprecations
See also L</Deprecated C APIs>.
=head2 Omitting a space between a regular expression and subsequent word
Omitting the space between a regular expression operator or
its modifiers and the following word is deprecated. For
example, C<< m/foo/sand $bar >> is for now still parsed
as C<< m/foo/s and $bar >>, but will now issue a warning.
=head2 C<\cI<X>>
The backslash-c construct was designed as a way of specifying
non-printable characters, but there were no restrictions (on ASCII
platforms) on what the character following the C<c> could be. Now,
a deprecation warning is raised if that character isn't an ASCII character.
Also, a deprecation warning is raised for C<"\c{"> (which is the same
as simply saying C<";">).
=head2 C<"\b{"> and C<"\B{">
In regular expressions, a literal C<"{"> immediately following a C<"\b">
(not in a bracketed character class) or a C<"\B{"> is now deprecated
to allow for its future use by Perl itself.
=head2 Perl 4-era .pl libraries
Perl bundles a handful of library files that predate Perl 5.
This bundling is now deprecated for most of these files, which are now
available from CPAN. The affected files now warn when run, if they were
installed as part of the core.
This is a mandatory warning, not obeying B<-X> or lexical warning bits.
The warning is modelled on that supplied by F<deprecate.pm> for
deprecated-in-core F<.pm> libraries. It points to the specific CPAN
distribution that contains the F<.pl> libraries. The CPAN versions, of
course, do not generate the warning.
=head2 List assignment to C<$[>
Assignment to C<$[> was deprecated and started to give warnings in
Perl version 5.12.0. This version of Perl (5.14) now also emits a warning
when assigning to C<$[> in list context. This fixes an oversight in 5.12.0.
=head2 Use of qw(...) as parentheses
Historically the parser fooled itself into thinking that C<qw(...)> literals
were always enclosed in parentheses, and as a result you could sometimes omit
parentheses around them:
for $x qw(a b c) { ... }
The parser no longer lies to itself in this way. Wrap the list literal in
parentheses like this:
for $x (qw(a b c)) { ... }
This is being deprecated because the parentheses in C<for $i (1,2,3) { ... }>
are not part of expression syntax. They are part of the statement
syntax, with the C<for> statement wanting literal parentheses.
The synthetic parentheses that a C<qw> expression acquired were only
intended to be treated as part of expression syntax.
Note that this does not change the behaviour of cases like:
use POSIX qw(setlocale localeconv);
our @EXPORT = qw(foo bar baz);
where parentheses were never required around the expression.
=head2 C<\N{BELL}>
This is because Unicode is using that name for a different character.
See L</Unicode Version 6.0 is now supported (mostly)> for more
explanation.
=head2 C<?PATTERN?>
C<?PATTERN?> (without the initial C<m>) has been deprecated and now produces
a warning. This is to allow future use of C<?> in new operators.
The match-once functionality is still available as C<m?PATTERN?>.
=head2 Tie functions on scalars holding typeglobs
Calling a tie function (C<tie>, C<tied>, C<untie>) with a scalar argument
acts on a filehandle if the scalar happens to hold a typeglob.
This is a long-standing bug that will be removed in Perl 5.16, as
there is currently no way to tie the scalar itself when it holds
a typeglob, and no way to untie a scalar that has had a typeglob
assigned to it.
Now there is a deprecation warning whenever a tie
function is used on a handle without an explicit C<*>.
=head2 User-defined case-mapping
This feature is being deprecated due to its many issues, as documented in
L<perlunicode/User-Defined Case Mappings (for serious hackers only)>.
This feature will be removed in Perl 5.16. Instead use the CPAN module
L<Unicode::Casing>, which provides improved functionality.
=head2 Deprecated modules
The following module will be removed from the core distribution in a
future release, and should be installed from CPAN instead. Distributions
on CPAN that require this should add it to their prerequisites. The
core version of these module now issues a deprecation warning.
If you ship a packaged version of Perl, either alone or as part of a
larger system, then you should carefully consider the repercussions of
core module deprecations. You may want to consider shipping your default
build of Perl with a package for the deprecated module that
installs into C<vendor> or C<site> Perl library directories. This will
inhibit the deprecation warnings.
Alternatively, you may want to consider patching F<lib/deprecate.pm>
to provide deprecation warnings specific to your packaging system
or distribution of Perl, consistent with how your packaging system
or distribution manages a staged transition from a release where the
installation of a single package provides the given functionality, to
a later release where the system administrator needs to know to install
multiple packages to get that same functionality.
You can silence these deprecation warnings by installing the module
in question from CPAN. To install the latest version of it by role
rather than by name, just install C<Task::Deprecations::5_14>.
=over
=item L<Devel::DProf>
We strongly recommend that you install and use L<Devel::NYTProf> instead
of L<Devel::DProf>, as L<Devel::NYTProf> offers significantly
improved profiling and reporting.
=back
=head1 Performance Enhancements
=head2 "Safe signals" optimisation
Signal dispatch has been moved from the runloop into control ops.
This should give a few percent speed increase, and eliminates nearly
all the speed penalty caused by the introduction of "safe signals"
in 5.8.0. Signals should still be dispatched within the same
statement as they were previously. If this does I<not> happen, or
if you find it possible to create uninterruptible loops, this is a
bug, and reports are encouraged of how to recreate such issues.
=head2 Optimisation of shift() and pop() calls without arguments
Two fewer OPs are used for shift() and pop() calls with no argument (with
implicit C<@_>). This change makes shift() 5% faster than C<shift @_>
on non-threaded perls, and 25% faster on threaded ones.
=head2 Optimisation of regexp engine string comparison work
The C<foldEQ_utf8> API function for case-insensitive comparison of strings (which
is used heavily by the regexp engine) was substantially refactored and
optimised -- and its documentation much improved as a free bonus.
=head2 Regular expression compilation speed-up
Compiling regular expressions has been made faster when upgrading
the regex to utf8 is necessary but this isn't known when the compilation begins.
=head2 String appending is 100 times faster
When doing a lot of string appending, perls built to use the system's
C<malloc> could end up allocating a lot more memory than needed in a
inefficient way.
C<sv_grow>, the function used to allocate more memory if necessary
when appending to a string, has been taught to round up the memory
it requests to a certain geometric progression, making it much faster on
certain platforms and configurations. On Win32, it's now about 100 times
faster.
=head2 Eliminate C<PL_*> accessor functions under ithreads
When C<MULTIPLICITY> was first developed, and interpreter state moved into
an interpreter struct, thread- and interpreter-local C<PL_*> variables
were defined as macros that called accessor functions (returning the
address of the value) outside the Perl core. The intent was to allow
members within the interpreter struct to change size without breaking
binary compatibility, so that bug fixes could be merged to a maintenance
branch that necessitated such a size change. This mechanism was redundant
and penalised well-behaved code. It has been removed.
=head2 Freeing weak references
When there are many weak references to an object, freeing that object
can under some circumstances take O(I<N*N>) time to free, where
I<N> is the number of references. The circumstances in which this can happen
have been reduced [perl #75254]
=head2 Lexical array and hash assignments
An earlier optimisation to speed up C<my @array = ...> and
C<my %hash = ...> assignments caused a bug and was disabled in Perl 5.12.0.
Now we have found another way to speed up these assignments [perl #82110].
=head2 C<@_> uses less memory
Previously, C<@_> was allocated for every subroutine at compile time with
enough space for four entries. Now this allocation is done on demand when
the subroutine is called [perl #72416].
=head2 Size optimisations to SV and HV structures
C<xhv_fill> has been eliminated from C<struct xpvhv>, saving 1 IV per hash and
on some systems will cause C<struct xpvhv> to become cache-aligned. To avoid
this memory saving causing a slowdown elsewhere, boolean use of C<HvFILL>
now calls C<HvTOTALKEYS> instead (which is equivalent), so while the fill
data when actually required are now calculated on demand, cases when
this needs to be done should be rare.
The order of structure elements in SV bodies has changed. Effectively,
the NV slot has swapped location with STASH and MAGIC. As all access to
SV members is via macros, this should be completely transparent. This
change allows the space saving for PVHVs documented above, and may reduce
the memory allocation needed for PVIVs on some architectures.
C<XPV>, C<XPVIV>, and C<XPVNV> now allocate only the parts of the C<SV> body
they actually use, saving some space.
Scalars containing regular expressions now allocate only the part of the C<SV>
body they actually use, saving some space.
=head2 Memory consumption improvements to Exporter
The C<@EXPORT_FAIL> AV is no longer created unless needed, hence neither is
the typeglob backing it. This saves about 200 bytes for every package that
uses Exporter but doesn't use this functionality.
=head2 Memory savings for weak references
For weak references, the common case of just a single weak reference
per referent has been optimised to reduce the storage required. In this
case it saves the equivalent of one small Perl array per referent.
=head2 C<%+> and C<%-> use less memory
The bulk of the C<Tie::Hash::NamedCapture> module used to be in the Perl
core. It has now been moved to an XS module to reduce overhead for
programs that do not use C<%+> or C<%->.
=head2 Multiple small improvements to threads
The internal structures of threading now make fewer API calls and fewer
allocations, resulting in noticeably smaller object code. Additionally,
many thread context checks have been deferred so they're done only
as needed (although this is only possible for non-debugging builds).
=head2 Adjacent pairs of nextstate opcodes are now optimized away
Previously, in code such as
use constant DEBUG => 0;
sub GAK {
warn if DEBUG;
print "stuff\n";
}
the ops for C<warn if DEBUG> would be folded to a C<null> op (C<ex-const>), but
the C<nextstate> op would remain, resulting in a runtime op dispatch of
C<nextstate>, C<nextstate>, etc.
The execution of a sequence of C<nextstate> ops is indistinguishable from just
the last C<nextstate> op so the peephole optimizer now eliminates the first of
a pair of C<nextstate> ops except when the first carries a label, since labels
must not be eliminated by the optimizer, and label usage isn't conclusively known
at compile time.
=head1 Modules and Pragmata
=head2 New Modules and Pragmata
=over 4
=item *
L<CPAN::Meta::YAML> 0.003 has been added as a dual-life module. It supports a
subset of YAML sufficient for reading and writing F<META.yml> and F<MYMETA.yml> files
included with CPAN distributions or generated by the module installation
toolchain. It should not be used for any other general YAML parsing or
generation task.
=item *
L<CPAN::Meta> version 2.110440 has been added as a dual-life module. It
provides a standard library to read, interpret and write CPAN distribution
metadata files (like F<META.json> and F<META.yml>) that describe a
distribution, its contents, and the requirements for building it and
installing it. The latest CPAN distribution metadata specification is
included as L<CPAN::Meta::Spec> and notes on changes in the specification
over time are given in L<CPAN::Meta::History>.
=item *
L<HTTP::Tiny> 0.012 has been added as a dual-life module. It is a very
small, simple HTTP/1.1 client designed for simple GET requests and file
mirroring. It has been added so that F<CPAN.pm> and L<CPANPLUS> can
"bootstrap" HTTP access to CPAN using pure Perl without relying on external
binaries like L<curl(1)> or L<wget(1)>.
=item *
L<JSON::PP> 2.27105 has been added as a dual-life module to allow CPAN
clients to read F<META.json> files in CPAN distributions.
=item *
L<Module::Metadata> 1.000004 has been added as a dual-life module. It gathers
package and POD information from Perl module files. It is a standalone module
based on L<Module::Build::ModuleInfo> for use by other module installation
toolchain components. L<Module::Build::ModuleInfo> has been deprecated in
favor of this module instead.
=item *
L<Perl::OSType> 1.002 has been added as a dual-life module. It maps Perl
operating system names (like "dragonfly" or "MSWin32") to more generic types
with standardized names (like "Unix" or "Windows"). It has been refactored
out of L<Module::Build> and L<ExtUtils::CBuilder> and consolidates such mappings into
a single location for easier maintenance.
=item *
The following modules were added by the L<Unicode::Collate>
upgrade. See below for details.
L<Unicode::Collate::CJK::Big5>
L<Unicode::Collate::CJK::GB2312>
L<Unicode::Collate::CJK::JISX0208>
L<Unicode::Collate::CJK::Korean>
L<Unicode::Collate::CJK::Pinyin>
L<Unicode::Collate::CJK::Stroke>
=item *
L<Version::Requirements> version 0.101020 has been added as a dual-life
module. It provides a standard library to model and manipulates module
prerequisites and version constraints defined in L<CPAN::Meta::Spec>.
=back
=head2 Updated Modules and Pragma
=over 4
=item *
L<attributes> has been upgraded from version 0.12 to 0.14.
=item *
L<Archive::Extract> has been upgraded from version 0.38 to 0.48.
Updates since 0.38 include: a safe print method that guards
L<Archive::Extract> from changes to C<$\>; a fix to the tests when run in core
Perl; support for TZ files; a modification for the lzma
logic to favour L<IO::Uncompress::Unlzma>; and a fix
for an issue with NetBSD-current and its new L<unzip(1)>
executable.
=item *
L<Archive::Tar> has been upgraded from version 1.54 to 1.76.
Important changes since 1.54 include the following:
=over
=item *
Compatibility with busybox implementations of L<tar(1)>.
=item *
A fix so that write() and create_archive()
close only filehandles they themselves opened.
=item *
A bug was fixed regarding the exit code of extract_archive.
=item *
The L<ptar(1)> utility has a new option to allow safe creation of
tarballs without world-writable files on Windows, allowing those
archives to be uploaded to CPAN.
=item *
A new L<ptargrep(1)> utility for using regular expressions against
the contents of files in a tar archive.
=item *
L<pax> extended headers are now skipped.
=back
=item *
L<Attribute::Handlers> has been upgraded from version 0.87 to 0.89.
=item *
L<autodie> has been upgraded from version 2.06_01 to 2.1001.
=item *
L<AutoLoader> has been upgraded from version 5.70 to 5.71.
=item *
The L<B> module has been upgraded from version 1.23 to 1.29.
It no longer crashes when taking apart a C<y///> containing characters
outside the octet range or compiled in a C<use utf8> scope.
The size of the shared object has been reduced by about 40%, with no
reduction in functionality.
=item *
L<B::Concise> has been upgraded from version 0.78 to 0.83.
L<B::Concise> marks rv2sv(), rv2av(), and rv2hv() ops with the new
C<OPpDEREF> flag as "DREFed".
It no longer produces mangled output with the B<-tree> option
[perl #80632].
=item *
L<B::Debug> has been upgraded from version 1.12 to 1.16.
=item *
L<B::Deparse> has been upgraded from version 0.96 to 1.03.
The deparsing of a C<nextstate> op has changed when it has both a
change of package relative to the previous nextstate, or a change of
C<%^H> or other state and a label. The label was previously emitted
first, but is now emitted last (5.12.1).
The C<no 5.13.2> or similar form is now correctly handled by L<B::Deparse>
(5.12.3).
L<B::Deparse> now properly handles the code that applies a conditional
pattern match against implicit C<$_> as it was fixed in [perl #20444].
Deparsing of C<our> followed by a variable with funny characters
(as permitted under the C<use utf8> pragma) has also been fixed [perl #33752].
=item *
L<B::Lint> has been upgraded from version 1.11_01 to 1.13.
=item *
L<base> has been upgraded from version 2.15 to 2.16.
=item *
L<Benchmark> has been upgraded from version 1.11 to 1.12.
=item *
L<bignum> has been upgraded from version 0.23 to 0.27.
=item *
L<Carp> has been upgraded from version 1.15 to 1.20.
L<Carp> now detects incomplete L<caller()|perlfunc/"caller EXPR">
overrides and avoids using bogus C<@DB::args>. To provide backtraces,
Carp relies on particular behaviour of the caller() builtin.
L<Carp> now detects if other code has overridden this with an
incomplete implementation, and modifies its backtrace accordingly.
Previously incomplete overrides would cause incorrect values in
backtraces (best case), or obscure fatal errors (worst case).
This fixes certain cases of "Bizarre copy of ARRAY" caused by modules
overriding caller() incorrectly (5.12.2).
It now also avoids using regular expressions that cause Perl to
load its Unicode tables, so as to avoid the "BEGIN not safe after
errors" error that ensue if there has been a syntax error
[perl #82854].
=item *
L<CGI> has been upgraded from version 3.48 to 3.52.
This provides the following security fixes: the MIME boundary in
multipart_init() is now random and the handling of
newlines embedded in header values has been improved.
=item *
L<Compress::Raw::Bzip2> has been upgraded from version 2.024 to 2.033.
It has been updated to use L<bzip2(1)> 1.0.6.
=item *
L<Compress::Raw::Zlib> has been upgraded from version 2.024 to 2.033.
=item *
L<constant> has been upgraded from version 1.20 to 1.21.
Unicode constants work once more. They have been broken since Perl 5.10.0
[CPAN RT #67525].
=item *
L<CPAN> has been upgraded from version 1.94_56 to 1.9600.
Major highlights:
=over 4
=item * much less configuration dialog hassle
=item * support for F<META/MYMETA.json>
=item * support for L<local::lib>
=item * support for L<HTTP::Tiny> to reduce the dependency on FTP sites
=item * automatic mirror selection
=item * iron out all known bugs in configure_requires
=item * support for distributions compressed with L<bzip2(1)>
=item * allow F<Foo/Bar.pm> on the command line to mean C<Foo::Bar>
=back
=item *
L<CPANPLUS> has been upgraded from version 0.90 to 0.9103.
A change to F<cpanp-run-perl>
resolves L<RT #55964|http://rt.cpan.org/Public/Bug/Display.html?id=55964>
and L<RT #57106|http://rt.cpan.org/Public/Bug/Display.html?id=57106>, both
of which related to failures to install distributions that use
C<Module::Install::DSL> (5.12.2).
A dependency on L<Config> was not recognised as a
core module dependency. This has been fixed.
L<CPANPLUS> now includes support for F<META.json> and F<MYMETA.json>.
=item *
L<CPANPLUS::Dist::Build> has been upgraded from version 0.46 to 0.54.
=item *
L<Data::Dumper> has been upgraded from version 2.125 to 2.130_02.
The indentation used to be off when C<$Data::Dumper::Terse> was set. This
has been fixed [perl #73604].
This upgrade also fixes a crash when using custom sort functions that might
cause the stack to change [perl #74170].
L<Dumpxs> no longer crashes with globs returned by C<*$io_ref>
[perl #72332].
=item *
L<DB_File> has been upgraded from version 1.820 to 1.821.
=item *
L<DBM_Filter> has been upgraded from version 0.03 to 0.04.
=item *
L<Devel::DProf> has been upgraded from version 20080331.00 to 20110228.00.
Merely loading L<Devel::DProf> now no longer triggers profiling to start.
Both C<use Devel::DProf> and C<perl -d:DProf ...> behave as before and start
the profiler.
B<NOTE>: L<Devel::DProf> is deprecated and will be removed from a future
version of Perl. We strongly recommend that you install and use
L<Devel::NYTProf> instead, as it offers significantly improved
profiling and reporting.
=item *
L<Devel::Peek> has been upgraded from version 1.04 to 1.07.
=item *
L<Devel::SelfStubber> has been upgraded from version 1.03 to 1.05.
=item *
L<diagnostics> has been upgraded from version 1.19 to 1.22.
It now renders pod links slightly better, and has been taught to find
descriptions for messages that share their descriptions with other
messages.
=item *
L<Digest::MD5> has been upgraded from version 2.39 to 2.51.
It is now safe to use this module in combination with threads.
=item *
L<Digest::SHA> has been upgraded from version 5.47 to 5.61.
C<shasum> now more closely mimics L<sha1sum(1)>/L<md5sum(1)>.
C<addfile> accepts all POSIX filenames.
New SHA-512/224 and SHA-512/256 transforms (ref. NIST Draft FIPS 180-4
[February 2011])
=item *
L<DirHandle> has been upgraded from version 1.03 to 1.04.
=item *
L<Dumpvalue> has been upgraded from version 1.13 to 1.16.
=item *
L<DynaLoader> has been upgraded from version 1.10 to 1.13.
It fixes a buffer overflow when passed a very long file name.
It no longer inherits from L<AutoLoader>; hence it no longer
produces weird error messages for unsuccessful method calls on classes that
inherit from L<DynaLoader> [perl #84358].
=item *
L<Encode> has been upgraded from version 2.39 to 2.42.
Now, all 66 Unicode non-characters are treated the same way U+FFFF has
always been treated: in cases when it was disallowed, all 66 are
disallowed, and in cases where it warned, all 66 warn.
=item *
L<Env> has been upgraded from version 1.01 to 1.02.
=item *
L<Errno> has been upgraded from version 1.11 to 1.13.
The implementation of L<Errno> has been refactored to use about 55% less memory.
On some platforms with unusual header files, like Win32 L<gcc(1)> using C<mingw64>
headers, some constants that weren't actually error numbers have been exposed
by L<Errno>. This has been fixed [perl #77416].
=item *
L<Exporter> has been upgraded from version 5.64_01 to 5.64_03.
Exporter no longer overrides C<$SIG{__WARN__}> [perl #74472]
=item *
L<ExtUtils::CBuilder> has been upgraded from version 0.27 to 0.280203.
=item *
L<ExtUtils::Command> has been upgraded from version 1.16 to 1.17.
=item *
L<ExtUtils::Constant> has been upgraded from 0.22 to 0.23.
The L<AUTOLOAD> helper code generated by C<ExtUtils::Constant::ProxySubs>
can now croak() for missing constants, or generate a complete C<AUTOLOAD>
subroutine in XS, allowing simplification of many modules that use it
(L<Fcntl>, L<File::Glob>, L<GDBM_File>, L<I18N::Langinfo>, L<POSIX>,
L<Socket>).
L<ExtUtils::Constant::ProxySubs> can now optionally push the names of all
constants onto the package's C<@EXPORT_OK>.
=item *
L<ExtUtils::Install> has been upgraded from version 1.55 to 1.56.
=item *
L<ExtUtils::MakeMaker> has been upgraded from version 6.56 to 6.57_05.
=item *
L<ExtUtils::Manifest> has been upgraded from version 1.57 to 1.58.
=item *
L<ExtUtils::ParseXS> has been upgraded from version 2.21 to 2.2210.
=item *
L<Fcntl> has been upgraded from version 1.06 to 1.11.
=item *
L<File::Basename> has been upgraded from version 2.78 to 2.82.
=item *
L<File::CheckTree> has been upgraded from version 4.4 to 4.41.
=item *
L<File::Copy> has been upgraded from version 2.17 to 2.21.
=item *
L<File::DosGlob> has been upgraded from version 1.01 to 1.04.
It allows patterns containing literal parentheses: they no longer need to
be escaped. On Windows, it no longer
adds an extra F<./> to file names
returned when the pattern is a relative glob with a drive specification,
like F<C:*.pl> [perl #71712].
=item *
L<File::Fetch> has been upgraded from version 0.24 to 0.32.
L<HTTP::Lite> is now supported for the "http" scheme.
The L<fetch(1)> utility is supported on FreeBSD, NetBSD, and
Dragonfly BSD for the C<http> and C<ftp> schemes.
=item *
L<File::Find> has been upgraded from version 1.15 to 1.19.
It improves handling of backslashes on Windows, so that paths like
F<C:\dir\/file> are no longer generated [perl #71710].
=item *
L<File::Glob> has been upgraded from version 1.07 to 1.12.
=item *
L<File::Spec> has been upgraded from version 3.31 to 3.33.
Several portability fixes were made in L<File::Spec::VMS>: a colon is now
recognized as a delimiter in native filespecs; caret-escaped delimiters are
recognized for better handling of extended filespecs; catpath() returns
an empty directory rather than the current directory if the input directory
name is empty; and abs2rel() properly handles Unix-style input (5.12.2).
=item *
L<File::stat> has been upgraded from 1.02 to 1.05.
The C<-x> and C<-X> file test operators now work correctly when run
by the superuser.
=item *
L<Filter::Simple> has been upgraded from version 0.84 to 0.86.
=item *
L<GDBM_File> has been upgraded from 1.10 to 1.14.
This fixes a memory leak when DBM filters are used.
=item *
L<Hash::Util> has been upgraded from 0.07 to 0.11.
L<Hash::Util> no longer emits spurious "uninitialized" warnings when
recursively locking hashes that have undefined values [perl #74280].
=item *
L<Hash::Util::FieldHash> has been upgraded from version 1.04 to 1.09.
=item *
L<I18N::Collate> has been upgraded from version 1.01 to 1.02.
=item *
L<I18N::Langinfo> has been upgraded from version 0.03 to 0.08.
langinfo() now defaults to using C<$_> if there is no argument given, just
as the documentation has always claimed.
=item *
L<I18N::LangTags> has been upgraded from version 0.35 to 0.35_01.
=item *
L<if> has been upgraded from version 0.05 to 0.0601.
=item *
L<IO> has been upgraded from version 1.25_02 to 1.25_04.
This version of L<IO> includes a new L<IO::Select>, which now allows L<IO::Handle>
objects (and objects in derived classes) to be removed from an L<IO::Select> set
even if the underlying file descriptor is closed or invalid.
=item *
L<IPC::Cmd> has been upgraded from version 0.54 to 0.70.
Resolves an issue with splitting Win32 command lines. An argument
consisting of the single character "0" used to be omitted (CPAN RT #62961).
=item *
L<IPC::Open3> has been upgraded from 1.05 to 1.09.
open3() now produces an error if the C<exec> call fails, allowing this
condition to be distinguished from a child process that exited with a
non-zero status [perl #72016].
The internal xclose() routine now knows how to handle file descriptors as
documented, so duplicating C<STDIN> in a child process using its file
descriptor now works [perl #76474].
=item *
L<IPC::SysV> has been upgraded from version 2.01 to 2.03.
=item *
L<lib> has been upgraded from version 0.62 to 0.63.
=item *
L<Locale::Maketext> has been upgraded from version 1.14 to 1.19.
L<Locale::Maketext> now supports external caches.
This upgrade also fixes an infinite loop in
C<Locale::Maketext::Guts::_compile()> when
working with tainted values (CPAN RT #40727).
C<< ->maketext >> calls now back up and restore C<$@> so error
messages are not suppressed (CPAN RT #34182).
=item *
L<Log::Message> has been upgraded from version 0.02 to 0.04.
=item *
L<Log::Message::Simple> has been upgraded from version 0.06 to 0.08.
=item *
L<Math::BigInt> has been upgraded from version 1.89_01 to 1.994.
This fixes, among other things, incorrect results when computing binomial
coefficients [perl #77640].
It also prevents C<sqrt($int)> from crashing under C<use bigrat>.
[perl #73534].
=item *
L<Math::BigInt::FastCalc> has been upgraded from version 0.19 to 0.28.
=item *
L<Math::BigRat> has been upgraded from version 0.24 to 0.26_02.
=item *
L<Memoize> has been upgraded from version 1.01_03 to 1.02.
=item *
L<MIME::Base64> has been upgraded from 3.08 to 3.13.
Includes new functions to calculate the length of encoded and decoded
base64 strings.
Now provides encode_base64url() and decode_base64url() functions to process
the base64 scheme for "URL applications".
=item *
L<Module::Build> has been upgraded from version 0.3603 to 0.3800.
A notable change is the deprecation of several modules.
L<Module::Build::Version> has been deprecated and L<Module::Build> now
relies on the L<version> pragma directly. L<Module::Build::ModuleInfo> has
been deprecated in favor of a standalone copy called L<Module::Metadata>.
L<Module::Build::YAML> has been deprecated in favor of L<CPAN::Meta::YAML>.
L<Module::Build> now also generates F<META.json> and F<MYMETA.json> files
in accordance with version 2 of the CPAN distribution metadata specification,
L<CPAN::Meta::Spec>. The older format F<META.yml> and F<MYMETA.yml> files are
still generated.
=item *
L<Module::CoreList> has been upgraded from version 2.29 to 2.47.
Besides listing the updated core modules of this release, it also stops listing
the C<Filespec> module. That module never existed in core. The scripts
generating L<Module::CoreList> confused it with L<VMS::Filespec>, which actually
is a core module as of Perl 5.8.7.
=item *
L<Module::Load> has been upgraded from version 0.16 to 0.18.
=item *
L<Module::Load::Conditional> has been upgraded from version 0.34 to 0.44.
=item *
The L<mro> pragma has been upgraded from version 1.02 to 1.07.
=item *
L<NDBM_File> has been upgraded from version 1.08 to 1.12.
This fixes a memory leak when DBM filters are used.
=item *
L<Net::Ping> has been upgraded from version 2.36 to 2.38.
=item *
L<NEXT> has been upgraded from version 0.64 to 0.65.
=item *
L<Object::Accessor> has been upgraded from version 0.36 to 0.38.
=item *
L<ODBM_File> has been upgraded from version 1.07 to 1.10.
This fixes a memory leak when DBM filters are used.
=item *
L<Opcode> has been upgraded from version 1.15 to 1.18.
=item *
The L<overload> pragma has been upgraded from 1.10 to 1.13.
C<overload::Method> can now handle subroutines that are themselves blessed
into overloaded classes [perl #71998].
The documentation has greatly improved. See L</Documentation> below.
=item *
L<Params::Check> has been upgraded from version 0.26 to 0.28.
=item *
The L<parent> pragma has been upgraded from version 0.223 to 0.225.
=item *
L<Parse::CPAN::Meta> has been upgraded from version 1.40 to 1.4401.
The latest Parse::CPAN::Meta can now read YAML and JSON files using
L<CPAN::Meta::YAML> and L<JSON::PP>, which are now part of the Perl core.
=item *
L<PerlIO::encoding> has been upgraded from version 0.12 to 0.14.
=item *
L<PerlIO::scalar> has been upgraded from 0.07 to 0.11.
A read() after a seek() beyond the end of the string no longer thinks it
has data to read [perl #78716].
=item *
L<PerlIO::via> has been upgraded from version 0.09 to 0.11.
=item *
L<Pod::Html> has been upgraded from version 1.09 to 1.11.
=item *
L<Pod::LaTeX> has been upgraded from version 0.58 to 0.59.
=item *
L<Pod::Perldoc> has been upgraded from version 3.15_02 to 3.15_03.
=item *
L<Pod::Simple> has been upgraded from version 3.13 to 3.16.
=item *
L<POSIX> has been upgraded from 1.19 to 1.24.
It now includes constants for POSIX signal constants.
=item *
The L<re> pragma has been upgraded from version 0.11 to 0.18.
The C<use re '/flags'> subpragma is new.
The regmust() function used to crash when called on a regular expression
belonging to a pluggable engine. Now it croaks instead.
regmust() no longer leaks memory.
=item *
L<Safe> has been upgraded from version 2.25 to 2.29.
Coderefs returned by reval() and rdo() are now wrapped via
wrap_code_refs() (5.12.1).
This fixes a possible infinite loop when looking for coderefs.
It adds several C<version::vxs::*> routines to the default share.
=item *
L<SDBM_File> has been upgraded from version 1.06 to 1.09.
=item *
L<SelfLoader> has been upgraded from 1.17 to 1.18.
It now works in taint mode [perl #72062].
=item *
The L<sigtrap> pragma has been upgraded from version 1.04 to 1.05.
It no longer tries to modify read-only arguments when generating a
backtrace [perl #72340].
=item *
L<Socket> has been upgraded from version 1.87 to 1.94.
See L</Improved IPv6 support> above.
=item *
L<Storable> has been upgraded from version 2.22 to 2.27.
Includes performance improvement for overloaded classes.
This adds support for serialising code references that contain UTF-8 strings
correctly. The L<Storable> minor version
number changed as a result, meaning that
L<Storable> users who set C<$Storable::accept_future_minor> to a C<FALSE> value
will see errors (see L<Storable/FORWARD COMPATIBILITY> for more details).
Freezing no longer gets confused if the Perl stack gets reallocated
during freezing [perl #80074].
=item *
L<Sys::Hostname> has been upgraded from version 1.11 to 1.16.
=item *
L<Term::ANSIColor> has been upgraded from version 2.02 to 3.00.
=item *
L<Term::UI> has been upgraded from version 0.20 to 0.26.
=item *
L<Test::Harness> has been upgraded from version 3.17 to 3.23.
=item *
L<Test::Simple> has been upgraded from version 0.94 to 0.98.
Among many other things, subtests without a C<plan> or C<no_plan> now have an
implicit done_testing() added to them.
=item *
L<Thread::Semaphore> has been upgraded from version 2.09 to 2.12.
It provides two new methods that give more control over the decrementing of
semaphores: C<down_nb> and C<down_force>.
=item *
L<Thread::Queue> has been upgraded from version 2.11 to 2.12.
=item *
The L<threads> pragma has been upgraded from version 1.75 to 1.83.
=item *
The L<threads::shared> pragma has been upgraded from version 1.32 to 1.37.
=item *
L<Tie::Hash> has been upgraded from version 1.03 to 1.04.
Calling C<< Tie::Hash->TIEHASH() >> used to loop forever. Now it C<croak>s.
=item *
L<Tie::Hash::NamedCapture> has been upgraded from version 0.06 to 0.08.
=item *
L<Tie::RefHash> has been upgraded from version 1.38 to 1.39.
=item *
L<Time::HiRes> has been upgraded from version 1.9719 to 1.9721_01.
=item *
L<Time::Local> has been upgraded from version 1.1901_01 to 1.2000.
=item *
L<Time::Piece> has been upgraded from version 1.15_01 to 1.20_01.
=item *
L<Unicode::Collate> has been upgraded from version 0.52_01 to 0.73.
L<Unicode::Collate> has been updated to use Unicode 6.0.0.
L<Unicode::Collate::Locale> now supports a plethora of new locales: I<ar, be,
bg, de__phonebook, hu, hy, kk, mk, nso, om, tn, vi, hr, ig, ja, ko, ru, sq,
se, sr, to, uk, zh, zh__big5han, zh__gb2312han, zh__pinyin>, and I<zh__stroke>.
The following modules have been added:
L<Unicode::Collate::CJK::Big5> for C<zh__big5han> which makes
tailoring of CJK Unified Ideographs in the order of CLDR's big5han ordering.
L<Unicode::Collate::CJK::GB2312> for C<zh__gb2312han> which makes
tailoring of CJK Unified Ideographs in the order of CLDR's gb2312han ordering.
L<Unicode::Collate::CJK::JISX0208> which makes tailoring of 6355 kanji
(CJK Unified Ideographs) in the JIS X 0208 order.
L<Unicode::Collate::CJK::Korean> which makes tailoring of CJK Unified Ideographs
in the order of CLDR's Korean ordering.
L<Unicode::Collate::CJK::Pinyin> for C<zh__pinyin> which makes
tailoring of CJK Unified Ideographs in the order of CLDR's pinyin ordering.
L<Unicode::Collate::CJK::Stroke> for C<zh__stroke> which makes
tailoring of CJK Unified Ideographs in the order of CLDR's stroke ordering.
This also sees the switch from using the pure-Perl version of this
module to the XS version.
=item *
L<Unicode::Normalize> has been upgraded from version 1.03 to 1.10.
=item *
L<Unicode::UCD> has been upgraded from version 0.27 to 0.32.
A new function, Unicode::UCD::num(), has been added. This function
returns the numeric value of the string passed it or C<undef> if the string
in its entirety has no "safe" numeric value. (For more detail, and for the
definition of "safe", see L<Unicode::UCD/num()>.)
This upgrade also includes several bug fixes:
=over 4
=item charinfo()
=over 4
=item *
It is now updated to Unicode Version 6.0.0 with I<Corrigendum #8>,
excepting that, just as with Perl 5.14, the code point at U+1F514 has no name.
=item *
Hangul syllable code points have the correct names, and their
decompositions are always output without requiring L<Lingua::KO::Hangul::Util>
to be installed.
=item *
CJK (Chinese-Japanese-Korean) code points U+2A700 to U+2B734
and U+2B740 to U+2B81D are now properly handled.
=item *
Numeric values are now output for those CJK code points that have them.
=item *
Names output for code points with multiple aliases are now the
corrected ones.
=back
=item charscript()
This now correctly returns "Unknown" instead of C<undef> for the script
of a code point that hasn't been assigned another one.
=item charblock()
This now correctly returns "No_Block" instead of C<undef> for the block
of a code point that hasn't been assigned to another one.
=back
=item *
The L<version> pragma has been upgraded from 0.82 to 0.88.
Because of a bug, now fixed, the is_strict() and is_lax() functions did not
work when exported (5.12.1).
=item *
The L<warnings> pragma has been upgraded from version 1.09 to 1.12.
Calling C<use warnings> without arguments is now significantly more efficient.
=item *
The L<warnings::register> pragma has been upgraded from version 1.01 to 1.02.
It is now possible to register warning categories other than the names of
packages using L<warnings::register>. See L<perllexwarn(1)> for more information.
=item *
L<XSLoader> has been upgraded from version 0.10 to 0.13.
=item *
L<VMS::DCLsym> has been upgraded from version 1.03 to 1.05.
Two bugs have been fixed [perl #84086]:
The symbol table name was lost when tying a hash, due to a thinko in
C<TIEHASH>. The result was that all tied hashes interacted with the
local symbol table.
Unless a symbol table name had been explicitly specified in the call
to the constructor, querying the special key C<:LOCAL> failed to
identify objects connected to the local symbol table.
=item *
The L<Win32> module has been upgraded from version 0.39 to 0.44.
This release has several new functions: Win32::GetSystemMetrics(),
Win32::GetProductInfo(), Win32::GetOSDisplayName().
The names returned by Win32::GetOSName() and Win32::GetOSDisplayName()
have been corrected.
=item *
L<XS::Typemap> has been upgraded from version 0.03 to 0.05.
=back
=head2 Removed Modules and Pragmata
As promised in Perl 5.12.0's release notes, the following modules have
been removed from the core distribution, and if needed should be installed
from CPAN instead.
=over
=item *
L<Class::ISA> has been removed from the Perl core. Prior version was 0.36.
=item *
L<Pod::Plainer> has been removed from the Perl core. Prior version was 1.02.
=item *
L<Switch> has been removed from the Perl core. Prior version was 2.16.
=back
The removal of L<Shell> has been deferred until after 5.14, as the
implementation of L<Shell> shipped with 5.12.0 did not correctly issue the
warning that it was to be removed from core.
=head1 Documentation
=head2 New Documentation
=head3 L<perlgpl>
L<perlgpl> has been updated to contain GPL version 1, as is included in the
F<README> distributed with Perl (5.12.1).
=head3 Perl 5.12.x delta files
The perldelta files for Perl 5.12.1 to 5.12.3 have been added from the
maintenance branch: L<perl5121delta>, L<perl5122delta>, L<perl5123delta>.
=head3 L<perlpodstyle>
New style guide for POD documentation,
split mostly from the NOTES section of the L<pod2man(1)> manpage.
=head3 L<perlsource>, L<perlinterp>, L<perlhacktut>, and L<perlhacktips>
See L</perlhack and perlrepository revamp>, below.
=head2 Changes to Existing Documentation
=head3 L<perlmodlib> is now complete
The L<perlmodlib> manpage that came with Perl 5.12.0 was missing several
modules due to a bug in the script that generates the list. This has been
fixed [perl #74332] (5.12.1).
=head3 Replace incorrect tr/// table in L<perlebcdic>
L<perlebcdic> contains a helpful table to use in C<tr///> to convert
between EBCDIC and Latin1/ASCII. The table was the inverse of the one
it describes, though the code that used the table worked correctly for
the specific example given.
The table has been corrected and the sample code changed to correspond.
The table has also been changed to hex from octal, and the recipes in the
pod have been altered to print out leading zeros to make all values
the same length.
=head3 Tricks for user-defined casing
L<perlunicode> now contains an explanation of how to override, mangle
and otherwise tweak the way Perl handles upper-, lower- and other-case
conversions on Unicode data, and how to provide scoped changes to alter
one's own code's behaviour without stomping on anybody else's.
=head3 INSTALL explicitly states that Perl requires a C89 compiler
This was already true, but it's now Officially Stated For The Record
(5.12.2).
=head3 Explanation of C<\xI<HH>> and C<\oI<OOO>> escapes
L<perlop> has been updated with more detailed explanation of these two
character escapes.
=head3 B<-0I<NNN>> switch
In L<perlrun>, the behaviour of the B<-0NNN> switch for B<-0400> or higher
has been clarified (5.12.2).
=head3 Maintenance policy
L<perlpolicy> now contains the policy on what patches are acceptable for
maintenance branches (5.12.1).
=head3 Deprecation policy
L<perlpolicy> now contains the policy on compatibility and deprecation
along with definitions of terms like "deprecation" (5.12.2).
=head3 New descriptions in L<perldiag>
The following existing diagnostics are now documented:
=over 4
=item *
L<Ambiguous use of %c resolved as operator %c|perldiag/"Ambiguous use of %c resolved as operator %c">
=item *
L<Ambiguous use of %c{%s} resolved to %c%s|perldiag/"Ambiguous use of %c{%s} resolved to %c%s">
=item *
L<Ambiguous use of %c{%s[...]} resolved to %c%s[...]|perldiag/"Ambiguous use of %c{%s[...]} resolved to %c%s[...]">
=item *
L<Ambiguous use of %c{%s{...}} resolved to %c%s{...}|perldiag/"Ambiguous use of %c{%s{...}} resolved to %c%s{...}">
=item *
L<Ambiguous use of -%s resolved as -&%s()|perldiag/"Ambiguous use of -%s resolved as -&%s()">
=item *
L<Invalid strict version format (%s)|perldiag/"Invalid strict version format (%s)">
=item *
L<Invalid version format (%s)|perldiag/"Invalid version format (%s)">
=item *
L<Invalid version object|perldiag/"Invalid version object">
=back
=head3 L<perlbook>
L<perlbook> has been expanded to cover many more popular books.
=head3 C<SvTRUE> macro
The documentation for the C<SvTRUE> macro in
L<perlapi> was simply wrong in stating that
get-magic is not processed. It has been corrected.
=head3 op manipulation functions
Several API functions that process optrees have been newly documented.
=head3 L<perlvar> revamp
L<perlvar> reorders the variables and groups them by topic. Each variable
introduced after Perl 5.000 notes the first version in which it is
available. L<perlvar> also has a new section for deprecated variables to
note when they were removed.
=head3 Array and hash slices in scalar context
These are now documented in L<perldata>.
=head3 C<use locale> and formats
L<perlform> and L<perllocale> have been corrected to state that
C<use locale> affects formats.
=head3 L<overload>
L<overload>'s documentation has practically undergone a rewrite. It
is now much more straightforward and clear.
=head3 perlhack and perlrepository revamp
The L<perlhack> document is now much shorter, and focuses on the Perl 5
development process and submitting patches to Perl. The technical content
has been moved to several new documents, L<perlsource>, L<perlinterp>,
L<perlhacktut>, and L<perlhacktips>. This technical content has
been only lightly edited.
The perlrepository document has been renamed to L<perlgit>. This new
document is just a how-to on using git with the Perl source code.
Any other content that used to be in perlrepository has been moved
to L<perlhack>.
=head3 Time::Piece examples
Examples in L<perlfaq4> have been updated to show the use of
L<Time::Piece>.
=head1 Diagnostics
The following additions or changes have been made to diagnostic output,
including warnings and fatal error messages. For the complete list of
diagnostic messages, see L<perldiag>.
=head2 New Diagnostics
=head3 New Errors
=over
=item Closure prototype called
This error occurs when a subroutine reference passed to an attribute
handler is called, if the subroutine is a closure [perl #68560].
=item Insecure user-defined property %s
Perl detected tainted data when trying to compile a regular
expression that contains a call to a user-defined character property
function, meaning C<\p{IsFoo}> or C<\p{InFoo}>.
See L<perlunicode/User-Defined Character Properties> and L<perlsec>.
=item panic: gp_free failed to free glob pointer - something is repeatedly re-creating entries
This new error is triggered if a destructor called on an object in a
typeglob that is being freed creates a new typeglob entry containing an
object with a destructor that creates a new entry containing an object etc.
=item Parsing code internal error (%s)
This new fatal error is produced when parsing
code supplied by an extension violates the
parser's API in a detectable way.
=item refcnt: fd %d%s
This new error only occurs if a internal consistency check fails when a
pipe is about to be closed.
=item Regexp modifier "/%c" may not appear twice
The regular expression pattern has one of the
mutually exclusive modifiers repeated.
=item Regexp modifiers "/%c" and "/%c" are mutually exclusive
The regular expression pattern has more than one of the mutually
exclusive modifiers.
=item Using !~ with %s doesn't make sense
This error occurs when C<!~> is used with C<s///r> or C<y///r>.
=back
=head3 New Warnings
=over
=item "\b{" is deprecated; use "\b\{" instead
=item "\B{" is deprecated; use "\B\{" instead
Use of an unescaped "{" immediately following a C<\b> or C<\B> is now
deprecated in order to reserve its use for Perl itself in a future release.
=item Operation "%s" returns its argument for ...
Performing an operation requiring Unicode semantics (such as case-folding)
on a Unicode surrogate or a non-Unicode character now triggers this
warning.
=item Use of qw(...) as parentheses is deprecated
See L</"Use of qw(...) as parentheses">, above, for details.
=back
=head2 Changes to Existing Diagnostics
=over 4
=item *
The "Variable $foo is not imported" warning that precedes a
C<strict 'vars'> error has now been assigned the "misc" category, so that
C<no warnings> will suppress it [perl #73712].
=item *
warn() and die() now produce "Wide character" warnings when fed a
character outside the byte range if C<STDERR> is a byte-sized handle.
=item *
The "Layer does not match this perl" error message has been replaced with
these more helpful messages [perl #73754]:
=over 4
=item *
PerlIO layer function table size (%d) does not match size expected by this
perl (%d)
=item *
PerlIO layer instance size (%d) does not match size expected by this perl
(%d)
=back
=item *
The "Found = in conditional" warning that is emitted when a constant is
assigned to a variable in a condition is now withheld if the constant is
actually a subroutine or one generated by C<use constant>, since the value
of the constant may not be known at the time the program is written
[perl #77762].
=item *
Previously, if none of the gethostbyaddr(), gethostbyname() and
gethostent() functions were implemented on a given platform, they would
all die with the message "Unsupported socket function 'gethostent' called",
with analogous messages for getnet*() and getserv*(). This has been
corrected.
=item *
The warning message about unrecognized regular expression escapes passed
through has been changed to include any literal "{" following the
two-character escape. For example, "\q{" is now emitted instead of "\q".
=back
=head1 Utility Changes
=head3 L<perlbug(1)>
=over 4
=item *
L<perlbug> now looks in the EMAIL environment variable for a return address
if the REPLY-TO and REPLYTO variables are empty.
=item *
L<perlbug> did not previously generate a "From:" header, potentially
resulting in dropped mail; it now includes that header.
=item *
The user's address is now used as the Return-Path.
Many systems these days don't have a valid Internet domain name, and
perlbug@perl.org does not accept email with a return-path that does
not resolve. So the user's address is now passed to sendmail so it's
less likely to get stuck in a mail queue somewhere [perl #82996].
=item *
L<perlbug> now always gives the reporter a chance to change the email
address it guesses for them (5.12.2).
=item *
L<perlbug> should no longer warn about uninitialized values when using the B<-d>
and B<-v> options (5.12.2).
=back
=head3 L<perl5db.pl>
=over
=item *
The remote terminal works after forking and spawns new sessions, one
per forked process.
=back
=head3 L<ptargrep>
=over 4
=item *
L<ptargrep> is a new utility to apply pattern matching to the contents of
files in a tar archive. It comes with C<Archive::Tar>.
=back
=head1 Configuration and Compilation
See also L</"Naming fixes in Policy_sh.SH may invalidate Policy.sh">,
above.
=over 4
=item *
CCINCDIR and CCLIBDIR for the mingw64 cross-compiler are now correctly
under F<$(CCHOME)\mingw\include> and F<\lib> rather than immediately below
F<$(CCHOME)>.
This means the "incpath", "libpth", "ldflags", "lddlflags" and
"ldflags_nolargefiles" values in F<Config.pm> and F<Config_heavy.pl> are now
set correctly.
=item *
C<make test.valgrind> has been adjusted to account for F<cpan/dist/ext>
separation.
=item *
On compilers that support it, B<-Wwrite-strings> is now added to cflags by
default.
=item *
The L<Encode> module can now (once again) be included in a static Perl
build. The special-case handling for this situation got broken in Perl
5.11.0, and has now been repaired.
=item *
The previous default size of a PerlIO buffer (4096 bytes) has been increased
to the larger of 8192 bytes and your local BUFSIZ. Benchmarks show that doubling
this decade-old default increases read and write performance by around
25% to 50% when using the default layers of perlio on top of unix. To choose
a non-default size, such as to get back the old value or to obtain an even
larger value, configure with:
./Configure -Accflags=-DPERLIOBUF_DEFAULT_BUFSIZ=N
where N is the desired size in bytes; it should probably be a multiple of
your page size.
=item *
An "incompatible operand types" error in ternary expressions when building
with C<clang> has been fixed (5.12.2).
=item *
Perl now skips setuid L<File::Copy> tests on partitions it detects mounted
as C<nosuid> (5.12.2).
=back
=head1 Platform Support
=head2 New Platforms
=over 4
=item AIX
Perl now builds on AIX 4.2 (5.12.1).
=back
=head2 Discontinued Platforms
=over 4
=item Apollo DomainOS
The last vestiges of support for this platform have been excised from
the Perl distribution. It was officially discontinued in version 5.12.0.
It had not worked for years before that.
=item MacOS Classic
The last vestiges of support for this platform have been excised from the
Perl distribution. It was officially discontinued in an earlier version.
=back
=head2 Platform-Specific Notes
=head3 AIX
=over
=item *
F<README.aix> has been updated with information about the XL C/C++ V11 compiler
suite (5.12.2).
=back
=head3 ARM
=over
=item *
The C<d_u32align> configuration probe on ARM has been fixed (5.12.2).
=back
=head3 Cygwin
=over 4
=item *
L<MakeMaker> has been updated to build manpages on cygwin.
=item *
Improved rebase behaviour
If a DLL is updated on cygwin the old imagebase address is reused.
This solves most rebase errors, especially when updating on core DLL's.
See L<http://www.tishler.net/jason/software/rebase/rebase-2.4.2.README>
for more information.
=item *
Support for the standard cygwin dll prefix (needed for FFIs)
=item *
Updated build hints file
=back
=head3 FreeBSD 7
=over
=item *
FreeBSD 7 no longer contains F</usr/bin/objformat>. At build time,
Perl now skips the F<objformat> check for versions 7 and higher and
assumes ELF (5.12.1).
=back
=head3 HP-UX
=over
=item *
Perl now allows B<-Duse64bitint> without promoting to C<use64bitall> on HP-UX
(5.12.1).
=back
=head3 IRIX
=over
=item *
Conversion of strings to floating-point numbers is now more accurate on
IRIX systems [perl #32380].
=back
=head3 Mac OS X
=over
=item *
Early versions of Mac OS X (Darwin) had buggy implementations of the
setregid(), setreuid(), setrgid(,) and setruid() functions, so Perl
would pretend they did not exist.
These functions are now recognised on Mac OS 10.5 (Leopard; Darwin 9) and
higher, as they have been fixed [perl #72990].
=back
=head3 MirBSD
=over
=item *
Previously if you built Perl with a shared F<libperl.so> on MirBSD (the
default config), it would work up to the installation; however, once
installed, it would be unable to find F<libperl>. Path handling is now
treated as in the other BSD dialects.
=back
=head3 NetBSD
=over
=item *
The NetBSD hints file has been changed to make the system malloc the
default.
=back
=head3 OpenBSD
=over
=item *
OpenBSD E<gt> 3.7 has a new malloc implementation which is I<mmap>-based,
and as such can release memory back to the OS; however, Perl's use of
this malloc causes a substantial slowdown, so we now default to using
Perl's malloc instead [perl #75742].
=back
=head3 OpenVOS
=over
=item *
Perl now builds again with OpenVOS (formerly known as Stratus VOS)
[perl #78132] (5.12.3).
=back
=head3 Solaris
=over
=item *
DTrace is now supported on Solaris. There used to be build failures, but
these have been fixed [perl #73630] (5.12.3).
=back
=head3 VMS
=over
=item *
Extension building on older (pre 7.3-2) VMS systems was broken because
configure.com hit the DCL symbol length limit of 1K. We now work within
this limit when assembling the list of extensions in the core build (5.12.1).
=item *
We fixed configuring and building Perl with B<-Uuseperlio> (5.12.1).
=item *
C<PerlIOUnix_open> now honours the default permissions on VMS.
When C<perlio> became the default and C<unix> became the default bottom layer,
the most common path for creating files from Perl became C<PerlIOUnix_open>,
which has always explicitly used C<0666> as the permission mask. This prevents
inheriting permissions from RMS defaults and ACLs, so to avoid that problem,
we now pass C<0777> to open(). In the VMS CRTL, C<0777> has a special
meaning over and above intersecting with the current umask; specifically, it
allows Unix syscalls to preserve native default permissions (5.12.3).
=item *
The shortening of symbols longer than 31 characters in the core C sources
and in extensions is now by default done by the C compiler rather than by
xsubpp (which could only do so for generated symbols in XS code). You can
reenable xsubpp's symbol shortening by configuring with -Uuseshortenedsymbols,
but you'll have some work to do to get the core sources to compile.
=item *
Record-oriented files (record format variable or variable with fixed control)
opened for write by the C<perlio> layer will now be line-buffered to prevent the
introduction of spurious line breaks whenever the perlio buffer fills up.
=item *
F<git_version.h> is now installed on VMS. This was an oversight in v5.12.0 which
caused some extensions to fail to build (5.12.2).
=item *
Several memory leaks in L<stat()|perlfunc/"stat FILEHANDLE"> have been fixed (5.12.2).
=item *
A memory leak in Perl_rename() due to a double allocation has been
fixed (5.12.2).
=item *
A memory leak in vms_fid_to_name() (used by realpath() and
realname()> has been fixed (5.12.2).
=back
=head3 Windows
See also L</"fork() emulation will not wait for signalled children"> and
L</"Perl source code is read in text mode on Windows">, above.
=over 4
=item *
Fixed build process for SDK2003SP1 compilers.
=item *
Compilation with Visual Studio 2010 is now supported.
=item *
When using old 32-bit compilers, the define C<_USE_32BIT_TIME_T> is now
set in C<$Config{ccflags}>. This improves portability when compiling
XS extensions using new compilers, but for a Perl compiled with old 32-bit
compilers.
=item *
C<$Config{gccversion}> is now set correctly when Perl is built using the
mingw64 compiler from L<http://mingw64.org> [perl #73754].
=item *
When building Perl with the mingw64 x64 cross-compiler C<incpath>,
C<libpth>, C<ldflags>, C<lddlflags> and C<ldflags_nolargefiles> values
in F<Config.pm> and F<Config_heavy.pl> were not previously being set
correctly because, with that compiler, the include and lib directories
are not immediately below C<$(CCHOME)> (5.12.2).
=item *
The build process proceeds more smoothly with mingw and dmake when
F<C:\MSYS\bin> is in the PATH, due to a C<Cwd> fix.
=item *
Support for building with Visual C++ 2010 is now underway, but is not yet
complete. See F<README.win32> or L<perlwin32> for more details.
=item *
The option to use an externally-supplied crypt(), or to build with no
crypt() at all, has been removed. Perl supplies its own crypt()
implementation for Windows, and the political situation that required
this part of the distribution to sometimes be omitted is long gone.
=back
=head1 Internal Changes
=head2 New APIs
=head3 CLONE_PARAMS structure added to ease correct thread creation
Modules that create threads should now create C<CLONE_PARAMS> structures
by calling the new function Perl_clone_params_new(), and free them with
Perl_clone_params_del(). This will ensure compatibility with any future
changes to the internals of the C<CLONE_PARAMS> structure layout, and that
it is correctly allocated and initialised.
=head3 New parsing functions
Several functions have been added for parsing Perl statements and
expressions. These functions are meant to be used by XS code invoked
during Perl parsing, in a recursive-descent manner, to allow modules to
augment the standard Perl syntax.
=over
=item *
L<parse_stmtseq()|perlapi/parse_stmtseq>
parses a sequence of statements, up to closing brace or EOF.
=item *
L<parse_fullstmt()|perlapi/parse_fullstmt>
parses a complete Perl statement, including optional label.
=item *
L<parse_barestmt()|perlapi/parse_barestmt>
parses a statement without a label.
=item *
L<parse_block()|perlapi/parse_block>
parses a code block.
=item *
L<parse_label()|perlapi/parse_label>
parses a statement label, separate from statements.
=item *
L<C<parse_fullexpr()>|perlapi/parse_fullexpr>,
L<C<parse_listexpr()>|perlapi/parse_listexpr>,
L<C<parse_termexpr()>|perlapi/parse_termexpr>, and
L<C<parse_arithexpr()>|perlapi/parse_arithexpr>
parse expressions at various precedence levels.
=back
=head3 Hints hash API
A new C API for introspecting the hinthash C<%^H> at runtime has been
added. See C<cop_hints_2hv>, C<cop_hints_fetchpvn>, C<cop_hints_fetchpvs>,
C<cop_hints_fetchsv>, and C<hv_copy_hints_hv> in L<perlapi> for details.
A new, experimental API has been added for accessing the internal
structure that Perl uses for C<%^H>. See the functions beginning with
C<cophh_> in L<perlapi>.
=head3 C interface to caller()
The C<caller_cx> function has been added as an XSUB-writer's equivalent of
caller(). See L<perlapi> for details.
=head3 Custom per-subroutine check hooks
XS code in an extension module can now annotate a subroutine (whether
implemented in XS or in Perl) so that nominated XS code will be called
at compile time (specifically as part of op checking) to change the op
tree of that subroutine. The compile-time check function (supplied by
the extension module) can implement argument processing that can't be
expressed as a prototype, generate customised compile-time warnings,
perform constant folding for a pure function, inline a subroutine
consisting of sufficiently simple ops, replace the whole call with a
custom op, and so on. This was previously all possible by hooking the
C<entersub> op checker, but the new mechanism makes it easy to tie the
hook to a specific subroutine. See L<perlapi/cv_set_call_checker>.
To help in writing custom check hooks, several subtasks within standard
C<entersub> op checking have been separated out and exposed in the API.
=head3 Improved support for custom OPs
Custom ops can now be registered with the new C<custom_op_register> C
function and the C<XOP> structure. This will make it easier to add new
properties of custom ops in the future. Two new properties have been added
already, C<xop_class> and C<xop_peep>.
C<xop_class> is one of the OA_*OP constants. It allows L<B> and other
introspection mechanisms to work with custom ops
that aren't BASEOPs. C<xop_peep> is a pointer to
a function that will be called for ops of this
type from C<Perl_rpeep>.
See L<perlguts/Custom Operators> and L<perlapi/Custom Operators> for more
detail.
The old C<PL_custom_op_names>/C<PL_custom_op_descs> interface is still
supported but discouraged.
=head3 Scope hooks
It is now possible for XS code to hook into Perl's lexical scope
mechanism at compile time, using the new C<Perl_blockhook_register>
function. See L<perlguts/"Compile-time scope hooks">.
=head3 The recursive part of the peephole optimizer is now hookable
In addition to C<PL_peepp>, for hooking into the toplevel peephole optimizer, a
C<PL_rpeepp> is now available to hook into the optimizer recursing into
side-chains of the optree.
=head3 New non-magical variants of existing functions
The following functions/macros have been added to the API. The C<*_nomg>
macros are equivalent to their non-C<_nomg> variants, except that they ignore
get-magic. Those ending in C<_flags> allow one to specify whether
get-magic is processed.
sv_2bool_flags
SvTRUE_nomg
sv_2nv_flags
SvNV_nomg
sv_cmp_flags
sv_cmp_locale_flags
sv_eq_flags
sv_collxfrm_flags
In some of these cases, the non-C<_flags> functions have
been replaced with wrappers around the new functions.
=head3 pv/pvs/sv versions of existing functions
Many functions ending with pvn now have equivalent C<pv/pvs/sv> versions.
=head3 List op-building functions
List op-building functions have been added to the
API. See L<op_append_elem|perlapi/op_append_elem>,
L<op_append_list|perlapi/op_append_list>, and
L<op_prepend_elem|perlapi/op_prepend_elem> in L<perlapi>.
=head3 C<LINKLIST>
The L<LINKLIST|perlapi/LINKLIST> macro, part of op building that
constructs the execution-order op chain, has been added to the API.
=head3 Localisation functions
The C<save_freeop>, C<save_op>, C<save_pushi32ptr> and C<save_pushptrptr>
functions have been added to the API.
=head3 Stash names
A stash can now have a list of effective names in addition to its usual
name. The first effective name can be accessed via the C<HvENAME> macro,
which is now the recommended name to use in MRO linearisations (C<HvNAME>
being a fallback if there is no C<HvENAME>).
These names are added and deleted via C<hv_ename_add> and
C<hv_ename_delete>. These two functions are I<not> part of the API.
=head3 New functions for finding and removing magic
The L<C<mg_findext()>|perlapi/mg_findext> and
L<C<sv_unmagicext()>|perlapi/sv_unmagicext>
functions have been added to the API.
They allow extension authors to find and remove magic attached to
scalars based on both the magic type and the magic virtual table, similar to how
sv_magicext() attaches magic of a certain type and with a given virtual table
to a scalar. This eliminates the need for extensions to walk the list of
C<MAGIC> pointers of an C<SV> to find the magic that belongs to them.
=head3 C<find_rundefsv>
This function returns the SV representing C<$_>, whether it's lexical
or dynamic.
=head3 C<Perl_croak_no_modify>
Perl_croak_no_modify() is short-hand for
C<Perl_croak("%s", PL_no_modify)>.
=head3 C<PERL_STATIC_INLINE> define
The C<PERL_STATIC_INLINE> define has been added to provide the best-guess
incantation to use for static inline functions, if the C compiler supports
C99-style static inline. If it doesn't, it'll give a plain C<static>.
C<HAS_STATIC_INLINE> can be used to check if the compiler actually supports
inline functions.
=head3 New C<pv_escape> option for hexadecimal escapes
A new option, C<PERL_PV_ESCAPE_NONASCII>, has been added to C<pv_escape> to
dump all characters above ASCII in hexadecimal. Before, one could get all
characters as hexadecimal or the Latin1 non-ASCII as octal.
=head3 C<lex_start>
C<lex_start> has been added to the API, but is considered experimental.
=head3 op_scope() and op_lvalue()
The op_scope() and op_lvalue() functions have been added to the API,
but are considered experimental.
=head2 C API Changes
=head3 C<PERL_POLLUTE> has been removed
The option to define C<PERL_POLLUTE> to expose older 5.005 symbols for
backwards compatibility has been removed. Its use was always discouraged,
and MakeMaker contains a more specific escape hatch:
perl Makefile.PL POLLUTE=1
This can be used for modules that have not been upgraded to 5.6 naming
conventions (and really should be completely obsolete by now).
=head3 Check API compatibility when loading XS modules
When Perl's API changes in incompatible ways (which usually happens between
major releases), XS modules compiled for previous versions of Perl will no
longer work. They need to be recompiled against the new Perl.
The C<XS_APIVERSION_BOOTCHECK> macro has been added to ensure that modules
are recompiled and to prevent users from accidentally loading modules
compiled for old perls into newer perls. That macro, which is called when
loading every newly compiled extension, compares the API version of the
running perl with the version a module has been compiled for and raises an
exception if they don't match.
=head3 Perl_fetch_cop_label
The first argument of the C API function C<Perl_fetch_cop_label> has changed
from C<struct refcounted_he *> to C<COP *>, to insulate the user from
implementation details.
This API function was marked as "may change", and likely isn't in use outside
the core. (Neither an unpacked CPAN nor Google's codesearch finds any other
references to it.)
=head3 GvCV() and GvGP() are no longer lvalues
The new GvCV_set() and GvGP_set() macros are now provided to replace
assignment to those two macros.
This allows a future commit to eliminate some backref magic between GV
and CVs, which will require complete control over assignment to the
C<gp_cv> slot.
=head3 CvGV() is no longer an lvalue
Under some circumstances, the CvGV() field of a CV is now
reference-counted. To ensure consistent behaviour, direct assignment to
it, for example C<CvGV(cv) = gv> is now a compile-time error. A new macro,
C<CvGV_set(cv,gv)> has been introduced to run this operation
safely. Note that modification of this field is not part of the public
API, regardless of this new macro (and despite its being listed in this section).
=head3 CvSTASH() is no longer an lvalue
The CvSTASH() macro can now only be used as an rvalue. CvSTASH_set()
has been added to replace assignment to CvSTASH(). This is to ensure
that backreferences are handled properly. These macros are not part of the
API.
=head3 Calling conventions for C<newFOROP> and C<newWHILEOP>
The way the parser handles labels has been cleaned up and refactored. As a
result, the newFOROP() constructor function no longer takes a parameter
stating what label is to go in the state op.
The newWHILEOP() and newFOROP() functions no longer accept a line
number as a parameter.
=head3 Flags passed to C<uvuni_to_utf8_flags> and C<utf8n_to_uvuni>
Some of the flags parameters to uvuni_to_utf8_flags() and
utf8n_to_uvuni() have changed. This is a result of Perl's now allowing
internal storage and manipulation of code points that are problematic
in some situations. Hence, the default actions for these functions has
been complemented to allow these code points. The new flags are
documented in L<perlapi>. Code that requires the problematic code
points to be rejected needs to change to use the new flags. Some flag
names are retained for backward source compatibility, though they do
nothing, as they are now the default. However the flags
C<UNICODE_ALLOW_FDD0>, C<UNICODE_ALLOW_FFFF>, C<UNICODE_ILLEGAL>, and
C<UNICODE_IS_ILLEGAL> have been removed, as they stem from a
fundamentally broken model of how the Unicode non-character code points
should be handled, which is now described in
L<perlunicode/Non-character code points>. See also the Unicode section
under L</Selected Bug Fixes>.
=head2 Deprecated C APIs
=over
=item C<Perl_ptr_table_clear>
C<Perl_ptr_table_clear> is no longer part of Perl's public API. Calling it
now generates a deprecation warning, and it will be removed in a future
release.
=item C<sv_compile_2op>
The sv_compile_2op() API function is now deprecated. Searches suggest
that nothing on CPAN is using it, so this should have zero impact.
It attempted to provide an API to compile code down to an optree, but failed
to bind correctly to lexicals in the enclosing scope. It's not possible to
fix this problem within the constraints of its parameters and return value.
=item C<find_rundefsvoffset>
The C<find_rundefsvoffset> function has been deprecated. It appeared that
its design was insufficient for reliably getting the lexical C<$_> at
run-time.
Use the new C<find_rundefsv> function or the C<UNDERBAR> macro
instead. They directly return the right SV
representing C<$_>, whether it's
lexical or dynamic.
=item C<CALL_FPTR> and C<CPERLscope>
Those are left from an old implementation of C<MULTIPLICITY> using C++ objects,
which was removed in Perl 5.8. Nowadays these macros do exactly nothing, so
they shouldn't be used anymore.
For compatibility, they are still defined for external C<XS> code. Only
extensions defining C<PERL_CORE> must be updated now.
=back
=head2 Other Internal Changes
=head3 Stack unwinding
The protocol for unwinding the C stack at the last stage of a C<die>
has changed how it identifies the target stack frame. This now uses
a separate variable C<PL_restartjmpenv>, where previously it relied on
the C<blk_eval.cur_top_env> pointer in the C<eval> context frame that
has nominally just been discarded. This change means that code running
during various stages of Perl-level unwinding no longer needs to take
care to avoid destroying the ghost frame.
=head3 Scope stack entries
The format of entries on the scope stack has been changed, resulting in a
reduction of memory usage of about 10%. In particular, the memory used by
the scope stack to record each active lexical variable has been halved.
=head3 Memory allocation for pointer tables
Memory allocation for pointer tables has been changed. Previously
C<Perl_ptr_table_store> allocated memory from the same arena system as
C<SV> bodies and C<HE>s, with freed memory remaining bound to those arenas
until interpreter exit. Now it allocates memory from arenas private to the
specific pointer table, and that memory is returned to the system when
C<Perl_ptr_table_free> is called. Additionally, allocation and release are
both less CPU intensive.
=head3 C<UNDERBAR>
The C<UNDERBAR> macro now calls C<find_rundefsv>. C<dUNDERBAR> is now a
noop but should still be used to ensure past and future compatibility.
=head3 String comparison routines renamed
The C<ibcmp_*> functions have been renamed and are now called C<foldEQ>,
C<foldEQ_locale>, and C<foldEQ_utf8>. The old names are still available as
macros.
=head3 C<chop> and C<chomp> implementations merged
The opcode bodies for C<chop> and C<chomp> and for C<schop> and C<schomp>
have been merged. The implementation functions Perl_do_chop() and
Perl_do_chomp(), never part of the public API, have been merged and
moved to a static function in F<pp.c>. This shrinks the Perl binary
slightly, and should not affect any code outside the core (unless it is
relying on the order of side-effects when C<chomp> is passed a I<list> of
values).
=head1 Selected Bug Fixes
=head2 I/O
=over 4
=item *
Perl no longer produces this warning:
$ perl -we 'open(my $f, ">", \my $x); binmode($f, "scalar")'
Use of uninitialized value in binmode at -e line 1.
=item *
Opening a glob reference via C<< open($fh, ">", \*glob) >> no longer
causes the glob to be corrupted when the filehandle is printed to. This would
cause Perl to crash whenever the glob's contents were accessed
[perl #77492].
=item *
PerlIO no longer crashes when called recursively, such as from a signal
handler. Now it just leaks memory [perl #75556].
=item *
Most I/O functions were not warning for unopened handles unless the
"closed" and "unopened" warnings categories were both enabled. Now only
C<use warnings 'unopened'> is necessary to trigger these warnings, as
had always been the intention.
=item *
There have been several fixes to PerlIO layers:
When C<binmode(FH, ":crlf")> pushes the C<:crlf> layer on top of the stack,
it no longer enables crlf layers lower in the stack so as to avoid
unexpected results [perl #38456].
Opening a file in C<:raw> mode now does what it advertises to do (first
open the file, then C<binmode> it), instead of simply leaving off the top
layer [perl #80764].
The three layers C<:pop>, C<:utf8>, and C<:bytes> didn't allow stacking when
opening a file. For example
this:
open(FH, ">:pop:perlio", "some.file") or die $!;
would throw an "Invalid argument" error. This has been fixed in this
release [perl #82484].
=back
=head2 Regular Expression Bug Fixes
=over
=item *
The regular expression engine no longer loops when matching
C<"\N{LATIN SMALL LIGATURE FF}" =~ /f+/i> and similar expressions
[perl #72998] (5.12.1).
=item *
The trie runtime code should no longer allocate massive amounts of memory,
fixing #74484.
=item *
Syntax errors in C<< (?{...}) >> blocks no longer cause panic messages
[perl #2353].
=item *
A pattern like C<(?:(o){2})?> no longer causes a "panic" error
[perl #39233].
=item *
A fatal error in regular expressions containing C<(.*?)> when processing
UTF-8 data has been fixed [perl #75680] (5.12.2).
=item *
An erroneous regular expression engine optimisation that caused regex verbs like
C<*COMMIT> sometimes to be ignored has been removed.
=item *
The regular expression bracketed character class C<[\8\9]> was effectively the
same as C<[89\000]>, incorrectly matching a NULL character. It also gave
incorrect warnings that the C<8> and C<9> were ignored. Now C<[\8\9]> is the
same as C<[89]> and gives legitimate warnings that C<\8> and C<\9> are
unrecognized escape sequences, passed-through.
=item *
A regular expression match in the right-hand side of a global substitution
(C<s///g>) that is in the same scope will no longer cause match variables
to have the wrong values on subsequent iterations. This can happen when an
array or hash subscript is interpolated in the right-hand side, as in
C<s|(.)|@a{ print($1), /./ }|g> [perl #19078].
=item *
Several cases in which characters in the Latin-1 non-ASCII range (0x80 to
0xFF) used not to match themselves, or used to match both a character class
and its complement, have been fixed. For instance, U+00E2 could match both
C<\w> and C<\W> [perl #78464] [perl #18281] [perl #60156].
=item *
Matching a Unicode character against an alternation containing characters
that happened to match continuation bytes in the former's UTF8
representation (like C<qq{\x{30ab}} =~ /\xab|\xa9/>) would cause erroneous
warnings [perl #70998].
=item *
The trie optimisation was not taking empty groups into account, preventing
"foo" from matching C</\A(?:(?:)foo|bar|zot)\z/> [perl #78356].
=item *
A pattern containing a C<+> inside a lookahead would sometimes cause an
incorrect match failure in a global match (for example, C</(?=(\S+))/g>)
[perl #68564].
=item *
A regular expression optimisation would sometimes cause a match with a
C<{n,m}> quantifier to fail when it should have matched [perl #79152].
=item *
Case-insensitive matching in regular expressions compiled under
C<use locale> now works much more sanely when the pattern or target
string is internally encoded in UTF8. Previously, under these
conditions the localeness was completely lost. Now, code points
above 255 are treated as Unicode, but code points between 0 and 255
are treated using the current locale rules, regardless of whether
the pattern or the string is encoded in UTF8. The few case-insensitive
matches that cross the 255/256 boundary are not allowed. For
example, 0xFF does not caselessly match the character at 0x178,
LATIN CAPITAL LETTER Y WITH DIAERESIS, because 0xFF may not be LATIN
SMALL LETTER Y in the current locale, and Perl has no way of knowing
if that character even exists in the locale, much less what code
point it is.
=item *
The C<(?|...)> regular expression construct no longer crashes if the final
branch has more sets of capturing parentheses than any other branch. This
was fixed in Perl 5.10.1 for the case of a single branch, but that fix did
not take multiple branches into account [perl #84746].
=item *
A bug has been fixed in the implementation of C<{...}> quantifiers in
regular expressions that prevented the code block in
C</((\w+)(?{ print $2 })){2}/> from seeing the C<$2> sometimes
[perl #84294].
=back
=head2 Syntax/Parsing Bugs
=over
=item *
C<when (scalar) {...}> no longer crashes, but produces a syntax error
[perl #74114] (5.12.1).
=item *
A label right before a string eval (C<foo: eval $string>) no longer causes
the label to be associated also with the first statement inside the eval
[perl #74290] (5.12.1).
=item *
The C<no 5.13.2> form of C<no> no longer tries to turn on features or
pragmata (like L<strict>) [perl #70075] (5.12.2).
=item *
C<BEGIN {require 5.12.0}> now behaves as documented, rather than behaving
identically to C<use 5.12.0>. Previously, C<require> in a C<BEGIN> block
was erroneously executing the C<use feature ':5.12.0'> and
C<use strict> behaviour, which only C<use> was documented to
provide [perl #69050].
=item *
A regression introduced in Perl 5.12.0, making
C<< my $x = 3; $x = length(undef) >> result in C<$x> set to C<3> has been
fixed. C<$x> will now be C<undef> [perl #85508] (5.12.2).
=item *
When strict "refs" mode is off, C<%{...}> in rvalue context returns
C<undef> if its argument is undefined. An optimisation introduced in Perl
5.12.0 to make C<keys %{...}> faster when used as a boolean did not take
this into account, causing C<keys %{+undef}> (and C<keys %$foo> when
C<$foo> is undefined) to be an error, which it should be so in strict
mode only [perl #81750].
=item *
Constant-folding used to cause
$text =~ ( 1 ? /phoo/ : /bear/)
to turn into
$text =~ /phoo/
at compile time. Now it correctly matches against C<$_> [perl #20444].
=item *
Parsing Perl code (either with string C<eval> or by loading modules) from
within a C<UNITCHECK> block no longer causes the interpreter to crash
[perl #70614].
=item *
String C<eval>s no longer fail after 2 billion scopes have been
compiled [perl #83364].
=item *
The parser no longer hangs when encountering certain Unicode characters,
such as U+387 [perl #74022].
=item *
Defining a constant with the same name as one of Perl's special blocks
(like C<INIT>) stopped working in 5.12.0, but has now been fixed
[perl #78634].
=item *
A reference to a literal value used as a hash key (C<$hash{\"foo"}>) used
to be stringified, even if the hash was tied [perl #79178].
=item *
A closure containing an C<if> statement followed by a constant or variable
is no longer treated as a constant [perl #63540].
=item *
C<state> can now be used with attributes. It
used to mean the same thing as
C<my> if any attributes were present [perl #68658].
=item *
Expressions like C<< @$a > 3 >> no longer cause C<$a> to be mentioned in
the "Use of uninitialized value in numeric gt" warning when C<$a> is
undefined (since it is not part of the C<< > >> expression, but the operand
of the C<@>) [perl #72090].
=item *
Accessing an element of a package array with a hard-coded number (as
opposed to an arbitrary expression) would crash if the array did not exist.
Usually the array would be autovivified during compilation, but typeglob
manipulation could remove it, as in these two cases which used to crash:
*d = *a; print $d[0];
undef *d; print $d[0];
=item *
The B<-C> command-line option, when used on the shebang line, can now be
followed by other options [perl #72434].
=item *
The C<B> module was returning C<B::OP>s instead of C<B::LOGOP>s for
C<entertry> [perl #80622]. This was due to a bug in the Perl core,
not in C<B> itself.
=back
=head2 Stashes, Globs and Method Lookup
Perl 5.10.0 introduced a new internal mechanism for caching MROs (method
resolution orders, or lists of parent classes; aka "isa" caches) to make
method lookup faster (so C<@ISA> arrays would not have to be searched
repeatedly). Unfortunately, this brought with it quite a few bugs. Almost
all of these have been fixed now, along with a few MRO-related bugs that
existed before 5.10.0:
=over
=item *
The following used to have erratic effects on method resolution, because
the "isa" caches were not reset or otherwise ended up listing the wrong
classes. These have been fixed.
=over
=item Aliasing packages by assigning to globs [perl #77358]
=item Deleting packages by deleting their containing stash elements
=item Undefining the glob containing a package (C<undef *Foo::>)
=item Undefining an ISA glob (C<undef *Foo::ISA>)
=item Deleting an ISA stash element (C<delete $Foo::{ISA}>)
=item Sharing @ISA arrays between classes (via C<*Foo::ISA = \@Bar::ISA> or
C<*Foo::ISA = *Bar::ISA>) [perl #77238]
=back
C<undef *Foo::ISA> would even stop a new C<@Foo::ISA> array from updating
caches.
=item *
Typeglob assignments would crash if the glob's stash no longer existed, so
long as the glob assigned to were named C<ISA> or the glob on either side of
the assignment contained a subroutine.
=item *
C<PL_isarev>, which is accessible to Perl via C<mro::get_isarev> is now
updated properly when packages are deleted or removed from the C<@ISA> of
other classes. This allows many packages to be created and deleted without
causing a memory leak [perl #75176].
=back
In addition, various other bugs related to typeglobs and stashes have been
fixed:
=over
=item *
Some work has been done on the internal pointers that link between symbol
tables (stashes), typeglobs, and subroutines. This has the effect that
various edge cases related to deleting stashes or stash entries (for example,
<%FOO:: = ()>), and complex typeglob or code-reference aliasing, will no
longer crash the interpreter.
=item *
Assigning a reference to a glob copy now assigns to a glob slot instead of
overwriting the glob with a scalar [perl #1804] [perl #77508].
=item *
A bug when replacing the glob of a loop variable within the loop has been fixed
[perl #21469]. This
means the following code will no longer crash:
for $x (...) {
*x = *y;
}
=item *
Assigning a glob to a PVLV used to convert it to a plain string. Now it
works correctly, and a PVLV can hold a glob. This would happen when a
nonexistent hash or array element was passed to a subroutine:
sub { $_[0] = *foo }->($hash{key});
# $_[0] would have been the string "*main::foo"
It also happened when a glob was assigned to, or returned from, an element
of a tied array or hash [perl #36051].
=item *
When trying to report C<Use of uninitialized value $Foo::BAR>, crashes could
occur if the glob holding the global variable in question had been detached
from its original stash by, for example, C<delete $::{"Foo::"}>. This has
been fixed by disabling the reporting of variable names in those
cases.
=item *
During the restoration of a localised typeglob on scope exit, any
destructors called as a result would be able to see the typeglob in an
inconsistent state, containing freed entries, which could result in a
crash. This would affect code like this:
local *@;
eval { die bless [] }; # puts an object in $@
sub DESTROY {
local $@; # boom
}
Now the glob entries are cleared before any destructors are called. This
also means that destructors can vivify entries in the glob. So Perl tries
again and, if the entries are re-created too many times, dies with a
"panic: gp_free ..." error message.
=item *
If a typeglob is freed while a subroutine attached to it is still
referenced elsewhere, the subroutine is renamed to C<__ANON__> in the same
package, unless the package has been undefined, in which case the C<__ANON__>
package is used. This could cause packages to be sometimes autovivified,
such as if the package had been deleted. Now this no longer occurs.
The C<__ANON__> package is also now used when the original package is
no longer attached to the symbol table. This avoids memory leaks in some
cases [perl #87664].
=item *
Subroutines and package variables inside a package whose name ends with
C<::> can now be accessed with a fully qualified name.
=back
=head2 Unicode
=over
=item *
What has become known as "the Unicode Bug" is almost completely resolved in
this release. Under C<use feature 'unicode_strings'> (which is
automatically selected by C<use 5.012> and above), the internal
storage format of a string no longer affects the external semantics.
[perl #58182].
There are two known exceptions:
=over
=item 1
The now-deprecated, user-defined case-changing
functions require utf8-encoded strings to operate. The CPAN module
L<Unicode::Casing> has been written to replace this feature without its
drawbacks, and the feature is scheduled to be removed in 5.16.
=item 2
quotemeta() (and its in-line equivalent C<\Q>) can also give different
results depending on whether a string is encoded in UTF-8. See
L<perlunicode/The "Unicode Bug">.
=back
=item *
Handling of Unicode non-character code points has changed.
Previously they were mostly considered illegal, except that in some
place only one of the 66 of them was known. The Unicode Standard
considers them all legal, but forbids their "open interchange".
This is part of the change to allow internal use of any code
point (see L</Core Enhancements>). Together, these changes resolve
[perl #38722], [perl #51918], [perl #51936], and [perl #63446].
=item *
Case-insensitive C<"/i"> regular expression matching of Unicode
characters that match multiple characters now works much more as
intended. For example
"\N{LATIN SMALL LIGATURE FFI}" =~ /ffi/ui
and
"ffi" =~ /\N{LATIN SMALL LIGATURE FFI}/ui
are both true. Previously, there were many bugs with this feature.
What hasn't been fixed are the places where the pattern contains the
multiple characters, but the characters are split up by other things,
such as in
"\N{LATIN SMALL LIGATURE FFI}" =~ /(f)(f)i/ui
or
"\N{LATIN SMALL LIGATURE FFI}" =~ /ffi*/ui
or
"\N{LATIN SMALL LIGATURE FFI}" =~ /[a-f][f-m][g-z]/ui
None of these match.
Also, this matching doesn't fully conform to the current Unicode
Standard, which asks that the matching be made upon the NFD
(Normalization Form Decomposed) of the text. However, as of this
writing (April 2010), the Unicode Standard is currently in flux about
what they will recommend doing with regard in such scenarios. It may be
that they will throw out the whole concept of multi-character matches.
[perl #71736].
=item *
Naming a deprecated character in C<\N{I<NAME>}> no longer leaks memory.
=item *
We fixed a bug that could cause C<\N{I<NAME>}> constructs followed by
a single C<"."> to be parsed incorrectly [perl #74978] (5.12.1).
=item *
C<chop> now correctly handles characters above C<"\x{7fffffff}">
[perl #73246].
=item *
Passing to C<index> an offset beyond the end of the string when the string
is encoded internally in UTF8 no longer causes panics [perl #75898].
=item *
warn() and die() now respect utf8-encoded scalars [perl #45549].
=item *
Sometimes the UTF8 length cache would not be reset on a value
returned by substr, causing C<length(substr($uni_string, ...))> to give
wrong answers. With C<${^UTF8CACHE}> set to -1, it would also produce
a "panic" error message [perl #77692].
=back
=head2 Ties, Overloading and Other Magic
=over
=item *
Overloading now works properly in conjunction with tied
variables. What formerly happened was that most ops checked their
arguments for overloading I<before> checking for magic, so for example
an overloaded object returned by a tied array access would usually be
treated as not overloaded [RT #57012].
=item *
Various instances of magic (like tie methods) being called on tied variables
too many or too few times have been fixed:
=over
=item *
C<< $tied->() >> did not always call FETCH [perl #8438].
=item *
Filetest operators and C<y///> and C<tr///> were calling FETCH too
many times.
=item *
The C<=> operator used to ignore magic on its right-hand side if the
scalar happened to hold a typeglob (if a typeglob was the last thing
returned from or assigned to a tied scalar) [perl #77498].
=item *
Dereference operators used to ignore magic if the argument was a
reference already (such as from a previous FETCH) [perl #72144].
=item *
C<splice> now calls set-magic (so changes made
by C<splice @ISA> are respected by method calls) [perl #78400].
=item *
In-memory files created by C<< open($fh, ">", \$buffer) >> were not calling
FETCH/STORE at all [perl #43789] (5.12.2).
=item *
utf8::is_utf8() now respects get-magic (like C<$1>) (5.12.1).
=back
=item *
Non-commutative binary operators used to swap their operands if the same
tied scalar was used for both operands and returned a different value for
each FETCH. For instance, if C<$t> returned 2 the first time and 3 the
second, then C<$t/$t> would evaluate to 1.5. This has been fixed
[perl #87708].
=item *
String C<eval> now detects taintedness of overloaded or tied
arguments [perl #75716].
=item *
String C<eval> and regular expression matches against objects with string
overloading no longer cause memory corruption or crashes [perl #77084].
=item *
L<readline|perlfunc/"readline EXPR"> now honors C<< <> >> overloading on tied
arguments.
=item *
C<< <expr> >> always respects overloading now if the expression is
overloaded.
Because "S<< <> as >> glob" was parsed differently from
"S<< <> as >> filehandle" from 5.6 onwards, something like C<< <$foo[0]> >> did
not handle overloading, even if C<$foo[0]> was an overloaded object. This
was contrary to the documentation for L<overload>, and meant that C<< <> >>
could not be used as a general overloaded iterator operator.
=item *
The fallback behaviour of overloading on binary operators was asymmetric
[perl #71286].
=item *
Magic applied to variables in the main package no longer affects other packages.
See L</Magic variables outside the main package> above [perl #76138].
=item *
Sometimes magic (ties, taintedness, etc.) attached to variables could cause
an object to last longer than it should, or cause a crash if a tied
variable were freed from within a tie method. These have been fixed
[perl #81230].
=item *
DESTROY methods of objects implementing ties are no longer able to crash by
accessing the tied variable through a weak reference [perl #86328].
=item *
Fixed a regression of kill() when a match variable is used for the
process ID to kill [perl #75812].
=item *
C<$AUTOLOAD> used to remain tainted forever if it ever became tainted. Now
it is correctly untainted if an autoloaded method is called and the method
name was not tainted.
=item *
C<sprintf> now dies when passed a tainted scalar for the format. It did
already die for arbitrary expressions, but not for simple scalars
[perl #82250].
=item *
C<lc>, C<uc>, C<lcfirst>, and C<ucfirst> no longer return untainted strings
when the argument is tainted. This has been broken since perl 5.8.9
[perl #87336].
=back
=head2 The Debugger
=over
=item *
The Perl debugger now also works in taint mode [perl #76872].
=item *
Subroutine redefinition works once more in the debugger [perl #48332].
=item *
When B<-d> is used on the shebang (C<#!>) line, the debugger now has access
to the lines of the main program. In the past, this sometimes worked and
sometimes did not, depending on the order in which things happened to be
arranged in memory [perl #71806].
=item *
A possible memory leak when using L<caller()|perlfunc/"caller EXPR"> to set
C<@DB::args> has been fixed (5.12.2).
=item *
Perl no longer stomps on C<$DB::single>, C<$DB::trace>, and C<$DB::signal>
if these variables already have values when C<$^P> is assigned to [perl #72422].
=item *
C<#line> directives in string evals were not properly updating the arrays
of lines of code (C<< @{"_< ..."} >>) that the debugger (or any debugging or
profiling module) uses. In threaded builds, they were not being updated at
all. In non-threaded builds, the line number was ignored, so any change to
the existing line number would cause the lines to be misnumbered
[perl #79442].
=back
=head2 Threads
=over
=item *
Perl no longer accidentally clones lexicals in scope within active stack
frames in the parent when creating a child thread [perl #73086].
=item *
Several memory leaks in cloning and freeing threaded Perl interpreters have been
fixed [perl #77352].
=item *
Creating a new thread when directory handles were open used to cause a
crash, because the handles were not cloned, but simply passed to the new
thread, resulting in a double free.
Now directory handles are cloned properly on Windows
and on systems that have a C<fchdir> function. On other
systems, new threads simply do not inherit directory
handles from their parent threads [perl #75154].
=item *
The typeglob C<*,>, which holds the scalar variable C<$,> (output field
separator), had the wrong reference count in child threads.
=item *
[perl #78494] When pipes are shared between threads, the C<close> function
(and any implicit close, such as on thread exit) no longer blocks.
=item *
Perl now does a timely cleanup of SVs that are cloned into a new
thread but then discovered to be orphaned (that is, their owners
are I<not> cloned). This eliminates several "scalars leaked"
warnings when joining threads.
=back
=head2 Scoping and Subroutines
=over
=item *
Lvalue subroutines are again able to return copy-on-write scalars. This
had been broken since version 5.10.0 [perl #75656] (5.12.3).
=item *
C<require> no longer causes C<caller> to return the wrong file name for
the scope that called C<require> and other scopes higher up that had the
same file name [perl #68712].
=item *
C<sort> with a C<($$)>-prototyped comparison routine used to cause the value
of C<@_> to leak out of the sort. Taking a reference to C<@_> within the
sorting routine could cause a crash [perl #72334].
=item *
Match variables (like C<$1>) no longer persist between calls to a sort
subroutine [perl #76026].
=item *
Iterating with C<foreach> over an array returned by an lvalue sub now works
[perl #23790].
=item *
C<$@> is now localised during calls to C<binmode> to prevent action at a
distance [perl #78844].
=item *
Calling a closure prototype (what is passed to an attribute handler for a
closure) now results in a "Closure prototype called" error message instead
of a crash [perl #68560].
=item *
Mentioning a read-only lexical variable from the enclosing scope in a
string C<eval> no longer causes the variable to become writable
[perl #19135].
=back
=head2 Signals
=over
=item *
Within signal handlers, C<$!> is now implicitly localized.
=item *
CHLD signals are no longer unblocked after a signal handler is called if
they were blocked before by C<POSIX::sigprocmask> [perl #82040].
=item *
A signal handler called within a signal handler could cause leaks or
double-frees. Now fixed [perl #76248].
=back
=head2 Miscellaneous Memory Leaks
=over
=item *
Several memory leaks when loading XS modules were fixed (5.12.2).
=item *
L<substr()|perlfunc/"substr EXPR,OFFSET,LENGTH,REPLACEMENT">,
L<pos()|perlfunc/"index STR,SUBSTR,POSITION">, L<keys()|perlfunc/"keys HASH">,
and L<vec()|perlfunc/"vec EXPR,OFFSET,BITS"> could, when used in combination
with lvalues, result in leaking the scalar value they operate on, and cause its
destruction to happen too late. This has now been fixed.
=item *
The postincrement and postdecrement operators, C<++> and C<-->, used to cause
leaks when used on references. This has now been fixed.
=item *
Nested C<map> and C<grep> blocks no longer leak memory when processing
large lists [perl #48004].
=item *
C<use I<VERSION>> and C<no I<VERSION>> no longer leak memory [perl #78436]
[perl #69050].
=item *
C<.=> followed by C<< <> >> or C<readline> would leak memory if C<$/>
contained characters beyond the octet range and the scalar assigned to
happened to be encoded as UTF8 internally [perl #72246].
=item *
C<eval 'BEGIN{die}'> no longer leaks memory on non-threaded builds.
=back
=head2 Memory Corruption and Crashes
=over
=item *
glob() no longer crashes when C<%File::Glob::> is empty and
C<CORE::GLOBAL::glob> isn't present [perl #75464] (5.12.2).
=item *
readline() has been fixed when interrupted by signals so it no longer
returns the "same thing" as before or random memory.
=item *
When assigning a list with duplicated keys to a hash, the assignment used to
return garbage and/or freed values:
@a = %h = (list with some duplicate keys);
This has now been fixed [perl #31865].
=item *
The mechanism for freeing objects in globs used to leave dangling
pointers to freed SVs, meaning Perl users could see corrupted state
during destruction.
Perl now frees only the affected slots of the GV, rather than freeing
the GV itself. This makes sure that there are no dangling refs or
corrupted state during destruction.
=item *
The interpreter no longer crashes when freeing deeply-nested arrays of
arrays. Hashes have not been fixed yet [perl #44225].
=item *
Concatenating long strings under C<use encoding> no longer causes Perl to
crash [perl #78674].
=item *
Calling C<< ->import >> on a class lacking an import method could corrupt
the stack, resulting in strange behaviour. For instance,
push @a, "foo", $b = bar->import;
would assign "foo" to C<$b> [perl #63790].
=item *
The C<recv> function could crash when called with the MSG_TRUNC flag
[perl #75082].
=item *
C<formline> no longer crashes when passed a tainted format picture. It also
taints C<$^A> now if its arguments are tainted [perl #79138].
=item *
A bug in how we process filetest operations could cause a segfault.
Filetests don't always expect an op on the stack, so we now use
TOPs only if we're sure that we're not C<stat>ing the C<_> filehandle.
This is indicated by C<OPf_KIDS> (as checked in ck_ftst) [perl #74542]
(5.12.1).
=item *
unpack() now handles scalar context correctly for C<%32H> and C<%32u>,
fixing a potential crash. split() would crash because the third item
on the stack wasn't the regular expression it expected. C<unpack("%2H",
...)> would return both the unpacked result and the checksum on the stack,
as would C<unpack("%2u", ...)> [perl #73814] (5.12.2).
=back
=head2 Fixes to Various Perl Operators
=over
=item *
The C<&>, C<|>, and C<^> bitwise operators no longer coerce read-only arguments
[perl #20661].
=item *
Stringifying a scalar containing "-0.0" no longer has the effect of turning
false into true [perl #45133].
=item *
Some numeric operators were converting integers to floating point,
resulting in loss of precision on 64-bit platforms [perl #77456].
=item *
sprintf() was ignoring locales when called with constant arguments
[perl #78632].
=item *
Combining the vector (C<%v>) flag and dynamic precision would
cause C<sprintf> to confuse the order of its arguments, making it
treat the string as the precision and vice-versa [perl #83194].
=back
=head2 Bugs Relating to the C API
=over
=item *
The C-level C<lex_stuff_pvn> function would sometimes cause a spurious
syntax error on the last line of the file if it lacked a final semicolon
[perl #74006] (5.12.1).
=item *
The C<eval_sv> and C<eval_pv> C functions now set C<$@> correctly when
there is a syntax error and no C<G_KEEPERR> flag, and never set it if the
C<G_KEEPERR> flag is present [perl #3719].
=item *
The XS multicall API no longer causes subroutines to lose reference counts
if called via the multicall interface from within those very subroutines.
This affects modules like L<List::Util>. Calling one of its functions with an
active subroutine as the first argument could cause a crash [perl #78070].
=item *
The C<SvPVbyte> function available to XS modules now calls magic before
downgrading the SV, to avoid warnings about wide characters [perl #72398].
=item *
The ref types in the typemap for XS bindings now support magical variables
[perl #72684].
=item *
C<sv_catsv_flags> no longer calls C<mg_get> on its second argument (the
source string) if the flags passed to it do not include SV_GMAGIC. So it
now matches the documentation.
=item *
C<my_strftime> no longer leaks memory. This fixes a memory leak in
C<POSIX::strftime> [perl #73520].
=item *
F<XSUB.h> now correctly redefines fgets under PERL_IMPLICIT_SYS [perl #55049]
(5.12.1).
=item *
XS code using fputc() or fputs() on Windows could cause an error
due to their arguments being swapped [perl #72704] (5.12.1).
=item *
A possible segfault in the C<T_PTROBJ> default typemap has been fixed
(5.12.2).
=item *
A bug that could cause "Unknown error" messages when
C<call_sv(code, G_EVAL)> is called from an XS destructor has been fixed
(5.12.2).
=back
=head1 Known Problems
This is a list of significant unresolved issues which are regressions
from earlier versions of Perl or which affect widely-used CPAN modules.
=over 4
=item *
C<List::Util::first> misbehaves in the presence of a lexical C<$_>
(typically introduced by C<my $_> or implicitly by C<given>). The variable
that gets set for each iteration is the package variable C<$_>, not the
lexical C<$_>.
A similar issue may occur in other modules that provide functions which
take a block as their first argument, like
foo { ... $_ ...} list
See also: L<http://rt.perl.org/rt3/Public/Bug/Display.html?id=67694>
=item *
readline() returns an empty string instead of a cached previous value
when it is interrupted by a signal
=item *
The changes in prototype handling break L<Switch>. A patch has been sent
upstream and will hopefully appear on CPAN soon.
=item *
The upgrade to F<ExtUtils-MakeMaker-6.57_05> has caused
some tests in the F<Module-Install> distribution on CPAN to
fail. (Specifically, F<02_mymeta.t> tests 5 and 21; F<18_all_from.t>
tests 6 and 15; F<19_authors.t> tests 5, 13, 21, and 29; and
F<20_authors_with_special_characters.t> tests 6, 15, and 23 in version
1.00 of that distribution now fail.)
=item *
On VMS, C<Time::HiRes> tests will fail due to a bug in the CRTL's
implementation of C<setitimer>: previous timer values would be cleared
if a timer expired but not if the timer was reset before expiring. HP
OpenVMS Engineering have corrected the problem and will release a patch
in due course (Quix case # QXCM1001115136).
=item *
On VMS, there were a handful of C<Module::Build> test failures we didn't
get to before the release; please watch CPAN for updates.
=back
=head1 Errata
=head2 keys(), values(), and each() work on arrays
You can now use the keys(), values(), and each() builtins on arrays;
previously you could use them only on hashes. See L<perlfunc> for details.
This is actually a change introduced in perl 5.12.0, but it was missed from
that release's L<perl5120delta>.
=head2 split() and C<@_>
split() no longer modifies C<@_> when called in scalar or void context.
In void context it now produces a "Useless use of split" warning.
This was also a perl 5.12.0 change that missed the perldelta.
=head1 Obituary
Randy Kobes, creator of http://kobesearch.cpan.org/ and
contributor/maintainer to several core Perl toolchain modules, passed
away on September 18, 2010 after a battle with lung cancer. The community
was richer for his involvement. He will be missed.
=head1 Acknowledgements
Perl 5.14.0 represents one year of development since
Perl 5.12.0 and contains nearly 550,000 lines of changes across nearly
3,000 files from 150 authors and committers.
Perl continues to flourish into its third decade thanks to a vibrant
community of users and developers. The following people are known to
have contributed the improvements that became Perl 5.14.0:
Aaron Crane, Abhijit Menon-Sen, Abigail, Ævar Arnfjörð Bjarmason,
Alastair Douglas, Alexander Alekseev, Alexander Hartmaier, Alexandr
Ciornii, Alex Davies, Alex Vandiver, Ali Polatel, Allen Smith, Andreas
König, Andrew Rodland, Andy Armstrong, Andy Dougherty, Aristotle
Pagaltzis, Arkturuz, Arvan, A. Sinan Unur, Ben Morrow, Bo Lindbergh,
Boris Ratner, Brad Gilbert, Bram, brian d foy, Brian Phillips, Casey
West, Charles Bailey, Chas. Owens, Chip Salzenberg, Chris 'BinGOs'
Williams, chromatic, Craig A. Berry, Curtis Jewell, Dagfinn Ilmari
Mannsåker, Dan Dascalescu, Dave Rolsky, David Caldwell, David Cantrell,
David Golden, David Leadbeater, David Mitchell, David Wheeler, Eric
Brine, Father Chrysostomos, Fingle Nark, Florian Ragwitz, Frank Wiegand,
Franz Fasching, Gene Sullivan, George Greer, Gerard Goossen, Gisle Aas,
Goro Fuji, Grant McLean, gregor herrmann, H.Merijn Brand, Hongwen Qiu,
Hugo van der Sanden, Ian Goodacre, James E Keenan, James Mastros, Jan
Dubois, Jay Hannah, Jerry D. Hedden, Jesse Vincent, Jim Cromie, Jirka
Hruška, John Peacock, Joshua ben Jore, Joshua Pritikin, Karl Williamson,
Kevin Ryde, kmx, Lars Dɪᴇᴄᴋᴏᴡ 迪拉斯, Larwan Berke, Leon Brocard, Leon
Timmermans, Lubomir Rintel, Lukas Mai, Maik Hentsche, Marty Pauley,
Marvin Humphrey, Matt Johnson, Matt S Trout, Max Maischein, Michael
Breen, Michael Fig, Michael G Schwern, Michael Parker, Michael Stevens,
Michael Witten, Mike Kelly, Moritz Lenz, Nicholas Clark, Nick Cleaton,
Nick Johnston, Nicolas Kaiser, Niko Tyni, Noirin Shirley, Nuno Carvalho,
Paul Evans, Paul Green, Paul Johnson, Paul Marquess, Peter J. Holzer,
Peter John Acklam, Peter Martini, Philippe Bruhat (BooK), Piotr Fusik,
Rafael Garcia-Suarez, Rainer Tammer, Reini Urban, Renee Baecker, Ricardo
Signes, Richard Möhn, Richard Soderberg, Rob Hoelz, Robin Barker, Ruslan
Zakirov, Salvador Fandiño, Salvador Ortiz Garcia, Shlomi Fish, Sinan
Unur, Sisyphus, Slaven Rezic, Steffen Müller, Steve Hay, Steven
Schubiger, Steve Peters, Sullivan Beck, Tatsuhiko Miyagawa, Tim Bunce,
Todd Rinaldo, Tom Christiansen, Tom Hukins, Tony Cook, Tye McQueen,
Vadim Konovalov, Vernon Lyon, Vincent Pit, Walt Mankowski, Wolfram
Humann, Yves Orton, Zefram, and Zsbán Ambrus.
This is woefully incomplete as it's automatically generated from version
control history. In particular, it doesn't include the names of the
(very much appreciated) contributors who reported issues in previous
versions of Perl that helped make Perl 5.14.0 better. For a more complete
list of all of Perl's historical contributors, please see the C<AUTHORS>
file in the Perl 5.14.0 distribution.
Many of the changes included in this version originated in the CPAN
modules included in Perl's core. We're grateful to the entire CPAN
community for helping Perl to flourish.
=head1 Reporting Bugs
If you find what you think is a bug, you might check the articles
recently posted to the comp.lang.perl.misc newsgroup and the Perl
bug database at http://rt.perl.org/perlbug/ . There may also be
information at http://www.perl.org/ , the Perl Home Page.
If you believe you have an unreported bug, please run the L<perlbug>
program included with your release. Be sure to trim your bug down
to a tiny but sufficient test case. Your bug report, along with the
output of C<perl -V>, will be sent off to perlbug@perl.org to be
analysed by the Perl porting team.
If the bug you are reporting has security implications, which make it
inappropriate to send to a publicly archived mailing list, then please send
it to perl5-security-report@perl.org. This points to a closed subscription
unarchived mailing list, which includes all the core committers, who are able
to help assess the impact of issues, figure out a resolution, and help
co-ordinate the release of patches to mitigate or fix the problem across all
platforms on which Perl is supported. Please use this address for
security issues in the Perl core I<only>, not for modules independently
distributed on CPAN.
=head1 SEE ALSO
The F<Changes> file for an explanation of how to view exhaustive details
on what changed.
The F<INSTALL> file for how to build Perl.
The F<README> file for general stuff.
The F<Artistic> and F<Copying> files for copyright information.
=cut
|