codegen: Retain array length for cast from/to generic array
codegen: Retain array length for cast from/to generic array

Fixes bug 687728.

GNOME/vala,Distrotech/vala,playya/vala,playya/vala,spidermonkdust/vala,spidermonkdust/vala,frida/vala,playya/vala,frida/vala,flobrosch/vala-fixes,severinh/vala,GNOME/vala,flobrosch/vala-fixes,severinh/vala,Distrotech/vala,rvu95/vala,frida/vala,Distrotech/vala,GNOME/vala,frida/vala,spidermonkdust/vala,frida/vala,xdave/pvala,severinh/vala,rvu95/vala,rvu95/vala,flobrosch/vala-fixes,GNOME/vala