From 1539a8c3efaf51f8109155df9a17e611fb04fd55 Mon Sep 17 00:00:00 2001 From: Felipe Zimmerle Date: Tue, 5 Apr 2016 09:56:08 -0300 Subject: [PATCH] Fix the coding style of the pull request #1115 --- src/actions/transformations/remove_whitespace.cc | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/actions/transformations/remove_whitespace.cc b/src/actions/transformations/remove_whitespace.cc index d09453fc..a76ff135 100644 --- a/src/actions/transformations/remove_whitespace.cc +++ b/src/actions/transformations/remove_whitespace.cc @@ -39,15 +39,14 @@ RemoveWhitespace::RemoveWhitespace(std::string action) std::string RemoveWhitespace::evaluate(std::string value, Transaction *transaction) { - long int i = 0; + int64_t i = 0; // loop through all the chars - while(i < value.size()) { + while (i < value.size()) { // remove whitespaces and non breaking spaces (NBSP) - if (isspace(value[i])||(value[i] == NBSP)) { - value.erase(i, 1); - } - else { + if (isspace(value[i]) || (value[i] == NBSP)) { + value.erase(i, 1); + } else { /* if the space is not a whitespace char, increment counter counter should not be incremented if a character is erased because the index erased will be replaced by the following character */