diff options
| author | jsmall-nvidia <jsmall@nvidia.com> | 2018-12-21 11:00:28 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-12-21 11:00:28 -0500 |
| commit | efa2c8f41aa5cd2c27990fd9b57ea0eff06976e7 (patch) | |
| tree | 4c1a4d8e6e71e81c42cfbf315610e380d75527bf /source/core/slang-test-tool-util.cpp | |
| parent | b5bda9b3d155234be079debe6997cbc900773cf2 (diff) | |
Feature/remove app context (#765)
* Remove AppContext. Use StdChannels to hold writers, and TestToolUtil to hold test tool specific functionality.
* StdChannels -> StdWriters
* getStdOut -> getOut, getStdError -> getError
Diffstat (limited to 'source/core/slang-test-tool-util.cpp')
| -rw-r--r-- | source/core/slang-test-tool-util.cpp | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/source/core/slang-test-tool-util.cpp b/source/core/slang-test-tool-util.cpp new file mode 100644 index 000000000..7ecfacefa --- /dev/null +++ b/source/core/slang-test-tool-util.cpp @@ -0,0 +1,21 @@ + +#include "slang-test-tool-util.h" + +namespace Slang +{ + +/* static */int TestToolUtil::getReturnCode(SlangResult res) +{ + if (SLANG_SUCCEEDED(res)) + { + return 0; + } + else if (res == SLANG_E_INTERNAL_FAIL) + { + return -1; + } + return 1; +} + +} + |
