From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: <3Jgd-XggKCicJSURFLGDJRRJOH.FRPOLEDELJDLOVRXUFHZDUH.RUJ@flex--gprocida.bounces.google.com> Received: from mail-wm1-x34a.google.com (mail-wm1-x34a.google.com [IPv6:2a00:1450:4864:20::34a]) by sourceware.org (Postfix) with ESMTPS id C6563385E007 for ; Fri, 27 Mar 2020 14:01:12 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org C6563385E007 Received: by mail-wm1-x34a.google.com with SMTP id n188so4404757wmf.0 for ; Fri, 27 Mar 2020 07:01:12 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:in-reply-to:message-id:mime-version :references:subject:from:to:cc; bh=+JZC9NVnPkp+FI+FY7TCL9X4JU0opBZmskR2idVSzwg=; b=XkhkIK0EN3mb8Jdpy0el0OAyeKKEl9MT/iDrEU8a1EpSaUw0cKOpCpqkK436KoccMx rKE4FkSJCuxAuVi4JCZPZ166PShtZ8H9Aywki8z5zAhM6quCGfzlUWHyVGwzt6dL0pRr 3GejzluCfC+c/QZczHHPZNgUy2uugCPhm4I14pA9VyaH6IaBJOLVsGuUPITTTOkMqmZ6 5r5NChEH1hU9HFwmZ/P5mX1sN7sNnKYls5oi+OSC96UPNPNBqUwNybEZq8uuEdD72Uic FonFkNCNvko1wSLrbfaaln+Glw7ISRzrqNenmdeC6l0XvdfPZx/wV4OMKmR2icnoaluh SLKA== X-Gm-Message-State: ANhLgQ3d75AmlsZmqGmtIEaucU8OE9wqyqMPPU9+I5RXpRjk/45ZebUc Kh1lT0SGBck/3Oul6e7dcRzgb48/zhRd0lf1Cpvp6D+n+ylkXa4WoXeosd0xb8ElbNIsLKiEBTk CFtlrzdoHxCt7heHRN9cCHsevChkX4pMaseMBBvfIgMRYNqTTHKits//ziXu4uf2WtPXK6Qg= X-Google-Smtp-Source: ADFU+vuT/Zu+Y0fXr2gremfoiBFvrZvl/U17UymKrjfvPuYY/tbAxSLxM2GhY1y28OghVtrEB+E6hNZv0wsS/g== X-Received: by 2002:adf:80cb:: with SMTP id 69mr4068369wrl.320.1585317670336; Fri, 27 Mar 2020 07:01:10 -0700 (PDT) Date: Fri, 27 Mar 2020 14:00:17 +0000 In-Reply-To: <20200327140017.1917-1-gprocida@google.com> Message-Id: <20200327140017.1917-8-gprocida@google.com> Mime-Version: 1.0 References: <20200327140017.1917-1-gprocida@google.com> X-Mailer: git-send-email 2.25.1.696.g5e7596f4ac-goog Subject: [PATCH 7/7] abidiff: Remove new lines after parameter diffs. From: Giuliano Procida To: libabigail@sourceware.org Cc: dodji@seketeli.org, kernel-team@android.com, gprocida@google.com, maennich@google.com Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-33.9 required=5.0 tests=BAYES_00, DKIMWL_WL_MED, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, USER_IN_DEF_DKIM_WL autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libabigail@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libabigail mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Mar 2020 14:01:14 -0000 These blank lines break up the output unexpectedly and often cause double blank lines after reporting of function changes. * src/abg-default-reporter.cc: (report_local_function_type_changes): Remove unnecessary blank lines after lists of parameter changes. * tests/data/test-*/test*report*.txt: Remove blank lines after parameter change lists in 12 files. Signed-off-by: Giuliano Procida --- src/abg-default-reporter.cc | 9 --------- .../data/test-diff-dwarf/test20-add-fn-parm-report-0.txt | 1 - .../test-diff-dwarf/test24-added-fn-parms-report-0.txt | 1 - .../test-diff-dwarf/test25-removed-fn-parms-report-0.txt | 1 - .../test26-added-parms-before-variadic-report.txt | 4 ---- .../test-diff-dwarf/test32-fnptr-changes-report-0.txt | 1 - .../test-diff-dwarf/test33-fnref-changes-report-0.txt | 1 - .../test-diff-dwarf/test42-PR21296-clanggcc-report0.txt | 1 - tests/data/test-diff-dwarf/test46-rust-report-0.txt | 1 - .../test30-pr18904-rvalueref-report0.txt | 1 - .../test30-pr18904-rvalueref-report1.txt | 1 - .../test30-pr18904-rvalueref-report2.txt | 1 - .../test35-pr18754-no-added-syms-report-0.txt | 1 - 13 files changed, 24 deletions(-) diff --git a/src/abg-default-reporter.cc b/src/abg-default-reporter.cc index 2754da4b..d2ac4a58 100644 --- a/src/abg-default-reporter.cc +++ b/src/abg-default-reporter.cc @@ -552,7 +552,6 @@ default_reporter::report_local_function_type_changes(const function_type_diff& d // this shouldn't be as straightforward. // Report about the parameters that got removed. - bool emitted = false; for (vector::const_iterator i = d.priv_->sorted_deleted_parms_.begin(); i != d.priv_->sorted_deleted_parms_.end(); @@ -561,13 +560,9 @@ default_reporter::report_local_function_type_changes(const function_type_diff& d out << indent << "parameter " << (*i)->get_index() << " of type '" << (*i)->get_type_pretty_representation() << "' was removed\n"; - emitted = true; } - if (emitted) - out << "\n"; // Report about the parameters that got added - emitted = false; for (vector::const_iterator i = d.priv_->sorted_added_parms_.begin(); i != d.priv_->sorted_added_parms_.end(); @@ -576,11 +571,7 @@ default_reporter::report_local_function_type_changes(const function_type_diff& d out << indent << "parameter " << (*i)->get_index() << " of type '" << (*i)->get_type_pretty_representation() << "' was added\n"; - emitted = true; } - - if (emitted) - out << "\n"; } /// Build and emit a textual report about a @ref function_type_diff. diff --git a/tests/data/test-diff-dwarf/test20-add-fn-parm-report-0.txt b/tests/data/test-diff-dwarf/test20-add-fn-parm-report-0.txt index 18b30645..022d0d11 100644 --- a/tests/data/test-diff-dwarf/test20-add-fn-parm-report-0.txt +++ b/tests/data/test-diff-dwarf/test20-add-fn-parm-report-0.txt @@ -6,4 +6,3 @@ Variables changes summary: 0 Removed, 0 Changed, 0 Added variable [C] 'function int add(int, int)' has some indirect sub-type changes: parameter 3 of type 'int' was added - diff --git a/tests/data/test-diff-dwarf/test24-added-fn-parms-report-0.txt b/tests/data/test-diff-dwarf/test24-added-fn-parms-report-0.txt index 8a21e38c..e270f48b 100644 --- a/tests/data/test-diff-dwarf/test24-added-fn-parms-report-0.txt +++ b/tests/data/test-diff-dwarf/test24-added-fn-parms-report-0.txt @@ -8,4 +8,3 @@ Variables changes summary: 0 Removed, 0 Changed, 0 Added variable parameter 2 of type 'char' was added parameter 3 of type 'int' was added - diff --git a/tests/data/test-diff-dwarf/test25-removed-fn-parms-report-0.txt b/tests/data/test-diff-dwarf/test25-removed-fn-parms-report-0.txt index 1253a8be..fab3a5f4 100644 --- a/tests/data/test-diff-dwarf/test25-removed-fn-parms-report-0.txt +++ b/tests/data/test-diff-dwarf/test25-removed-fn-parms-report-0.txt @@ -8,4 +8,3 @@ Variables changes summary: 0 Removed, 0 Changed, 0 Added variable parameter 2 of type 'char' was removed parameter 3 of type 'int' was removed - diff --git a/tests/data/test-diff-dwarf/test26-added-parms-before-variadic-report.txt b/tests/data/test-diff-dwarf/test26-added-parms-before-variadic-report.txt index 2432e53c..bfeb4f3b 100644 --- a/tests/data/test-diff-dwarf/test26-added-parms-before-variadic-report.txt +++ b/tests/data/test-diff-dwarf/test26-added-parms-before-variadic-report.txt @@ -9,25 +9,21 @@ Variables changes summary: 0 Removed, 0 Changed, 0 Added variable type size changed from 0 to 64 (in bits) parameter 3 of type '...' was added - [C] 'function void fun2(const char*, ...)' has some indirect sub-type changes: parameter 2 of type '...' changed: entity changed from 'variadic parameter type' to 'const char*' type size changed from 0 to 64 (in bits) parameter 3 of type '...' was added - [C] 'function void fun3(const char*, const int*, ...)' has some indirect sub-type changes: parameter 3 of type '...' changed: entity changed from 'variadic parameter type' to 'const int*' type size changed from 0 to 64 (in bits) parameter 4 of type '...' was added - [C] 'function void fun4(const char*, const int*, ...)' has some indirect sub-type changes: parameter 3 of type '...' changed: entity changed from 'variadic parameter type' to 'const int*' type size changed from 0 to 64 (in bits) parameter 4 of type '...' was added - diff --git a/tests/data/test-diff-dwarf/test32-fnptr-changes-report-0.txt b/tests/data/test-diff-dwarf/test32-fnptr-changes-report-0.txt index b3a0f9c4..8c6c6f73 100644 --- a/tests/data/test-diff-dwarf/test32-fnptr-changes-report-0.txt +++ b/tests/data/test-diff-dwarf/test32-fnptr-changes-report-0.txt @@ -33,7 +33,6 @@ Variables changes summary: 0 Removed, 0 Changed, 0 Added variable type of 'int ()* S::fnptr0' changed: in pointed to type 'function type int ()': parameter 1 of type 'double' was added - type of 'int ()* S::fnptr1' changed: in pointed to type 'function type int ()': entity changed from 'function type int ()' to 'void' diff --git a/tests/data/test-diff-dwarf/test33-fnref-changes-report-0.txt b/tests/data/test-diff-dwarf/test33-fnref-changes-report-0.txt index 8b529fdc..2e886cf6 100644 --- a/tests/data/test-diff-dwarf/test33-fnref-changes-report-0.txt +++ b/tests/data/test-diff-dwarf/test33-fnref-changes-report-0.txt @@ -34,7 +34,6 @@ Variables changes summary: 0 Removed, 0 Changed, 0 Added variable type of 'int ()& S::fnref0' changed: in referenced type 'function type int ()': parameter 1 of type 'double' was added - type of 'int ()& S::fnref1' changed: in referenced type 'function type int ()': entity changed from 'function type int ()' to 'int*' diff --git a/tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt b/tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt index b45fa918..ff9e2841 100644 --- a/tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt +++ b/tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt @@ -14,7 +14,6 @@ Variables changes summary: 0 Removed, 0 Changed, 0 Added variable name of symbol changed from _ZN3STRD1Ev to _ZN3STRD2Ev parameter 1 of type 'int' was removed - [C] 'function std::tuple my_forward_as_tuple(STR&&)' has some indirect sub-type changes: return type changed: type name changed from 'std::tuple' to 'std::tuple' diff --git a/tests/data/test-diff-dwarf/test46-rust-report-0.txt b/tests/data/test-diff-dwarf/test46-rust-report-0.txt index 0c745256..0562456e 100644 --- a/tests/data/test-diff-dwarf/test46-rust-report-0.txt +++ b/tests/data/test-diff-dwarf/test46-rust-report-0.txt @@ -14,4 +14,3 @@ Variables changes summary: 0 Removed, 0 Changed, 0 Added variable name of 'one::Foo::a' changed to 'two::Foo::a' parameter 2 of type 'u32' was added - diff --git a/tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt b/tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt index 6867c0ea..79d41913 100644 --- a/tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt +++ b/tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt @@ -1318,7 +1318,6 @@ Variable symbols changes summary: 0 Removed, 0 Added variable symbol not referen type of 'void ()* InitTableEntry::func' changed: in pointed to type 'function type void ()': parameter 1 of type 'typedef MyoArena' was added - and name of 'InitTableEntry::func' changed to '__anonymous_struct__2::func' [C] 'function int __offload_offload(OFFLOAD, const char*, int, int, VarDesc*, VarDesc2*, int, void**, void*, int, void*)' has some indirect sub-type changes: diff --git a/tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt b/tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt index 951f0605..215cfbea 100644 --- a/tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt +++ b/tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt @@ -1318,7 +1318,6 @@ Variable symbols changes summary: 0 Removed, 0 Added variable symbol not referen type of 'void ()* InitTableEntry::func' changed: in pointed to type 'function type void ()': parameter 1 of type 'typedef MyoArena' was added - and name of 'InitTableEntry::func' changed to '__anonymous_struct__2::func' at offload_table.h:295:1 [C] 'function int __offload_offload(OFFLOAD, const char*, int, int, VarDesc*, VarDesc2*, int, void**, void*, int, void*)' at compiler_if_host.cpp:456:1 has some indirect sub-type changes: diff --git a/tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt b/tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt index fdd96bc8..09fdb9c6 100644 --- a/tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt +++ b/tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt @@ -1318,7 +1318,6 @@ Variable symbols changes summary: 0 Removed, 0 Added variable symbol not referen type of 'void ()* InitTableEntry::func' changed: in pointed to type 'function type void ()': parameter 1 of type 'typedef MyoArena' was added - and name of 'InitTableEntry::func' changed to '__anonymous_struct__2::func' at offload_table.h:295:1 [C] 'function int __offload_offload(OFFLOAD, const char*, int, int, VarDesc*, VarDesc2*, int, void**, void*, int, void*)' at compiler_if_host.cpp:456:1 has some indirect sub-type changes: diff --git a/tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt b/tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt index c0e56207..1f6e3e79 100644 --- a/tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt +++ b/tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt @@ -234,7 +234,6 @@ Variable symbols changes summary: 0 Removed, 0 Added variable symbol not referen type of 'void ()* InitTableEntry::func' changed: in pointed to type 'function type void ()': parameter 1 of type 'typedef MyoArena' was added - and name of 'InitTableEntry::func' changed to '__anonymous_struct__2::func' [C] 'function int __offload_offload(OFFLOAD, const char*, int, int, VarDesc*, VarDesc2*, int, void**, void*, int, void*)' has some indirect sub-type changes: -- 2.25.1.696.g5e7596f4ac-goog