I fail to see your point here.
sgl_baseof uses offsetof with a valid struct type and a valid field name, so where is the UB? Unless you feed it an invalid pointer, but then all bets are off.
sgl_baseof uses offsetof with a valid struct type and a valid field name, so where is the UB? Unless you feed it an invalid pointer, but then all bets are off.
If an implementation provides offsetof and it doesn't work, that implementation would go out of fashion in a heart beat.
Where is the practical use of this information?
How is this even an argument?