I am looking for C++ code to get getch() and getche() functions for linux. I briefly looked at the code and I saw that they are using the new
keyword just like an identifier.
Here is the link : What is Equivalent to getch() & getche() in Linux?
static struct termios old, new;
tcsetattr(0, TCSANOW, &new); /* use these new terminal i/o settings now */
Could anyone explain how it is possible? Is it valid C++ code? Thanks.