[PATCH] Bug 22075 data_member_diff_comp comparison functor isn't a total ordering.

Mark Wielaard mark@klomp.org
Sun Jan 1 00:00:00 GMT 2017


On Wed, 2017-09-13 at 15:36 +0200, Mark Wielaard wrote:
> This might be nitpicking, but why isn't the code after the first name
> comparison dead? Given two change nodes, if the initial offsets are
> the
> same and the secondary offsets are the same (meaning they moved
> similarly), then how can the names also be the same? Wouldn't that
> mean
> that the first and second change node are identical?

Answering myself. Since I am clearly confused :)
When the first name comparison is done, we have only compared the
initial offsets, so the names can still be identical. That just implies
the change offsets will be different.

I am still slightly confused why the second/last name comparison will
ever be reached. And if it can be reached why it must always be
different and cannot be equal. But I might not fully understand what
the change nodes represent.

Cheers,

Mark



More information about the Libabigail mailing list