Ensure correct handling of units in _arithmetic

Closes #2413