error: call of overloaded function ambiguous

  ambiguous, c++, stl

i am trying to compile ustl c++ library with mingw gcc compiler on win10.

The 41th line in the C ++ header below was able to solve thanks to this answer, but there is a problem at 43 line. How should I solve it?

https://github.com/msharov/ustl/blob/master/fstream.h#L41

    // int          ioctl (const char* rname, int request, long argument = 0);   // orig
    int         ioctl (const char* rname, int request, long argument = 0u);
    inline int      ioctl (const char* rname, int request, int argument)    { return fstream::ioctl (rname, request, long(argument)); }
    inline int      ioctl (const char* rname, int request, void* argument)  { return fstream::ioctl (rname, request, intptr_t(argument)); }

MingW GCC compiler (10.3.0 (Rev5, Built by MSYS2 project)) error message:

fstream.h:43:132: error: call of overloaded ‘ioctl(const char*&, int&,
uintptr_t)’ is ambiguous 43 | inline int ioctl (const char*
rname, int request, void* argument) { return fstream::ioctl (rname,
request, uintptr_t(argument)); }

Source: Windows Questions C++

LEAVE A COMMENT