Closed AlejandroCornejo closed 1 week ago
CI fails
Anyone knows how to sort this CI error out? @roigcarlo
Kratos::KratosStructuralMechanicsApplication::mLinearTrussElement2D3N' will be initialized after [-Werror=reorder]
285 | const LinearTrussElement2D<3> mLinearTrussElement2D3N;
I cannot reproduce it in my pc, either with WIN and WSL linux...
This is a warning that appears as an error because of the CI.
Its telling you that in the class creator you have a member initializer list which has a different order than the member declaration. In spanish:
class foo {
// This one is an error. Should be mArg2(), mArg3()
// |
// -----------------V
foo(): mArg1(), mArg3(), mArg2() { ... }
int mArg1;
int mArg2;
int mArg3;
}
Just change the order of the affected variable in the initialization list and should be fixed.
Edit: Fun fact, the warning has little to do with the construction order, its better to do it this way because the destructor uses the reverse order when destroying the class and can only obtain such order from the declaration, and not the initialization, and this one can indeed lead to problems.
@loumalouomega now it passes!
@loumalouomega now it passes!
Huuuum, how do I know that it actually passes and it is not the evil genius changing my perception of it?, I compile therefore I exist?
📝 Description Adding 2 and 3 noded plane truss elements. Classic implementation of linear and quadratic FE with numerical integration. I am reusing the truss constitutive law already existing in the app (with a minor modification). Test added for each truss element. They are able to print axial forces and strains.
Template implementation for efficiency.
@RiccardoRossi @WPK4FEM