fix #11 make it impossible to create degenerate primitives