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
Matthias (t3l) said:
I just noticed that this is only an issue with the string representation and that the underlying queue/deqeue codes works fine. Anyway, this should be fixed. However, I reduced the priority to "minor".
a.dequeueres34: Int = 2a.dequeueres35: Int = 3a.dequeueres36: Int = 10
Kevin Mas Ruiz (kmruiz) said (edited on Aug 3, 2015 11:14:20 AM UTC):
I don't agree, because that is a implementation detail that the client should ignore. I really think it's a minor bug.
Edit: ------
PriorityQueue is supposed to have, from the client side of the class, always the correct order. If internally it does this incrementally or not is not important for the user.
Also having a simple and reliable inspection method like toString is very useful for assertions when unit testing.
Well, the problem is best described by code. Look at the order of the elements after I add the first "3". It seems to be wrong.
The text was updated successfully, but these errors were encountered: