Tag Archives: errors

errors , bugs and how to fix this

error: ‘memset’ was not declared in this scope

If you receive: error: ‘memset’ was not declared in this scope

Fix it by including: #include <cstring> in the source of C++file. If you use C than use : #include <string.h> .

C::B bad compiler selection.

Under codeblocks if you select a bad compiler, you got this error:

Click right under project and select Buil Options….Now select your compiler.

warning: deprecated conversion from string constant to ‘char*’

I might encounter when I compile with code::blocks one C++ file.

You won’t get that error .

So , you need to make an explicit typecast:

error: ‘for’ loop initial declarations are only allowed in C99 mode

Some errors you might encounter when you compile with code::blocks.

The one of many reason is you have written a code like:

To solve this error , just write code like this: