mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-27 02:01:42 +00:00
[wpimath] Fix various constexpr support bugs (#7676)
This commit is contained in:
@@ -79,8 +79,13 @@ TEST(Rotation2dTest, Inequality) {
|
||||
}
|
||||
|
||||
TEST(Rotation2dTest, ToMatrix) {
|
||||
#if __GNUC__ <= 11
|
||||
Rotation2d before{20_deg};
|
||||
Rotation2d after{before.ToMatrix()};
|
||||
#else
|
||||
constexpr Rotation2d before{20_deg};
|
||||
constexpr Rotation2d after{before.ToMatrix()};
|
||||
#endif
|
||||
|
||||
EXPECT_EQ(before, after);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user