phaseField icon indicating copy to clipboard operation
phaseField copied to clipboard

Using `[[maybe_unused]]` for `q_point_loc`

Open landinjm opened this issue 1 year ago • 0 comments

Adding the [[maybe_unused]] attribute can suppress compiler warnings if variables are not used (since c++17).

https://github.com/prisms-center/phaseField/blob/5f4829aa30fc3e637f57f353e4179ea5d8f1446e/include/matrixFreePDE.h#L268-L276

We can use this for q_point_loc to suppress some the warnings since it won't always be used in whatever PDE the user decides on.

One thing to note is that this will require somewhat recent compilers since it's from the c++ 2017 standard.

landinjm avatar Aug 19 '24 16:08 landinjm