1"""Input file for C++ api test""" 2 3def exercise_the_api(): 4 var1 = CcInfo # @unused 5 6exercise_the_api() 7 8def my_rule_impl(ctx): 9 _ignore = [ctx] # @unused 10 return [] 11 12# buildifier: disable=unsorted-dict-items 13cpp_related_rule = rule( 14 implementation = my_rule_impl, 15 doc = "This rule does C++-related things.", 16 attrs = { 17 "first": attr.label(mandatory = True, allow_single_file = True), 18 "second": attr.string_dict(mandatory = True), 19 "third": attr.output(mandatory = True), 20 "fourth": attr.bool(default = False, mandatory = False), 21 }, 22) 23