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
{{ message }}
Repository navigation
Consider replacing foreach on IList/List with for loop #138
When parsing thousands of scripts foreach approach generates at least N * 2 unnecessary enumerators, e.g. in TSQL160Parser here and here.
Also somewhere in the deep of generated code it produces lots (~N*10) of enumerators on IList<Identifier> but I was unable to locate this place. It'd be great if this was fixed too.
Also please take a look at this IEnumerableimplicit cast wherease the source is List and some code addressing this IEnumerable with foreach could be actually rewritten into more optimal for. And there is another suspicious foreach a couple of lines below which may affect iterating through children objects. Perhaps it will work faster and with less garbage objects for GC if implemented as for loop and index-based access to IList elements.
Activity