Declare functions before they're used.