Commit 1d2af38
Use the new `PathBase.scandir()` method in `PathBase.glob()`, which greatly
reduces the number of `PathBase.stat()` calls needed when globbing.
There are no user-facing changes, because the pathlib ABCs are still
private and `Path.glob()` doesn't use the implementation in its superclass.
1 parent 21d2e70 commit 1d2af38
File tree
3 files changed
+10
-25
lines changed- Lib
- pathlib
- test/test_pathlib
3 files changed
+10
-25
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
364 | 364 | | |
365 | 365 | | |
366 | 366 | | |
367 | | - | |
368 | | - | |
369 | | - | |
370 | | - | |
371 | | - | |
372 | | - | |
373 | 367 | | |
374 | 368 | | |
375 | 369 | | |
| |||
438 | 432 | | |
439 | 433 | | |
440 | 434 | | |
| 435 | + | |
441 | 436 | | |
442 | 437 | | |
443 | 438 | | |
| |||
446 | 441 | | |
447 | 442 | | |
448 | 443 | | |
449 | | - | |
| 444 | + | |
450 | 445 | | |
451 | 446 | | |
452 | 447 | | |
| |||
495 | 490 | | |
496 | 491 | | |
497 | 492 | | |
| 493 | + | |
498 | 494 | | |
499 | 495 | | |
500 | 496 | | |
| |||
504 | 500 | | |
505 | 501 | | |
506 | 502 | | |
507 | | - | |
| 503 | + | |
508 | 504 | | |
509 | 505 | | |
510 | 506 | | |
| |||
533 | 529 | | |
534 | 530 | | |
535 | 531 | | |
536 | | - | |
537 | 532 | | |
538 | 533 | | |
539 | 534 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
94 | 94 | | |
95 | 95 | | |
96 | 96 | | |
97 | | - | |
98 | | - | |
99 | | - | |
100 | | - | |
101 | | - | |
102 | | - | |
103 | | - | |
104 | | - | |
| 97 | + | |
105 | 98 | | |
106 | 99 | | |
107 | 100 | | |
108 | 101 | | |
109 | 102 | | |
110 | 103 | | |
111 | | - | |
112 | | - | |
113 | | - | |
114 | | - | |
115 | | - | |
116 | 104 | | |
117 | 105 | | |
118 | 106 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1633 | 1633 | | |
1634 | 1634 | | |
1635 | 1635 | | |
1636 | | - | |
1637 | | - | |
| 1636 | + | |
| 1637 | + | |
| 1638 | + | |
| 1639 | + | |
1638 | 1640 | | |
1639 | 1641 | | |
1640 | 1642 | | |
| |||
2479 | 2481 | | |
2480 | 2482 | | |
2481 | 2483 | | |
2482 | | - | |
| 2484 | + | |
2483 | 2485 | | |
2484 | 2486 | | |
2485 | 2487 | | |
| |||
0 commit comments