[Bug gdb/27528] New: compile fail (binutils/gdb/ada-lang.c)
klen_s at mail dot ru
sourceware-bugzilla@sourceware.org
Fri Mar 5 21:48:16 GMT 2021
https://sourceware.org/bugzilla/show_bug.cgi?id=27528
Bug ID: 27528
Summary: compile fail (binutils/gdb/ada-lang.c)
Product: gdb
Version: HEAD
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: gdb
Assignee: unassigned at sourceware dot org
Reporter: klen_s at mail dot ru
Target Milestone: ---
Created attachment 13292
--> https://sourceware.org/bugzilla/attachment.cgi?id=13292&action=edit
patch
build binutils with fail compile of binutils/gdb/ada-lang.c
sources: HEAD
configure args: src/binutils/configure -v
--prefix=/klen/tools/arm-kgp-eabi_@_x86_64-kgp-linux-gnu_westmere
--target=arm-kgp-eabi --host=x86_64-kgp-linux-gnu --build=x86_64-kgp-linux-gnu
--disable-werror --enable-multilib --with-pic --enable-nls --enable-lto
--enable-plugins --enable-static --disable-shared --with-expat --disable-sim
--enable-gold --enable--threads --disable-source-highlight
compiler output error:
CXX ada-lang.o
../../../src/bu-gdb/gdb/ada-lang.c: В функции «const char*
ada_fold_name(gdb::string_view)»:
../../../src/bu-gdb/gdb/ada-lang.c:947:64: ошибка: нет соответствующей функции
для вызова «to_string(std::basic_string_view<char>)»
947 | fold_storage = to_string (name.substr (1, name.size () - 2));
| ^
In file included from
/klen/tools/x86_64-kgp-linux-gnu-znver2-avx2/lib/gcc/x86_64-kgp-linux-gnu/11.0.1/include/c++/string:55,
from ../../../src/bu-gdb/gdb/../gdbsupport/common-utils.h:23,
from ../../../src/bu-gdb/gdb/../gdbsupport/common-defs.h:125,
from ../../../src/bu-gdb/gdb/defs.h:28,
from ../../../src/bu-gdb/gdb/ada-lang.c:21:
patch:
diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
index bb50222f81..8f27f3ccdf 100644
--- a/gdb/ada-lang.c
+++ b/gdb/ada-lang.c
@@ -944,10 +944,10 @@ ada_fold_name (gdb::string_view name)
static std::string fold_storage;
if (!name.empty () && name[0] == '\'')
- fold_storage = to_string (name.substr (1, name.size () - 2));
+ fold_storage = gdb::to_string (name.substr (1, name.size () - 2));
else
{
- fold_storage = to_string (name);
+ fold_storage = gdb::to_string (name);
for (int i = 0; i < name.size (); i += 1)
fold_storage[i] = tolower (fold_storage[i]);
}
--
You are receiving this mail because:
You are on the CC list for the bug.
More information about the Gdb-prs
mailing list