D: Fix allprotected_not.i compilation.

The director cycle breaking code was emitted when protectors
were not actually enabled on the parent class, leading to
swigIsMethodOverridden being called but not declared.