Commit 0588f2c
Improve
* Restrict `middle(::AbstractRange)` eltype and improve performance
* Revert eltype restriction
* Apply suggestions from code review
Co-authored-by: Milan Bouchet-Valat <[email protected]>
* Fix typo: `r` -> `a`
* Update test/runtests.jl
Co-authored-by: Milan Bouchet-Valat <[email protected]>
* Fix CI failure
* Add `middle(0:typemax(Int))` test
Co-authored-by: Milan Bouchet-Valat <[email protected]>middle(::AbstractRange) performance (#116)1 parent 576db0f commit 0588f2c
2 files changed
+24
-22
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
765 | 765 | | |
766 | 766 | | |
767 | 767 | | |
768 | | - | |
| 768 | + | |
769 | 769 | | |
770 | | - | |
771 | | - | |
| 770 | + | |
| 771 | + | |
772 | 772 | | |
773 | 773 | | |
774 | 774 | | |
775 | 775 | | |
776 | 776 | | |
777 | 777 | | |
778 | | - | |
779 | | - | |
780 | | - | |
781 | | - | |
782 | | - | |
783 | | - | |
784 | | - | |
785 | | - | |
786 | | - | |
787 | | - | |
788 | | - | |
789 | | - | |
790 | 778 | | |
791 | 779 | | |
792 | 780 | | |
| |||
801 | 789 | | |
802 | 790 | | |
803 | 791 | | |
| 792 | + | |
| 793 | + | |
| 794 | + | |
| 795 | + | |
| 796 | + | |
804 | 797 | | |
805 | 798 | | |
806 | 799 | | |
| |||
997 | 990 | | |
998 | 991 | | |
999 | 992 | | |
1000 | | - | |
| 993 | + | |
1001 | 994 | | |
1002 | | - | |
| 995 | + | |
1003 | 996 | | |
1004 | 997 | | |
1005 | 998 | | |
| |||
1012 | 1005 | | |
1013 | 1006 | | |
1014 | 1007 | | |
1015 | | - | |
| 1008 | + | |
1016 | 1009 | | |
1017 | 1010 | | |
1018 | 1011 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
24 | 33 | | |
25 | 34 | | |
26 | 35 | | |
| |||
547 | 556 | | |
548 | 557 | | |
549 | 558 | | |
550 | | - | |
| 559 | + | |
551 | 560 | | |
552 | 561 | | |
553 | 562 | | |
554 | 563 | | |
555 | | - | |
| 564 | + | |
556 | 565 | | |
557 | 566 | | |
558 | 567 | | |
559 | | - | |
| 568 | + | |
560 | 569 | | |
561 | 570 | | |
562 | 571 | | |
| |||
958 | 967 | | |
959 | 968 | | |
960 | 969 | | |
961 | | - | |
| 970 | + | |
0 commit comments