Skip to content

Commit 4830935

Browse files
committed
---
yaml --- r: 109950 b: refs/heads/master c: 51ea4fb h: refs/heads/master v: v3
1 parent 9ef76c6 commit 4830935

File tree

107 files changed

+235
-481
lines changed

Some content is hidden

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

107 files changed

+235
-481
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: 339d4002617d5b36d6125d8a1781a6ada2e0a3f8
2+
refs/heads/master: 51ea4fb17f8a6c37220b971dd8c7f343f9fdcea2
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: c7fac4471201977fdb1c0c0a26c87287e12dc644
55
refs/heads/try: f64fdf524a434f0e5cd0bc91d09c144723f3c90d

trunk/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ documentation.
55

66
## Quick Start
77

8-
1. Download a [binary installer][installer] for your platform.
8+
1. Download a [binary insaller][installer] for your platform.
99
2. Read the [tutorial].
1010
3. Enjoy!
1111

trunk/mk/dist.mk

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ dist-install-dir-$(1): PREPARE_BIN_CMD=$(DEFAULT_PREPARE_BIN_CMD)
215215
dist-install-dir-$(1): PREPARE_LIB_CMD=$(DEFAULT_PREPARE_LIB_CMD)
216216
dist-install-dir-$(1): PREPARE_MAN_CMD=$(DEFAULT_PREPARE_MAN_CMD)
217217
dist-install-dir-$(1): PREPARE_CLEAN=true
218-
dist-install-dir-$(1): prepare-base-dir-$(1) docs compiler-docs
218+
dist-install-dir-$(1): prepare-base-dir-$(1)
219219
$$(Q)(cd $$(PREPARE_DEST_DIR)/ && find . -type f | sed 's/^\.\///') \
220220
> tmp/dist/manifest-$(1).in
221221
$$(Q)mv tmp/dist/manifest-$(1).in $$(PREPARE_DEST_DIR)/$$(CFG_LIBDIR_RELATIVE)/rustlib/manifest.in
@@ -224,7 +224,6 @@ dist-install-dir-$(1): prepare-base-dir-$(1) docs compiler-docs
224224
$$(Q)$$(PREPARE_MAN_CMD) $$(S)LICENSE-APACHE $$(PREPARE_DEST_DIR)
225225
$$(Q)$$(PREPARE_MAN_CMD) $$(S)LICENSE-MIT $$(PREPARE_DEST_DIR)
226226
$$(Q)$$(PREPARE_MAN_CMD) $$(S)README.md $$(PREPARE_DEST_DIR)
227-
$$(Q)cp -r doc $$(PREPARE_DEST_DIR)
228227
$$(Q)$$(PREPARE_BIN_CMD) $$(S)src/etc/install.sh $$(PREPARE_DEST_DIR)
229228

230229
dist/$$(PKG_NAME)-$(1).tar.gz: dist-install-dir-$(1)

trunk/src/doc/guide-unsafe.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,7 @@ asm!(assembly template
294294
);
295295
```
296296

297-
Any use of `asm` is feature gated (requires `#![feature(asm)]` on the
297+
Any use of `asm` is feature gated (requires `#[feature(asm)];` on the
298298
crate to allow) and of course requires an `unsafe` block.
299299

300300
> **Note**: the examples here are given in x86/x86-64 assembly, but all
@@ -306,7 +306,7 @@ The `assembly template` is the only required parameter and must be a
306306
literal string (i.e `""`)
307307

308308
```
309-
#![feature(asm)]
309+
#[feature(asm)];
310310
311311
#[cfg(target_arch = "x86")]
312312
#[cfg(target_arch = "x86_64")]
@@ -334,7 +334,7 @@ Output operands, input operands, clobbers and options are all optional
334334
but you must add the right number of `:` if you skip them:
335335

336336
```
337-
# #![feature(asm)]
337+
# #[feature(asm)];
338338
# #[cfg(target_arch = "x86")] #[cfg(target_arch = "x86_64")]
339339
# fn main() { unsafe {
340340
asm!("xor %eax, %eax"
@@ -348,7 +348,7 @@ asm!("xor %eax, %eax"
348348
Whitespace also doesn't matter:
349349

350350
```
351-
# #![feature(asm)]
351+
# #[feature(asm)];
352352
# #[cfg(target_arch = "x86")] #[cfg(target_arch = "x86_64")]
353353
# fn main() { unsafe {
354354
asm!("xor %eax, %eax" ::: "eax");
@@ -362,7 +362,7 @@ Input and output operands follow the same format: `:
362362
expressions must be mutable lvalues:
363363

364364
```
365-
# #![feature(asm)]
365+
# #[feature(asm)];
366366
# #[cfg(target_arch = "x86")] #[cfg(target_arch = "x86_64")]
367367
fn add(a: int, b: int) -> int {
368368
let mut c = 0;
@@ -390,7 +390,7 @@ compiler not to assume any values loaded into those registers will
390390
stay valid.
391391

392392
```
393-
# #![feature(asm)]
393+
# #[feature(asm)];
394394
# #[cfg(target_arch = "x86")] #[cfg(target_arch = "x86_64")]
395395
# fn main() { unsafe {
396396
// Put the value 0x200 in eax

trunk/src/doc/po/ja/rust.md.po

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Japanese translations for Rust package
2-
# Copyright (C) 2013-2014 The Rust Project Developers
2+
# Copyright (C) 2013 The Rust Project Developers
33
# This file is distributed under the same license as the Rust package.
44
# Automatically generated, 2013.
55
#
@@ -886,7 +886,7 @@ msgstr ""
886886
#: src/doc/rust.md:2008
887887
#, fuzzy
888888
#| msgid "~~~~ use std::task::spawn;"
889-
msgid "~~~~ {.ignore} #![warn(unstable)]"
889+
msgid "~~~~ {.ignore} #[warn(unstable)];"
890890
msgstr ""
891891
"~~~~\n"
892892
"use std::task::spawn;"

trunk/src/doc/tutorial.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1492,8 +1492,8 @@ Rust uses the unary star operator (`*`) to access the contents of a
14921492
box or pointer, similarly to C.
14931493
14941494
~~~
1495-
let owned = ~20;
1496-
let borrowed = &30;
1495+
let owned = ~10;
1496+
let borrowed = &20;
14971497

14981498
let sum = *owned + *borrowed;
14991499
~~~

trunk/src/etc/combine-tests.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ def scrub(b):
5454
#[crate_id=\"run_pass_stage2#0.1\"];
5555
#[crate_id=\"run_pass_stage2#0.1\"];
5656
#[feature(globs, macro_rules, struct_variant, managed_boxes)];
57-
#![allow(warnings)]
57+
#[allow(warnings)];
5858
extern crate collections;
5959
"""
6060
)

trunk/src/libarena/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
html_favicon_url = "http://www.rust-lang.org/favicon.ico",
2424
html_root_url = "http://static.rust-lang.org/doc/master")]
2525
#![allow(missing_doc)]
26+
#![allow(visible_private_types)] // NOTE: remove after a stage0 snap
2627

2728
extern crate collections;
2829

trunk/src/libcollections/lib.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@
2222

2323
#![feature(macro_rules, managed_boxes, default_type_params, phase)]
2424

25+
#![allow(visible_private_types)] // NOTE: remove after a stage0 snap
26+
2527
extern crate rand;
2628

2729
#[cfg(test)] extern crate test;

trunk/src/libcollections/priority_queue.rs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -117,11 +117,6 @@ impl<T:Ord> PriorityQueue<T> {
117117
/// Create an empty PriorityQueue
118118
pub fn new() -> PriorityQueue<T> { PriorityQueue{data: ~[],} }
119119

120-
/// Create an empty PriorityQueue with capacity `capacity`
121-
pub fn with_capacity(capacity: uint) -> PriorityQueue<T> {
122-
PriorityQueue { data: slice::with_capacity(capacity) }
123-
}
124-
125120
/// Create a PriorityQueue from a vector (heapify)
126121
pub fn from_vec(xs: ~[T]) -> PriorityQueue<T> {
127122
let mut q = PriorityQueue{data: xs,};

trunk/src/libcollections/smallintmap.rs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -112,11 +112,6 @@ impl<V> SmallIntMap<V> {
112112
/// Create an empty SmallIntMap
113113
pub fn new() -> SmallIntMap<V> { SmallIntMap{v: ~[]} }
114114

115-
/// Create an empty SmallIntMap with capacity `capacity`
116-
pub fn with_capacity(capacity: uint) -> SmallIntMap<V> {
117-
SmallIntMap { v: slice::with_capacity(capacity) }
118-
}
119-
120115
pub fn get<'a>(&'a self, key: &uint) -> &'a V {
121116
self.find(key).expect("key not present")
122117
}

trunk/src/libcollections/trie.rs

Lines changed: 13 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -293,46 +293,32 @@ impl Mutable for TrieSet {
293293
fn clear(&mut self) { self.map.clear() }
294294
}
295295

296-
impl Set<uint> for TrieSet {
297-
#[inline]
298-
fn contains(&self, value: &uint) -> bool {
299-
self.map.contains_key(value)
300-
}
301-
302-
#[inline]
303-
fn is_disjoint(&self, other: &TrieSet) -> bool {
304-
self.iter().all(|v| !other.contains(&v))
305-
}
306-
296+
impl TrieSet {
297+
/// Create an empty TrieSet
307298
#[inline]
308-
fn is_subset(&self, other: &TrieSet) -> bool {
309-
self.iter().all(|v| other.contains(&v))
299+
pub fn new() -> TrieSet {
300+
TrieSet{map: TrieMap::new()}
310301
}
311302

303+
/// Return true if the set contains a value
312304
#[inline]
313-
fn is_superset(&self, other: &TrieSet) -> bool {
314-
other.is_subset(self)
305+
pub fn contains(&self, value: &uint) -> bool {
306+
self.map.contains_key(value)
315307
}
316-
}
317308

318-
impl MutableSet<uint> for TrieSet {
309+
/// Add a value to the set. Return true if the value was not already
310+
/// present in the set.
319311
#[inline]
320-
fn insert(&mut self, value: uint) -> bool {
312+
pub fn insert(&mut self, value: uint) -> bool {
321313
self.map.insert(value, ())
322314
}
323315

316+
/// Remove a value from the set. Return true if the value was
317+
/// present in the set.
324318
#[inline]
325-
fn remove(&mut self, value: &uint) -> bool {
319+
pub fn remove(&mut self, value: &uint) -> bool {
326320
self.map.remove(value)
327321
}
328-
}
329-
330-
impl TrieSet {
331-
/// Create an empty TrieSet
332-
#[inline]
333-
pub fn new() -> TrieSet {
334-
TrieSet{map: TrieMap::new()}
335-
}
336322

337323
/// Visit all values in reverse order
338324
#[inline]

trunk/src/libgetopts/lib.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,8 @@
8787
#![deny(missing_doc)]
8888
#![deny(deprecated_owned_vector)]
8989

90+
#![allow(visible_private_types)] // NOTE: remove after a stage0 snap
91+
9092
#[cfg(test)] #[phase(syntax, link)] extern crate log;
9193

9294
use std::cmp::Eq;

trunk/src/liblog/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2014 The Rust Project Developers. See the COPYRIGHT
1+
// Copyright 2015 The Rust Project Developers. See the COPYRIGHT
22
// file at the top-level directory of this distribution and at
33
// http://rust-lang.org/COPYRIGHT.
44
//
@@ -15,7 +15,7 @@ Utilities for program-wide and customizable logging
1515
## Example
1616
1717
```
18-
#![feature(phase)]
18+
#[feature(phase)];
1919
#[phase(syntax, link)] extern crate log;
2020
2121
fn main() {

trunk/src/liblog/macros.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
/// # Example
2222
///
2323
/// ```
24-
/// #![feature(phase)]
24+
/// #[feature(phase)];
2525
/// #[phase(syntax, link)] extern crate log;
2626
///
2727
/// # fn main() {
@@ -45,7 +45,7 @@ macro_rules! log(
4545
/// # Example
4646
///
4747
/// ```
48-
/// #![feature(phase)]
48+
/// #[feature(phase)];
4949
/// #[phase(syntax, link)] extern crate log;
5050
///
5151
/// # fn main() {
@@ -63,7 +63,7 @@ macro_rules! error(
6363
/// # Example
6464
///
6565
/// ```
66-
/// #![feature(phase)]
66+
/// #[feature(phase)];
6767
/// #[phase(syntax, link)] extern crate log;
6868
///
6969
/// # fn main() {
@@ -81,7 +81,7 @@ macro_rules! warn(
8181
/// # Example
8282
///
8383
/// ```
84-
/// #![feature(phase)]
84+
/// #[feature(phase)];
8585
/// #[phase(syntax, link)] extern crate log;
8686
///
8787
/// # fn main() {
@@ -101,7 +101,7 @@ macro_rules! info(
101101
/// # Example
102102
///
103103
/// ```
104-
/// #![feature(phase)]
104+
/// #[feature(phase)];
105105
/// #[phase(syntax, link)] extern crate log;
106106
///
107107
/// # fn main() {
@@ -118,7 +118,7 @@ macro_rules! debug(
118118
/// # Example
119119
///
120120
/// ```
121-
/// #![feature(phase)]
121+
/// #[feature(phase)];
122122
/// #[phase(syntax, link)] extern crate log;
123123
///
124124
/// # fn main() {

trunk/src/libnative/lib.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,8 @@
5151
#![deny(unused_result, unused_must_use)]
5252
#![allow(non_camel_case_types)]
5353

54+
#![allow(visible_private_types)] // NOTE: remove after a stage0 snap
55+
5456
// NB this crate explicitly does *not* allow glob imports, please seriously
5557
// consider whether they're needed before adding that feature here (the
5658
// answer is that you don't need them)

trunk/src/librand/lib.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,8 @@ println!("{:?}", tuple_ptr)
7171
html_root_url = "http://static.rust-lang.org/doc/master")]
7272

7373
#![feature(macro_rules, managed_boxes, phase)]
74+
75+
#![allow(visible_private_types)] // NOTE: remove after a stage0 snap
7476
#![deny(deprecated_owned_vector)]
7577

7678
#[cfg(test)]

trunk/src/librustc/driver/session.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -232,9 +232,6 @@ impl Session {
232232
pub fn span_end_note(&self, sp: Span, msg: &str) {
233233
self.diagnostic().span_end_note(sp, msg)
234234
}
235-
pub fn fileline_note(&self, sp: Span, msg: &str) {
236-
self.diagnostic().fileline_note(sp, msg)
237-
}
238235
pub fn note(&self, msg: &str) {
239236
self.diagnostic().handler().note(msg)
240237
}

trunk/src/librustc/front/test.rs

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -404,17 +404,21 @@ fn is_test_crate(krate: &ast::Crate) -> bool {
404404
}
405405

406406
fn mk_test_descs(cx: &TestCtxt) -> @ast::Expr {
407+
let mut descs = Vec::new();
407408
debug!("building test vector from {} tests", cx.testfns.borrow().len());
409+
for test in cx.testfns.borrow().iter() {
410+
descs.push(mk_test_desc_and_fn_rec(cx, test));
411+
}
412+
413+
let inner_expr = @ast::Expr {
414+
id: ast::DUMMY_NODE_ID,
415+
node: ast::ExprVec(descs, ast::MutImmutable),
416+
span: DUMMY_SP,
417+
};
408418

409419
@ast::Expr {
410420
id: ast::DUMMY_NODE_ID,
411-
node: ast::ExprVstore(@ast::Expr {
412-
id: ast::DUMMY_NODE_ID,
413-
node: ast::ExprVec(cx.testfns.borrow().iter().map(|test| {
414-
mk_test_desc_and_fn_rec(cx, test)
415-
}).collect()),
416-
span: DUMMY_SP,
417-
}, ast::ExprVstoreSlice),
421+
node: ast::ExprVstore(inner_expr, ast::ExprVstoreSlice),
418422
span: DUMMY_SP,
419423
}
420424
}

trunk/src/librustc/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@ This API is completely unstable and subject to change.
3131
#![feature(macro_rules, globs, struct_variant, managed_boxes, quote,
3232
default_type_params, phase)]
3333

34+
#![allow(visible_private_types)] // NOTE: remove after a stage0 snap
35+
#![allow(unrecognized_lint)] // NOTE: remove after a stage0 snap
36+
3437
extern crate flate;
3538
extern crate arena;
3639
extern crate syntax;

0 commit comments

Comments
 (0)