aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--c/main.cpp4
-rw-r--r--c/pl.h2
2 files changed, 3 insertions, 3 deletions
diff --git a/c/main.cpp b/c/main.cpp
index 7937b50..6865e4c 100644
--- a/c/main.cpp
+++ b/c/main.cpp
@@ -69,9 +69,9 @@ void OnTerminate() noexcept
TerminateMsg<TCHAR>(TEXT("a Prolog exception"), tsz);
else
TerminateMsg<char>("a Prolog exception", NULL);
- } catch (Win32Error& e) {
+ } catch (const Win32Error& e) {
TerminateMsg<TCHAR>(TEXT("a Windows error"), e.what<TCHAR>());
- } catch (std::exception& e) {
+ } catch (const std::exception& e) {
TerminateMsg<char>("an exception", e.what());
} catch (...) {
TerminateMsg<char>("an exception", NULL);
diff --git a/c/pl.h b/c/pl.h
index 44b8a5e..d1c01c4 100644
--- a/c/pl.h
+++ b/c/pl.h
@@ -111,7 +111,7 @@ int Pl(const char* const szMod, const char* const szPred, T... xs)
{
try {
return Plx(szMod, szPred, xs...);
- } catch (term_t& t) {
+ } catch (const term_t& t) {
return 0;
}
}