import_cpp.h 748 B

12345678910111213141516171819202122232425
  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. #ifndef CARBON_TOOLCHAIN_SEM_IR_IMPORT_CPP_H_
  5. #define CARBON_TOOLCHAIN_SEM_IR_IMPORT_CPP_H_
  6. #include "common/raw_string_ostream.h"
  7. #include "toolchain/sem_ir/typed_insts.h"
  8. namespace Carbon::SemIR {
  9. // Per `import Cpp` data.
  10. struct ImportCpp : Printable<ImportCpp> {
  11. auto Print(llvm::raw_ostream& out) const -> void {
  12. out << "{node_id: " << node_id << ", library_id: " << library_id << "}";
  13. }
  14. Parse::ImportDeclId node_id;
  15. StringLiteralValueId library_id;
  16. };
  17. } // namespace Carbon::SemIR
  18. #endif // CARBON_TOOLCHAIN_SEM_IR_IMPORT_CPP_H_