From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 87655 invoked by alias); 12 May 2017 01:20:29 -0000 Mailing-List: contact libabigail-help@sourceware.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Id: List-Subscribe: Sender: libabigail-owner@sourceware.org Received: (qmail 87504 invoked by uid 48); 12 May 2017 01:20:25 -0000 From: "woodard at redhat dot com" To: libabigail@sourceware.org Subject: [Bug default/21486] New: missing const when comparing C++ object files Date: Sun, 01 Jan 2017 00:00:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: libabigail X-Bugzilla-Component: default X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: woodard at redhat dot com X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: dodji at redhat dot com X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter cc target_milestone Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2017-q2/txt/msg00014.txt.bz2 https://sourceware.org/bugzilla/show_bug.cgi?id=3D21486 Bug ID: 21486 Summary: missing const when comparing C++ object files Product: libabigail Version: unspecified Status: NEW Severity: normal Priority: P2 Component: default Assignee: dodji at redhat dot com Reporter: woodard at redhat dot com CC: libabigail at sourceware dot org Target Milestone: --- Doing some introspection on libabigail itself with different compilers it f= lags this error: [C]'function void abigail::dump(abigail::ir::translation_unit_sptr, std::ostream&, bool)' at abg-writer.cc:4091:1 has some indirect sub-type changes: parameter 1 of type 'typedef abigail::ir::translation_unit_sptr' change= d: entity changed from 'typedef abigail::ir::translation_unit_sptr' to 'const abigail::ir::translation_unit_sptr' type size hasn't changed parameter 3 of type 'bool' changed: entity changed from 'bool' to 'const bool' type size hasn't changed [ben@localhost build]$ g++ --version g++ (GCC) 6.3.1 20161221 (Red Hat 6.3.1-1) Copyright (C) 2016 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. [ben@localhost build]$ clang++ --version clang version 3.9.1 (tags/RELEASE_391/final) Target: x86_64-unknown-linux-gnu Thread model: posix InstalledDir: /usr/bin The function definition does seem to have a const: void dump(const translation_unit_sptr t, std::ostream& o, const bool annotate) { if (t) dump(*t, o, annotate); } digging through the readelf output it looks like it is a libabigail bug: GCC's debug-info looks correct: [ 41147] subprogram external (flag_present) yes name (strp) "dump" decl_file (data1) 2 decl_line (data2) 4069 linkage_name (strp) "abigail::dump(abigail::ir::translation_unit const&, std::basic_ostream >&, bool)" declaration (flag_present) yes sibling (ref4) [ 41167] [ 41157] formal_parameter type (ref4) [ 6b4b9] [ 4115c] formal_parameter type (ref4) [ 42e87] [ 41161] formal_parameter type (ref4) [ 3c1a1] [ 6b4b9] reference_type byte_size (data1) 8 type (ref4) [ 3d90e] [ 3d90e] const_type type (ref4) [ 3d7dd] [ 3d7dd] class_type name (strp) "translation_unit" declaration (flag_present) yes sibling (ref4) [ 3d90e] --=20 You are receiving this mail because: You are on the CC list for the bug.