Quantcast
Channel: YouTrackReSharper (RSRP) - Bug and Issue Tracker
Viewing all articles
Browse latest Browse all 106942

RSRP-296676: GetEnumerator() methods of many collections lack [Pure] annotation

$
0
0
Reporter Vladimir Reshetnikov (nikov) Vladimir Reshetnikov (nikov)
Created Apr 21, 2012 6:49:04 AM
Updated Apr 21, 2012 11:40:51 AM
Priority Normal
Type Bug
Fix versions No Fix versions
State Submitted
Assignee Alexey Kuptsov (alexey.kuptsov)
Subsystem No subsystem
Affected versions No Affected versions
Fixed in build No Fixed in build
using System.Collections;
using System.Collections.Generic;
using System.Collections.Specialized;
using System.Diagnostics;

class A
{
    static void Foo()
    {
        var x1 = new List<int>();
        x1.GetEnumerator(); // Correct warning

        var x2 = new Stack<int>();
        x2.GetEnumerator();

        var x3 = new Queue<int>();
        x3.GetEnumerator();

        var x4 = new LinkedList<int>();
        x4.GetEnumerator();

        var x6 = new Dictionary<int, int>();
        x6.GetEnumerator();

        var x7 = new StringCollection();
        x7.GetEnumerator();

        var x8 = new NameValueCollection();
        x8.GetEnumerator();

        var x9 = new ArrayList();
        x9.GetEnumerator();

        var x10 = new Stack();
        x10.GetEnumerator();

        var x11 = new ProcessModuleCollection(new ProcessModule[0]);
        x11.GetEnumerator();
    }
}

Viewing all articles
Browse latest Browse all 106942

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>