Fixed some windows issues

This commit is contained in:
2024-12-06 16:27:19 +01:00
parent fd62fb822d
commit f73ca0eaec
4 changed files with 27 additions and 13 deletions

View File

@ -95,12 +95,12 @@ class ArgManager {
template<typename T>
std::optional<T> get(const int id) {
if(id < pos_argument.size()) return Argument<T>::get(pos_argument[id]);
std::optional<T> get(const unsigned int id) {
if((unsigned int) id < pos_argument.size()) return Argument<T>::get(pos_argument[id]);
return std::make_optional<T>();
}
std::istream& get_input(const int id) {
std::istream& get_input(const unsigned int id) {
if(id < pos_argument.size()) return ArgInput::get(pos_argument[id]);
return util::cin;
}
@ -171,7 +171,7 @@ class ArgFactory {
if(flag) {
parse_flag(manager, flag);
}
int i = 0;
unsigned int i = 0;
for(const auto& arg : vec) {
std::shared_ptr<_Argument> a;
if(i >= pos_arg_rules.size()) throw std::invalid_argument("More arguments then excpected");