fix order of declaration