Making sure no warnings are printed (except for getenv) on windows.
This commit is contained in:
6
json.cpp
6
json.cpp
@@ -92,7 +92,7 @@ const JSON &JSON::at(unsigned int index) const {
|
||||
|
||||
int JSON::length() const {
|
||||
if( Type == Class::Array )
|
||||
return Internal.List->size();
|
||||
return static_cast<int>(Internal.List->size());
|
||||
else
|
||||
return -1;
|
||||
}
|
||||
@@ -105,9 +105,9 @@ bool JSON::hasKey(const std::string &key) const {
|
||||
|
||||
int JSON::size() const {
|
||||
if( Type == Class::Object )
|
||||
return Internal.Map->size();
|
||||
return static_cast<int>(Internal.Map->size());
|
||||
else if( Type == Class::Array )
|
||||
return Internal.List->size();
|
||||
return static_cast<int>(Internal.List->size());
|
||||
else
|
||||
return -1;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user