fix #2575, unexpected linspace behavior with integers