But line 133 already handled a bare nan and Mul already returns nan if a factor is nan. So I don't think that we will ever encounter a c that is nan at this point in the code. That's why I am suggesting the movement of the test.