Change Namespace formatting to use the scope's name. (#3782)

This change only affects the generated IR, but I think it's cleaning up
an existing issue with namespace name printing.
This commit is contained in:
Jon Ross-Perkins
2024-03-14 21:12:26 +00:00
committed by GitHub
parent 28d76e6164
commit 295c8eb97f
24 changed files with 136 additions and 129 deletions
@@ -17,16 +17,16 @@ fn F() {
// CHECK:STDOUT:
// CHECK:STDOUT: file {
// CHECK:STDOUT: package: <namespace> = namespace [template] {
// CHECK:STDOUT: .A = %.loc7
// CHECK:STDOUT: .A = %A
// CHECK:STDOUT: .F = %F
// CHECK:STDOUT: }
// CHECK:STDOUT: %.loc7: <namespace> = namespace [template] {}
// CHECK:STDOUT: %A: <namespace> = namespace [template] {}
// CHECK:STDOUT: %F: <function> = fn_decl @F [template] {}
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: fn @F() {
// CHECK:STDOUT: !entry:
// CHECK:STDOUT: %A.ref: <namespace> = name_ref A, file.%.loc7 [template = file.%.loc7]
// CHECK:STDOUT: %A.ref: <namespace> = name_ref A, file.%A [template = file.%A]
// CHECK:STDOUT: %.loc13: ref <error> = deref <error>
// CHECK:STDOUT: return
// CHECK:STDOUT: }