Skip to content

Commit a689e30

Browse files
committed
---
yaml --- r: 80691 b: refs/heads/try c: b9a8b37 h: refs/heads/master i: 80689: 56f781a 80687: 4df5489 v: v3
1 parent 135970e commit a689e30

File tree

3 files changed

+17
-10
lines changed

3 files changed

+17
-10
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
refs/heads/master: 4c6bf4872012c010f84dc7fa2cdfe87522533f89
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: cbd1eefbd350797b783df119fed7956d7e1c74ad
5-
refs/heads/try: cbe79bbbd3062973add9306e958af4d87de98065
5+
refs/heads/try: b9a8b3700b6f3b49a9b31af1e55caaa147f069e9
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
88
refs/heads/try2: 147ecfdd8221e4a4d4e090486829a06da1e0ca3c

branches/try/src/librust/rust.rs

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -60,14 +60,20 @@ struct Command<'self> {
6060
usage_full: UsageSource<'self>,
6161
}
6262

63-
static COMMANDS: &'static [Command<'static>] = &'static [
64-
Command {
63+
static NUM_OF_COMMANDS: uint = 7;
64+
65+
// FIXME(#7617): should just be &'static [Command<'static>]
66+
// but mac os doesn't seem to like that and tries to loop
67+
// past the end of COMMANDS in usage thus passing garbage
68+
// to str::repeat and eventually malloc and crashing.
69+
static COMMANDS: [Command<'static>, .. NUM_OF_COMMANDS] = [
70+
Command{
6571
cmd: "build",
6672
action: CallMain("rustc", rustc::main_args),
6773
usage_line: "compile rust source files",
6874
usage_full: UsgCall(rustc_help),
6975
},
70-
Command {
76+
Command{
7177
cmd: "run",
7278
action: Call(cmd_run),
7379
usage_line: "build an executable, and run it",
@@ -77,7 +83,7 @@ static COMMANDS: &'static [Command<'static>] = &'static [
7783
\n\nUsage:\trust run <filename> [<arguments>...]"
7884
)
7985
},
80-
Command {
86+
Command{
8187
cmd: "test",
8288
action: Call(cmd_test),
8389
usage_line: "build a test executable, and run it",
@@ -87,25 +93,25 @@ static COMMANDS: &'static [Command<'static>] = &'static [
8793
./<filestem>test~\"\n\nUsage:\trust test <filename>"
8894
)
8995
},
90-
Command {
96+
Command{
9197
cmd: "doc",
9298
action: CallMain("rustdoc", rustdoc::main_args),
9399
usage_line: "generate documentation from doc comments",
94100
usage_full: UsgCall(rustdoc::config::usage),
95101
},
96-
Command {
102+
Command{
97103
cmd: "pkg",
98104
action: CallMain("rustpkg", rustpkg::main_args),
99105
usage_line: "download, build, install rust packages",
100106
usage_full: UsgCall(rustpkg::usage::general),
101107
},
102-
Command {
108+
Command{
103109
cmd: "sketch",
104110
action: CallMain("rusti", rusti::main_args),
105111
usage_line: "run a rust interpreter",
106112
usage_full: UsgStr("\nUsage:\trusti"),
107113
},
108-
Command {
114+
Command{
109115
cmd: "help",
110116
action: Call(cmd_help),
111117
usage_line: "show detailed usage of a command",

branches/try/src/libsyntax/ast.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,8 @@ impl Eq for Ident {
4747
// if it should be non-hygienic (most things are), just compare the
4848
// 'name' fields of the idents. Or, even better, replace the idents
4949
// with Name's.
50-
fail!(fmt!("not allowed to compare these idents: %?, %?", self, other));
50+
fail!(fmt!("not allowed to compare these idents: %?, %?. Probably \
51+
related to issue #6993", self, other));
5152
}
5253
}
5354
fn ne(&self, other: &Ident) -> bool {

0 commit comments

Comments
 (0)