summaryrefslogtreecommitdiff
path: root/source/slang/slang-check-stmt.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'source/slang/slang-check-stmt.cpp')
-rw-r--r--source/slang/slang-check-stmt.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/source/slang/slang-check-stmt.cpp b/source/slang/slang-check-stmt.cpp
index 6efc3e52e..b2830febe 100644
--- a/source/slang/slang-check-stmt.cpp
+++ b/source/slang/slang-check-stmt.cpp
@@ -157,7 +157,7 @@ namespace Slang
}
Expr* e = expr;
e = CheckTerm(e);
- e = coerce(m_astBuilder->getBoolType(), e);
+ e = coerce(CoercionSite::General, m_astBuilder->getBoolType(), e);
return e;
}
@@ -313,7 +313,7 @@ namespace Slang
{
if (function)
{
- stmt->expression = coerce(function->returnType.Ptr(), stmt->expression);
+ stmt->expression = coerce(CoercionSite::Return, function->returnType.Ptr(), stmt->expression);
}
else
{