Skip to content

Commit 91f3b1d

Browse files
committed
---
yaml --- r: 236519 b: refs/heads/auto c: abfbea2 h: refs/heads/master i: 236517: e8c0df1 236515: 04de116 236511: d2d9eec v: v3
1 parent 1523b20 commit 91f3b1d

File tree

14 files changed

+51
-13
lines changed

14 files changed

+51
-13
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503
88
refs/tags/release-0.3.1: 495bae036dfe5ec6ceafd3312b4dca48741e845b
99
refs/tags/release-0.4: e828ea2080499553b97dfe33b3f4d472b4562ad7
1010
refs/tags/release-0.5: 7e3bcfbf21278251ee936ad53e92e9b719702d73
11-
refs/heads/auto: 47c176e9d22827744c0afa866450a8bd2bc9575c
11+
refs/heads/auto: abfbea26494e602282f7a06b28a37beb66886e2d
1212
refs/tags/release-0.6: b4ebcfa1812664df5e142f0134a5faea3918544c
1313
refs/tags/0.1: b19db808c2793fe2976759b85a355c3ad8c8b336
1414
refs/tags/0.2: 1754d02027f2924bed83b0160ee340c7f41d5ea1

branches/auto/src/doc/trpl/iterators.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -281,8 +281,7 @@ If you are trying to execute a closure on an iterator for its side effects,
281281
just use `for` instead.
282282

283283
There are tons of interesting iterator adapters. `take(n)` will return an
284-
iterator over the next `n` elements of the original iterator. Note that this
285-
has no side effect on the original iterator. Let's try it out with our infinite
284+
iterator over the next `n` elements of the original iterator. Let's try it out with our infinite
286285
iterator from before:
287286

288287
```rust

branches/auto/src/liblibc/lib.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3901,6 +3901,8 @@ pub mod consts {
39013901
pub const MAP_POPULATE : c_int = 0x08000;
39023902
pub const MAP_NONBLOCK : c_int = 0x010000;
39033903
pub const MAP_STACK : c_int = 0x020000;
3904+
3905+
pub const PATH_MAX: c_int = 4096;
39043906
}
39053907
#[cfg(any(target_arch = "mips",
39063908
target_arch = "mipsel"))]
@@ -3928,6 +3930,8 @@ pub mod consts {
39283930
pub const MAP_POPULATE : c_int = 0x010000;
39293931
pub const MAP_NONBLOCK : c_int = 0x020000;
39303932
pub const MAP_STACK : c_int = 0x040000;
3933+
3934+
pub const PATH_MAX: c_int = 4096;
39313935
}
39323936
#[cfg(target_os = "linux")]
39333937
pub mod sysconf {

branches/auto/src/librustc_back/target/apple_base.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ pub fn opts() -> TargetOptions {
2424
dll_suffix: ".dylib".to_string(),
2525
archive_format: "bsd".to_string(),
2626
pre_link_args: Vec::new(),
27-
exe_allocation_crate: super::best_allocator(),
27+
exe_allocation_crate: super::maybe_jemalloc(),
2828
.. Default::default()
2929
}
3030
}

branches/auto/src/librustc_back/target/bitrig_base.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ pub fn opts() -> TargetOptions {
2020
has_rpath: true,
2121
position_independent_executables: true,
2222
archive_format: "gnu".to_string(),
23-
exe_allocation_crate: super::best_allocator(),
23+
exe_allocation_crate: "alloc_system".to_string(),
2424

2525
.. Default::default()
2626
}

branches/auto/src/librustc_back/target/dragonfly_base.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ pub fn opts() -> TargetOptions {
2727
),
2828
position_independent_executables: true,
2929
archive_format: "gnu".to_string(),
30-
exe_allocation_crate: super::best_allocator(),
30+
exe_allocation_crate: super::maybe_jemalloc(),
3131
.. Default::default()
3232
}
3333
}

branches/auto/src/librustc_back/target/freebsd_base.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ pub fn opts() -> TargetOptions {
1818
executables: true,
1919
has_rpath: true,
2020
archive_format: "gnu".to_string(),
21-
exe_allocation_crate: super::best_allocator(),
21+
exe_allocation_crate: super::maybe_jemalloc(),
2222

2323
.. Default::default()
2424
}

branches/auto/src/librustc_back/target/linux_base.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ pub fn opts() -> TargetOptions {
2929
],
3030
position_independent_executables: true,
3131
archive_format: "gnu".to_string(),
32-
exe_allocation_crate: super::best_allocator(),
32+
exe_allocation_crate: super::maybe_jemalloc(),
3333
.. Default::default()
3434
}
3535
}

branches/auto/src/librustc_back/target/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -458,7 +458,7 @@ impl Target {
458458
}
459459
}
460460

461-
fn best_allocator() -> String {
461+
fn maybe_jemalloc() -> String {
462462
if cfg!(disable_jemalloc) {
463463
"alloc_system".to_string()
464464
} else {

branches/auto/src/librustc_back/target/openbsd_base.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ pub fn opts() -> TargetOptions {
2727
),
2828
position_independent_executables: true,
2929
archive_format: "gnu".to_string(),
30-
exe_allocation_crate: super::best_allocator(),
30+
exe_allocation_crate: "alloc_system".to_string(),
3131
.. Default::default()
3232
}
3333
}

branches/auto/src/librustc_back/target/windows_base.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ pub fn opts() -> TargetOptions {
6464
// Always enable DEP (NX bit) when it is available
6565
"-Wl,--nxcompat".to_string(),
6666
),
67-
exe_allocation_crate: super::best_allocator(),
67+
exe_allocation_crate: super::maybe_jemalloc(),
6868

6969
.. Default::default()
7070
}

branches/auto/src/librustc_back/target/windows_msvc_base.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ pub fn opts() -> TargetOptions {
6060
"/NXCOMPAT".to_string(),
6161
],
6262
archive_format: "gnu".to_string(),
63-
exe_allocation_crate: super::best_allocator(),
63+
exe_allocation_crate: "alloc_system".to_string(),
6464

6565
.. Default::default()
6666
}

branches/auto/src/rustbook/static/rustbook.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ h1, h2, h3, h4, h5, h6 {
139139
}
140140

141141
pre {
142-
padding: 16px;
142+
padding: 11px;
143143
overflow: auto;
144144
font-size: 85%;
145145
line-height: 1.45;
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
// Copyright 2015 The Rust Project Developers. See the COPYRIGHT
2+
// file at the top-level directory of this distribution and at
3+
// http://rust-lang.org/COPYRIGHT.
4+
//
5+
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
6+
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
7+
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
8+
// option. This file may not be copied, modified, or distributed
9+
// except according to those terms.
10+
11+
// Test that static methods can be invoked on `type` aliases
12+
13+
#![allow(unused_variables)]
14+
15+
pub mod foo {
16+
pub mod bar {
17+
pub mod baz {
18+
pub struct Qux;
19+
20+
impl Qux {
21+
pub fn new() {}
22+
}
23+
}
24+
}
25+
}
26+
27+
fn main() {
28+
29+
type Ham = foo::bar::baz::Qux;
30+
let foo = foo::bar::baz::Qux::new(); // invoke directly
31+
let bar = Ham::new(); // invoke via type alias
32+
33+
type StringVec = Vec<String>;
34+
let sv = StringVec::new();
35+
}

0 commit comments

Comments
 (0)