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
In elm-review, I currently sort comments by their start position.
I seem to remember that the comments were in a somewhat random order, but I can't reproduce anything else than just the reverse order.
Currently we have:
moduleTestModuleexposing (..)
-- 1a =""-- 2
which gives the following comment list:
[Node<range>"-- 2",Node<range>"-- 1"]
and I think that having it be in the reverse order will be more intuitive and useful:
[Node<range>"-- 1",Node<range>"-- 2"]
Side-note: I seem to understand that the way documentation is added in post-processing is by going through all comments and looking at ranges.
I think that having sorted them be sorted can lead to optimizations, like not going further down the list if the start range of the item to look for is before the current item's start range (In other words, using a recursive function rather than List.filter + List.head). I am not good at benchmarking, but that does sound faster to me than the current way, and sorting comments would help with that.
The text was updated successfully, but these errors were encountered:
In
elm-review
, I currently sort comments by their start position.I seem to remember that the comments were in a somewhat random order, but I can't reproduce anything else than just the reverse order.
Currently we have:
which gives the following comment list:
and I think that having it be in the reverse order will be more intuitive and useful:
Side-note: I seem to understand that the way documentation is added in post-processing is by going through all comments and looking at ranges.
I think that having sorted them be sorted can lead to optimizations, like not going further down the list if the start range of the item to look for is before the current item's start range (In other words, using a recursive function rather than List.filter + List.head). I am not good at benchmarking, but that does sound faster to me than the current way, and sorting comments would help with that.
The text was updated successfully, but these errors were encountered: