diff --git a/src/Makefile b/src/Makefile index 96794daa..d252715e 100644 --- a/src/Makefile +++ b/src/Makefile @@ -2,7 +2,7 @@ sources := $(wildcard *.cc) objects := $(addprefix ., $(sources:.cc=.o)) deps := $(addprefix ., $(sources:.cc=.d)) -CXXFLAGS += -std=c++11 -g -Wall -Wno-reorder -Wno-sign-compare +CXXFLAGS += -std=c++11 -g -Wall -Wno-reorder -Wno-sign-compare -pedantic LIBS += -lmenu -lncursesw -lboost_regex debug ?= yes diff --git a/src/dynamic_selection_list.hh b/src/dynamic_selection_list.hh index 34f4c05c..1d976992 100644 --- a/src/dynamic_selection_list.hh +++ b/src/dynamic_selection_list.hh @@ -25,7 +25,7 @@ private: const BufferIterator& end) override; }; -}; +} #endif // dynamic_selection_list_hh_INCLUDED diff --git a/src/highlighters.cc b/src/highlighters.cc index dd3becf8..b8d1c348 100644 --- a/src/highlighters.cc +++ b/src/highlighters.cc @@ -196,7 +196,7 @@ HighlighterAndId highlight_search_factory(const HighlighterParameters params, co { throw runtime_error(String("regex error: ") + err.what()); } -}; +} HighlighterAndId highlight_regex_option_factory(const HighlighterParameters params, const Window& window) { @@ -211,7 +211,7 @@ HighlighterAndId highlight_regex_option_factory(const HighlighterParameters para auto get_regex = [option_name, &options]{ return options[option_name].get(); }; return {"hloption_" + option_name, DynamicRegexHighlighter{colors, get_regex}}; -}; +} void expand_tabulations(const OptionManager& options, DisplayBuffer& display_buffer) { diff --git a/src/remote.cc b/src/remote.cc index f3d5db01..2e19cc45 100644 --- a/src/remote.cc +++ b/src/remote.cc @@ -53,7 +53,7 @@ public: void write(const T& val) { write((const char*)&val, sizeof(val)); - }; + } void write(const String& str) { @@ -67,7 +67,7 @@ public: write(view.size()); for (auto& val : view) write(val); - }; + } template void write(const std::vector& vec) @@ -119,7 +119,7 @@ T read(int socket) char value[sizeof(T)]; read(socket, value, sizeof(T)); return *(T*)(value); -}; +} template<> String read(int socket) @@ -131,7 +131,7 @@ String read(int socket) assert(length < 2048); read(socket, buffer, (int)length); return String(buffer, buffer+(int)length); -}; +} template std::vector read_vector(int socket) @@ -142,7 +142,7 @@ std::vector read_vector(int socket) while (size--) res.push_back(read(socket)); return res; -}; +} template<> DisplayAtom read(int socket)