nir/lower_variables: Use a for loop for get_deref_node
nir/lower_variables: Use a for loop for get_deref_node

Reviewed-by: Connor Abbott <71178acffcc112b21e5858656e5751f5e4aa9364@gmail.com>

metora/MesaGLSLCompiler,metora/MesaGLSLCompiler,metora/MesaGLSLCompiler