BUILD 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134
  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 = "action",
  8. srcs = ["action.cpp"],
  9. hdrs = ["action.h"],
  10. deps = [
  11. ":containers",
  12. ":value",
  13. "//common:ostream",
  14. "//executable_semantics/ast:expression",
  15. "//executable_semantics/ast:function_definition",
  16. "//executable_semantics/ast:statement",
  17. "@llvm-project//llvm:Support",
  18. ],
  19. )
  20. cc_library(
  21. name = "address",
  22. hdrs = ["address.h"],
  23. deps = [
  24. ":field_path",
  25. "//common:ostream",
  26. "@llvm-project//llvm:Support",
  27. ],
  28. )
  29. cc_library(
  30. name = "containers",
  31. srcs = [
  32. "list_node.h",
  33. ],
  34. hdrs = [
  35. "dictionary.h",
  36. "stack.h",
  37. ],
  38. deps = ["//common:check"],
  39. )
  40. cc_library(
  41. name = "field_path",
  42. hdrs = ["field_path.h"],
  43. deps = [
  44. "//common:ostream",
  45. "@llvm-project//llvm:Support",
  46. ],
  47. )
  48. cc_library(
  49. name = "frame",
  50. srcs = ["frame.cpp"],
  51. hdrs = ["frame.h"],
  52. deps = [
  53. ":action",
  54. ":address",
  55. ":containers",
  56. "//common:ostream",
  57. "@llvm-project//llvm:Support",
  58. ],
  59. )
  60. cc_library(
  61. name = "heap",
  62. srcs = ["heap.cpp"],
  63. hdrs = ["heap.h"],
  64. deps = [
  65. ":address",
  66. ":value",
  67. "//common:ostream",
  68. "@llvm-project//llvm:Support",
  69. ],
  70. )
  71. cc_library(
  72. name = "interpreter",
  73. srcs = [
  74. "interpreter.cpp",
  75. ],
  76. hdrs = [
  77. "interpreter.h",
  78. ],
  79. deps = [
  80. ":action",
  81. ":address",
  82. ":containers",
  83. ":frame",
  84. ":heap",
  85. ":value",
  86. "//common:check",
  87. "//common:ostream",
  88. "//executable_semantics/ast:declaration",
  89. "//executable_semantics/ast:expression",
  90. "//executable_semantics/ast:function_definition",
  91. "//executable_semantics/common:tracing_flag",
  92. "@llvm-project//llvm:Support",
  93. ],
  94. )
  95. cc_library(
  96. name = "typecheck",
  97. srcs = ["typecheck.cpp"],
  98. hdrs = ["typecheck.h"],
  99. deps = [
  100. ":containers",
  101. ":interpreter",
  102. "//common:ostream",
  103. "//executable_semantics/ast:expression",
  104. "//executable_semantics/ast:function_definition",
  105. "//executable_semantics/ast:statement",
  106. "//executable_semantics/common:tracing_flag",
  107. "@llvm-project//llvm:Support",
  108. ],
  109. )
  110. cc_library(
  111. name = "value",
  112. srcs = ["value.cpp"],
  113. hdrs = ["value.h"],
  114. deps = [
  115. ":address",
  116. ":containers",
  117. ":field_path",
  118. "//common:ostream",
  119. "//executable_semantics/ast:function_definition",
  120. "//executable_semantics/ast:statement",
  121. "@llvm-project//llvm:Support",
  122. ],
  123. )