You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
refactor: replace sort package usage with slices/cmp
Modernise pre-1.21 sorting idioms: sort.Strings/Ints/Slice become
slices.Sort/SortFunc, Names() collapses to slices.Sorted(maps.Keys),
and the sort-then-take-first pattern in the lexer registry becomes
slices.MinFunc, which is O(n) and deterministically breaks priority
ties by registration order.
The exported Lexers/PrioritisedLexers sort.Interface method sets are
retained for external users; PrioritisedLexers.Less now delegates to
the new compareLexersByPriority comparator so the ordering logic has
a single source of truth.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
0 commit comments