Rearrange function order in source file to match header