summaryrefslogtreecommitdiffstats
path: root/source/slang/lower.cpp
diff options
context:
space:
mode:
authorTim Foley <tfoley@nvidia.com>2017-07-10 10:44:02 -0700
committerTim Foley <tfoley@nvidia.com>2017-07-10 10:44:02 -0700
commitb2fb0f7134de4e0b1a0db685eb1ae3c0678a33c5 (patch)
tree5597bca9d791391e069c8997a84ac9a8b1061024 /source/slang/lower.cpp
parent8abdf2dddd10feb9794c86cdf6b2159a2b6383e4 (diff)
Try to be more robust against un-checked types during lowering, etc.
- Try to handle `ErrorType` gracefully when computing type layouts - When outputting a `TypeExp`, if the type part is errorneous (or missing), try to use the expression part - Make sure to lower the expressions side of a `TypeExp` during lowering
Diffstat (limited to 'source/slang/lower.cpp')
-rw-r--r--source/slang/lower.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/source/slang/lower.cpp b/source/slang/lower.cpp
index 165812fae..9f117106b 100644
--- a/source/slang/lower.cpp
+++ b/source/slang/lower.cpp
@@ -445,6 +445,7 @@ struct LoweringVisitor
{
TypeExp result;
result.type = lowerType(typeExp.type);
+ result.exp = lowerExpr(typeExp.exp);
return result;
}