================
Comment at: lib/AST/ASTDiagnostic.cpp:1131-1137
@@ +1130,9 @@
+    if (Iter.isEnd() && ArgExpr->isValueDependent()) {
+      TemplateArgument::ArgKind Kind = Iter.getDesugar().getKind();
+      if (Kind == TemplateArgument::Integral) {
+        Int = Iter.getDesugar().getAsIntegral();
+      } else if (Kind == TemplateArgument::Expression) {
+        ArgExpr = Iter.getDesugar().getAsExpr();
+        Int = ArgExpr->EvaluateKnownConstInt(Context);
+      } else {
+        llvm_unreachable("Unexpected template argument kind");
----------------
Why did you change from a switch statement to an if chain here?

http://reviews.llvm.org/D4226



_______________________________________________
cfe-commits mailing list
cfe-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to