Skip to content

Overloading issue in stringer.h #14

@sjalloq

Description

@sjalloq

Hi there,

I'm trying to compile on OS X using XCode and am getting the following error.

Thanks.

g++ --version
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include/c++/4.2.1
Apple LLVM version 10.0.0 (clang-1000.11.45.5)
Target: x86_64-apple-darwin18.2.0
In file included from ./json_lexer.h:67:
./stringer.h:590:21: error: call to 'toString' is ambiguous
        m_buffer += toString(arg,10);
                    ^~~~~~~~
./stringer.h:100:21: note: candidate function
        inline std::string toString(int64_t value, int base = 10, unsigned int padding = 0)
                           ^
./stringer.h:143:21: note: candidate function
        inline std::string toString(int value, int base = 10)
                           ^
./stringer.h:149:21: note: candidate function
        inline std::string toString(unsigned int value, int base = 10)
                           ^
1 error generated.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions