BUILD 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  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. load("@rules_cc//cc:defs.bzl", "cc_library")
  5. package(default_visibility = ["//executable_semantics:__subpackages__"])
  6. cc_library(
  7. name = "declaration",
  8. srcs = ["declaration.cpp"],
  9. hdrs = [
  10. "abstract_syntax_tree.h",
  11. "declaration.h",
  12. ],
  13. deps = [
  14. ":function_definition",
  15. ":member",
  16. ":struct_definition",
  17. "//executable_semantics/interpreter:containers",
  18. ],
  19. )
  20. cc_library(
  21. name = "expression",
  22. srcs = ["expression.cpp"],
  23. hdrs = ["expression.h"],
  24. deps = ["//common:indirect_value"],
  25. )
  26. cc_library(
  27. name = "function_definition",
  28. srcs = ["function_definition.cpp"],
  29. hdrs = ["function_definition.h"],
  30. deps = [
  31. ":expression",
  32. ":statement",
  33. ],
  34. )
  35. cc_library(
  36. name = "member",
  37. srcs = ["member.cpp"],
  38. hdrs = ["member.h"],
  39. deps = [":expression"],
  40. )
  41. cc_library(
  42. name = "statement",
  43. srcs = ["statement.cpp"],
  44. hdrs = ["statement.h"],
  45. deps = [
  46. ":expression",
  47. "//common:check",
  48. ],
  49. )
  50. cc_library(
  51. name = "struct_definition",
  52. hdrs = ["struct_definition.h"],
  53. deps = [":member"],
  54. )