- 21 1月, 2015 4 次提交
-
-
由 Brian Anderson 提交于
-
由 Brian Anderson 提交于
-
由 Brian Anderson 提交于
-
由 bors 提交于
Original [issue](https://github.com/rust-lang/rust/issues/19278) that inspired this patch. The [reference.md] has evolved past simple grammatical constructs, and it serves a different purpose. The intent for the proposed _grammar.md_ is to hold **only** the official reference for the language grammar. This document would keep track of grammatical changes to the language over time, facilitate discussions over proposed changes to the existing grammar, and serve as basis for building parsers by third-parties (IDE's, GitHub linguist, CodeMirror, etc.). The current state of the PR contains all the grammars that were available in [reference.md] and nothing else. There are still a lot of missing pieces that weren't available. The following are just a few of the definitions missing: - [Functions](https://github.com/icorderi/rust/blob/docs/grammar/src/doc/grammar.md#functions) - [Structures](https://github.com/icorderi/rust/blob/docs/grammar/src/doc/grammar.md#structures) - [Traits](https://github.com/icorderi/rust/blob/docs/grammar/src/doc/grammar.md#traits) - [Implementations](https://github.com/icorderi/rust/blob/docs/grammar/src/doc/grammar.md#implementations) - [Operators](https://github.com/icorderi/rust/blob/docs/grammar/src/doc/grammar.md#unary-operator-expressions) - [Statements](https://github.com/icorderi/rust/blob/docs/grammar/src/doc/grammar.md#statements) - [Expressions](https://github.com/icorderi/rust/blob/docs/grammar/src/doc/grammar.md#expressions) [reference.md]: https://github.com/rust-lang/rust/blob/master/src/doc/reference.md We need help from people familiar with those grammatical constructs to fill in the missing pieces.
-
- 20 1月, 2015 10 次提交
-
-
由 bors 提交于
Closes #21350
-
由 bors 提交于
The script is intended as a tool for doing every sort of verifications amenable to Rustdoc's HTML output. For example, link checkers would go to this script. It already parses HTML into a document tree form (with a slight caveat), so future tests can make use of it. As an example, relevant `rustdoc-*` run-make tests have been updated to use `htmldocck.py` and got their `verify.sh` removed. In the future they may go to a dedicated directory with htmldocck running by default. The detailed explanation of test scripts is provided as a docstring of htmldocck. cc #19723
-
由 bors 提交于
cc #19872, this may help give some insight
-
由 bors 提交于
These two attributes are used to change the entry point into a Rust program, but for now they're being put behind feature gates until we have a chance to think about them a little more. The #[start] attribute specifically may have its signature changed. This is a breaking change to due the usage of these attributes generating errors by default now. If your crate is using these attributes, add this to your crate root: #![feature(start)] // if you're using the #[start] attribute #![feature(main)] // if you're using the #[main] attribute cc #20064
-
由 bors 提交于
This commit aims to stabilize the `TypeId` abstraction by moving it out of the `intrinsics` module into the `any` module of the standard library. Specifically, * `TypeId` is now defined at `std::any::TypeId` * `TypeId::hash` has been removed in favor of an implementation of `Hash`. This commit also performs a final pass over the `any` module, confirming the following: * `Any::get_type_id` remains unstable as *usage* of the `Any` trait will likely never require this, and the `Any` trait does not need to be implemented for any other types. As a result, this implementation detail can remain unstable until associated statics are implemented. * `Any::downcast_ref` is now stable * `Any::downcast_mut` is now stable * `BoxAny` remains unstable. While a direct impl on `Box<Any>` is allowed today it does not allow downcasting of trait objects like `Box<Any + Send>` (those returned from `Thread::join`). This is covered by #18737. * `BoxAny::downcast` is now stable.
-
由 bors 提交于
importing object type string key maps is still supported writing them should be explicit, and can be done as follows ```rust let some_tree_map : TreeMap<String, Json> = ...; Json::Object(some_tree_map).to_writer(&mut writer); ``` related to #8335, #9028, #9142
-
由 bors 提交于
Closes #21033. The new strategy for parsing a field pattern is to look 1 token ahead and if it's a colon, parse as "fieldname: pat", otherwise parse the shorthand form "(box) (ref) (mut) fieldname)". The previous strategy was to parse "(ref) (mut) fieldname" then if we encounter a colon, throw an error if either "ref" or "mut" were encountered.
-
由 bors 提交于
Part of collections reform v1, #18424 Also, iteration is simplified: ``` before test btree::map::bench::iter_1000 ... bench: 17177 ns/iter (+/- 6302) test btree::map::bench::iter_100000 ... bench: 1735731 ns/iter (+/- 23908) test btree::map::bench::iter_20 ... bench: 386 ns/iter (+/- 148) after test btree::map::bench::iter_1000 ... bench: 15777 ns/iter (+/- 346) test btree::map::bench::iter_100000 ... bench: 1602604 ns/iter (+/- 73629) test btree::map::bench::iter_20 ... bench: 339 ns/iter (+/- 91) ``` cc @gereeter @cgaebel r? @Gankro
-
由 Tom Chittenden 提交于
-
由 Piotr Czarnecki 提交于
Simplify BTree's iterators, too.
-
- 19 1月, 2015 17 次提交
-
-
由 bors 提交于
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
-
由 Oliver 'ker' Schneider 提交于
-
由 Oliver 'ker' Schneider 提交于
-
由 Oliver 'ker' Schneider 提交于
Conflicts: src/libserialize/serialize.rs
-
由 Oliver 'ker' Schneider 提交于
-
由 bors 提交于
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
-
由 bors 提交于
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.
-
由 bors 提交于
This avoids having ast::Ty nodes which have no counterpart in the source.
-
由 Alex Crichton 提交于
This commit aims to stabilize the `TypeId` abstraction by moving it out of the `intrinsics` module into the `any` module of the standard library. Specifically, * `TypeId` is now defined at `std::any::TypeId` * `TypeId::hash` has been removed in favor of an implementation of `Hash`. This commit also performs a final pass over the `any` module, confirming the following: * `Any::get_type_id` remains unstable as *usage* of the `Any` trait will likely never require this, and the `Any` trait does not need to be implemented for any other types. As a result, this implementation detail can remain unstable until associated statics are implemented. * `Any::downcast_ref` is now stable * `Any::downcast_mut` is now stable * `BoxAny` remains unstable. While a direct impl on `Box<Any>` is allowed today it does not allow downcasting of trait objects like `Box<Any + Send>` (those returned from `Thread::join`). This is covered by #18737. * `BoxAny::downcast` is now stable.
-
由 Alex Crichton 提交于
-
由 Alex Crichton 提交于
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
-
由 Alex Crichton 提交于
Helps reduce some rightward drift
-
由 bors 提交于
This patch fixes IP_ADD_MEMBERSHIP problem described here: https://github.com/rust-lang/rust/issues/20381 I've tested on my ProbeR project, everything seems ok.
-
由 James Miller 提交于
-
由 James Miller 提交于
-
由 James Miller 提交于
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.
-
由 Alex Crichton 提交于
cc #19872, this may help give some insight
-
- 18 1月, 2015 9 次提交
-
-
由 Corey Richardson 提交于
Closes #21350
-
由 klutzy 提交于
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.
-
由 Seo Sanghyeon 提交于
-
由 bors 提交于
* 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.
-
由 bors 提交于
Follow up to #21008. r? @nikomatsakis
-
由 bors 提交于
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
-
由 Kang Seonghoon 提交于
-
由 bors 提交于
auto merge of #21330 : JeffBelgum/rust/collections-reform-issue-19986-add-append-and-split-off, r=Gankro Please review carefully. Contains unsafe and is my first commit to Rust. Uses ptr::copy_nonoverlapping_memory. Attempts to handle zero-size types correctly.
-
由 Brian Anderson 提交于
-