195 lines
6.5 KiB
Plaintext
195 lines
6.5 KiB
Plaintext
Program {
|
|
ast: Block(
|
|
[
|
|
Statement(
|
|
Fn {
|
|
struct_name: None,
|
|
name: Ident(
|
|
"main",
|
|
),
|
|
params: [
|
|
(
|
|
Ident(
|
|
"argc",
|
|
),
|
|
Owned(
|
|
Ident(
|
|
"i32",
|
|
),
|
|
),
|
|
),
|
|
(
|
|
Ident(
|
|
"argv",
|
|
),
|
|
Ref {
|
|
inner: Array {
|
|
inner: Owned(
|
|
Ident(
|
|
"Str",
|
|
),
|
|
),
|
|
},
|
|
mutable: false,
|
|
},
|
|
),
|
|
],
|
|
ret_type: Some(
|
|
Owned(
|
|
Ident(
|
|
"i32",
|
|
),
|
|
),
|
|
),
|
|
qual_const: false,
|
|
qual_extern: None,
|
|
body: Some(
|
|
Block(
|
|
[
|
|
Expr(
|
|
Return(
|
|
Some(
|
|
Literal(
|
|
Number(
|
|
Number {
|
|
val: 0,
|
|
base: 10,
|
|
signed: false,
|
|
},
|
|
),
|
|
),
|
|
),
|
|
),
|
|
),
|
|
],
|
|
),
|
|
),
|
|
},
|
|
),
|
|
Statement(
|
|
Fn {
|
|
struct_name: Some(
|
|
Ident(
|
|
"Baz",
|
|
),
|
|
),
|
|
name: Ident(
|
|
"main",
|
|
),
|
|
params: [
|
|
(
|
|
Ident(
|
|
"self",
|
|
),
|
|
Ref {
|
|
inner: Owned(
|
|
Ident(
|
|
"Baz",
|
|
),
|
|
),
|
|
mutable: true,
|
|
},
|
|
),
|
|
(
|
|
Ident(
|
|
"a",
|
|
),
|
|
Ref {
|
|
inner: Owned(
|
|
Ident(
|
|
"Foo",
|
|
),
|
|
),
|
|
mutable: false,
|
|
},
|
|
),
|
|
(
|
|
Ident(
|
|
"b",
|
|
),
|
|
Ref {
|
|
inner: Owned(
|
|
Ident(
|
|
"Bar",
|
|
),
|
|
),
|
|
mutable: true,
|
|
},
|
|
),
|
|
],
|
|
ret_type: Some(
|
|
Ref {
|
|
inner: Owned(
|
|
Ident(
|
|
"Nya",
|
|
),
|
|
),
|
|
mutable: false,
|
|
},
|
|
),
|
|
qual_const: false,
|
|
qual_extern: None,
|
|
body: None,
|
|
},
|
|
),
|
|
Statement(
|
|
Fn {
|
|
struct_name: Some(
|
|
Ident(
|
|
"Baz",
|
|
),
|
|
),
|
|
name: Ident(
|
|
"main",
|
|
),
|
|
params: [
|
|
(
|
|
Ident(
|
|
"a",
|
|
),
|
|
Ref {
|
|
inner: Owned(
|
|
Ident(
|
|
"Foo",
|
|
),
|
|
),
|
|
mutable: false,
|
|
},
|
|
),
|
|
(
|
|
Ident(
|
|
"b",
|
|
),
|
|
Ref {
|
|
inner: Owned(
|
|
Ident(
|
|
"Bar",
|
|
),
|
|
),
|
|
mutable: true,
|
|
},
|
|
),
|
|
],
|
|
ret_type: Some(
|
|
Ref {
|
|
inner: Owned(
|
|
Ident(
|
|
"Nya",
|
|
),
|
|
),
|
|
mutable: false,
|
|
},
|
|
),
|
|
qual_const: false,
|
|
qual_extern: None,
|
|
body: None,
|
|
},
|
|
),
|
|
],
|
|
),
|
|
structs: {},
|
|
enums: {},
|
|
types: {},
|
|
functions: {},
|
|
member_functions: {},
|
|
} |