| Age | Commit message (Collapse) | Author | Lines |
|
They're forever doomed to be out-of-date. Also, don't assume the user is
installing a particular version.
|
|
These were just left out by mistake!
|
|
|
|
|
|
These used to return wrong results in case they were expanded inside compiler’s
iternal syntax sugar (closures, if-let) expansions
Fixes #26322
|
|
Using the wrong landing pad has obvious bad effects, like dropping a value
twice.
Testcase written by Alex Crichton.
Fixes #25089.
|
|
This commit adds a ./configure option called `--disable-elf-tls` which disables
ELF based TLS (that which is communicated to LLVM) on platforms which already
support it. OSX 10.6 does not support this form of TLS, and some users of Rust
need to target 10.6 and are unable to do so due to the usage of TLS. The
standard library will continue to use ELF based TLS on OSX by default (as the
officially supported platform is 10.7+), but this adds an option to compile the
standard library in a way that is compatible with 10.6.
Conflicts:
src/libstd/thread/local.rs
|
|
This commit stabilizes the following APIs, slating them all to be cherry-picked
into the 1.1 release.
* fs::FileType (and transitively the derived trait implementations)
* fs::Metadata::file_type
* fs::FileType::is_dir
* fs::FileType::is_file
* fs::FileType::is_symlink
* fs::DirEntry::metadata
* fs::DirEntry::file_type
* fs::DirEntry::file_name
* fs::set_permissions
* fs::symlink_metadata
* os::raw::{self, *}
* os::{android, bitrig, linux, ...}::raw::{self, *}
* os::{android, bitrig, linux, ...}::fs::MetadataExt
* os::{android, bitrig, linux, ...}::fs::MetadataExt::as_raw_stat
* os::unix::fs::PermissionsExt
* os::unix::fs::PermissionsExt::mode
* os::unix::fs::PermissionsExt::set_mode
* os::unix::fs::PermissionsExt::from_mode
* os::unix::fs::OpenOptionsExt
* os::unix::fs::OpenOptionsExt::mode
* os::unix::fs::DirEntryExt
* os::unix::fs::DirEntryExt::ino
* os::windows::fs::MetadataExt
* os::windows::fs::MetadataExt::file_attributes
* os::windows::fs::MetadataExt::creation_time
* os::windows::fs::MetadataExt::last_access_time
* os::windows::fs::MetadataExt::last_write_time
* os::windows::fs::MetadataExt::file_size
The `os::unix::fs::Metadata` structure was also removed entirely, moving all of
its associated methods into the `os::unix::fs::MetadataExt` trait instead. The
methods are all marked as `#[stable]` still.
As some minor cleanup, some deprecated and unstable fs apis were also removed:
* File::path
* Metadata::accessed
* Metadata::modified
Features that were explicitly left unstable include:
* fs::WalkDir - the semantics of this were not considered in the recent fs
expansion RFC.
* fs::DirBuilder - it's still not 100% clear if the naming is right here and if
the set of functionality exposed is appropriate.
* fs::canonicalize - the implementation on Windows here is specifically in
question as it always returns a verbatim path. Additionally the Unix
implementation is susceptible to buffer overflows on long paths unfortunately.
* fs::PathExt - as this is just a convenience trait, it is not stabilized at
this time.
* fs::set_file_times - this funciton is still waiting on a time abstraction.
Conflicts:
src/libstd/os/android/raw.rs
|
|
Conflicts:
src/libcollections/borrow.rs
|
|
Closes #25812.
|
|
|
|
Use a struct called Hole that keeps track of an invalid location
in the vector and fills the hole on drop.
I include a run-pass test that the current BinaryHeap fails, and the new
one passes.
Fixes #25842
|
|
This iterator was mistakenly not reexported at the top level, preventing
actually naming the type!
Closes #25519
|
|
The method was stabilized but the structure was forgotten to be stabilized.
Closes #25480
|
|
Debug overflow checks for arithmetic negation landed in #24500, at which time
the `abs` method on signed integers was changed to using `wrapping_neg` to
ensure that the function never panicked. This implied that `abs` of `INT_MIN`
would return `INT_MIN`, another negative value. When this change was back-ported
to beta, however, in #24708, the `wrapping_neg` function had not yet been
backported, so the implementation was changed in #24785 to `!self + 1`. This
change had the unintended side effect of enabling debug overflow checks for the
`abs` function. Consequently, the current state of affairs is that the beta
branch checks for overflow in debug mode for `abs` and the nightly branch does
not.
This commit alters the behavior of nightly to have `abs` always check for
overflow in debug mode. This change is more consistent with the way the standard
library treats overflow as well, and it is also not a breaking change as it's
what the beta branch currently does (albeit if by accident).
cc #25378
|
|
(cherry picked from commit 494901a8b46c699b530e7209114bde44b1de4451)
|
|
|
|
The recent quote changes unfortunately broke unquoting statements like `let foo = 5` because the parser requires their to be a trailing semicolon in those statements. Along the way I added support for unquoting generics and where clauses as well as better pretty printing of `token::Interpolated`.
|
|
|
|
|
|
|
|
r? @steveklabnik
|
|
The assume intrinsic has a strong, negative impact on compile times, so
we're currently only using it in places where LLVM can simplify it to
nonnull metadata on a load intruction. Unfortunately a recent change
that fixed invalid assume calls introduce new assume calls for which
this simplification can not happen, leading to a massive regression in
compile times in certain cases.
Moving the assumptions from the middle of the function to the beginning
allows the simplification to happen again, bringing compile times back
to their old levels.
Fixes #25393
|
|
Also start factoring out an API for compiler tools to use and fix a bug that was preventing DXR indexing Rust properly.
r? @huonw
|
|
Closes #25430
|
|
|
|
For https://github.com/rust-lang/rust/issues/24407
|
|
|
|
r? @alexcrichton
|
|
- Successful merges: #25404, #25405, #25407, #25408, #25410, #25412, #25413, #25414, #25418, #25420
- Failed merges:
|
|
The assume intrinsic has a strong, negative impact on compile times, so
we're currently only using it in places where LLVM can simplify it to
nonnull metadata on a load intruction. Unfortunately a recent change
that fixed invalid assume calls introduce new assume calls for which
this simplification can not happen, leading to a massive regression in
compile times in certain cases.
Moving the assumptions from the middle of the function to the beginning
allows the simplification to happen again, bringing compile times back
to their old levels.
Fixes #25393
|
|
|
|
It seems to refer to something that used to exist, but got moved, and then not everything got cleaned up.
|
|
|
|
|
|
r? @steveklabnik
|
|
Every time I profile my code I find something new to add #[inline] to. (:
|
|
|
|
r=steveklabnik
I fixed the typo of the value of e in the memory tables. It is a reference to d, and so it should contain the memory location of d. I also fixed the incorrectly formatted tables so they display properly in html pages.
|
|
|
|
|
|
This PR fixes a comment in the `while Loops` section of the Rust book with the correct type of a variable binding.
|
|
|
|
Stripping unconfigured items prior to collecting crate metadata means we
can say things like `#![cfg_attr(foo, crate_type="lib")]`.
Fixes #25347.
|
|
It seems to refer to something that used to exist, but got moved, and
then not everything got cleaned up.
|
|
|
|
|
|
- Successful merges: #25354, #25381, #25391, #25395, #25397, #25398, #25401
- Failed merges:
|
|
|
|
|