Move declaration into the scope where it is needed.