From 8880e309857873a38bc2aa8c09060dbedd5a29c6 Mon Sep 17 00:00:00 2001 From: Anton Vasiliev Date: Tue, 24 Mar 2020 15:48:04 +0300 Subject: [PATCH] Fix incorrect comment in Queue.Dequeue (#34006) The comment in front of System.Collections.Queue.Dequeue() changed to match actual routine behavior. --- .../System.Collections.NonGeneric/src/System/Collections/Queue.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libraries/System.Collections.NonGeneric/src/System/Collections/Queue.cs b/src/libraries/System.Collections.NonGeneric/src/System/Collections/Queue.cs index 5dbb967..890d83e 100644 --- a/src/libraries/System.Collections.NonGeneric/src/System/Collections/Queue.cs +++ b/src/libraries/System.Collections.NonGeneric/src/System/Collections/Queue.cs @@ -182,7 +182,7 @@ namespace System.Collections } // Removes the object at the head of the queue and returns it. If the queue - // is empty, this method simply returns null. + // is empty, this method throws an InvalidOperationException. public virtual object? Dequeue() { if (Count == 0) -- 2.7.4