We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b82d661 commit 00f9faaCopy full SHA for 00f9faa
src/cppsafeio.cpp
@@ -5,15 +5,17 @@
5
#include <stdexcept>
6
#include <limits>
7
8
+
9
#if defined _WIN32
- #include <conio.h>
10
+ //#include <conio.h> //uncomment if your compiler supports conio.h
11
#endif
12
13
void CppSafeIO::clearConsole()
14
{
15
16
- clrscr();
17
+ system("cls");
18
+ //clrsrc(); //uncomment if your compiler supports conio.h, and comment out the previous statement
19
20
#elif defined (__LINUX__) || defined(__gnu_linux__) || defined(__linux__)
21
@@ -24,7 +26,7 @@ void CppSafeIO::clearConsole()
24
26
25
27
std::cout << "\x1b[2J\x1b[H";
28
- #elif defined (__APPLE__)
29
+ #elif defined (__APPLE__)
30
31
system("clear");
32
0 commit comments