declaration.carbon 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  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. interface I {}
  7. impl i32 as I;
  8. // CHECK:STDOUT: --- declaration.carbon
  9. // CHECK:STDOUT:
  10. // CHECK:STDOUT: constants {
  11. // CHECK:STDOUT: %.1: type = interface_type @I [template]
  12. // CHECK:STDOUT: }
  13. // CHECK:STDOUT:
  14. // CHECK:STDOUT: file {
  15. // CHECK:STDOUT: package: <namespace> = namespace [template] {
  16. // CHECK:STDOUT: .I = %I.decl
  17. // CHECK:STDOUT: }
  18. // CHECK:STDOUT: %I.decl: type = interface_decl @I [template = constants.%.1] {}
  19. // CHECK:STDOUT: impl_decl @impl {
  20. // CHECK:STDOUT: %I.ref: type = name_ref I, %I.decl [template = constants.%.1]
  21. // CHECK:STDOUT: }
  22. // CHECK:STDOUT: }
  23. // CHECK:STDOUT:
  24. // CHECK:STDOUT: interface @I {
  25. // CHECK:STDOUT: %Self: I = bind_symbolic_name Self [symbolic]
  26. // CHECK:STDOUT:
  27. // CHECK:STDOUT: !members:
  28. // CHECK:STDOUT: .Self = %Self
  29. // CHECK:STDOUT: witness = ()
  30. // CHECK:STDOUT: }
  31. // CHECK:STDOUT:
  32. // CHECK:STDOUT: impl @impl: i32 as I;
  33. // CHECK:STDOUT: