From 935600fb9612ef569f1f68f60b0b7cdd57ce7af6 Mon Sep 17 00:00:00 2001 From: Tom Harley Date: Wed, 30 Oct 2019 14:38:00 +0000 Subject: Enable -Weverything Clang has a -Weverything option, that enables all compile-time warnings and elevates them all to errors. This option is now passed to the compiler, and all warnings/errors the code produced have been addressed. Using -Weverything locks the project into using clang as its compiler: this should not be a problem since clang is probably being used to compile the LLVM output of the project anyway. If support for other compilers is required, it should be simple enough to replace -Weverything with an equivalent collection of portable flags. Explicit Makefile rules for compiling the C files produced by flex/bison are now included in the project since these C files absolutely do not pass -Weverything checks. --- scope.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'scope.h') diff --git a/scope.h b/scope.h index 196f88a..3737f63 100644 --- a/scope.h +++ b/scope.h @@ -1,5 +1,5 @@ -#ifndef _SCOPE_H -#define _SCOPE_H +#ifndef SCOPE_H +#define SCOPE_H #include @@ -23,4 +23,4 @@ void scope_pop_layer(scope *sc); void scope_add_entry(scope sc, char *id, LLVMValueRef val, LLVMTypeRef type); scope_entry *scope_find(scope sc, char *id); -#endif /* _SCOPE_H */ +#endif /* SCOPE_H */ -- cgit v1.2.1