build: Fix clang build warnings

This commit is contained in:
Calcitem 2020-10-30 01:41:19 +08:00
parent df33b731ea
commit 8a5b3f3bff
2 changed files with 4 additions and 2 deletions

View File

@ -159,7 +159,7 @@ CXXFLAGS += -Wall -Wcast-qual -fno-exceptions -std=c++17 $(EXTRACXXFLAGS)
DEPENDFLAGS += -std=c++17
LDFLAGS += $(EXTRALDFLAGS)
CXXFLAGS += -Wno-class-memaccess -I../include -I.
CXXFLAGS += -I../include -I.
ifeq ($(COMP),)
COMP=gcc
@ -169,6 +169,7 @@ ifeq ($(COMP),gcc)
comp=gcc
CXX=g++
CXXFLAGS += -pedantic -Wextra -Wshadow
CXXFLAGS += -Wno-class-memaccess
ifeq ($(ARCH),armv7)
ifeq ($(OS),Android)
@ -220,6 +221,7 @@ ifeq ($(COMP),clang)
comp=clang
CXX=clang++
CXXFLAGS += -pedantic -Wextra -Wshadow
CXXFLAGS += -Wno-class-varargs
ifneq ($(KERNEL),Darwin)
ifneq ($(KERNEL),OpenBSD)

View File

@ -66,7 +66,7 @@ const string PieceToChar(Piece p)
return "*";
}
const Piece CharToPiece(char ch)
Piece CharToPiece(char ch)
{
if (ch == '*') {