Skip to content

Commit f5efdd5

Browse files
committed
---
yaml --- r: 3402 b: refs/heads/master c: 9561def h: refs/heads/master v: v3
1 parent 8a05972 commit f5efdd5

File tree

5 files changed

+9
-9
lines changed

5 files changed

+9
-9
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: fb14afd5eb8ab19f08e37e295fb207f0a1bb8e23
2+
refs/heads/master: 9561def20974acb302034c21b6de221972918d27

trunk/src/comp/front/parser.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ fn bad_expr_word_table() -> hashmap[str, ()] {
139139
words.insert("be", ());
140140
words.insert("fail", ());
141141
words.insert("type", ());
142-
words.insert("res", ());
142+
words.insert("resource", ());
143143
words.insert("check", ());
144144
words.insert("assert", ());
145145
words.insert("claim", ());
@@ -2045,7 +2045,7 @@ fn parse_item(&parser p, vec[ast::attribute] attrs) -> parsed_item {
20452045
ret got_item(parse_item_tag(p, attrs));
20462046
} else if (eat_word(p, "obj")) {
20472047
ret got_item(parse_item_obj(p, lyr, attrs));
2048-
} else if (eat_word(p, "res")) {
2048+
} else if (eat_word(p, "resource")) {
20492049
ret got_item(parse_item_res(p, lyr, attrs));
20502050
} else { ret no_item; }
20512051
}

trunk/src/test/compile-fail/copy-a-resource.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// error-pattern:Copying a non-copyable type
22

3-
res foo(int i) {}
3+
resource foo(int i) {}
44

55
fn main() {
66
auto x <- foo(10);

trunk/src/test/run-pass/expr-alt-box.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@
55

66
// Tests for alt as expressions resulting in boxed types
77
fn test_box() {
8-
auto rs = alt (true) { case (true) { @100 } };
9-
assert (*rs == 100);
8+
auto res = alt (true) { case (true) { @100 } };
9+
assert (*res == 100);
1010
}
1111

1212
fn test_str() {
13-
auto rs = alt (true) { case (true) { "happy" } };
14-
assert (rs == "happy");
13+
auto res = alt (true) { case (true) { "happy" } };
14+
assert (res == "happy");
1515
}
1616

1717
fn main() { test_box(); test_str(); }

trunk/src/test/run-pass/resource-destruct.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
res shrinky_pointer(@mutable int i) {
1+
resource shrinky_pointer(@mutable int i) {
22
*i -= 1;
33
}
44

0 commit comments

Comments
 (0)