BUILD 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. # Part of the Carbon Language project, under the Apache License v2.0 with LLVM
  2. # Exceptions. See /LICENSE for license information.
  3. # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  4. package(default_visibility = ["//explorer:__subpackages__"])
  5. cc_library(
  6. name = "arena",
  7. hdrs = ["arena.h"],
  8. deps = [
  9. ":nonnull",
  10. ],
  11. )
  12. cc_library(
  13. name = "error_builders",
  14. hdrs = ["error_builders.h"],
  15. deps = [
  16. ":source_location",
  17. "//common:error",
  18. ],
  19. )
  20. cc_test(
  21. name = "error_builders_test",
  22. srcs = ["error_builders_test.cpp"],
  23. deps = [
  24. ":error_builders",
  25. ":source_location",
  26. "//testing/util:gtest_main",
  27. "//testing/util:test_raw_ostream",
  28. "@com_google_googletest//:gtest",
  29. ],
  30. )
  31. cc_library(
  32. name = "nonnull",
  33. hdrs = ["nonnull.h"],
  34. deps = [
  35. "//common:check",
  36. ],
  37. )
  38. cc_library(
  39. name = "source_location",
  40. hdrs = ["source_location.h"],
  41. deps = [
  42. ":nonnull",
  43. "//common:ostream",
  44. ],
  45. )
  46. cc_library(
  47. name = "trace_stream",
  48. hdrs = ["trace_stream.h"],
  49. deps = [
  50. ":source_location",
  51. "//common:check",
  52. "//common:ostream",
  53. "//explorer/common:nonnull",
  54. "@llvm-project//llvm:Support",
  55. ],
  56. )
  57. cc_test(
  58. name = "set_program_phase_raii_test",
  59. srcs = ["set_program_phase_raii_test.cpp"],
  60. deps = [
  61. ":trace_stream",
  62. "//testing/util:gtest_main",
  63. "@com_google_googletest//:gtest",
  64. ],
  65. )
  66. cc_test(
  67. name = "set_file_context_raii_test",
  68. srcs = ["set_file_context_raii_test.cpp"],
  69. deps = [
  70. ":source_location",
  71. ":trace_stream",
  72. "//testing/util:gtest_main",
  73. "@com_google_googletest//:gtest",
  74. ],
  75. )