Skip to content

Commit 22c0226

Browse files
committed
Lint docs: Sort versions, so that stable comes first
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.
1 parent c950602 commit 22c0226

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)