Hi @ma guangzhi ,
I recommend that you read this documentation, which states:
It can't be virtual. A constructor can't be defined as constexpr when the enclosing class has any virtual base classes.
Best regards,
Elya
If the answer is the right solution, please click "Accept Answer" and upvote it.If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.