Use of forward declarations is confusing

Create issue
Issue #45 closed
David Williams created an issue

Several people (including myself...) have been confused with the use of forward declarations. Because PolyVox provides these in PolyVoxForwardDeclarations.h it means that a user can forget to include a required header file but the forward declaration can be included through some other path. The compiler then recognizes the class but doesn't have the definition, which results in an error message much more confusing than if it just hadn't found it.

See here:

Is this use of forward declarations beneficial, especially in a project like PolyVox which is almost entirely header-based? Should it be restructured?

Comments (1)

  1. Log in to comment