I was just considering this situation last night when playing with opengl. OderWat - that's the solution I'm using, but it does get a bit awkward sometimes: import opengl var x: array[4, GLVectorf2] = [ [1.0.GLFloat, 1.0], [1.0.GLFloat, 1.0], [1.0.GLFloat, 1.0], [1.0.GLFloat, 1.0] ]
I wondered if I could use a converter to automatically downgrade float64 to GLfloat but this didn't change anything (maybe I'm using it wrong?): import opengl converter toGLFloat(i: float): GLfloat = i.GLfloat var x: array[4, GLVectorf2] = [ # got array constructor for float64 but expected GLfloat [1.0, 1.0], [1.0, 1.0], [1.0, 1.0], [1.0, 1.0] ]