Fix some trailing spaces and a tab that sneaked into the code base

This commit is contained in:
Maxime Coste 2018-04-05 08:52:33 +10:00
parent 6ee68b5b08
commit 71a1893a5e
8 changed files with 11 additions and 11 deletions

View File

@ -105,7 +105,7 @@ DisplayLine::iterator DisplayLine::split(iterator it, ColumnCount count)
return m_atoms.insert(it, std::move(atom));
}
auto pos = utf8::advance(get_iterator(it->buffer(), it->begin()),
get_iterator(it->buffer(), it->end()),
get_iterator(it->buffer(), it->end()),
count).coord();
return split(it, pos);
}

View File

@ -291,7 +291,7 @@ struct HashMap
constexpr bool empty() const { return m_items.empty(); }
constexpr void reserve(size_t size)
{
m_items.reserve(size);
m_items.reserve(size);
m_index.reserve(size);
}

View File

@ -75,7 +75,7 @@ String to_json(Color color)
String to_json(Attribute attributes)
{
struct Attr { Attribute attr; StringView name; }
attrs[] {
attrs[] {
{ Attribute::Exclusive, "exclusive" },
{ Attribute::Underline, "underline" },
{ Attribute::Reverse, "reverse" },

View File

@ -9,7 +9,7 @@
#include "string_utils.hh"
#include "vector.hh"
#include <cstring>
#include <cstring>
namespace Kakoune
{
@ -390,7 +390,7 @@ private:
std::sort(ranges.begin(), ranges.end(),
[](auto& lhs, auto& rhs) { return lhs.min < rhs.min; });
// merge overlapping ranges
// merge overlapping ranges
auto pos = ranges.begin();
for (auto next = pos+1; next != ranges.end(); ++next)
{

View File

@ -173,7 +173,7 @@ public:
uint32_t size() const
{
kak_assert(m_write_pos >= header_size);
kak_assert(m_write_pos >= header_size);
uint32_t res;
memcpy(&res, m_stream.data() + sizeof(MessageType), sizeof(uint32_t));
return res;
@ -181,7 +181,7 @@ public:
MessageType type() const
{
kak_assert(m_write_pos >= header_size);
kak_assert(m_write_pos >= header_size);
return *reinterpret_cast<const MessageType*>(m_stream.data());
}

View File

@ -353,7 +353,7 @@ find_surrounding(const Container& container, Iterator pos,
first = utf8::previous(first, container.begin());
if (auto res = find_opening(first+1, container, opening, closing, level, nestable))
first = (flags & ObjectFlags::Inner) ? res->second : res->first;
first = (flags & ObjectFlags::Inner) ? res->second : res->first;
else
return {};
}
@ -370,7 +370,7 @@ find_surrounding(const Container& container, Iterator pos,
if (auto res = find_closing(last, container, opening, closing, level, nestable))
last = (flags & ObjectFlags::Inner) ? utf8::previous(res->first, container.begin())
: utf8::previous(res->second, container.begin());
: utf8::previous(res->second, container.begin());
else
return {};
}

View File

@ -191,7 +191,7 @@ public:
const char* data() const { return is_long() ? l.ptr : s.string; }
char* data() { return is_long() ? l.ptr : s.string; }
template<bool copy = true>
template<bool copy = true>
void reserve(size_t new_capacity);
void set_size(size_t size);
void force_size(size_t new_size);

View File

@ -21,7 +21,7 @@ static WordList get_words(StringView content, ConstArrayView<Codepoint> extra_wo
{
if (is_word(*it))
{
const char* word = it.base();
const char* word = it.base();
while (++it != content.end() and is_word(*it))
{}
res.emplace_back(word, it.base());