Marcel Hlopko | b10e49b | 2022-05-09 03:57:32 -0700 | [diff] [blame] | 1 | // Part of the Crubit 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 | |
| 5 | #ifndef THIRD_PARTY_CRUBIT_RS_BINDINGS_FROM_CC_COLLECT_INSTANTIATIONS_H_ |
| 6 | #define THIRD_PARTY_CRUBIT_RS_BINDINGS_FROM_CC_COLLECT_INSTANTIATIONS_H_ |
| 7 | |
| 8 | #include <string> |
| 9 | |
| 10 | #include "absl/status/statusor.h" |
| 11 | #include "absl/types/span.h" |
| 12 | |
| 13 | namespace crubit { |
| 14 | |
| 15 | // Parses Rust source files given their filenames and returns a vector with all |
| 16 | // C++ class template instantiations requested by calls to the `cc_template!` |
| 17 | // macro. |
| 18 | absl::StatusOr<std::vector<std::string>> CollectInstantiations( |
| 19 | absl::Span<const std::string> rust_sources); |
| 20 | |
| 21 | } // namespace crubit |
| 22 | |
| 23 | #endif // THIRD_PARTY_CRUBIT_RS_BINDINGS_FROM_CC_COLLECT_INSTANTIATIONS_H_ |