Click here to Skip to main content
15,897,371 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi!When I'm compiling a program a header file is opening in that it's showing an error as it is an invalid preprocessor directive
the statement is showing wrong {typedefsize_t rsize_t;}
what changes should i do now ini the header file the name of the header file is (crtdefs.h)

What I have tried:

i've tried to change the code by just adding # before the typedefsize_t rsize_t;
but it,s not working

And i removed the codeline then it's showing error in another header file mingw.h

i replaced the word rsize with resize but also it's not working
Posted
Updated 6-Sep-18 17:47pm
Comments
Patrice T 6-Sep-18 23:22pm    
Richard MacCutchan 7-Sep-18 4:52am    
Of course it's not working, you are changing something that will affect other elements in the file. Do not edit system header files, ever; it will just bring you trouble. Please edit your question and show the exact detail from the compilation. If that file truly contains the text you have shown above, then someone has already corrupted it.

1 solution

The file crtdefs.h is a compiler header file and you should NOT make changes to it. It contains the C Run-Time Library definitions and if you change it all kinds of bad things could happen in your program.

It is hard to guess what the problem is without seeing your code. It could also be conflicting arguments passed to the compiler that caused the problem so you should include the command-line you use to compile your program.

You can edit your question to include this information.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900