Ill say this again : GLSL is not C! Kinda makes you admire people who make shaders work though doesnt it :-).
The standard has only one chance of succeeding : if board manufacturers implement it correctly. Otherwise nobody will use it. You see Nvidias little game here. Pissed at the fact CG wasnt chosen to be the OpenGL standard (giving them ... oh an 18 month lead on ATi) but instead a good standard proposed by 3dlabs, they have deliberately placed less resources in getting glsl right and in some cases deliberately made choices that hijack it. Its despicable. Its business.
Meanwhile ATi are much more correct but fail in lots of areas (like arrays).
Whilst its true you can create an array of any type, you can only do so with a constructor, not a definition. Therefore:
float a[2]={1.0,2.0}; is completely illegal but Nvidia allow it, screwing us all by undermining the standard and locking you into their hardware with your shader.
Meanwhile Ati allow the legal syntax:
float a[2]=float[2](1.0,2.0);
Great! Only their hardware doesnt support it!!!
So in the end they are as bad as each other when it comes to glsl.
So yes, Rbraz, you can create - through constructor syntax only - arrays of any type. They wont work though. And no array declarations in C form are legal even in next gen shaders. Don't ask me why but its so. But dont misunderstand - you should be able to treat arrays as first class citizens in version 120 - but it simply does not work...there is specs and reality. I think your GLSL book also says there is a noise function...but only 3dlabs cards ever implemented it.
Taj