Jaagrav / CodeX

CodeX is an online compiler for various languages like Java, C++, Python, etc. Execute code in various languages on your own website for free with the CodeX API!!!
https://codex.jaagrav.in/
268 stars 65 forks source link

How to ignore compiler warnings in cpp? #1

Closed aakashpothepalli closed 2 years ago

aakashpothepalli commented 3 years ago

The compiler throws warnings in the output even for small things... For example, here I have not used a variable even though I have declared it.. Now the compiler throws me this warning

./Playground/file0.cpp: In function 'int main()':
./Playground/file0.cpp:28:12: warning: unused variable 'es' [-Wunused-variable]
28 | int es = 0;

I have to parse and sanitise the output before showing it on the website. Is there any way for me to disable the warnings?

Btw, thanks for designing and providing the API for free :)

Jaagrav commented 2 years ago

Sorry for the late reply, you unfortunately cannot avoid warnings that are generated, it is a fault from my side and tbh I do not have a quick fix for it when the code gets executed on one of my laptops. Sorry for the inconvenience.