Fix warnings on visual studio, including changing unsigned to std::size_t

This commit is contained in:
Jesse Beder
2015-01-24 14:38:22 -06:00
parent ad712c4f2d
commit 0c8a539361
12 changed files with 66 additions and 58 deletions

View File

@@ -155,7 +155,7 @@ void EmitterState::EndedGroup(GroupType::value type) {
}
// reset old settings
unsigned lastIndent = (m_groups.empty() ? 0 : m_groups.top().indent);
std::size_t lastIndent = (m_groups.empty() ? 0 : m_groups.top().indent);
assert(m_curIndent >= lastIndent);
m_curIndent -= lastIndent;
@@ -276,7 +276,7 @@ bool EmitterState::SetIntFormat(EMITTER_MANIP value, FmtScope::value scope) {
}
}
bool EmitterState::SetIndent(unsigned value, FmtScope::value scope) {
bool EmitterState::SetIndent(std::size_t value, FmtScope::value scope) {
if (value <= 1)
return false;
@@ -284,7 +284,8 @@ bool EmitterState::SetIndent(unsigned value, FmtScope::value scope) {
return true;
}
bool EmitterState::SetPreCommentIndent(unsigned value, FmtScope::value scope) {
bool EmitterState::SetPreCommentIndent(std::size_t value,
FmtScope::value scope) {
if (value == 0)
return false;
@@ -292,7 +293,8 @@ bool EmitterState::SetPreCommentIndent(unsigned value, FmtScope::value scope) {
return true;
}
bool EmitterState::SetPostCommentIndent(unsigned value, FmtScope::value scope) {
bool EmitterState::SetPostCommentIndent(std::size_t value,
FmtScope::value scope) {
if (value == 0)
return false;