Date: Thu, 21 Nov 1996 17:21:49 +0200 (IST) From: Eli Zaretskii To: "A.Appleyard" Cc: DJGPP AT delorie DOT com Subject: Re: v2 unwanted warnings In-Reply-To: Message-Id: Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On Thu, 21 Nov 1996, A.Appleyard wrote: > (0) About how many messages are there per day now on djgpp email group? Can you read Usenet News? If so, you can just read the comp.os.msdos.djgpp news group whenever you have time. All DJGPP messages are automaticvally reflected there. > is stuffed out with hundreds of `warning: unused parameter' warning lines. > How to stop these warning and still use -Wall for its other useful properties? Try this (it's in the gcc docs, btw): gcc -Wall -Wno-unused ... However, -Wno-unused also shuts up gcc in other cases (such as whenever a function is declared static but never defined, whenever a label is declared but not used, and whenever a statement computes a result that is explicitly not used), and you might still want those. So you might consider pacifying -Wall by other means. One simple way is this: void myfunc (int var1, int var2, int var3) { var2 = var2; /* unused, pacify -Wall */ .... There are other methods, all documented in the gcc docs (such as the `unused' attribute), but most of them are gcc-specific and won't do if you need your program to compile with other compilers. The above trick will always work. > (2) Can this warning be suppressed specifically, similarly?:- > `warning: suggest parentheses around assignment used as truth value' Use -Wno-parentheses. I don't know about the last one, since I never push C that far.