if-range. Closes #1754