mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 22:02:55 +01:00
Implement checking observe declarations (#6709)
This adds SemIR structs and implements building `observe` lists, as well as naming, formatting, and importing `observe` declarations. --------- Co-authored-by: Dana Jansens <danakj@orodu.net>
This commit is contained in:
co-authored by
Dana Jansens
parent
918bb9364f
commit
08385adeb5
@@ -69,6 +69,8 @@ fn Main() {
|
||||
// CHECK:STDOUT: %.loc16_10: init %empty_tuple.type = tuple_init () [concrete = constants.%empty_tuple]
|
||||
// CHECK:STDOUT: %.loc16_11: init %empty_tuple.type = converted %a.ref, %.loc16_10 [concrete = constants.%empty_tuple]
|
||||
// CHECK:STDOUT: return %.loc16_11
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !observes:
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Main() {
|
||||
@@ -79,5 +81,7 @@ fn Main() {
|
||||
// CHECK:STDOUT: %.loc20_9.2: %empty_tuple.type = converted %.loc20_9.1, %empty_tuple [concrete = constants.%empty_tuple]
|
||||
// CHECK:STDOUT: %Echo.call: init %empty_tuple.type = call %Echo.ref(%.loc20_9.2)
|
||||
// CHECK:STDOUT: return
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !observes:
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
Reference in New Issue
Block a user