[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug default/21486] New: missing const when comparing C++ object files
https://sourceware.org/bugzilla/show_bug.cgi?id=21486
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 flags
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' changed:
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<char,
std::char_traits<char> >&, 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]
--
You are receiving this mail because:
You are on the CC list for the bug.