Skip to content

Commit

Permalink
Add code comment where we take the next-best arity (currently lowest)
Browse files Browse the repository at this point in the history
  • Loading branch information
Moosieus committed Nov 15, 2024
1 parent a83ea03 commit dc6e91d
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ defmodule Lexical.RemoteControl.CodeIntelligence.Definition do
|> Stream.flat_map(&resolve_defdelegate/1)
|> Stream.uniq_by(& &1.subject)
|> maybe_reject_private_defs(m, nlss, pos)
# sort by arity and take the lowest.
|> Enum.sort(fn %Entry{} = a, %Entry{} = b ->
String.last(a.subject) < String.last(b.subject)
end)
Expand Down

0 comments on commit dc6e91d

Please sign in to comment.