We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 792259a commit d5b30eeCopy full SHA for d5b30ee
lib/AST/ASTVerifier.cpp
@@ -836,6 +836,19 @@ struct ASTNodeBase {};
836
verifyCheckedBase(S);
837
}
838
839
+ void verifyChecked(TupleExpr *E) {
840
+ const TupleType *exprTy = E->getType()->castTo<TupleType>();
841
+ for_each(exprTy->getElements().begin(), exprTy->getElements().end(),
842
+ E->getElements().begin(),
843
+ [this](const TupleTypeElt &field, const Expr *elt) {
844
+ checkTrivialSubtype(field.getType()->getUnlabeledType(Ctx),
845
+ elt->getType()->getUnlabeledType(Ctx),
846
+ "tuple and element");
847
+ });
848
+ // FIXME: Check all the variadic elements.
849
+ verifyCheckedBase(E);
850
+ }
851
+
852
void verifyChecked(InOutExpr *E) {
853
Type srcObj = checkLValue(E->getSubExpr()->getType(),
854
"result of InOutExpr");
0 commit comments