@@ -4544,6 +4544,7 @@ class ConstraintSystem {
4544
4544
// / Generate constraints for the given solution target.
4545
4545
// /
4546
4546
// / \returns true if an error occurred, false otherwise.
4547
+ LLVM_NODISCARD
4547
4548
bool generateConstraints (SolutionApplicationTarget &target,
4548
4549
FreeTypeVariableBinding allowFreeTypeVariables);
4549
4550
@@ -4552,18 +4553,21 @@ class ConstraintSystem {
4552
4553
// / \param closure the closure expression
4553
4554
// /
4554
4555
// / \returns \c true if constraint generation failed, \c false otherwise
4556
+ LLVM_NODISCARD
4555
4557
bool generateConstraints (ClosureExpr *closure);
4556
4558
4557
4559
// / Generate constraints for the given (unchecked) expression.
4558
4560
// /
4559
4561
// / \returns a possibly-sanitized expression, or null if an error occurred.
4562
+ LLVM_NODISCARD
4560
4563
Expr *generateConstraints (Expr *E, DeclContext *dc,
4561
4564
bool isInputExpression = true );
4562
4565
4563
4566
// / Generate constraints for binding the given pattern to the
4564
4567
// / value of the given expression.
4565
4568
// /
4566
4569
// / \returns a possibly-sanitized initializer, or null if an error occurred.
4570
+ LLVM_NODISCARD
4567
4571
Type generateConstraints (Pattern *P, ConstraintLocatorBuilder locator,
4568
4572
bool bindPatternVarsOneWay,
4569
4573
PatternBindingDecl *patternBinding,
@@ -4573,6 +4577,7 @@ class ConstraintSystem {
4573
4577
// /
4574
4578
// / \returns true if there was an error in constraint generation, false
4575
4579
// / if generation succeeded.
4580
+ LLVM_NODISCARD
4576
4581
bool generateConstraints (StmtCondition condition, DeclContext *dc);
4577
4582
4578
4583
// / Generate constraints for a case statement.
@@ -4582,6 +4587,7 @@ class ConstraintSystem {
4582
4587
// /
4583
4588
// / \returns true if there was an error in constraint generation, false
4584
4589
// / if generation succeeded.
4590
+ LLVM_NODISCARD
4585
4591
bool generateConstraints (CaseStmt *caseStmt, DeclContext *dc,
4586
4592
Type subjectType, ConstraintLocator *locator);
4587
4593
@@ -4625,6 +4631,7 @@ class ConstraintSystem {
4625
4631
// / \param propertyType The type of the wrapped property.
4626
4632
// /
4627
4633
// / \returns true if there is an error.
4634
+ LLVM_NODISCARD
4628
4635
bool generateWrappedPropertyTypeConstraints (VarDecl *wrappedVar,
4629
4636
Type initializerType,
4630
4637
Type propertyType);
0 commit comments