Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Non standard forward declaration assuming namespace breaks unity builds #374

Open
kunitoki opened this issue Jul 29, 2024 · 0 comments
Open

Comments

@kunitoki
Copy link

In some files (nested_bool.cpp nested_trigger.cpp and nested_number.cpp), there are wrong forward declarations:

using namespace rive;
class StateMachineInstance; // < this is not in the global namespace, and results in a different symbol because it's not enclosed in the correct namespace (using namespace here is not placing all symbols in that namespace)

// more code here that should be inside the rive namespace

should be instead

namespace rive {
class StateMachineInstance;

// more code here that should be inside the rive namespace
} // namespace rive

Also consider not doing using namespace rive; in cpp in the global namespace, this is breaking unity builds.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant