I have just started writing C code in dev-c++. The programs are running fine, but each C program shows me the following warning:

[Warning] command line option "-fno-access-control" is valid for C++/ObjC++ but not for C

The test program I used was:

int main(){
return 0;

After searching a lot all I could find was:

-fno-access-control Do not obey access control semantics

Can anyone please explain, what is this all about?

7 Years
Discussion Span
Last Post by Kanoisa

Go to Project -> Project Options -> Compiler -> C++ Compiler and set "Turn off all access checking option" to No.

So, this is actually the problem of the compiler, nothing less on my code.. right..?
If that is the case, then why is it not set as "NO" by default..


On occasion it is. It depends on when DevC++ is first used if it is set to default as C++ or C (although to be honest i would stay away from devC++ all together)

Its just one of those little things that bug people. So basically what were saying here is your code is fine devC++ is complaining about nothing and it does not matter :)

Edited by Kanoisa: n/a

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.