From 58ecec37747636b3483bbcba29a7f3e0e2372697 Mon Sep 17 00:00:00 2001 From: Brentley Jones Date: Wed, 9 Feb 2022 09:31:56 -0600 Subject: [PATCH] Improve documentation for select() (#14769) * Reference documentation that explains when to use Label rather than a label string. * Remove mention of constraint_settings as they can't be used as select keys. Closes #14458. PiperOrigin-RevId: 420129541 (cherry picked from commit 67a133b431ccece22b7dd9a72f0837cff77d4360) Co-authored-by: Fabian Meumertzheim --- .../google/devtools/build/lib/packages/StarlarkLibrary.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/google/devtools/build/lib/packages/StarlarkLibrary.java b/src/main/java/com/google/devtools/build/lib/packages/StarlarkLibrary.java index 6c9025e81923b9..10566e409bc76e 100644 --- a/src/main/java/com/google/devtools/build/lib/packages/StarlarkLibrary.java +++ b/src/main/java/com/google/devtools/build/lib/packages/StarlarkLibrary.java @@ -332,8 +332,9 @@ public Depset depset( doc = "A dict that maps configuration conditions to values. Each key is a " + "Label or a label string" - + " that identifies a config_setting, constraint_setting, or constraint_value" - + " instance."), + + " that identifies a config_setting or constraint_value instance. See the" + + " " + + "documentation on macros for when to use a Label instead of a string."), @Param( name = "no_match_error", defaultValue = "''",