I've never tried declaring a static variable in the initialisation expression of a for loop. It that legal?