This commit modifies resolve to prevent conflicts with typedef names in the same
method that conflits are prevented with enum names. This is a breaking change
due to the differing semantics in resolve, and any errors generated on behalf of
this change require that a conflicting typedef, module, or structure to be
renamed so they do not conflict.
[breaking-change]
Closes#6936
LLVM gets overwhelmed when presented with a zeroinitializer for a large
type. In unoptimised builds, it generates a long sequence of stores to
memory. In optmised builds, it manages to generate a standard memset of
zero values, but takes a long time doing so.
Call out to the `llvm.memset` function to zero out the memory instead.
Fixes#21264
This is a [breaking-change] since `std::dynamic_lib::dl` is now
private.
When `LoadLibraryW()` fails, original code called `errno()` to get error
code. However, there was local allocation of `Vec` before
`LoadLibraryW()`, and it drops before `errno()`, and the drop
(deallocation) changed `errno`! Therefore `dynamic_lib::open()` thought
it always succeeded.
This commit fixes the issue.
This commit also sets Windows error mode during `LoadLibrary()` to
prevent "dll load failed" dialog.
This commit modifies resolve to prevent conflicts with typedef names in the same
method that conflits are prevented with enum names. This is a breaking change
due to the differing semantics in resolve, and any errors generated on behalf of
this change require that a conflicting typedef, module, or structure to be
renamed so they do not conflict.
[breaking-change]
Closes#6936
LLVM gets overwhelmed when presented with a zeroinitializer for a large
type. In unoptimised builds, it generates a long sequence of stores to
memory. In optmised builds, it manages to generate a standard memset of
zero values, but takes a long time doing so.
Call out to the `llvm.memset` function to zero out the memory instead.
This is a [breaking-change] since `std::dynamic_lib::dl` is now
private.
When `LoadLibraryW()` fails, original code called `errno()` to get error
code. However, there was local allocation of `Vec` before
`LoadLibraryW()`, and it drops before `errno()`, and the drop
(deallocation) changed `errno`! Therefore `dynamic_lib::open()` thought
it always succeeded.
This commit fixes the issue.
This commit also sets Windows error mode during `LoadLibrary()` to
prevent "dll load failed" dialog.
* add `Token::AndAnd` (double borrow)
* add `Token::DotDot` (range notation)
* remove `Token::Pound` and `Token::At`
This fixes a syntax error when parsing `fn f() -> RangeTo<i32> { return ..1; }`.
Also, remove `fn_expr_lookahead`.
It's from the `fn~` days and seems to no longer be necessary.
This fixes the issues mentioned in https://github.com/rust-lang/rust/pull/21236, as well as the one https://github.com/rust-lang/rust/issues/21230 where `CFG_BOOTSTRAP_KEY` was being set to simply 'N'. It changes the build such that `RUSTC_BOOTSTRAP_KEY` is only exported on -beta and -stable, so that the behavior of the -dev, -nightly, and snapshot compilers is the same everywhere.
Haven't run it completely through 'make check' yet, but the I have verified that the aforementioned issues are fixed.
r? @alexcrichton cc @eddyb
Please review carefully. Contains unsafe and is my first commit to Rust.
Uses ptr::copy_nonoverlapping_memory. Attempts to handle zero-size types correctly.
"Idiomatic code should not use extra whitespace in the middle of a line to provide alignment."
http://aturon.github.io/style/whitespace.html
I realize the linked page still needs an RFC, but the docs should be written in accordance with the guidelines nevertheless.
In accordance with [collections reform part 2][rfc] this macro has been moved to
an external [bitflags crate][crate] which is [available though
crates.io][cratesio]. Inside the standard distribution the macro has been moved
to a crate called `rustc_bitflags` for current users to continue using.
[rfc]: https://github.com/rust-lang/rfcs/blob/master/text/0509-collections-reform-part-2.md
[crate]: https://github.com/rust-lang/bitflags
[cratesio]: http://crates.io/crates/bitflags
The major user of `bitflags!` in terms of a public-facing possibly-stable API
today is the `FilePermissions` structure inside of `std::io`. This user,
however, will likely no longer use `bitflags!` after I/O reform has landed. To
prevent breaking APIs today, this structure remains as-is.
Current users of the `bitflags!` macro should add this to their `Cargo.toml`:
bitflags = "0.1"
and this to their crate root:
#[macro_use] extern crate bitflags;
Due to the removal of a public macro, this is a:
[breaking-change]
The example of the `Index` and `IndexMut` trait contained too much `Foo`.
It now contains a bit more `Bar` to make things clearer which parts are
defining the type of the index.
I searched for times when we were hiding functions with # in the documentation,
and fixed them to not use it unless neccesary.
I also made random improvements whenever I changed something. For example,
I changed Example to Examples, for consistency.
Fixes#13423
Replace deprecated integer suffixes. Remove integer type notations
altogether where possible. Replace uses of deprecated `range()`
function with range notation.
* Use range notation instead of deprecated `range()`
* Remove deprecated `u` integer suffixes used in ranges
* Replace deprecated `i` integer suffixes with `is` for vector numbers
`Thread::spawn()` still gives "use of unstable item" warning which I
hadn't found a way to fix.
The collections were promoted to stable by mistake and do not match RFC 509.
This reverts the stability back to unstable.
[breaking-change] since previously stable API became unstable.
Fixes#21193