Fix a warning by conditionalizing a forward declaration.