Can virtual functions like X::f() in the following code
X::f()
struct X { constexpr virtual int f() const { return 0; } };
Can virtual functions be constexpr?
Yes. Only since C++20, virtual functions can be constexpr.
constexpr