-
Notifications
You must be signed in to change notification settings - Fork 90
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
Remove most deprecated declarations #2291
Conversation
UpXSplitIndex and DownXSplitIndex are still used in the unit tests
clang-tidy review says "All clean, LGTM! 👍" |
* next: (1828 commits) Use MPI_COMM_NULL rather than nullptr Apply clang-format changes Apply clang-format changes Don't compile LaplaceXY2 with 3D metrics Apply clang-format changes Apply clang-format changes Laplacexy2 modifications Apply clang-format changes Apply clang-format changes nvcc needs toString(HYPRE_SOLVER_TYPE) nvcc now seems to need the factory flags Update fmt to latest version Apply clang-format changes Output BoutException.what() in PhysicsModel main() use hasParallelSlices Apply clang-format changes Only destroy if it exists Backgrounds don't work with parallel BCs Ensure that parallel slices exist CI: Remove unused stage from clang-tidy-review job ...
* next: Apply clang-format CI: Don't update submodules (already updated) CI: Workaround for git ownership checks in container CI: Bump actions/checkout version CI: Use latest version of cmake in clang-tidy-review Add 'u' format flag to BOUT.settings output Adds a 'u' format, commenting unused options Print wether an option was marked as conditionally used
This reverts commit 21f720e.
`vecops.hxx` requires `Field/Vector` headers to be used, so may as well always include them
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clang-tidy made some suggestions
@@ -225,17 +225,13 @@ public: | |||
// return the appropriate index. Some corners cells are actually | |||
// sent along with the rest of the edge. This can be predicted | |||
// based on teh value of xy[In|Out][Up|Down]Mesh_SendsInner. | |||
if (mesh->yUpMesh && wait_any_count < 0 && mesh->communicatingY && | |||
mesh->UpXSplitIndex() > 0) { | |||
if (mesh->yUpMesh && wait_any_count < 0 && mesh->communicatingY) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: implicit conversion 'FakeParallelMesh *' -> bool [readability-implicit-bool-conversion]
if (mesh->yUpMesh && wait_any_count < 0 && mesh->communicatingY) { | |
if ((mesh->yUpMesh != nullptr) && wait_any_count < 0 && mesh->communicatingY) { |
*indx = wait_any_count = 0; | ||
} else if (mesh->yDownMesh && wait_any_count < 1 && mesh->communicatingY && | ||
mesh->UpXSplitIndex() == 0) { | ||
} else if (mesh->yDownMesh && wait_any_count < 1 && mesh->communicatingY) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: implicit conversion 'FakeParallelMesh *' -> bool [readability-implicit-bool-conversion]
} else if (mesh->yDownMesh && wait_any_count < 1 && mesh->communicatingY) { | |
} else if ((mesh->yDownMesh != nullptr) && wait_any_count < 1 && mesh->communicatingY) { |
*indx = wait_any_count = 1; | ||
} else if (mesh->yDownMesh && wait_any_count < 2 && mesh->communicatingY && | ||
mesh->DownXSplitIndex() > 0) { | ||
} else if (mesh->yDownMesh && wait_any_count < 2 && mesh->communicatingY) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: implicit conversion 'FakeParallelMesh *' -> bool [readability-implicit-bool-conversion]
} else if (mesh->yDownMesh && wait_any_count < 2 && mesh->communicatingY) { | |
} else if ((mesh->yDownMesh != nullptr) && wait_any_count < 2 && mesh->communicatingY) { |
*indx = wait_any_count = 2; | ||
} else if (mesh->yDownMesh && wait_any_count < 3 && mesh->communicatingY && | ||
mesh->DownXSplitIndex() == 0) { | ||
} else if (mesh->yDownMesh && wait_any_count < 3 && mesh->communicatingY) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: implicit conversion 'FakeParallelMesh *' -> bool [readability-implicit-bool-conversion]
} else if (mesh->yDownMesh && wait_any_count < 3 && mesh->communicatingY) { | |
} else if ((mesh->yDownMesh != nullptr) && wait_any_count < 3 && mesh->communicatingY) { |
I'm reasonably certain everything removed here is marked deprecated in v4.4, but it's plausible there's something I've missed that should be deprecated there first.
There's a small number of things that are still in use and so can't be removed yet:
FieldGenerator::generate(BoutReal x, BoutReal y, BoutReal z, BoutReal t)
: this basically needs the boundary conditions rewrite before we can remove this, which is upsettingI don't know why I thought we needed to keep this, it's gone!Mesh::UpXSplitIndex/DownXSplitIndex
: used in the unit tests for the fake parallel mesh. Could be removed fromMesh
and made aprotected
method ofBoutMesh
lowpass
: we changed thekeep_zonal
argument fromint
tobool
. Unfortunately,int
s are implicitly convertable tobool
s, and theint
version, while deprecated, doesASSERT0
that only 0s or 1s are passed. A better solution might be to use an enum to strongly type the argument: