Skip to content

Commit 7d2dd42

Browse files
committed
---
yaml --- r: 231934 b: refs/heads/auto c: 2662a72 h: refs/heads/master v: v3
1 parent cb6bdf2 commit 7d2dd42

Some content is hidden

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

64 files changed

+845
-3044
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: 33f0920d0e81cf95cb62f380c13f100f3e1d804c
11+
refs/heads/auto: 2662a72537111b4b486813bc284ff560a3ec3bc7
1212
refs/tags/release-0.6: b4ebcfa1812664df5e142f0134a5faea3918544c
1313
refs/tags/0.1: b19db808c2793fe2976759b85a355c3ad8c8b336
1414
refs/tags/0.2: 1754d02027f2924bed83b0160ee340c7f41d5ea1

branches/auto/configure

Lines changed: 29 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -885,28 +885,6 @@ then
885885
CFG_DISABLE_JEMALLOC=1
886886
fi
887887

888-
# default gcc version under OpenBSD maybe too old, try using egcc, which is a
889-
# gcc version from ports
890-
if [ $CFG_OSTYPE = unknown-openbsd ]
891-
then
892-
if [ $("$CFG_GCC" --version 2>&1 | grep -c ' 4\.[0-6]') -ne 0 ]; then
893-
step_msg "older GCC found, try with egcc instead"
894-
895-
# probe again but using egcc
896-
probe CFG_GCC egcc
897-
898-
# and use egcc/eg++ for CC/CXX too if it was found
899-
# (but user setting has priority)
900-
if [ -n "$CFG_GCC" ]; then
901-
CC="${CC:-egcc}"
902-
CXX="${CXX:-eg++}"
903-
fi
904-
fi
905-
906-
step_msg "on OpenBSD, disabling jemalloc"
907-
CFG_DISABLE_JEMALLOC=1
908-
fi
909-
910888
# OS X 10.9, gcc is actually clang. This can cause some confusion in the build
911889
# system, so if we find that gcc is clang, we should just use clang directly.
912890
if [ $CFG_OSTYPE = apple-darwin -a -z "$CFG_ENABLE_CLANG" ]
@@ -978,7 +956,7 @@ then
978956
LLVM_VERSION=$($LLVM_CONFIG --version)
979957

980958
case $LLVM_VERSION in
981-
(3.[5-8]*)
959+
(3.[5-7]*)
982960
msg "found ok version of LLVM: $LLVM_VERSION"
983961
;;
984962
(*)
@@ -1052,7 +1030,7 @@ then
10521030
esac
10531031
else
10541032
case $CFG_CLANG_VERSION in
1055-
(3.2* | 3.3* | 3.4* | 3.5* | 3.6* | 3.7* | 3.8*)
1033+
(3.2* | 3.3* | 3.4* | 3.5* | 3.6* | 3.7*)
10561034
step_msg "found ok version of CLANG: $CFG_CLANG_VERSION"
10571035
;;
10581036
(*)
@@ -1191,12 +1169,21 @@ do
11911169
#
11921170
# Consequently here we try to detect when that happens and print an
11931171
# error if it does.
1194-
if $CFG_PYTHON -c 'import sys; print sys.argv[1]' `pwd` | grep '^/'
1172+
if $CFG_PYTHON -c 'import sys; print sys.argv[1]' `pwd` | grep '^/' > /dev/null
11951173
then
1196-
err "python is silently translating windows paths to MSYS paths \
1197-
and the build will fail if this python is used.\n\n \
1198-
Either an official python install must be used or an \
1199-
alternative python package in MinGW must be used."
1174+
err "
1175+
1176+
python is silently translating windows paths to MSYS paths \
1177+
and the build will fail if this python is used.
1178+
1179+
Either an official python install must be used or an \
1180+
alternative python package in MinGW must be used.
1181+
1182+
If you are building under msys2 try installing the mingw-w64-x86_64-python2 \
1183+
package instead of python2:
1184+
1185+
$ pacman -R python2 && pacman -S mingw-w64-x86_64-python2
1186+
"
12001187
fi
12011188

12021189
# MSVC requires cmake because that's how we're going to build LLVM
@@ -1207,10 +1194,19 @@ do
12071194
# detect that here and error.
12081195
if ! "$CFG_CMAKE" --help | sed -n '/^Generators/,$p' | grep 'Visual Studio' > /dev/null
12091196
then
1210-
err "cmake does not support Visual Studio generators.\n\n \
1211-
This is likely due to it being an msys/cygwin build of cmake, \
1212-
rather than the required windows version, built using MinGW \
1213-
or Visual Studio."
1197+
err "
1198+
1199+
cmake does not support Visual Studio generators.
1200+
1201+
This is likely due to it being an msys/cygwin build of cmake, \
1202+
rather than the required windows version, built using MinGW \
1203+
or Visual Studio.
1204+
1205+
If you are building under msys2 try installing the mingw-w64-x86_64-cmake \
1206+
package instead of cmake:
1207+
1208+
$ pacman -R cmake && pacman -S mingw-w64-x86_64-cmake
1209+
"
12141210
fi
12151211

12161212
# Use the REG program to figure out where VS is installed

branches/auto/src/doc/nomicon/destructors.md

Lines changed: 6 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -26,16 +26,13 @@ this is totally fine.
2626
For instance, a custom implementation of `Box` might write `Drop` like this:
2727

2828
```rust
29-
#![feature(alloc, heap_api, core_intrinsics, unique)]
30-
31-
extern crate alloc;
29+
#![feature(heap_api, core_intrinsics, unique)]
3230

31+
use std::rt::heap;
3332
use std::ptr::Unique;
3433
use std::intrinsics::drop_in_place;
3534
use std::mem;
3635

37-
use alloc::heap;
38-
3936
struct Box<T>{ ptr: Unique<T> }
4037

4138
impl<T> Drop for Box<T> {
@@ -48,7 +45,6 @@ impl<T> Drop for Box<T> {
4845
}
4946
}
5047
}
51-
# fn main() {}
5248
```
5349

5450
and this works fine because when Rust goes to drop the `ptr` field it just sees
@@ -58,16 +54,13 @@ use-after-free the `ptr` because when drop exits, it becomes inacessible.
5854
However this wouldn't work:
5955

6056
```rust
61-
#![feature(alloc, heap_api, core_intrinsics, unique)]
62-
63-
extern crate alloc;
57+
#![feature(heap_api, core_intrinsics, unique)]
6458

59+
use std::rt::heap;
6560
use std::ptr::Unique;
6661
use std::intrinsics::drop_in_place;
6762
use std::mem;
6863

69-
use alloc::heap;
70-
7164
struct Box<T>{ ptr: Unique<T> }
7265

7366
impl<T> Drop for Box<T> {
@@ -94,7 +87,6 @@ impl<T> Drop for SuperBox<T> {
9487
}
9588
}
9689
}
97-
# fn main() {}
9890
```
9991

10092
After we deallocate the `box`'s ptr in SuperBox's destructor, Rust will
@@ -137,16 +129,13 @@ The classic safe solution to overriding recursive drop and allowing moving out
137129
of Self during `drop` is to use an Option:
138130

139131
```rust
140-
#![feature(alloc, heap_api, core_intrinsics, unique)]
141-
142-
extern crate alloc;
132+
#![feature(heap_api, core_intrinsics, unique)]
143133

134+
use std::rt::heap;
144135
use std::ptr::Unique;
145136
use std::intrinsics::drop_in_place;
146137
use std::mem;
147138

148-
use alloc::heap;
149-
150139
struct Box<T>{ ptr: Unique<T> }
151140

152141
impl<T> Drop for Box<T> {
@@ -176,7 +165,6 @@ impl<T> Drop for SuperBox<T> {
176165
}
177166
}
178167
}
179-
# fn main() {}
180168
```
181169

182170
However this has fairly odd semantics: you're saying that a field that *should*

branches/auto/src/doc/nomicon/vec-alloc.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ This is perfectly fine because we already have `cap == 0` as our sentinel for no
99
allocation. We don't even need to handle it specially in almost any code because
1010
we usually need to check if `cap > len` or `len > 0` anyway. The traditional
1111
Rust value to put here is `0x01`. The standard library actually exposes this
12-
as `alloc::heap::EMPTY`. There are quite a few places where we'll
12+
as `std::rt::heap::EMPTY`. There are quite a few places where we'll
1313
want to use `heap::EMPTY` because there's no real allocation to talk about but
1414
`null` would make the compiler do bad things.
1515

@@ -20,12 +20,11 @@ the `heap` API anyway, so let's just get that dependency over with.
2020
So:
2121

2222
```rust,ignore
23-
#![feature(alloc, heap_api)]
23+
#![feature(heap_api)]
2424
25+
use std::rt::heap::EMPTY;
2526
use std::mem;
2627
27-
use alloc::heap::EMPTY;
28-
2928
impl<T> Vec<T> {
3029
fn new() -> Self {
3130
assert!(mem::size_of::<T>() != 0, "We're not ready to handle ZSTs");

branches/auto/src/doc/nomicon/vec-final.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,17 @@
22

33
```rust
44
#![feature(unique)]
5-
#![feature(alloc, heap_api)]
6-
7-
extern crate alloc;
5+
#![feature(heap_api)]
86

97
use std::ptr::{Unique, self};
8+
use std::rt::heap;
109
use std::mem;
1110
use std::ops::{Deref, DerefMut};
1211
use std::marker::PhantomData;
1312

14-
use alloc::heap;
13+
14+
15+
1516

1617
struct RawVec<T> {
1718
ptr: Unique<T>,

0 commit comments

Comments
 (0)