Remove old flags.
RELNOTES:
Removed flags `--incompatible_checked_arithmetic`, `--incompatible_dict_literal_has_no_duplicates`, `--incompatible_disallow_keyword_only_args`, and ` --incompatible_comprehension_variables_do_not_leak`.
PiperOrigin-RevId: 185977740
diff --git a/src/main/java/com/google/devtools/build/lib/syntax/Eval.java b/src/main/java/com/google/devtools/build/lib/syntax/Eval.java
index 9a1ed7a..a13a9fc 100644
--- a/src/main/java/com/google/devtools/build/lib/syntax/Eval.java
+++ b/src/main/java/com/google/devtools/build/lib/syntax/Eval.java
@@ -94,13 +94,10 @@
}
}
+ // TODO(laurentlb): Could be moved to the Parser or the ValidationEnvironment?
FunctionSignature sig = node.getSignature().getSignature();
- if (env.getSemantics().incompatibleDisallowKeywordOnlyArgs()
- && sig.getShape().getMandatoryNamedOnly() > 0) {
- throw new EvalException(
- node.getLocation(),
- "Keyword-only argument is forbidden. You can temporarily disable this "
- + "error using the flag --incompatible_disallow_keyword_only_args=false");
+ if (sig.getShape().getMandatoryNamedOnly() > 0) {
+ throw new EvalException(node.getLocation(), "Keyword-only argument is forbidden.");
}
env.update(