Fixes sign-compare warnings
This commit is contained in:
parent
a1494e938a
commit
9b0f5d9b0d
41 changed files with 109 additions and 108 deletions
|
|
@ -207,7 +207,7 @@ dap::ResponseOrError<dap::SetBreakpointsResponse> BreakpointManager::SetBreakpoi
|
|||
found.pop();
|
||||
continue;
|
||||
}
|
||||
for (int i = 0; i < func->LineInfoCount; i++)
|
||||
for (uint i = 0; i < func->LineInfoCount; i++)
|
||||
{
|
||||
if (func->LineInfo[i].LineNumber == line)
|
||||
{
|
||||
|
|
@ -453,7 +453,7 @@ dap::ResponseOrError<dap::SetInstructionBreakpointsResponse> BreakpointManager::
|
|||
|
||||
dap::SetInstructionBreakpointsResponse response;
|
||||
ClearBreakpointsType(BreakpointInfo::Type::Instruction);
|
||||
for (int i = 0; i < breakpoints.size(); i++)
|
||||
for (uint i = 0; i < breakpoints.size(); i++)
|
||||
{
|
||||
auto &bp = breakpoints[i];
|
||||
void *srcAddress = (void *)(std::stoull(bp.instructionReference.substr(2), nullptr, 16));
|
||||
|
|
|
|||
|
|
@ -337,7 +337,7 @@ dap::array<dap::Breakpoint> DebugExecutionManager::SetExceptionBreakpointFilters
|
|||
{
|
||||
m_exceptionFilters.clear();
|
||||
dap::array<dap::Breakpoint> breakpoints;
|
||||
for (int i = 0; i < filterIds.size(); i++)
|
||||
for (uint i = 0; i < filterIds.size(); i++)
|
||||
{
|
||||
auto breakpoint = dap::Breakpoint();
|
||||
int64_t id = (int64_t)DebugExecutionManager::GetFilterID(filterIds[i]);
|
||||
|
|
|
|||
|
|
@ -750,7 +750,7 @@ static std::string GetParameterName(const VMFrame *m_stackFrame, int paramidx)
|
|||
static const char *const INVOKER = "invoker";
|
||||
static const char *const STATE_POINTER = "stateinfo";
|
||||
|
||||
auto implicitCount = GetImplicitParmeterCount(m_stackFrame);
|
||||
int implicitCount = GetImplicitParmeterCount(m_stackFrame);
|
||||
if (paramidx < implicitCount)
|
||||
{
|
||||
switch (paramidx)
|
||||
|
|
@ -771,7 +771,7 @@ static std::string GetParameterName(const VMFrame *m_stackFrame, int paramidx)
|
|||
if (variant)
|
||||
{
|
||||
auto ¶ms = variant->ArgNames;
|
||||
if (paramidx < params.Size())
|
||||
if (paramidx < params.SSize())
|
||||
{
|
||||
return params[paramidx].GetChars();
|
||||
}
|
||||
|
|
@ -1156,4 +1156,4 @@ static FBaseCVar *FindConsoleVariable(const std::string &name)
|
|||
return FindCVar(name.c_str(), nullptr);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -214,7 +214,7 @@ bool ArrayStateNode::GetChildNode(std::string name, std::shared_ptr<StateNodeBas
|
|||
break;
|
||||
default:
|
||||
// too large, return a ptr to the array element
|
||||
assert(elementIndex <= static_cast<FArray *>(array_head)->Count);
|
||||
assert(unsigned(elementIndex) <= static_cast<FArray *>(array_head)->Count);
|
||||
element_val = VMValue((void *)(((char *)static_cast<FArray *>(array_head)->Array) + (elementIndex * elementType->Size)));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ bool StackFrameStateNode::SerializeToProtocol(dap::StackFrame &stackFrame, PexCa
|
|||
{
|
||||
// end of the function, get the max line number
|
||||
int max_line = 0;
|
||||
for (int i = 0; i < scriptFunction->LineInfoCount; i++)
|
||||
for (uint i = 0; i < scriptFunction->LineInfoCount; i++)
|
||||
{
|
||||
if (scriptFunction->LineInfo[i].LineNumber > max_line)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -489,7 +489,7 @@ dap::ResponseOrError<dap::VariablesResponse> ZScriptDebugger::GetVariables(const
|
|||
bool only_indexed = request.filter.value("") == "indexed";
|
||||
bool only_named = request.filter.value("") == "named";
|
||||
|
||||
for (int64_t i = 0; i < variableNodes.size(); i++)
|
||||
for (int64_t i = 0; i < (int64_t)variableNodes.size(); i++)
|
||||
{
|
||||
auto asVariableSerializable = dynamic_cast<IProtocolVariableSerializable *>(variableNodes.at(i).get());
|
||||
if (!asVariableSerializable)
|
||||
|
|
|
|||
|
|
@ -577,9 +577,9 @@ VMFrame *VMFrameStack::PopFrame()
|
|||
|
||||
void VMCheckParamCount(VMFunction* func, int retcount, int argcount)
|
||||
{
|
||||
if (func->Proto->ReturnTypes.Size() != retcount)
|
||||
if (func->Proto->ReturnTypes.SSize() != retcount)
|
||||
I_FatalError("Incorrect return value passed to %s", func->PrintableName);
|
||||
if (func->Proto->ArgumentTypes.Size() != argcount)
|
||||
if (func->Proto->ArgumentTypes.SSize() != argcount)
|
||||
I_FatalError("Incorrect parameter count passed to %s", func->PrintableName);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue