Skip to content

Commit 461e88e

Browse files
committed
---
yaml --- r: 95142 b: refs/heads/dist-snap c: b7fe83d h: refs/heads/master v: v3
1 parent 05fc98d commit 461e88e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

88 files changed

+494
-722
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ refs/heads/try: c274a6888410ce3e357e014568b43310ed787d36
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
88
refs/heads/try2: 147ecfdd8221e4a4d4e090486829a06da1e0ca3c
9-
refs/heads/dist-snap: 353578a7b36c003da8f5ac818a1554cdb652f9c2
9+
refs/heads/dist-snap: b7fe83d573d8073f7d663bee5c0b3e1493b9998d
1010
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
1111
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503
1212
refs/heads/try3: 9387340aab40a73e8424c48fd42f0c521a4875c0

branches/dist-snap/src/etc/emacs/rust-mode-tests.el

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -196,35 +196,6 @@ This is some more text. Fee fie fo fum. Humpty dumpty sat on a wall.
196196
*very very very long string
197197
*/"))
198198

199-
(ert-deftest fill-paragraph-single-line-style-with-code-before ()
200-
(test-fill-paragraph
201-
"fn foo() { }
202-
/// This is my comment. This is more of my comment. This is even more."
203-
"fn foo() { }
204-
/// This is my comment. This is
205-
/// more of my comment. This is
206-
/// even more." 14))
207-
208-
(ert-deftest fill-paragraph-single-line-style-with-code-after ()
209-
(test-fill-paragraph
210-
"/// This is my comment. This is more of my comment. This is even more.
211-
fn foo() { }"
212-
"/// This is my comment. This is
213-
/// more of my comment. This is
214-
/// even more.
215-
fn foo() { }" 1 73))
216-
217-
(ert-deftest fill-paragraph-single-line-style-code-before-and-after ()
218-
(test-fill-paragraph
219-
"fn foo() { }
220-
/// This is my comment. This is more of my comment. This is even more.
221-
fn bar() { }"
222-
"fn foo() { }
223-
/// This is my comment. This is
224-
/// more of my comment. This is
225-
/// even more.
226-
fn bar() { }" 14 67))
227-
228199
(defun test-auto-fill (initial position inserted expected)
229200
(rust-test-manip-code
230201
initial

branches/dist-snap/src/etc/emacs/rust-mode.el

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -300,8 +300,7 @@
300300
(let
301301
((fill-paragraph-function
302302
(if (not (eq fill-paragraph-function 'rust-fill-paragraph))
303-
fill-paragraph-function))
304-
(fill-paragraph-handle-comment t))
303+
fill-paragraph-function)))
305304
(apply 'fill-paragraph args)
306305
t))))))
307306

branches/dist-snap/src/libextra/base64.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ impl<'self> FromBase64 for &'self str {
200200
'0'..'9' => buf |= val + 0x04,
201201
'+'|'-' => buf |= 0x3E,
202202
'/'|'_' => buf |= 0x3F,
203-
'\r'|'\n' => continue,
203+
'\r'|'\n' => loop,
204204
'=' => break,
205205
_ => return Err(format!("Invalid character '{}' at position {}",
206206
self.char_at(idx), idx))

branches/dist-snap/src/libextra/fileinput.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -303,7 +303,7 @@ impl io::Reader for FileInput {
303303
let b = r.read_byte();
304304

305305
if b < 0 {
306-
continue;
306+
loop;
307307
}
308308

309309
if b == '\n' as int {

branches/dist-snap/src/libextra/getopts.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,13 +85,15 @@ use std::vec;
8585

8686
/// Name of an option. Either a string or a single char.
8787
#[deriving(Clone, Eq)]
88+
#[allow(missing_doc)]
8889
pub enum Name {
8990
Long(~str),
9091
Short(char),
9192
}
9293

9394
/// Describes whether an option has an argument.
9495
#[deriving(Clone, Eq)]
96+
#[allow(missing_doc)]
9597
pub enum HasArg {
9698
Yes,
9799
No,
@@ -100,6 +102,7 @@ pub enum HasArg {
100102

101103
/// Describes how often an option may occur.
102104
#[deriving(Clone, Eq)]
105+
#[allow(missing_doc)]
103106
pub enum Occur {
104107
Req,
105108
Optional,
@@ -141,6 +144,7 @@ pub struct Matches {
141144
/// The type returned when the command line does not conform to the
142145
/// expected format. Pass this value to <fail_str> to get an error message.
143146
#[deriving(Clone, Eq, ToStr)]
147+
#[allow(missing_doc)]
144148
pub enum Fail_ {
145149
ArgumentMissing(~str),
146150
UnrecognizedOption(~str),
@@ -151,6 +155,7 @@ pub enum Fail_ {
151155

152156
/// The type of failure that occured.
153157
#[deriving(Eq)]
158+
#[allow(missing_doc)]
154159
pub enum FailType {
155160
ArgumentMissing_,
156161
UnrecognizedOption_,

branches/dist-snap/src/libextra/glob.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ impl Pattern {
211211
let cs = parse_char_specifiers(chars.slice(i + 2, i + 3 + j));
212212
tokens.push(AnyExcept(cs));
213213
i += j + 4;
214-
continue;
214+
loop;
215215
}
216216
}
217217
}
@@ -222,7 +222,7 @@ impl Pattern {
222222
let cs = parse_char_specifiers(chars.slice(i + 1, i + 2 + j));
223223
tokens.push(AnyWithin(cs));
224224
i += j + 3;
225-
continue;
225+
loop;
226226
}
227227
}
228228
}

branches/dist-snap/src/libextra/hex.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ impl<'self> FromHex for &'self str {
100100
'0'..'9' => buf |= byte - ('0' as u8),
101101
' '|'\r'|'\n'|'\t' => {
102102
buf >>= 4;
103-
continue
103+
loop
104104
}
105105
_ => return Err(format!("Invalid character '{}' at position {}",
106106
self.char_at(idx), idx))

branches/dist-snap/src/libextra/list.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,14 @@
1313

1414

1515
#[deriving(Clone, Eq)]
16+
#[allow(missing_doc)]
1617
pub enum List<T> {
1718
Cons(T, @List<T>),
1819
Nil,
1920
}
2021

2122
#[deriving(Eq)]
23+
#[allow(missing_doc)]
2224
pub enum MutList<T> {
2325
MutCons(T, @mut MutList<T>),
2426
MutNil,

branches/dist-snap/src/libextra/num/bigint.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -413,7 +413,7 @@ impl Integer for BigUint {
413413
}
414414
if d0.is_zero() {
415415
n = 2;
416-
continue;
416+
loop;
417417
}
418418
n = 1;
419419
// FIXME(#6102): Assignment operator for BigInt causes ICE

branches/dist-snap/src/libextra/priority_queue.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ impl<T:Ord> PriorityQueue<T> {
140140
let x = replace(&mut self.data[parent], init());
141141
move_val_init(&mut self.data[pos], x);
142142
pos = parent;
143-
continue
143+
loop
144144
}
145145
break
146146
}

branches/dist-snap/src/libextra/semver.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ use std::to_str::ToStr;
3838
/// An identifier in the pre-release or build metadata. If the identifier can
3939
/// be parsed as a decimal value, it will be represented with `Numeric`.
4040
#[deriving(Clone, Eq)]
41+
#[allow(missing_doc)]
4142
pub enum Identifier {
4243
Numeric(uint),
4344
AlphaNumeric(~str)

branches/dist-snap/src/libextra/terminfo/parm.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ enum FormatState {
3939

4040
/// Types of parameters a capability can use
4141
#[deriving(Clone)]
42+
#[allow(missing_doc)]
4243
pub enum Param {
4344
String(~str),
4445
Number(int)

branches/dist-snap/src/libextra/terminfo/parser/compiled.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,7 @@ pub fn parse(file: @Reader, longnames: bool) -> Result<~TermInfo, ~str> {
276276
for (i, v) in string_offsets.iter().enumerate() {
277277
let offset = *v;
278278
if offset == 0xFFFF { // non-entry
279-
continue;
279+
loop;
280280
}
281281

282282
let name = if snames[i] == "_" {
@@ -289,7 +289,7 @@ pub fn parse(file: @Reader, longnames: bool) -> Result<~TermInfo, ~str> {
289289
// undocumented: FFFE indicates cap@, which means the capability is not present
290290
// unsure if the handling for this is correct
291291
string_map.insert(name.to_owned(), ~[]);
292-
continue;
292+
loop;
293293
}
294294

295295

branches/dist-snap/src/libextra/time.rs

Lines changed: 8 additions & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -734,59 +734,6 @@ fn do_strptime(s: &str, format: &str) -> Result<Tm, ~str> {
734734
}
735735

736736
fn do_strftime(format: &str, tm: &Tm) -> ~str {
737-
fn days_in_year(year: int) -> i32 {
738-
if ((year % 4 == 0) && ((year % 100 != 0) || (year % 400 == 0))) {
739-
366 /* Days in a leap year */
740-
} else {
741-
365 /* Days in a non-leap year */
742-
}
743-
}
744-
745-
fn iso_week_days(yday: i32, wday: i32) -> int {
746-
/* The number of days from the first day of the first ISO week of this
747-
* year to the year day YDAY with week day WDAY.
748-
* ISO weeks start on Monday. The first ISO week has the year's first
749-
* Thursday.
750-
* YDAY may be as small as yday_minimum.
751-
*/
752-
let yday: int = yday as int;
753-
let wday: int = wday as int;
754-
let iso_week_start_wday: int = 1; /* Monday */
755-
let iso_week1_wday: int = 4; /* Thursday */
756-
let yday_minimum: int = 366;
757-
/* Add enough to the first operand of % to make it nonnegative. */
758-
let big_enough_multiple_of_7: int = (yday_minimum / 7 + 2) * 7;
759-
760-
yday - (yday - wday + iso_week1_wday + big_enough_multiple_of_7) % 7
761-
+ iso_week1_wday - iso_week_start_wday
762-
}
763-
764-
fn iso_week(ch:char, tm: &Tm) -> ~str {
765-
let mut year: int = tm.tm_year as int + 1900;
766-
let mut days: int = iso_week_days (tm.tm_yday, tm.tm_wday);
767-
768-
if (days < 0) {
769-
/* This ISO week belongs to the previous year. */
770-
year -= 1;
771-
days = iso_week_days (tm.tm_yday + (days_in_year(year)), tm.tm_wday);
772-
} else {
773-
let d: int = iso_week_days (tm.tm_yday - (days_in_year(year)),
774-
tm.tm_wday);
775-
if (0 <= d) {
776-
/* This ISO week belongs to the next year. */
777-
year += 1;
778-
days = d;
779-
}
780-
}
781-
782-
match ch {
783-
'G' => format!("{}", year),
784-
'g' => format!("{:02d}", (year % 100 + 100) % 100),
785-
'V' => format!("{:02d}", days / 7 + 1),
786-
_ => ~""
787-
}
788-
}
789-
790737
fn parse_type(ch: char, tm: &Tm) -> ~str {
791738
//FIXME (#2350): Implement missing types.
792739
let die = || format!("strftime: can't understand this format {} ", ch);
@@ -865,8 +812,8 @@ fn do_strftime(format: &str, tm: &Tm) -> ~str {
865812
parse_type('m', tm),
866813
parse_type('d', tm))
867814
}
868-
'G' => iso_week('G', tm),
869-
'g' => iso_week('g', tm),
815+
//'G' {}
816+
//'g' {}
870817
'H' => format!("{:02d}", tm.tm_hour),
871818
'I' => {
872819
let mut h = tm.tm_hour;
@@ -908,12 +855,12 @@ fn do_strftime(format: &str, tm: &Tm) -> ~str {
908855
parse_type('S', tm))
909856
}
910857
't' => ~"\t",
911-
'U' => format!("{:02d}", (tm.tm_yday - tm.tm_wday + 7) / 7),
858+
//'U' {}
912859
'u' => {
913860
let i = tm.tm_wday as int;
914861
(if i == 0 { 7 } else { i }).to_str()
915862
}
916-
'V' => iso_week('V', tm),
863+
//'V' {}
917864
'v' => {
918865
format!("{}-{}-{}",
919866
parse_type('e', tm),
@@ -1275,8 +1222,8 @@ mod tests {
12751222
assert_eq!(local.strftime("%e"), ~"13");
12761223
assert_eq!(local.strftime("%f"), ~"000054321");
12771224
assert_eq!(local.strftime("%F"), ~"2009-02-13");
1278-
assert_eq!(local.strftime("%G"), ~"2009");
1279-
assert_eq!(local.strftime("%g"), ~"09");
1225+
// assert!(local.strftime("%G") == "2009");
1226+
// assert!(local.strftime("%g") == "09");
12801227
assert_eq!(local.strftime("%H"), ~"15");
12811228
assert_eq!(local.strftime("%I"), ~"03");
12821229
assert_eq!(local.strftime("%j"), ~"044");
@@ -1293,9 +1240,9 @@ mod tests {
12931240
assert_eq!(local.strftime("%s"), ~"1234567890");
12941241
assert_eq!(local.strftime("%T"), ~"15:31:30");
12951242
assert_eq!(local.strftime("%t"), ~"\t");
1296-
assert_eq!(local.strftime("%U"), ~"06");
1243+
// assert!(local.strftime("%U") == "06");
12971244
assert_eq!(local.strftime("%u"), ~"5");
1298-
assert_eq!(local.strftime("%V"), ~"07");
1245+
// assert!(local.strftime("%V") == "07");
12991246
assert_eq!(local.strftime("%v"), ~"13-Feb-2009");
13001247
// assert!(local.strftime("%W") == "06");
13011248
assert_eq!(local.strftime("%w"), ~"5");

branches/dist-snap/src/libextra/url.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -359,12 +359,12 @@ pub fn query_to_str(query: &Query) -> ~str {
359359
pub fn get_scheme(rawurl: &str) -> Result<(~str, ~str), ~str> {
360360
for (i,c) in rawurl.iter().enumerate() {
361361
match c {
362-
'A' .. 'Z' | 'a' .. 'z' => continue,
362+
'A' .. 'Z' | 'a' .. 'z' => loop,
363363
'0' .. '9' | '+' | '-' | '.' => {
364364
if i == 0 {
365365
return Err(~"url: Scheme must begin with a letter.");
366366
}
367-
continue;
367+
loop;
368368
}
369369
':' => {
370370
if i == 0 {
@@ -420,7 +420,7 @@ fn get_authority(rawurl: &str) ->
420420
let mut end = len;
421421

422422
for (i,c) in rawurl.iter().enumerate() {
423-
if i < 2 { continue; } // ignore the leading //
423+
if i < 2 { loop; } // ignore the leading //
424424

425425
// deal with input class first
426426
match c {
@@ -558,7 +558,7 @@ fn get_path(rawurl: &str, authority: bool) ->
558558
'A' .. 'Z' | 'a' .. 'z' | '0' .. '9' | '&' |'\'' | '(' | ')' | '.'
559559
| '@' | ':' | '%' | '/' | '+' | '!' | '*' | ',' | ';' | '='
560560
| '_' | '-' => {
561-
continue;
561+
loop;
562562
}
563563
'?' | '#' => {
564564
end = i;

branches/dist-snap/src/libextra/uuid.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@ struct UuidFields {
116116
}
117117

118118
/// Error details for string parsing failures
119+
#[allow(missing_doc)]
119120
pub enum ParseError {
120121
ErrorInvalidLength(uint),
121122
ErrorInvalidCharacter(char, uint),

branches/dist-snap/src/librust/rust.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ pub fn main() {
247247
os::set_exit_status(exit_code);
248248
return;
249249
}
250-
_ => {}
250+
_ => loop
251251
}
252252
}
253253
}

branches/dist-snap/src/librustc/back/link.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1004,7 +1004,7 @@ pub fn link_args(sess: Session,
10041004
for cratepath in r.iter() {
10051005
if cratepath.filetype() == Some(".rlib") {
10061006
args.push(cratepath.to_str());
1007-
continue;
1007+
loop;
10081008
}
10091009
let dir = cratepath.dirname();
10101010
if dir != ~"" { args.push(~"-L" + dir); }

branches/dist-snap/src/librustc/lib/llvm.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
// LLVM wrappers are intended to be called from trans,
1212
// which already runs in a #[fixed_stack_segment]
1313
#[allow(cstack)];
14-
#[allow(non_uppercase_pattern_statics)];
1514

1615
use std::c_str::ToCStr;
1716
use std::hashmap::HashMap;

branches/dist-snap/src/librustc/middle/borrowck/check_loans.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -263,8 +263,8 @@ impl<'self> CheckLoanCtxt<'self> {
263263
debug2!("illegal_if={:?}", illegal_if);
264264

265265
for restr in loan1.restrictions.iter() {
266-
if !restr.set.intersects(illegal_if) { continue; }
267-
if restr.loan_path != loan2.loan_path { continue; }
266+
if !restr.set.intersects(illegal_if) { loop; }
267+
if restr.loan_path != loan2.loan_path { loop; }
268268

269269
match (new_loan.mutbl, old_loan.mutbl) {
270270
(MutableMutability, MutableMutability) => {

0 commit comments

Comments
 (0)