Move references to top of file