error: call of overloaded ‘to_chars(std::array<char, 10>::pointer, std::array<char, 10>::pointer, const int&, std::chars_format)’ is ambiguous

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi:

Attempting to compile the function 'test()' as shown below gives the following compiler error

error: call of overloaded ‘to_chars(std::array<char, 10>::pointer, std::array<char, 10>::pointer, const int&, std::chars_format)’ is ambiguous

Environment

 GNU/Linux 6.9.3-arch1-1
 GNU glibc 2.39
 g++ 15.0.0 20240726 (experimental) (GCC)


Compiler invocation

 g++ -std=c++23 -v -O0 -fmodules-ts -lstdc++exp num2str.cc


Code

auto test () -> void {

      int const num {433};

      std::array <char, 10> str {};

      std::to_chars_result result {
            std::to_chars (
                  str.data ()
                  , str.data () + str.size ()
                  , num
                  , std::chars_format::fixed
                  )
      };

}


Any pointers ?


warm regards
Saifi.



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux