mirror of
https://github.com/CLIUtils/CLI11.git
synced 2025-05-08 07:43:52 +00:00
Fixes for Windows warnings
This commit is contained in:
parent
e328364ae7
commit
4b07ef52d5
@ -19,6 +19,7 @@ if(CMAKE_COMPILER_IS_GNUCC)
|
||||
endif()
|
||||
if(MSVC)
|
||||
add_definitions("/W4")
|
||||
add_definitions(-D_CRT_SECURE_NO_WARNINGS)
|
||||
endif()
|
||||
|
||||
add_library(CLI INTERFACE)
|
||||
|
@ -519,9 +519,9 @@ public:
|
||||
}
|
||||
|
||||
/// Check with name instead of pointer
|
||||
bool got_subcommand(std::string name) const {
|
||||
bool got_subcommand(std::string name_) const {
|
||||
for(const auto subcomptr : selected_subcommands)
|
||||
if(subcomptr->check_name(name))
|
||||
if(subcomptr->check_name(name_))
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
@ -630,7 +630,7 @@ protected:
|
||||
// Collect positionals
|
||||
|
||||
// Loop over all positionals
|
||||
for(int i=0; i<missing.size(); i++) {
|
||||
for(size_t i=0; i<missing.size(); i++) {
|
||||
|
||||
// Skip non-positionals (speedup)
|
||||
if(missing.at(i).first != detail::Classifer::NONE)
|
||||
|
Loading…
x
Reference in New Issue
Block a user