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

Add constexpr to static member functions for point types, add macro for if constexpr #4735

Merged

Conversation

al-tu
Copy link
Contributor

@al-tu al-tu commented Apr 29, 2021

a small subset of related [to constexpr point constructors MR] changes

@al-tu al-tu marked this pull request as ready for review May 1, 2021 12:13
@kunaltyagi kunaltyagi changed the title constexpr static member functions for point types Add constexpr to static member functions for point types, add macro for if constexpr May 2, 2021
@kunaltyagi kunaltyagi added changelog: enhancement Meta-information for changelog generation changelog: new feature Meta-information for changelog generation module: common labels May 2, 2021
@kunaltyagi
Copy link
Member

Successfully compiled this PR with C++17 flag, but didn't test if the constexpr functions actually were compile time only

@mvieth mvieth merged commit f11cf55 into PointCloudLibrary:master May 4, 2021
@al-tu
Copy link
Contributor Author

al-tu commented May 8, 2021

Successfully compiled this PR with C++17 flag, but didn't test if the constexpr functions actually were compile time only

#4752 follow up for this MR, covered with static_asserts. didn't cover c++17 macro to be expanded to constexpr if

@al-tu al-tu deleted the constexpr-statics-for-point-types branch July 28, 2021 22:30
mvieth pushed a commit to mvieth/pcl that referenced this pull request Dec 27, 2021
… for `if constexpr` (PointCloudLibrary#4735)

* static mem functions returning constants made constexpr

* static mem functions returning constants made constexpr

* static mem functions returning constants made constexpr

* static mem functions returning constants made constexpr
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog: enhancement Meta-information for changelog generation changelog: new feature Meta-information for changelog generation module: common
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants