Hello niki,
I think this is just read the D register , the aim is clear the RDRF Flag.
You can see this in the RM

you can confirm it through the your project .
Hope it helps
Have a great day,
Alice Yang
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------