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

Work around an issue in Teuchos::rcpFromRef() with types only forward declared. #16608

Merged
merged 1 commit into from Feb 12, 2024

Conversation

bangerth
Copy link
Member

@bangerth bangerth commented Feb 8, 2024

Specifically, calling Teuchos::rcpFromRef(T*) internally calls typeid(T) which only works if T is a complete type. Unfortunately, my MPI library only forward declares the MPI communicator class and makes MPI_Comm a pointer to this incomplete class. This leads to an error in rcpFromRef().

It turns out that this is documented, see the documentation of rcpFromRef() at https://docs.trilinos.org/dev/packages/teuchos/doc/html/classTeuchos_1_1RCP.html#a6c754d72d6d232c97e38bc359ab6ef82 and the reference to rcpFromUndefRef() there (see https://docs.trilinos.org/dev/packages/teuchos/doc/html/classTeuchos_1_1RCP.html#a823eee3138de3b23dab97b3f37e197f3).

@bangerth
Copy link
Member Author

Ping?

@masterleinad masterleinad merged commit da635b4 into dealii:master Feb 12, 2024
15 checks passed
@bangerth bangerth deleted the t-2 branch February 12, 2024 18:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants