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

private field 'm_componentNames' is not used #2880

Closed
cj215 opened this issue Dec 8, 2023 · 4 comments · Fixed by #2812
Closed

private field 'm_componentNames' is not used #2880

cj215 opened this issue Dec 8, 2023 · 4 comments · Fixed by #2812
Labels
type: bug Something isn't working type: new A new issue has been created and requires attention

Comments

@cj215
Copy link

cj215 commented Dec 8, 2023

Describe the bug
Compilation error in file GEOS/src/coreComponents/constitutive/fluid/multifluid/compositional/models/ComponentProperties.hpp:130:24 possibly caused by this commit #2799

In file included from /Users/clem/Documents/GitHub/GEOS/src/coreComponents/constitutive/fluid/multifluid/PVTDriver.cpp:24:
In file included from /Users/clem/Documents/GitHub/GEOS/src/coreComponents/constitutive/fluid/multifluid/MultiFluidSelector.hpp:30:
In file included from /Users/clem/Documents/GitHub/GEOS/src/coreComponents/constitutive/fluid/multifluid/compositional/CompositionalMultiphaseFluid.hpp:22:
In file included from /Users/clem/Documents/GitHub/GEOS/src/coreComponents/constitutive/fluid/multifluid/compositional/CompositionalMultiphaseFluidUpdates.hpp:22:
/Users/clem/Documents/GitHub/GEOS/src/coreComponents/constitutive/fluid/multifluid/compositional/models/ComponentProperties.hpp:130:24: error: private field 'm_componentNames' is not used [-Werror,-Wunused-private-field]
  string_array const & m_componentNames;
                       ^
1 error generated.
make[2]: *** [coreComponents/constitutive/CMakeFiles/constitutive.dir/fluid/multifluid/PVTDriver.cpp.o] Error 1
make[1]: *** [coreComponents/constitutive/CMakeFiles/constitutive.dir/all] Error 2
make: *** [all] Error 2]

To Reproduce
Building GEOS on macOS or Ubuntu 18.04 (where I had the error)

Expected behavior
Compilation fails

Platform

  • Machine macOS or Ubuntu 18.04
  • Compiler: Apple clang version 14.0.3
  • GEOSX commit a1fd561
@cj215 cj215 added type: bug Something isn't working type: new A new issue has been created and requires attention labels Dec 8, 2023
@TotoGaz
Copy link
Contributor

TotoGaz commented Dec 8, 2023

What is your compiler on ubuntu? Are you compiling in Release or Debug mode? (or both?)

@cj215
Copy link
Author

cj215 commented Dec 8, 2023

On Ubuntu clang version 6.0.0-1ubuntu2 --> Quite old and can't be updated unless I update from 18.04 to 22.04 hence I went on macOS to avoid doing that

I am compiling in Release mode, I have not tried Debug

@TotoGaz
Copy link
Contributor

TotoGaz commented Dec 8, 2023

Is the warning is legitimate?

@TotoGaz TotoGaz linked a pull request Dec 11, 2023 that will close this issue
@cj215
Copy link
Author

cj215 commented Dec 11, 2023

Thanks, this has removed the error and promted another one. The error is quite similar on both macOS and Ubuntu, I am going to be looking into this in the next few days
macOs error.txt
Ubuntu 18_04 error.txt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug Something isn't working type: new A new issue has been created and requires attention
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants