enable warnings

llvm
Clyne 2 years ago
parent 2aaec63b91
commit 81b2fa5d3c

@ -1,4 +1,5 @@
CXXFLAGS += -std=c++17 -g3 -ggdb -O0 CXXFLAGS += -std=c++17 -g3 -ggdb -O0 \
-Wall -Wextra -pedantic -Wno-vla -Werror
CXXFILES := corewords.cpp dictionary.cpp parser.cpp state.cpp types.cpp CXXFILES := corewords.cpp dictionary.cpp parser.cpp state.cpp types.cpp
OBJFILES := $(subst .cpp,.o,$(CXXFILES)) OBJFILES := $(subst .cpp,.o,$(CXXFILES))

@ -115,7 +115,7 @@ Word Dictionary::input()
bool Dictionary::equal(Word word, std::string_view sv) const bool Dictionary::equal(Word word, std::string_view sv) const
{ {
if (sv.size() != word.end - word.start) if (sv.size() != static_cast<Addr>(word.end - word.start))
return false; return false;
for (unsigned i = 0; i < sv.size(); ++i) { for (unsigned i = 0; i < sv.size(); ++i) {

Loading…
Cancel
Save