From patchwork Wed Jan 1 00:00:00 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dodji Seketeli X-Patchwork-Id: 39001 From: dodji@seketeli.org (Dodji Seketeli) Date: Wed, 01 Jan 2020 00:00:00 -0000 Subject: [PATCH 2/2] Tag add/remove/change lines unconditionally with [A], [D], [C]. In-Reply-To: <20200305160317.101386-2-gprocida@google.com> (Giuliano Procida's message of "Thu, 5 Mar 2020 16:03:17 +0000") References: <20200305160317.101386-1-gprocida@google.com> <20200305160317.101386-2-gprocida@google.com> Message-ID: <86ftelwmc7.fsf@seketeli.org> Hey Giuliano, Thank you for looking into this. I have some comments down below. Giuliano Procida a ?crit: > These tags were previously only emitted by the default reporter if the > there were more than 100 (hard-coded constant) items in a a list. The > leaf reporter emitted them unconditionally. This change simplifies the > code, makes output more consistent and makes it easier to interpret > diffs of diff output. > > * src/abg-default-reporter.cc (report): Remove calculations of > number of changes (total) and arbitrary threshold (large_num) > and emit prefixes ([A], [D], [C]) unconditionally. > * tests/data/test-*/*report*.txt: Add prefixes to reports. When I run the testsuite with this patch, I get a regression in runtestdiffpkg. Maybe the part of this patch that emits the [A],[D] prefixes for added/removed ELF symbols not referenced by debug info and for binaries (by abipkgdiff) is missing? Here is the error I am getting when running the runtestdiffpkg test: $ ./build/tests/runtestdiffpkg $ [...] Cheers, --- /home/dodji/git/libabigail/patches/tests/data/test-diff-pkg/dbus-glib-0.104-3.fc23.x86_64--dbus-glib-0.104-3.fc23.armv7hl-report-0.txt 2020-03-06 15:34:18.428218583 +0100 +++ /home/dodji/git/libabigail/patches/build/tests/output/test-diff-pkg/dbus-glib-0.104-3.fc23.x86_64--dbus-glib-0.104-3.fc23.armv7hl-report-0.txt 2020-03-06 15:59:59.346851954 +0100 @@ -23,6 +23,6 @@ ================ end of changes of 'dbus-binding-tool'=============== Removed binaries: - [D] /usr/lib64/libdbus-glib-1.so.2.3.2, SONAME: libdbus-glib-1.so.2 + /usr/lib64/libdbus-glib-1.so.2.3.2, SONAME: libdbus-glib-1.so.2 Added binaries: - [A] /usr/lib/libdbus-glib-1.so.2.3.2, SONAME: libdbus-glib-1.so.2 + /usr/lib/libdbus-glib-1.so.2.3.2, SONAME: libdbus-glib-1.so.2 --- /home/dodji/git/libabigail/patches/tests/data/test-diff-pkg/PR24690/PR24690-report-0.txt 2020-03-06 15:34:18.428218583 +0100 +++ /home/dodji/git/libabigail/patches/build/tests/output/test-diff-pkg/PR24690/PR24690-report-0.txt 2020-03-06 16:00:02.605904230 +0100 @@ -24,9 +24,9 @@ 3 removed types unreachable from any public interface: - [A] struct _GUnixFDList at gunixfdlist.h:58:1 - [A] typedef GUnixFDList at giotypes.h:549:1 - [A] typedef GUnixFDListPrivate at gunixfdlist.h:41:1 + struct _GUnixFDList at gunixfdlist.h:58:1 + typedef GUnixFDList at giotypes.h:549:1 + typedef GUnixFDListPrivate at gunixfdlist.h:41:1 1 changed type unreachable from any public interface: