################################################################################
# Protocol Buffers Compiler - Generation of accessors for individual fields.
################################################################################

load("@rules_cc//cc:defs.bzl", "cc_library")
load("//build_defs:cpp_opts.bzl", "COPTS")

cc_library(
    name = "accessors",
    srcs = [
        "accessor_case.cc",
        "accessors.cc",
        "default_value.cc",
        "map.cc",
        "repeated_field.cc",
        "singular_message.cc",
        "singular_scalar.cc",
        "singular_string.cc",
        "unsupported_field.cc",
    ],
    hdrs = [
        "accessor_case.h",
        "accessors.h",
        "default_value.h",
        "generator.h",
    ],
    copts = COPTS,
    strip_include_prefix = "/src",
    visibility = [
        "//pkg:__pkg__",
        "//src/google/protobuf/compiler:__subpackages__",
    ],
    deps = [
        "//src/google/protobuf",
        "//src/google/protobuf/compiler/cpp:names_internal",
        "//src/google/protobuf/compiler/rust:context",
        "//src/google/protobuf/compiler/rust:naming",
        "//src/google/protobuf/compiler/rust:rust_field_type",
        "//src/google/protobuf/io:tokenizer",
        "@com_google_absl//absl/log:absl_check",
        "@com_google_absl//absl/log:absl_log",
        "@com_google_absl//absl/strings",
        "@com_google_absl//absl/strings:str_format",
    ],
)
