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
My guess is that lazy was not considered when writing the cop. This sounds like a reasonable request to not register an offense when lazy is used. This is probably impacting Performance/Count as well. This should be pretty easy to implement.
Hi there. First, many thanks for the great work :)
Performance/Detect doesn't look to handle Enumerator::Lazy instances.
2.2.2 :001 > [1, 2, 3, 4, 5].lazy.select { i % 2 == 0 }.first(2) => [2, 4]
Not sure if this is known and/or planning in supporting it ?
One workaround is to
take(n).to_a
The text was updated successfully, but these errors were encountered: