[m-dev.] diff: don't pass -Wtraditional to gcc
Fergus Henderson
fjh at cs.mu.OZ.AU
Fri Nov 17 14:49:01 AEDT 2000
Estimated hours taken: 0.25
scripts/mgnuc.in:
compiler/mercury_compile.m:
Don't pass `-Wtraditional' to GNU C, since this results in
many warnings with gcc 2.96, e.g. about the use of ANSI C
preprocessor constructors such as string concatenation and
indented `#define'. We don't care about compatibility with
pre-ANSI C compilers.
Workspace: /home/pgrad/fjh/ws/hg
Index: compiler/mercury_compile.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mercury_compile.m,v
retrieving revision 1.181
diff -u -d -r1.181 mercury_compile.m
--- compiler/mercury_compile.m 2000/10/14 04:00:12 1.181
+++ compiler/mercury_compile.m 2000/11/17 03:47:29
@@ -2780,9 +2780,9 @@
% if --inline-alloc is enabled, don't enable missing-prototype
% warnings, since gc_inline.h is missing lots of prototypes
( InlineAlloc = yes ->
- WarningOpt = "-Wall -Wwrite-strings -Wpointer-arith -Wtraditional -Wshadow -Wmissing-prototypes -Wno-unused -Wno-uninitialized "
+ WarningOpt = "-Wall -Wwrite-strings -Wpointer-arith -Wshadow -Wmissing-prototypes -Wno-unused -Wno-uninitialized "
;
- WarningOpt = "-Wall -Wwrite-strings -Wpointer-arith -Wtraditional -Wshadow -Wmissing-prototypes -Wno-unused -Wno-uninitialized -Wstrict-prototypes "
+ WarningOpt = "-Wall -Wwrite-strings -Wpointer-arith -Wshadow -Wmissing-prototypes -Wno-unused -Wno-uninitialized -Wstrict-prototypes "
)
; CompilerType = lcc ->
WarningOpt = "-w "
Index: scripts/mgnuc.in
===================================================================
RCS file: /home/mercury1/repository/mercury/scripts/mgnuc.in,v
retrieving revision 1.73
diff -u -d -r1.73 mgnuc.in
--- scripts/mgnuc.in 2000/09/21 05:01:11 1.73
+++ scripts/mgnuc.in 2000/11/17 03:44:11
@@ -38,6 +38,7 @@
# Note: we do not enable the following gcc warnings:
# -Wredundant-decls causes too many complaints in system header files
+# -Wtraditional we don't care about compatibility with pre-ANSI C
# -Wconversion really only intended to help people using \`unprotoize'
# -Waggregate-return not useful, IMHO
@@ -46,6 +47,8 @@
# -pedantic causes unsuppressable warnings about LVALUE_CAST()
# -Wnested-externs causes unsuppressable warnings about callentry()
# -Wid-clash-31 causes warnings about entry_mercury__xxx ...
+# we don't care about compatibility with C compilers
+# that have short fixed limits on identifier length
# -Wenum-clash is for C++ only
# -Wunused causes various spurious warnings
--
Fergus Henderson <fjh at cs.mu.oz.au> | "I have always known that the pursuit
| of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh> | -- the last words of T. S. Garp.
--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to: mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions: mercury-developers-request at cs.mu.oz.au
--------------------------------------------------------------------------
More information about the developers
mailing list