Avoid 'unsigned' in ctu

This commit is contained in:
Daniel Marjamäki 2019-07-13 20:31:50 +02:00
parent e489d9a40f
commit 49dd2deef1
2 changed files with 7 additions and 7 deletions

View File

@ -457,7 +457,7 @@ std::list<CTU::FileInfo::UnsafeUsage> CTU::getUnsafeUsage(const Tokenizer *token
}
static bool findPath(const std::string &callId,
unsigned int callArgNr,
int callArgNr,
MathLib::bigint unsafeValue,
CTU::FileInfo::InvalidValueType invalidValue,
const std::map<std::string, std::list<const CTU::FileInfo::CallBase *>> &callsMap,

View File

@ -40,16 +40,16 @@ namespace CTU {
struct Location {
Location() = default;
Location(const Tokenizer *tokenizer, const Token *tok);
Location(const std::string &fileName, unsigned int linenr) : fileName(fileName), linenr(linenr) {}
Location(const std::string &fileName, int linenr) : fileName(fileName), linenr(linenr) {}
std::string fileName;
unsigned int linenr;
int linenr;
};
struct UnsafeUsage {
UnsafeUsage() = default;
UnsafeUsage(const std::string &myId, unsigned int myArgNr, const std::string &myArgumentName, const Location &location, MathLib::bigint value) : myId(myId), myArgNr(myArgNr), myArgumentName(myArgumentName), location(location), value(value) {}
UnsafeUsage(const std::string &myId, int myArgNr, const std::string &myArgumentName, const Location &location, MathLib::bigint value) : myId(myId), myArgNr(myArgNr), myArgumentName(myArgumentName), location(location), value(value) {}
std::string myId;
unsigned int myArgNr;
int myArgNr;
std::string myArgumentName;
Location location;
MathLib::bigint value;
@ -89,7 +89,7 @@ namespace CTU {
public:
NestedCall() = default;
NestedCall(const std::string &myId, unsigned int myArgNr, const std::string &callId, unsigned int callArgnr, const std::string &callFunctionName, const Location &location)
NestedCall(const std::string &myId, int myArgNr, const std::string &callId, int callArgnr, const std::string &callFunctionName, const Location &location)
: CallBase(callId, callArgnr, callFunctionName, location),
myId(myId),
myArgNr(myArgNr) {
@ -101,7 +101,7 @@ namespace CTU {
bool loadFromXml(const tinyxml2::XMLElement *xmlElement);
std::string myId;
unsigned int myArgNr;
int myArgNr;
};
std::list<FunctionCall> functionCalls;