Skip to content

Commit 650369b

Browse files
committed
---
yaml --- r: 3291 b: refs/heads/master c: 718ee98 h: refs/heads/master i: 3289: fafb1ea 3287: d408f14 v: v3
1 parent afbbaf8 commit 650369b

File tree

2 files changed

+11
-12
lines changed

2 files changed

+11
-12
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
---
2-
refs/heads/master: c34e9b33d9d9252ea343b08d4f4a70c59896e0e9
2+
refs/heads/master: 718ee98f43e7feecb38249a3519174054e3b7c79
Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,29 @@
11
use std;
22

33
fn main() {
4-
obj a() {
4+
obj normal() {
55
fn foo() -> int { ret 2; }
66
}
7-
auto my_a = a();
8-
// Extending an object with a new method
7+
auto my_normal_obj = normal();
98

10-
auto my_b = obj {
9+
// Extending an object with a new method
10+
auto my_anon_obj = obj {
1111
fn bar() -> int {
1212
ret 3;
1313
}
14-
with my_a
14+
with my_normal_obj
1515
};
1616

17-
assert (my_a.foo() == 2);
18-
assert (my_b.bar() == 3);
17+
assert (my_normal_obj.foo() == 2);
18+
assert (my_anon_obj.bar() == 3);
1919

20-
auto my_c = obj {
20+
auto another_anon_obj = obj {
2121
fn baz() -> int {
2222
ret 4;
2323
}
24-
with my_b
24+
with my_anon_obj
2525
};
2626

27-
assert (my_c.baz() == 4);
27+
assert (another_anon_obj.baz() == 4);
2828

2929
}
30-

0 commit comments

Comments
 (0)