Maintenance Ruby 3.4 gets fixes, but no new features. Switch to Ruby 4.0 →
instance method
SyntaxSuggest::PriorityQueue#sorted
sorted
lib/syntax_suggest/priority_queue.rb
View on GitHub ↗
# File tmp/rubies/ruby-3.4.1/lib/syntax_suggest/priority_queue.rb, line 55
def sorted
out = []
elements = @elements.dup
while (element = pop)
out << element
end
@elements = elements
out.reverse
end
Used for testing, extremely not performant