mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 22:02:55 +01:00
turn off tracing by default, change golden (#381)
* turn off tracing by default, change golden * Update executable_semantics/main.cpp Co-authored-by: Jon Meow <46229924+jonmeow@users.noreply.github.com> * Update executable_semantics/main.cpp Co-authored-by: Jon Meow <46229924+jonmeow@users.noreply.github.com> * merge with trunk, update goldens Co-authored-by: Jon Meow <46229924+jonmeow@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
co-authored by
Jon Meow
parent
ced98ef021
commit
7c4fcd3fa5
-71
@@ -1,72 +1 @@
|
||||
********** source program **********
|
||||
fn main () -> Int {
|
||||
return 0;
|
||||
|
||||
}
|
||||
********** type checking **********
|
||||
--- step exp Int --->
|
||||
--- step exp Int --->
|
||||
|
||||
********** type checking complete **********
|
||||
fn main () -> Int {
|
||||
return 0;
|
||||
}
|
||||
********** starting execution **********
|
||||
********** initializing globals **********
|
||||
--- step exp () --->
|
||||
********** calling main function **********
|
||||
{
|
||||
stack: top{main()<-1>}
|
||||
heap: fun<main>,
|
||||
env: main: fun<main>,
|
||||
}
|
||||
--- step exp main() --->
|
||||
{
|
||||
stack: top{main<-1> :: main()<0>}
|
||||
heap: fun<main>,
|
||||
env: main: fun<main>,
|
||||
}
|
||||
--- step exp main --->
|
||||
{
|
||||
stack: top{fun<main><-1> :: main()<0>}
|
||||
heap: fun<main>,
|
||||
env: main: fun<main>,
|
||||
}
|
||||
--- handle value fun<main> with main()<1>(fun<main>,) --->
|
||||
{
|
||||
stack: top{()<-1> :: main()<1>(fun<main>,)}
|
||||
heap: fun<main>,
|
||||
env: main: fun<main>,
|
||||
}
|
||||
--- step exp () --->
|
||||
{
|
||||
stack: top{()<-1> :: main()<1>(fun<main>,)}
|
||||
heap: fun<main>,
|
||||
env: main: fun<main>,
|
||||
}
|
||||
--- handle value () with main()<2>(fun<main>,(),) --->
|
||||
pattern_match((), ())
|
||||
{
|
||||
stack: main{return 0;<-1>} :: top{}
|
||||
heap: fun<main>,
|
||||
env: main: fun<main>,
|
||||
}
|
||||
--- step stmt return 0; --->
|
||||
{
|
||||
stack: main{0<-1> :: return 0;<0>} :: top{}
|
||||
heap: fun<main>,
|
||||
env: main: fun<main>,
|
||||
}
|
||||
--- step exp 0 --->
|
||||
{
|
||||
stack: main{0<-1> :: return 0;<0>} :: top{}
|
||||
heap: fun<main>,
|
||||
env: main: fun<main>,
|
||||
}
|
||||
--- handle value 0 with return 0;<1>(0,) --->
|
||||
{
|
||||
stack: top{0<-1>}
|
||||
heap: fun<main>,
|
||||
env: main: fun<main>,
|
||||
}
|
||||
result: 0
|
||||
|
||||
Reference in New Issue
Block a user