Bug 17760 (Enumerator.Reset) - System.Collection.Generic.List<T>.Enumerator.Reset() does not reset 'current' field.
Summary: System.Collection.Generic.List<T>.Enumerator.Reset() does not reset 'current'...
Alias: Enumerator.Reset
Product: Class Libraries
Classification: Mono
Component: mscorlib ()
Version: unspecified
Hardware: All All
: --- normal
Target Milestone: Untriaged
Assignee: Marek Safar
URL: https://github.com/mono/mono/blob/mas...
Depends on:
Reported: 2014-02-13 16:08 UTC by Aberro
Modified: 2014-02-13 16:28 UTC (History)
2 users (show)

Tags: generics; list; enumerator
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report on GitHub or Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description Aberro 2014-02-13 16:08:29 UTC
Description of Problem:

Steps to reproduce the problem:
1. Get enumerator of List with some items in it.
2. Make some MoveNext()
3. Invoke Reset()
4. ...
5. PROFIT?..

Actual Results: 
Enumerator.Current returns last Current value that was valid before calling Reset().

Expected Results: 
Enumerator.Current should return default(T) value after Reset().

How often does this happen? 

Additional Information:
Comment 1 Marek Safar 2014-02-13 16:28:49 UTC
Fixed in master