1"""Input file to test <angle bracket bugs> 2 3See https://github.com/bazelbuild/skydoc/issues/186 4and https://github.com/bazelbuild/stardoc/issues/132""" 5 6def bracket_function(param = "<default>"): 7 """Dummy docstring with <brackets>. 8 9 This rule runs checks on <angle brackets>. 10 11 Args: 12 param: an arg with **formatted** docstring, <default> by default. 13 14 Returns: 15 some <angled> brackets 16 17 Deprecated: 18 deprecated for <reasons> 19 """ 20 return param 21 22# buildifier: disable=unsorted-dict-items 23bracketuse = provider( 24 doc = "Information with <brackets>", 25 fields = { 26 "foo": "A string representing <foo>", 27 "bar": "A string representing bar", 28 "baz": "A string representing baz", 29 }, 30) 31 32def _rule_impl(ctx): 33 _ignore = [ctx] # @unused 34 return [] 35 36my_anglebrac = rule( 37 implementation = _rule_impl, 38 doc = "Rule with <brackets>", 39 attrs = { 40 "useless": attr.string( 41 doc = "Args with some tags: <tag1>, <tag2>", 42 default = "Find <brackets>", 43 ), 44 }, 45) 46 47def _bracket_aspect_impl(ctx): 48 _ignore = [ctx] # @unused 49 return [] 50 51bracket_aspect = aspect( 52 implementation = _bracket_aspect_impl, 53 doc = "Aspect with <brackets>", 54 attr_aspects = ["deps"], 55 attrs = { 56 "brackets": attr.string( 57 doc = "Attribute with <brackets>", 58 default = "<default>", 59 ), 60 }, 61) 62