[trivial] silence the warning about this pointer#635
Conversation
buechlerm
left a comment
There was a problem hiding this comment.
So we know that copying the raw bytes into the object here is safe because you wrote it all (and the target is effectly empyt at this point), but is there an approach that guarantees safety, or is this a case where this operation can only be written with that knowledge. To be clear, I'm not asking you to do anything different, just trying to learn.
Copying is safe because we "fill in" after. So we want to use memcpy to copy the top-level structure of the struct. The pointers will be invalid after |
|
Waiting for the final tests to pass. They're stuck in the queue right now. |
PR Summary
Tiny, trivial change. It is safe to copy the
thispointer in variant, due to how the recursive serialization routines work. However, C++20 warns. This makes the compiler happy.PR Checklist
make formatcommand after configuring withcmake.plan_historiesfolder, with a filename the same as the MR number.If preparing for a new release, in addition please check the following: