Reporting error on calling memcpy
c
Solution
You can use the preprocessor for this, like
#define memcpy(a, b, c) do_not_use_memcpy
Put that in a header file that is included in all source files, and the preprocessor will replace all calls to `memcpy` with the (undefined) symbol `do_not_use_memcpy`. As that symbol is undefined, you will get a compiler error about it.
Problem
How can I make sure that if someone uses come specific function(say memcpy) in code, then it returns an error. We have removed all the instances of memcpy from code with some internal designed function, what I want to make sure is that whenever someone uses memcpy in future, the compiler throws an errors msg.