Auto Arrays & casting

BlitzMax Forums/BlitzMax Programming/Auto Arrays & casting

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

Local a:Double[][] = [[0.5,0.5],[1.0,1.0]] 'error
Local a:Double[][] = [[0.5!,0.5!],[1.0!,1.0!]] 'works

It's the same with Floats & Integers.

Could we have the compiler do necessary casting instead of having to specify it? Or is there a *deep* reason we need to be specific?

It's just a small nuisance :)

Local vert:Double[][] = ..
[[-0.5!, -0.5!, -0.5!],..
[ 0.5!, -0.5!, -0.5!],..
[ 0.5!, -0.5!, 0.5!],..
[-0.5!, -0.5!, 0.5!],..
[-0.5!, 0.5!, -0.5!],..
[ 0.5!, 0.5!, -0.5!],..
[ 0.5!, 0.5!, 0.5!],..
[-0.5!, 0.5!, 0.5!]]

Cheers
Tom