abclinuxu.cz AbcLinuxu.cz itbiz.cz ITBiz.cz HDmag.cz HDmag.cz abcprace.cz AbcPráce.cz
AbcLinuxu hledá autory!
Inzerujte na AbcPráce.cz od 950 Kč
Rozšířené hledání
×
dnes 14:33 | Nová verze

The Document Foundation oznámila na svém blogu vydání nové verze 7.0 svobodného kancelářského balíku LibreOffice. Podrobný přehled nových vlastností i s náhledy v poznámkách k vydání (cs) nebo také na Youtube a PeerTube.

Ladislav Hagara | Komentářů: 0
dnes 13:33 | Nová verze

Byla vydána nová stabilní verze 3.2 (3.2.1967.41) webového prohlížeče Vivaldi (Wikipedie). Přehled novinek v příspěvku na blogu. Zdůraznit lze vylepšený obraz v obraze. Nejnovější Vivaldi je postaven na Chromiu 84.0.4147.108.

Ladislav Hagara | Komentářů: 3
dnes 01:11 | Nová verze

Wayfire, kompozitní správce oken inspirovaný Compizem běžící nad Waylandem, byl vydán ve verzi 0.5.0. Zdrojové kódy jsou k dispozici na GitHubu. Videoukázky na YouTube.

Ladislav Hagara | Komentářů: 2
včera 12:22 | Komunita

Neziskové technologické konsorcium Linux Foundation rozšířilo seznam svých oficiálních projektů. Nejnovějším projektem je Open Source Security Foundation (OpenSSF), jehož cílem je zvýšit bezpečnost open source softwaru. Více například v příspěvcích na blozích GitHubu nebo Microsoftu.

Ladislav Hagara | Komentářů: 3
včera 11:44 | Nová verze

Byla vydána verze 3.1 webového aplikačního frameworku napsaného v Pythonu Django (Wikipedie). Přehled novinek v poznámkách k vydání.

Ladislav Hagara | Komentářů: 0
včera 01:11 | Nová verze

Svobodná federalizovaná sociální síť Mastodon byla aktualizována. Vydání 3.2 mj. přepracovává audio přehrávač, zlepšuje zabezpečení přihlášení aj.

Fluttershy, yay! | Komentářů: 0
3.8. 14:00 | Komunita

Byla vydána verze 1.5.0 dynamického programovacího jazyka Julia (Wikipedie) určeného zejména pro vědecké výpočty. Přehled novinek v příspěvku na blogu a v poznámkách k vydání. Aktualizována byla také dokumentace. Na YouTube jsou ke zhlédnutí záznamy přednášek z konference JuliaCon 2020 konané online minulý týden.

Ladislav Hagara | Komentářů: 0
3.8. 13:33 | IT novinky

Sdružení CZ.NIC informuje, že pro domény s koncovkou .CZ, jejichž platnost nebyla včas prodloužena, platí opět ochranná lhůta 60 dnů (30 dnů je doména plně funkční, 30 dnů je vyřazena z DNS – není dostupná). Po více než čtyřech měsících tak končí zvláštní režim, kdy byla funkčnost nezaplacených domén dočasně prodloužena ze 30 na 60 dnů z důvodu mimořádné situace související s onemocněním COVID-19.

Ladislav Hagara | Komentářů: 23
3.8. 09:00 | Nová verze

Byla vydána nová verze linuxové distribuce BunsenLabs Linux s předkonfigurovaným správcem oken Openbox. Její název je Lithium a založena je na Debianu 10 Buster. Přehled novinek v poznámkách k vydání. BunsenLabs Linux je nástupcem dnes již nevyvíjené linuxové distribuce CrunchBang (zkráceně #!).

Ladislav Hagara | Komentářů: 0
3.8. 08:00 | Nová verze

Po 9 týdnech vývoje od vydání Linuxu 5.7 oznámil Linus Torvalds vydání Linuxu 5.8 (LKML). Přehled nových vlastností a vylepšení na stránce Linux Kernel Newbies.

Ladislav Hagara | Komentářů: 1
Dokážete si představit, že by váš hlavní počítač (desktop, notebook) byl v současné době založen na architektuře jiné než x86 (x86_64)? Například ARM, POWER, RISC-V,…
 (9%)
 (12%)
 (57%)
 (16%)
 (6%)
Celkem 139 hlasů
 Komentářů: 11, poslední dnes 08:59
Rozcestník

Dotaz: Rozbite G++

26.7. 22:38 LK
Rozbite G++
Přečteno: 443×

Nazdar, na PC mam rozbite g++ - tusite, kde moze byt problem? Najmensi reproducer:

$ cat /tmp/a.cpp 
#include <string>

int main() {
  return 0;
}

Vystup:

$ g++ /tmp/a.cpp 
In file included from /usr/include/c++/9/bits/stl_iterator.h:66,
                 from /usr/include/c++/9/bits/stl_algobase.h:67,
                 from /usr/include/c++/9/bits/char_traits.h:39,
                 from /usr/include/c++/9/string:40,
                 from /tmp/a.cpp:1:
/usr/include/c++/9/bits/ptr_traits.h:144:14: error: ‘_GLIBCXX20_CONSTEXPR’ does not name a type
  144 |       static _GLIBCXX20_CONSTEXPR pointer
      |              ^~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/9/ext/new_allocator.h:33,
                 from /usr/include/x86_64-linux-gnu/c++/8/bits/c++allocator.h:33,
                 from /usr/include/c++/9/bits/allocator.h:46,
                 from /usr/include/c++/9/string:41,
                 from /tmp/a.cpp:1:
/usr/include/c++/9/new:125:1: error: ‘_GLIBCXX_NODISCARD’ does not name a type
  125 | _GLIBCXX_NODISCARD void* operator new(std::size_t) _GLIBCXX_THROW (std::bad_alloc)
      | ^~~~~~~~~~~~~~~~~~
/usr/include/c++/9/new:127:1: error: ‘_GLIBCXX_NODISCARD’ does not name a type
  127 | _GLIBCXX_NODISCARD void* operator new[](std::size_t) _GLIBCXX_THROW (std::bad_alloc)
      | ^~~~~~~~~~~~~~~~~~
/usr/include/c++/9/new:139:1: error: ‘_GLIBCXX_NODISCARD’ does not name a type
  139 | _GLIBCXX_NODISCARD void* operator new(std::size_t, const std::nothrow_t&) _GLIBCXX_USE_NOEXCEPT
      | ^~~~~~~~~~~~~~~~~~
/usr/include/c++/9/new:141:1: error: ‘_GLIBCXX_NODISCARD’ does not name a type
  141 | _GLIBCXX_NODISCARD void* operator new[](std::size_t, const std::nothrow_t&) _GLIBCXX_USE_NOEXCEPT
      | ^~~~~~~~~~~~~~~~~~
/usr/include/c++/9/new:173:1: error: ‘_GLIBCXX_NODISCARD’ does not name a type
  173 | _GLIBCXX_NODISCARD inline void* operator new(std::size_t, void* __p) _GLIBCXX_USE_NOEXCEPT
      | ^~~~~~~~~~~~~~~~~~
/usr/include/c++/9/new:175:1: error: ‘_GLIBCXX_NODISCARD’ does not name a type
  175 | _GLIBCXX_NODISCARD inline void* operator new[](std::size_t, void* __p) _GLIBCXX_USE_NOEXCEPT
      | ^~~~~~~~~~~~~~~~~~
In file included from /usr/include/x86_64-linux-gnu/c++/8/bits/c++allocator.h:33,
                 from /usr/include/c++/9/bits/allocator.h:46,
                 from /usr/include/c++/9/string:41,
                 from /tmp/a.cpp:1:
/usr/include/c++/9/ext/new_allocator.h:79:7: error: ‘_GLIBCXX20_CONSTEXPR’ does not name a type
   79 |       _GLIBCXX20_CONSTEXPR
      |       ^~~~~~~~~~~~~~~~~~~~
/usr/include/c++/9/ext/new_allocator.h:82:7: error: ‘_GLIBCXX20_CONSTEXPR’ does not name a type
   82 |       _GLIBCXX20_CONSTEXPR
      |       ^~~~~~~~~~~~~~~~~~~~
/usr/include/c++/9/ext/new_allocator.h:86:2: error: ‘_GLIBCXX20_CONSTEXPR’ does not name a type
   86 |  _GLIBCXX20_CONSTEXPR
      |  ^~~~~~~~~~~~~~~~~~~~
/usr/include/c++/9/ext/new_allocator.h:101:7: error: ‘_GLIBCXX_NODISCARD’ does not name a type
  101 |       _GLIBCXX_NODISCARD pointer
      |       ^~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/9/string:41,
                 from /tmp/a.cpp:1:
/usr/include/c++/9/bits/allocator.h:137:7: error: ‘_GLIBCXX20_CONSTEXPR’ does not name a type
  137 |       _GLIBCXX20_CONSTEXPR
      |       ^~~~~~~~~~~~~~~~~~~~
/usr/include/c++/9/bits/allocator.h:140:7: error: ‘_GLIBCXX20_CONSTEXPR’ does not name a type
  140 |       _GLIBCXX20_CONSTEXPR
      |       ^~~~~~~~~~~~~~~~~~~~
/usr/include/c++/9/bits/allocator.h:150:2: error: ‘_GLIBCXX20_CONSTEXPR’ does not name a type
  150 |  _GLIBCXX20_CONSTEXPR
      |  ^~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/9/ext/alloc_traits.h:36,
                 from /usr/include/c++/9/bits/basic_string.h:40,
                 from /usr/include/c++/9/string:55,
                 from /tmp/a.cpp:1:
/usr/include/c++/9/bits/alloc_traits.h:304:7: error: ‘_GLIBCXX_NODISCARD’ does not name a type
  304 |       _GLIBCXX_NODISCARD static pointer
      |       ^~~~~~~~~~~~~~~~~~
/usr/include/c++/9/bits/alloc_traits.h:319:7: error: ‘_GLIBCXX_NODISCARD’ does not name a type
  319 |       _GLIBCXX_NODISCARD static pointer
      |       ^~~~~~~~~~~~~~~~~~
/usr/include/c++/9/bits/alloc_traits.h:442:7: error: ‘_GLIBCXX_NODISCARD’ does not name a type
  442 |       _GLIBCXX_NODISCARD static pointer
      |       ^~~~~~~~~~~~~~~~~~
/usr/include/c++/9/bits/alloc_traits.h:456:7: error: ‘_GLIBCXX_NODISCARD’ does not name a type
  456 |       _GLIBCXX_NODISCARD static pointer
      |       ^~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/9/string:55,
                 from /tmp/a.cpp:1:
/usr/include/c++/9/bits/basic_string.h:1030:7: error: ‘_GLIBCXX_NODISCARD’ does not name a type
 1030 |       _GLIBCXX_NODISCARD bool
      |       ^~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/9/bits/basic_string.h:40,
                 from /usr/include/c++/9/string:55,
                 from /tmp/a.cpp:1:
/usr/include/c++/9/ext/alloc_traits.h: In instantiation of ‘struct __gnu_cxx::__alloc_traits<std::allocator<char>, char>’:
/usr/include/c++/9/bits/basic_string.h:80:24:   required from ‘class std::__cxx11::basic_string<char>’
/usr/include/c++/9/bits/basic_string.h:6504:68:   required from here
/usr/include/c++/9/ext/alloc_traits.h:66:23: error: no members matching ‘__gnu_cxx::__alloc_traits<std::allocator<char>, char>::_Base_type {aka std::allocator_traits<std::allocator<char> >}::allocate’ in ‘__gnu_cxx::__alloc_traits<std::allocator<char>, char>::_Base_type’ {aka ‘struct std::allocator_traits<std::allocator<char> >’}
   66 |     using _Base_type::allocate;
      |                       ^~~~~~~~
/usr/include/c++/9/ext/alloc_traits.h: In instantiation of ‘struct __gnu_cxx::__alloc_traits<std::allocator<wchar_t>, wchar_t>’:
/usr/include/c++/9/bits/basic_string.h:80:24:   required from ‘class std::__cxx11::basic_string<wchar_t>’
/usr/include/c++/9/bits/basic_string.h:6610:68:   required from here
/usr/include/c++/9/ext/alloc_traits.h:66:23: error: no members matching ‘__gnu_cxx::__alloc_traits<std::allocator<wchar_t>, wchar_t>::_Base_type {aka std::allocator_traits<std::allocator<wchar_t> >}::allocate’ in ‘__gnu_cxx::__alloc_traits<std::allocator<wchar_t>, wchar_t>::_Base_type’ {aka ‘struct std::allocator_traits<std::allocator<wchar_t> >’}
/usr/include/c++/9/ext/alloc_traits.h: In instantiation of ‘struct __gnu_cxx::__alloc_traits<std::allocator<char16_t>, char16_t>’:
/usr/include/c++/9/bits/basic_string.h:80:24:   required from ‘class std::__cxx11::basic_string<char16_t>’
/usr/include/c++/9/bits/basic_string.h:6784:41:   required from here
/usr/include/c++/9/ext/alloc_traits.h:66:23: error: no members matching ‘__gnu_cxx::__alloc_traits<std::allocator<char16_t>, char16_t>::_Base_type {aka std::allocator_traits<std::allocator<char16_t> >}::allocate’ in ‘__gnu_cxx::__alloc_traits<std::allocator<char16_t>, char16_t>::_Base_type’ {aka ‘struct std::allocator_traits<std::allocator<char16_t> >’}
/usr/include/c++/9/ext/alloc_traits.h: In instantiation of ‘struct __gnu_cxx::__alloc_traits<std::allocator<char32_t>, char32_t>’:
/usr/include/c++/9/bits/basic_string.h:80:24:   required from ‘class std::__cxx11::basic_string<char32_t>’
/usr/include/c++/9/bits/basic_string.h:6799:41:   required from here
/usr/include/c++/9/ext/alloc_traits.h:66:23: error: no members matching ‘__gnu_cxx::__alloc_traits<std::allocator<char32_t>, char32_t>::_Base_type {aka std::allocator_traits<std::allocator<char32_t> >}::allocate’ in ‘__gnu_cxx::__alloc_traits<std::allocator<char32_t>, char32_t>::_Base_type’ {aka ‘struct std::allocator_traits<std::allocator<char32_t> >’}
In file included from /usr/include/c++/9/string:55,
                 from /tmp/a.cpp:1:
/usr/include/c++/9/bits/basic_string.h: In instantiation of ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::pointer std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_local_data() [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::pointer = char*]’:
/usr/include/c++/9/bits/basic_string.h:553:73:   required from ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&&) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]’
/usr/include/c++/9/bits/basic_string.h:6548:20:   required from here
/usr/include/c++/9/bits/basic_string.h:193:49: error: ‘pointer_to’ is not a member of ‘std::pointer_traits<char*>’
  193 |  return std::pointer_traits<pointer>::pointer_to(*_M_local_buf);
      |         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~
/usr/include/c++/9/bits/basic_string.h: In instantiation of ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::pointer std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_local_data() [with _CharT = wchar_t; _Traits = std::char_traits<wchar_t>; _Alloc = std::allocator<wchar_t>; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::pointer = wchar_t*]’:
/usr/include/c++/9/bits/basic_string.h:553:73:   required from ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&&) [with _CharT = wchar_t; _Traits = std::char_traits<wchar_t>; _Alloc = std::allocator<wchar_t>]’
/usr/include/c++/9/bits/basic_string.h:6651:22:   required from here
/usr/include/c++/9/bits/basic_string.h:193:49: error: ‘pointer_to’ is not a member of ‘std::pointer_traits<wchar_t*>’
/usr/include/c++/9/bits/basic_string.h: In instantiation of ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::pointer std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_local_data() [with _CharT = char16_t; _Traits = std::char_traits<char16_t>; _Alloc = std::allocator<char16_t>; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::pointer = char16_t*]’:
/usr/include/c++/9/bits/basic_string.h:512:41:   required from ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(const _CharT*, std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type, const _Alloc&) [with _CharT = char16_t; _Traits = std::char_traits<char16_t>; _Alloc = std::allocator<char16_t>; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type = long unsigned int]’
/usr/include/c++/9/bits/basic_string.h:6839:49:   required from here
/usr/include/c++/9/bits/basic_string.h:193:49: error: ‘pointer_to’ is not a member of ‘std::pointer_traits<char16_t*>’
/usr/include/c++/9/bits/basic_string.h: In instantiation of ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::pointer std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_local_data() [with _CharT = char32_t; _Traits = std::char_traits<char32_t>; _Alloc = std::allocator<char32_t>; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::pointer = char32_t*]’:
/usr/include/c++/9/bits/basic_string.h:512:41:   required from ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(const _CharT*, std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type, const _Alloc&) [with _CharT = char32_t; _Traits = std::char_traits<char32_t>; _Alloc = std::allocator<char32_t>; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type = long unsigned int]’
/usr/include/c++/9/bits/basic_string.h:6844:49:   required from here
/usr/include/c++/9/bits/basic_string.h:193:49: error: ‘pointer_to’ is not a member of ‘std::pointer_traits<char32_t*>’
/usr/include/c++/9/bits/basic_string.h: In instantiation of ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_pointer std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_local_data() const [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_pointer = const char*]’:
/usr/include/c++/9/bits/basic_string.h:222:26:   required from ‘bool std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_is_local() const [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]’
/usr/include/c++/9/bits/basic_string.h:555:12:   required from ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&&) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>]’
/usr/include/c++/9/bits/basic_string.h:6548:20:   required from here
/usr/include/c++/9/bits/basic_string.h:203:55: error: ‘pointer_to’ is not a member of ‘std::pointer_traits<const char*>’
  203 |  return std::pointer_traits<const_pointer>::pointer_to(*_M_local_buf);
      |         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~
/usr/include/c++/9/bits/basic_string.h: In instantiation of ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_pointer std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_local_data() const [with _CharT = wchar_t; _Traits = std::char_traits<wchar_t>; _Alloc = std::allocator<wchar_t>; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_pointer = const wchar_t*]’:
/usr/include/c++/9/bits/basic_string.h:222:26:   required from ‘bool std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_is_local() const [with _CharT = wchar_t; _Traits = std::char_traits<wchar_t>; _Alloc = std::allocator<wchar_t>]’
/usr/include/c++/9/bits/basic_string.h:555:12:   required from ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&&) [with _CharT = wchar_t; _Traits = std::char_traits<wchar_t>; _Alloc = std::allocator<wchar_t>]’
/usr/include/c++/9/bits/basic_string.h:6651:22:   required from here
/usr/include/c++/9/bits/basic_string.h:203:55: error: ‘pointer_to’ is not a member of ‘std::pointer_traits<const wchar_t*>’
/usr/include/c++/9/bits/basic_string.h: In instantiation of ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_pointer std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_local_data() const [with _CharT = char16_t; _Traits = std::char_traits<char16_t>; _Alloc = std::allocator<char16_t>; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_pointer = const char16_t*]’:
/usr/include/c++/9/bits/basic_string.h:222:26:   required from ‘bool std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_is_local() const [with _CharT = char16_t; _Traits = std::char_traits<char16_t>; _Alloc = std::allocator<char16_t>]’
/usr/include/c++/9/bits/basic_string.h:555:12:   required from ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&&) [with _CharT = char16_t; _Traits = std::char_traits<char16_t>; _Alloc = std::allocator<char16_t>]’
/usr/include/c++/9/bits/basic_string.h:6839:49:   required from here
/usr/include/c++/9/bits/basic_string.h:203:55: error: ‘pointer_to’ is not a member of ‘std::pointer_traits<const char16_t*>’
/usr/include/c++/9/bits/basic_string.h: In instantiation of ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_pointer std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_local_data() const [with _CharT = char32_t; _Traits = std::char_traits<char32_t>; _Alloc = std::allocator<char32_t>; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::const_pointer = const char32_t*]’:
/usr/include/c++/9/bits/basic_string.h:222:26:   required from ‘bool std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_is_local() const [with _CharT = char32_t; _Traits = std::char_traits<char32_t>; _Alloc = std::allocator<char32_t>]’
/usr/include/c++/9/bits/basic_string.h:555:12:   required from ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&&) [with _CharT = char32_t; _Traits = std::char_traits<char32_t>; _Alloc = std::allocator<char32_t>]’
/usr/include/c++/9/bits/basic_string.h:6844:49:   required from here
/usr/include/c++/9/bits/basic_string.h:203:55: error: ‘pointer_to’ is not a member of ‘std::pointer_traits<const char32_t*>’
In file included from /usr/include/c++/9/string:56,
                 from /tmp/a.cpp:1:
/usr/include/c++/9/bits/basic_string.tcc: In instantiation of ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::pointer std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_create(std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type&, std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type) [with _CharT = char16_t; _Traits = std::char_traits<char16_t>; _Alloc = std::allocator<char16_t>; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::pointer = char16_t*; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type = long unsigned int]’:
/usr/include/c++/9/bits/basic_string.tcc:219:14:   required from ‘void std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_construct(_InIterator, _InIterator, std::forward_iterator_tag) [with _FwdIterator = const char16_t*; _CharT = char16_t; _Traits = std::char_traits<char16_t>; _Alloc = std::allocator<char16_t>]’
/usr/include/c++/9/bits/basic_string.h:247:11:   required from ‘void std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_construct_aux(_InIterator, _InIterator, std::__false_type) [with _InIterator = const char16_t*; _CharT = char16_t; _Traits = std::char_traits<char16_t>; _Alloc = std::allocator<char16_t>]’
/usr/include/c++/9/bits/basic_string.h:266:4:   required from ‘void std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_construct(_InIterator, _InIterator) [with _InIterator = const char16_t*; _CharT = char16_t; _Traits = std::char_traits<char16_t>; _Alloc = std::allocator<char16_t>]’
/usr/include/c++/9/bits/basic_string.h:513:9:   required from ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(const _CharT*, std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type, const _Alloc&) [with _CharT = char16_t; _Traits = std::char_traits<char16_t>; _Alloc = std::allocator<char16_t>; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type = long unsigned int]’
/usr/include/c++/9/bits/basic_string.h:6839:49:   required from here
/usr/include/c++/9/bits/basic_string.tcc:153:37: error: ‘allocate’ is not a member of ‘std::__cxx11::basic_string<char16_t>::_Alloc_traits’ {aka ‘__gnu_cxx::__alloc_traits<std::allocator<char16_t>, char16_t>’}
  153 |       return _Alloc_traits::allocate(_M_get_allocator(), __capacity + 1);
      |              ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/9/bits/basic_string.tcc: In instantiation of ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::pointer std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_create(std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type&, std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type) [with _CharT = char32_t; _Traits = std::char_traits<char32_t>; _Alloc = std::allocator<char32_t>; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::pointer = char32_t*; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type = long unsigned int]’:
/usr/include/c++/9/bits/basic_string.tcc:219:14:   required from ‘void std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_construct(_InIterator, _InIterator, std::forward_iterator_tag) [with _FwdIterator = const char32_t*; _CharT = char32_t; _Traits = std::char_traits<char32_t>; _Alloc = std::allocator<char32_t>]’
/usr/include/c++/9/bits/basic_string.h:247:11:   required from ‘void std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_construct_aux(_InIterator, _InIterator, std::__false_type) [with _InIterator = const char32_t*; _CharT = char32_t; _Traits = std::char_traits<char32_t>; _Alloc = std::allocator<char32_t>]’
/usr/include/c++/9/bits/basic_string.h:266:4:   required from ‘void std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::_M_construct(_InIterator, _InIterator) [with _InIterator = const char32_t*; _CharT = char32_t; _Traits = std::char_traits<char32_t>; _Alloc = std::allocator<char32_t>]’
/usr/include/c++/9/bits/basic_string.h:513:9:   required from ‘std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::basic_string(const _CharT*, std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type, const _Alloc&) [with _CharT = char32_t; _Traits = std::char_traits<char32_t>; _Alloc = std::allocator<char32_t>; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type = long unsigned int]’
/usr/include/c++/9/bits/basic_string.h:6844:49:   required from here
/usr/include/c++/9/bits/basic_string.tcc:153:37: error: ‘allocate’ is not a member of ‘std::__cxx11::basic_string<char32_t>::_Alloc_traits’ {aka ‘__gnu_cxx::__alloc_traits<std::allocator<char32_t>, char32_t>’}

Detaily: Ubuntu 20.04.1 LTS (focal) "g++ --version" vracia "g++ (Ubuntu 9.3.0-10ubuntu2) 9.3.0" (+GNU reci)


Řešení dotazu:


Odpovědi

26.7. 22:46 debian+ | skóre: 10 | blog: analyzy
Rozbalit Rozbalit vše Re: Rozbite G++
Nemas rozbite. Ale ak chces includovat a la string.h z C-ka, tak mas includovat cstring.
debian.plus@protonmail.com
28.7. 20:29 hm
Rozbalit Rozbalit vše Re: Rozbite G++
Debiane děláš si prdel???????????????????????
26.7. 22:50 debian+ | skóre: 10 | blog: analyzy
Rozbalit Rozbalit vše Re: Rozbite G++
Nemas to ok:
$ cat a.cpp
#include <string>

int main() {
	  return 0;
}
$
$ g++ a.cpp
$ g++ --version
g++ (Debian 9.3.0-16) 9.3.0
Copyright (C) 2019 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.
debian.plus@protonmail.com
26.7. 22:54 debian+ | skóre: 10 | blog: analyzy
Rozbalit Rozbalit vše Re: Rozbite G++
Nainstaluj si balicek g++-10, a robi to aj v g++ desiatke?

Zdroj: https://packages.ubuntu.com/search?keywords=g%2B%2B
debian.plus@protonmail.com
27.7. 01:36 Bherzet | skóre: 14 | blog: Bherzetův blog
Rozbalit Rozbalit vše Re: Rozbite G++
Připadá mi to jako by se ti nějak pomíchaly hlavičkové soubory s jinou verzí g++. _GLIBCXX_NODISCARD je nejspíš atribut [[nodiscard]], _GLIBCXX20_CONSTEXPR je constexpr. Našel jsem třeba nějaký náhodný zdroják, kde (CTRL+F _GLIBCXX20_CONSTEXPR):
#ifndef _GLIBCXX20_CONSTEXPR
# if __cplusplus > 201703L
#  define _GLIBCXX20_CONSTEXPR constexpr
Takže je otázka, proč ty tam tyhle definice nemáš (i když jinde se tam používají) a kompilátor tomu nerozumí. Zkus g++ prostě přeinstalovat (a případně předtím ještě promazat ty hlavičkové soubory).
Řešení 2× (Gréta, Bherzet)
27.7. 06:59 LK
Rozbalit Rozbalit vše Re: Rozbite G++

Diky moc, toto nakoniec nepriamo pomohlo.

Preinstalovat g++ nepomohlo - ale mas dobry postreh a vsimol si si, ze mam premiesane hlavickove subory. Tak som odinstaloval libgcc-8-dev a libgcc-7-dev (a vsetko, co na tom zaviselo) a kompilacia uz ide.

Založit nové vláknoNahoru

Tiskni Sdílej: Linkuj Jaggni to Vybrali.sme.sk Google Del.icio.us Facebook

ISSN 1214-1267   www.czech-server.cz
© 1999-2015 Nitemedia s. r. o. Všechna práva vyhrazena.