Skip to content

ambiguous simplecpp::TokenList constructors with >= C++17 #588

Description

@firewave

Calling simplecpp::TokenList with a char buffer will lead to a compilation failure because of ambiguous constructors:

/home/user/CLionProjects/cppcheck/externals/simplecpp/./simplecpp.h:254:9: note: candidate constructor
  254 |         TokenList(std::string_view data, std::vector<std::string> &filenames, const std::string &filename=std::string(), OutputList *outputList = nullptr)
      |         ^
/home/user/CLionProjects/cppcheck/externals/simplecpp/./simplecpp.h:271:9: note: candidate constructor
  271 |         TokenList(const std::string &filename, std::vector<std::string> &filenames, OutputList *outputList = nullptr);
      |         ^

Fixing #424 might make this more explicit when we no longer allow the filename to be provided via the vector and the explicit parameter.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions