Closed mcdonnelldean closed 8 years ago
@mcollina Re coveralls, I can improve coverage but it will involve moving the equal()
function and exposing it. Thoughts?
@mcollina You can set a number in coveralls so that coverage doesn't report errors like above. Right now I think it will fire every time there is any decrease.
@davidmarkclements @mcollina Could you sanity check something. Since we return early, are we defeating the purpose of the XOR check in the first place since it's for time based comparisons.
You can set a number in coveralls so that coverage doesn't report errors like above. Right now I think it will fire every time there is any decrease.
@mcdonnelldean I hope it's good now.
Could you sanity check something. Since we return early, are we defeating the purpose of the XOR check in the first place since it's for time based comparisons.
Nope, because you can have a lot of patterns like { cmd: 'x', token: VARIABLE }
.
LGTM for me.
Awesome, and your fix worked, it now passes fully. I'm stuck for time for release until later this afternoon.
CC: @mcollina @davidmarkclements
In a weird twist of fate, on average, the XOR check is faster than simple equality.
With XOR
Simple === check
Having said that the variance is so little over more than 10 runs that they are for all intents and purposes comparable performance wise. Because of this I have opted to make it the default rather than providing an option to enable.
Thoughts?