diff options
author | 2015-04-20 13:11:40 +0000 | |
---|---|---|
committer | 2015-04-20 16:40:58 +0000 | |
commit | d95efa3138b888663ba677aea38c5640393f0f68 (patch) | |
tree | f8494a0fc458f251cbe70efd361a5b43741071fa /src/main/java/com/google | |
parent | 3bc3d5a69bb991a76d085bf8db9f7117ba58b464 (diff) |
Skylark documentation: Add missing links
--
MOS_MIGRATED_REVID=91578316
Diffstat (limited to 'src/main/java/com/google')
4 files changed, 16 insertions, 14 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/rules/SkylarkAttr.java b/src/main/java/com/google/devtools/build/lib/rules/SkylarkAttr.java index 93ba241a3a..549e0252af 100644 --- a/src/main/java/com/google/devtools/build/lib/rules/SkylarkAttr.java +++ b/src/main/java/com/google/devtools/build/lib/rules/SkylarkAttr.java @@ -241,8 +241,8 @@ public final class SkylarkAttr { }; @SkylarkBuiltin(name = "label_list", doc = - "Creates an attribute of type list of labels. " - + "See <code>label</code> for more information.", + "Creates an attribute of type list of labels. " + + "See <a href=\"#modules.attr.label\">label</a> for more information.", objectType = SkylarkAttr.class, returnType = Attribute.class, optionalParams = { @@ -285,7 +285,7 @@ public final class SkylarkAttr { }; @SkylarkBuiltin(name = "output", doc = - "Creates an attribute of type output. Its default value is None. " + "Creates an attribute of type output. Its default value is None. " + "The user provides a file name (string) and the rule must create an action that " + "generates the file.", objectType = SkylarkAttr.class, @@ -304,8 +304,8 @@ public final class SkylarkAttr { }; @SkylarkBuiltin(name = "output_list", doc = - "Creates an attribute of type list of outputs. Its default value is []. " - + "See <code>output</code> above for more information.", + "Creates an attribute of type list of outputs. Its default value is <code>[]</code>. " + + "See <a href=\"#modules.attr.output\">output</a> above for more information.", objectType = SkylarkAttr.class, returnType = Attribute.class, optionalParams = { diff --git a/src/main/java/com/google/devtools/build/lib/rules/SkylarkRuleClassFunctions.java b/src/main/java/com/google/devtools/build/lib/rules/SkylarkRuleClassFunctions.java index 9f5b6be371..68e9cfe53d 100644 --- a/src/main/java/com/google/devtools/build/lib/rules/SkylarkRuleClassFunctions.java +++ b/src/main/java/com/google/devtools/build/lib/rules/SkylarkRuleClassFunctions.java @@ -194,8 +194,9 @@ public class SkylarkRuleClassFunctions { + "If True, the rule must end with <code>_test</code> (otherwise it cannot)."), @Param(name = "attrs", type = Map.class, doc = "dictionary to declare all the attributes of the rule. It maps from an attribute name " - + "to an attribute object (see 'attr' module). Attributes starting with <code>_</code> " - + "are private, and can be used to add an implicit dependency on a label."), + + "to an attribute object (see <a href=\"#modules.attr\">attr</a> module). " + + "Attributes starting with <code>_</code> are private, and can be used to add " + + "an implicit dependency on a label."), @Param(name = "outputs", doc = "outputs of this rule. " + "It is a dictionary mapping from string to a template name. " + "For example: <code>{\"ext\": \"${name}.ext\"}</code>. <br>" diff --git a/src/main/java/com/google/devtools/build/lib/rules/SkylarkRuleContext.java b/src/main/java/com/google/devtools/build/lib/rules/SkylarkRuleContext.java index 28eaf79401..5b7c51b655 100644 --- a/src/main/java/com/google/devtools/build/lib/rules/SkylarkRuleContext.java +++ b/src/main/java/com/google/devtools/build/lib/rules/SkylarkRuleContext.java @@ -359,22 +359,22 @@ public final class SkylarkRuleContext { } @SkylarkCallable(name = "configuration", structField = true, - doc = "Returns the default configuration. See the <code>configuration</code> type for " - + "more details.") + doc = "Returns the default configuration. See the <a href=\"#modules.configuration\">" + + "configuration</a> type for more details.") public BuildConfiguration getConfiguration() { return ruleContext.getConfiguration(); } @SkylarkCallable(name = "host_configuration", structField = true, - doc = "Returns the host configuration. See the <code>configuration</code> type for " - + "more details.") + doc = "Returns the host configuration. See the <a href=\"#modules.configuration\">" + + "configuration</a> type for more details.") public BuildConfiguration getHostConfiguration() { return ruleContext.getHostConfiguration(); } @SkylarkCallable(name = "data_configuration", structField = true, - doc = "Returns the data configuration. See the <code>configuration</code> type for " - + "more details.") + doc = "Returns the data configuration. See the <a href=\"#modules.configuration\">" + + "configuration</a> type for more details.") public BuildConfiguration getDataConfiguration() { return ruleContext.getConfiguration().getConfiguration(ConfigurationTransition.DATA); } diff --git a/src/main/java/com/google/devtools/build/lib/syntax/ClassObject.java b/src/main/java/com/google/devtools/build/lib/syntax/ClassObject.java index 1c3b3e29b8..9ed20cc68a 100644 --- a/src/main/java/com/google/devtools/build/lib/syntax/ClassObject.java +++ b/src/main/java/com/google/devtools/build/lib/syntax/ClassObject.java @@ -57,7 +57,8 @@ public interface ClassObject { @Immutable @SkylarkModule(name = "struct", doc = "A special language element to support structs (i.e. simple value objects). " - + "See the global <code>struct</code> method for more details.") + + "See the global <a href=\"#modules._top_level.struct\">struct</a> function " + + "for more details.") public class SkylarkClassObject implements ClassObject { private final ImmutableMap<String, Object> values; |