Read-only mirrors. Development, issues and pull requests are on GitHub.

summaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authorMartin Hořeňovský2017-08-22 22:06:37 +0200
committerMartin Hořeňovský2017-08-22 22:06:37 +0200
commitc03e8fce92de2d04843a38f589eaceffc293e257 (patch)
tree662f33086bb4c45747b03b5ce312ccd73e359b94 /include
parent27640a5a968a0981eeab5f354aa52459641b2e91 (diff)
downloadcatch3-c03e8fce92de2d04843a38f589eaceffc293e257.tar.gz
Explicitly ignore return value of getchar
This silences MSVC warning about ignored return value
Diffstat (limited to 'include')
-rw-r--r--include/catch_session.hpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/catch_session.hpp b/include/catch_session.hpp
index ec3ce7cc..b183d73d 100644
--- a/include/catch_session.hpp
+++ b/include/catch_session.hpp
@@ -208,12 +208,12 @@ namespace Catch {
int run() {
if( ( m_configData.waitForKeypress & WaitForKeypress::BeforeStart ) != 0 ) {
Catch::cout() << "...waiting for enter/ return before starting" << std::endl;
- std::getchar();
+ static_cast<void>(std::getchar());
}
int exitCode = runInternal();
if( ( m_configData.waitForKeypress & WaitForKeypress::BeforeExit ) != 0 ) {
Catch::cout() << "...waiting for enter/ return before exiting, with code: " << exitCode << std::endl;
- std::getchar();
+ static_cast<void>(std::getchar());
}
return exitCode;
}