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

Name Collision with local variable RT in TrickThreadCoordinator.cpp #157

Closed
joshtews opened this issue Jan 10, 2025 · 1 comment
Closed
Assignees
Labels
enhancement New feature or request

Comments

@joshtews
Copy link

joshtews commented Jan 10, 2025

I have been getting a build error regarding the the local variable "RT" in the Thread Coordinator here:
https://github.com/nasa/TrickHLA/blob/32f75a17ff3a05993eadc0575a4b409e6fdfd7b6/source/TrickHLA/TrickThreadCoordinator.cpp#L1365C5-L1365C45

It appears that somewhere within my build environment RT is also getting defined as a macro and causing trickHLA to fail during the preprocessor and be unbuildable. Unfortunately at this time I do not know the origins of what is defining RT in my local environment.

I am aware that this issue could be blamed on some part of my local environment. However I feel that this local variable is named using a naming convention commonly reserved for defined constants or macros and is likely to cause conflicts for others as well.

If you find it acceptable I would suggest renaming this variable "RT" to something less likely to conflict with externally defined constants

@dandexter dandexter self-assigned this Jan 13, 2025
@dandexter dandexter added the enhancement New feature or request label Jan 13, 2025
@dandexter
Copy link
Contributor

I have renamed the RT local variable to RT_frame to help avoid the 'RT' macro your environment seems to be including.

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

No branches or pull requests

2 participants