[Constraint graph] Enable one-way constraints in function builders.

Enable one-way constraints by default for function builders, finishing
rdar://problem/50150793.
This commit is contained in:
Doug Gregor
2019-08-19 22:08:34 -07:00
parent e77b04012e
commit b4e80cfd90
9 changed files with 42 additions and 19 deletions

View File

@@ -441,8 +441,10 @@ static bool ParseLangArgs(LangOptions &Opts, ArgList &Args,
if (Args.getLastArg(OPT_solver_disable_shrink))
Opts.SolverDisableShrink = true;
if (Args.getLastArg(OPT_enable_function_builder_one_way_constraints))
Opts.FunctionBuilderOneWayConstraints = true;
Opts.FunctionBuilderOneWayConstraints =
Args.hasFlag(OPT_enable_function_builder_one_way_constraints,
OPT_disable_function_builder_one_way_constraints,
/*Default=*/true);
if (const Arg *A = Args.getLastArg(OPT_value_recursion_threshold)) {
unsigned threshold;