Adding -Wextra -Werror to compiler flags and fixing issues.
This commit is contained in:
parent
226aff325f
commit
e921a24929
|
@ -129,6 +129,8 @@ llvm::Type *LLVMType(Type const& type) {
|
||||||
case Type::UNKNOWN:
|
case Type::UNKNOWN:
|
||||||
return nullptr; // FIXME
|
return nullptr; // FIXME
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
static
|
static
|
||||||
|
@ -355,7 +357,7 @@ bool BitcodeEmitter::emit(Input const& node) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool BitcodeEmitter::emit(Abort const& node) {
|
bool BitcodeEmitter::emit(Abort const&) {
|
||||||
llvm::Function *callee = module->getFunction(ABORT_NAME);
|
llvm::Function *callee = module->getFunction(ABORT_NAME);
|
||||||
|
|
||||||
if (callee == nullptr) {
|
if (callee == nullptr) {
|
||||||
|
|
|
@ -85,7 +85,9 @@ include_directories(
|
||||||
${CMAKE_CURRENT_SOURCE_DIR}
|
${CMAKE_CURRENT_SOURCE_DIR}
|
||||||
)
|
)
|
||||||
|
|
||||||
add_definitions(-Wall -Wno-deprecated-register -std=c++0x -DYYDEBUG=0 -O2)
|
add_definitions(
|
||||||
|
-Wall -Wextra -Werror -Wno-deprecated-register -std=c++0x -DYYDEBUG=0 -O2
|
||||||
|
)
|
||||||
|
|
||||||
bison_target(Parser Monicelli.ypp ${CMAKE_CURRENT_BINARY_DIR}/Parser.cpp)
|
bison_target(Parser Monicelli.ypp ${CMAKE_CURRENT_BINARY_DIR}/Parser.cpp)
|
||||||
flex_target(Scanner Monicelli.lpp ${CMAKE_CURRENT_BINARY_DIR}/Lexer.cpp)
|
flex_target(Scanner Monicelli.lpp ${CMAKE_CURRENT_BINARY_DIR}/Lexer.cpp)
|
||||||
|
|
Reference in New Issue
Block a user