import_forward_decl.carbon 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  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. //
  5. // AUTOUPDATE
  6. // --- a.carbon
  7. library "a" api;
  8. class ForwardDecl;
  9. // --- a.impl.carbon
  10. library "a" impl;
  11. class ForwardDecl {
  12. }
  13. // CHECK:STDOUT: --- a.carbon
  14. // CHECK:STDOUT:
  15. // CHECK:STDOUT: constants {
  16. // CHECK:STDOUT: %ForwardDecl: type = class_type @ForwardDecl [template]
  17. // CHECK:STDOUT: }
  18. // CHECK:STDOUT:
  19. // CHECK:STDOUT: file {
  20. // CHECK:STDOUT: package: <namespace> = namespace [template] {
  21. // CHECK:STDOUT: .Core = %Core
  22. // CHECK:STDOUT: .ForwardDecl = %ForwardDecl.decl
  23. // CHECK:STDOUT: }
  24. // CHECK:STDOUT: %Core: <namespace> = namespace [template] {}
  25. // CHECK:STDOUT: %ForwardDecl.decl: type = class_decl @ForwardDecl [template = constants.%ForwardDecl] {}
  26. // CHECK:STDOUT: }
  27. // CHECK:STDOUT:
  28. // CHECK:STDOUT: class @ForwardDecl;
  29. // CHECK:STDOUT:
  30. // CHECK:STDOUT: --- a.impl.carbon
  31. // CHECK:STDOUT:
  32. // CHECK:STDOUT: constants {
  33. // CHECK:STDOUT: %ForwardDecl: type = class_type @ForwardDecl [template]
  34. // CHECK:STDOUT: %.1: type = struct_type {} [template]
  35. // CHECK:STDOUT: }
  36. // CHECK:STDOUT:
  37. // CHECK:STDOUT: file {
  38. // CHECK:STDOUT: package: <namespace> = namespace [template] {
  39. // CHECK:STDOUT: .Core = %Core
  40. // CHECK:STDOUT: .ForwardDecl = %ForwardDecl.decl
  41. // CHECK:STDOUT: }
  42. // CHECK:STDOUT: %import_ref: type = import_ref ir0, inst+2, loaded [template = constants.%ForwardDecl]
  43. // CHECK:STDOUT: %Core: <namespace> = namespace [template] {}
  44. // CHECK:STDOUT: %ForwardDecl.decl: type = class_decl @ForwardDecl [template = constants.%ForwardDecl] {}
  45. // CHECK:STDOUT: }
  46. // CHECK:STDOUT:
  47. // CHECK:STDOUT: class @ForwardDecl {
  48. // CHECK:STDOUT: !members:
  49. // CHECK:STDOUT: .Self = constants.%ForwardDecl
  50. // CHECK:STDOUT: }
  51. // CHECK:STDOUT: