summaryrefslogtreecommitdiffstats
path: root/source/slang/lower.cpp
diff options
context:
space:
mode:
authorYong He <yonghe@outlook.com>2017-11-04 18:07:09 -0400
committerYong He <yonghe@outlook.com>2017-11-04 18:07:09 -0400
commitd1009d1a5ac7463dc74169ed7c6e1e692b3541d7 (patch)
treeb21cd74ca6daabd655f5a2625c2698de16a92dd1 /source/slang/lower.cpp
parent1f9686ce87573efdd4ad56040deb2d424fe51929 (diff)
parent784bd914cface6e5837ef0da7aee0df2e16c4999 (diff)
merge with fixWarnings branch
Diffstat (limited to 'source/slang/lower.cpp')
-rw-r--r--source/slang/lower.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/source/slang/lower.cpp b/source/slang/lower.cpp
index 7f18659ae..d207aac72 100644
--- a/source/slang/lower.cpp
+++ b/source/slang/lower.cpp
@@ -424,7 +424,7 @@ static SourceLoc getPosition(LoweredExpr const& expr)
case LoweredExpr::Flavor::VaryingTuple: return expr.getVaryingTupleExpr()->loc;
default:
SLANG_UNREACHABLE("all cases handled");
- return SourceLoc();
+ UNREACHABLE_RETURN(SourceLoc());
}
}
@@ -907,7 +907,7 @@ struct LoweringVisitor
default:
SLANG_UNREACHABLE("all cases handled");
- return LoweredExpr();
+ UNREACHABLE_RETURN(LoweredExpr());
}
}
@@ -2241,11 +2241,11 @@ struct LoweringVisitor
Modifiers shallowCloneModifiers(Modifiers const& oldModifiers)
{
- RefPtr<SharedModifiers> shared = new SharedModifiers();
- shared->next = oldModifiers.first;
+ RefPtr<SharedModifiers> sharedModifiers = new SharedModifiers();
+ sharedModifiers->next = oldModifiers.first;
Modifiers newModifiers;
- newModifiers.first = shared;
+ newModifiers.first = sharedModifiers;
return newModifiers;
}
@@ -3840,7 +3840,7 @@ struct LoweringVisitor
substitutions->args.Add(elementType);
substitutions->args.Add(elementCount);
- auto declRef = DeclRef<Decl>(vectorTypeDecl.Ptr(), substitutions);
+ auto declRef = DeclRef<Decl>(vectorTypeDecl.Ptr(), substs);
return DeclRefType::Create(
session,