mirror of
https://github.com/oatpp/oatpp.git
synced 2025-02-05 17:09:38 +08:00
Fixed warnings 2 in the project (implicit cast, move, unused and uninitialized variables).
This commit is contained in:
parent
1b6451ebfe
commit
5df66ea902
@ -174,7 +174,7 @@ Action CoroutineStarter::next(Action&& action) {
|
||||
Action result = m_first;
|
||||
m_first = nullptr;
|
||||
m_last = nullptr;
|
||||
return std::move(result);
|
||||
return result;
|
||||
}
|
||||
|
||||
CoroutineStarter& CoroutineStarter::next(CoroutineStarter&& starter) {
|
||||
|
@ -690,7 +690,7 @@ public:
|
||||
m_coroutine->m_callback = (FunctionPtr)(callback);
|
||||
Action result = m_coroutine;
|
||||
m_coroutine = nullptr;
|
||||
return std::move(result);
|
||||
return result;
|
||||
|
||||
}
|
||||
|
||||
|
@ -122,7 +122,7 @@ Deserializer::AbstractObjectWrapper Deserializer::readInt32Value(oatpp::parser::
|
||||
if(caret.isAtText("null", true)){
|
||||
return AbstractObjectWrapper(Int32::ObjectWrapper::Class::getType());
|
||||
} else {
|
||||
return AbstractObjectWrapper(Int32::ObjectType::createAbstract((int)caret.parseInt()), Int32::ObjectWrapper::Class::getType());
|
||||
return AbstractObjectWrapper(Int32::ObjectType::createAbstract((const int)caret.parseInt()), Int32::ObjectWrapper::Class::getType());
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -298,8 +298,8 @@ void Parser::parseResponseStartingLine(ResponseStartingLine& line,
|
||||
error = Status::CODE_400;
|
||||
return;
|
||||
}
|
||||
|
||||
line.statusCode = (int)caret.parseInt();
|
||||
|
||||
line.statusCode = (v_int32)caret.parseInt();
|
||||
|
||||
auto descriptionLabel = caret.putLabel();
|
||||
if(caret.findRN()){
|
||||
|
@ -52,4 +52,4 @@ void DtoBody::declareHeaders(Headers& headers) noexcept {
|
||||
}
|
||||
}
|
||||
|
||||
}}}}}
|
||||
}}}}}
|
||||
|
@ -116,7 +116,7 @@ void ChunkedBufferTest::onRun() {
|
||||
OATPP_ASSERT(oatpp::String((const char*)&wholeText->getData()[i], substringSize, false) == stream.getSubstring(i, substringSize));
|
||||
}
|
||||
|
||||
substringSize = ChunkedBuffer::CHUNK_ENTRY_SIZE * 2;
|
||||
substringSize = (v_int32) ChunkedBuffer::CHUNK_ENTRY_SIZE * 2;
|
||||
for(v_int32 i = 0; i < wholeText->getSize() - substringSize; i ++) {
|
||||
OATPP_ASSERT(oatpp::String((const char*)&wholeText->getData()[i], substringSize, false) == stream.getSubstring(i, substringSize));
|
||||
}
|
||||
@ -126,4 +126,4 @@ void ChunkedBufferTest::onRun() {
|
||||
|
||||
}
|
||||
|
||||
}}}}}
|
||||
}}}}}
|
||||
|
Loading…
Reference in New Issue
Block a user