Skip to content

Commit c5dbd1d

Browse files
Lint docs: Sort versions, so that stable comes first (#15149)
I expect that most people use stable Clippy. So having `master` be the first documentation link in the list is weird. Now the versions are sorted stable->beta->master. changelog: none
2 parents cd15aeb + 22c0226 commit c5dbd1d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

util/versions.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@
66
import sys
77

88
def key(v):
9-
if v == "master":
10-
return sys.maxsize
119
if v == "stable":
12-
return sys.maxsize - 1
10+
return sys.maxsize
1311
if v == "beta":
12+
return sys.maxsize - 1
13+
if v == "master":
1414
return sys.maxsize - 2
1515
if v == "pre-1.29.0":
1616
return -1

0 commit comments

Comments
 (0)