Commit graph

35172 commits

Author SHA1 Message Date
bors
92e9e70d15 auto merge of #19882 : steveklabnik/rust/fix_download, r=nikomatsakis
Thank you, @Ap0ph1s.
2014-12-15 19:12:44 +00:00
bors
1b97cd338b auto merge of #19785 : brson/rust/rollup, r=brson 2014-12-15 15:33:11 +00:00
Steve Klabnik
bd776b5090 Fix windows download links
Thank you, @Ap0ph1s.
2014-12-15 09:55:56 -05:00
Brian Anderson
1cb7e9fc63 rollup merge of #19814: jbranchaud/fix-a-typo-in-ownership-guide 2014-12-15 06:45:37 -08:00
Brian Anderson
f0bf34de9f rollup merge of #19812: frewsxcv/expansion-include-enum
In preparation for [removing the `std::cmp::Ordering` reexport](https://github.com/rust-lang/rust/issues/19253), this needs to be done to prevent errors like:

```
note: in expansion of #[deriving]
note: expansion site
error: unresolved name `std::cmp::Equal`
#[deriving(Clone, PartialEq, PartialOrd, Eq, Ord, Show)]
                                             ^~~
```
2014-12-15 06:45:36 -08:00
Brian Anderson
e52efe262d rollup merge of #19804: kballard/vim-new-unicode-escapes 2014-12-15 06:45:36 -08:00
Brian Anderson
74fde5e10d rollup merge of #19802: jbranchaud/add-btreeset-new-doctest 2014-12-15 06:45:36 -08:00
Brian Anderson
77d2a116c4 rollup merge of #19793: tomjakubowski/metadata-const-attrs
Fix #19773

Together with #19774 (which this is rebased on):

Fix #18156, fix #19722, fix #19185

r? @alexcrichton (since this was your suggestion!)
2014-12-15 06:45:36 -08:00
Brian Anderson
53982b64f3 rollup merge of #19787: akiss77/fix-i8-c_char
On AArch64, libc::c_char is u8. There are some places in the code where i8 is assumed, which causes compilation errors.

(AArch64 is not officially supported yet, but this change does not hurt any other targets and makes the code future-proof.)
2014-12-15 06:45:35 -08:00
Brian Anderson
0b214bfee0 rollup merge of #19784: csouth3/vim-syntax-iter
Vim still incorrectly highlights just `ExactSize` as a valid trait name, but the trait has been renamed to `ExactSizeIterator`.
2014-12-15 06:45:35 -08:00
Brian Anderson
e8e8677072 rollup merge of #19779: Noctune/master
The old PartialOrd impl for raw pointers would always return Some(_), so It might as well implement Ord too.
2014-12-15 06:45:35 -08:00
Brian Anderson
5691c0f49a rollup merge of #19775: SimonSapin/gedit-new-unicode-escape 2014-12-15 06:45:35 -08:00
Brian Anderson
3673486c6d rollup merge of #19774: tomjakubowski/rustdoc-consts-statics
Build `clean::ConstantItem` values in the `inline` module and
pretty-print the AST for inlined const items.

Doc strings are still missing from inlined constants (see #19773).

Partially address #18156, #19722, #19185

Fix #15821

r? @alexcrichton
2014-12-15 06:45:34 -08:00
Brian Anderson
7afee3a1ab rollup merge of #19771: jbranchaud/add-btreeset-iter-doctests 2014-12-15 06:45:34 -08:00
Brian Anderson
e717362ce5 rollup merge of #19763: csouth3/remove-featuregates
This is a revival of #19517 (per request of @alexcrichton) now that the new snapshots have landed.  We can now remove the last feature gates for if_let, while_let, and tuple_indexing scattered throughout the test sources since these features have been added to Rust.

Closes #19473.
2014-12-15 06:45:34 -08:00
Brian Anderson
1f349f6c71 rollup merge of #19754: steveklabnik/remove_sundown 2014-12-15 06:45:33 -08:00
Brian Anderson
8404ea66d9 rollup merge of #19746: steveklabnik/gh9266
Fixes #9266
2014-12-15 06:45:33 -08:00
Brian Anderson
cb2119823d rollup merge of #19738: steveklabnik/gh19717
Fixes #19717
2014-12-15 06:45:33 -08:00
Brian Anderson
36f7f1e301 rollup merge of #19735: sethpollack/patch-1 2014-12-15 06:45:33 -08:00
Brian Anderson
42f4d636fa rollup merge of #19714: steveklabnik/gh16219
These should be properly annotated instead.

Fixes #16219.
2014-12-15 06:44:21 -08:00
Brian Anderson
6c4a2bc55f rollup merge of #19710: steveklabnik/gh15449
Fixes #15499.
2014-12-15 06:44:20 -08:00
Brian Anderson
34dfa7addb rollup merge of #19709: steveklabnik/po4a_fix
This line was declared twice, which causes the build of i10n docs to
fail.
2014-12-15 06:44:20 -08:00
bors
ef0bc464af auto merge of #19778 : aochagavia/rust/ice, r=alexcrichton
Fixes #19734
2014-12-15 11:17:44 +00:00
bors
b677746b1e auto merge of #19750 : murarth/rust/rusti-support, r=brson
Makes a couple changes that support the implementation of a REPL:

* Implementation of wrapper code for LLVM ExecutionEngine API
* Fixing a change I made earlier to reset compiler state in `phase_1_[...]`
  instead of `compile_input` as the latter is not used in a REPL
2014-12-15 08:32:45 +00:00
bors
126db549b0 auto merge of #19742 : vhbit/rust/copy-for-bitflags, r=alexcrichton 2014-12-15 00:07:35 +00:00
bors
6085a71623 auto merge of #19703 : nikomatsakis/rust/unsafe-trait, r=acrichto
This PR allows declaring traits and impls as `unsafe`. An `unsafe` trait requires an `unsafe` impl. An `unsafe` impl does not permit unsafe code within its interior (unless that code is contained within an unsafe block or unsafe fn, as normal). The commits are standalone.

r? @alexcrichton 
cc #13231
2014-12-14 19:07:29 +00:00
Niko Matsakis
7855893ac7 Add a bunch of new tests per Alex's suggestion. 2014-12-14 11:11:55 -05:00
Niko Matsakis
5fe0ad1c0f Implement unsafe trait semantics. 2014-12-14 11:11:55 -05:00
Niko Matsakis
22f777ba2e Parse unsafe impl but don't do anything particularly interesting with the results. 2014-12-14 11:11:55 -05:00
Niko Matsakis
5686a91914 Parse unsafe trait but do not do anything with it beyond parsing and integrating into rustdoc etc. 2014-12-14 11:11:55 -05:00
Niko Matsakis
092d04a40a Rename FnStyle trait to Unsafety. 2014-12-14 11:11:55 -05:00
bors
93c0610096 auto merge of #19725 : vadimcn/rust/inst-path, r=alexcrichton
Change default installation directory to %SYSTEMDRIVE%\Rust.
Modify user PATH, rather than system PATH.
2014-12-14 16:07:32 +00:00
bors
52f7a4a351 auto merge of #19338 : nikomatsakis/rust/unboxed-closure-purge-the-proc, r=acrichto
They are replaced with unboxed closures.

cc @pcwalton @aturon 

This is a [breaking-change]. Mostly, uses of `proc()` simply need to be converted to `move||` (unboxed closures), but in some cases the adaptations required are more complex (particularly for library authors). A detailed write-up can be found here: http://smallcultfollowing.com/babysteps/blog/2014/11/26/purging-proc/

The commits are ordered to emphasize the more important changes, but are not truly standalone.
2014-12-14 11:37:27 +00:00
bors
3a9305ce82 auto merge of #19690 : barosl/rust/struct-variant-as-a-function-ice, r=alexcrichton
Unlike a tuple variant constructor which can be called as a function, a struct variant constructor is not a function, so cannot be called.

If the user tries to assign the constructor to a variable, an ICE occurs, because there is no way to use it later. So we should stop the constructor from being used like that.

A similar mechanism already exists for a normal struct, as it prohibits a struct from being resolved. This commit does the same for a struct variant.

This commit also includes some changes to the existing tests.

Fixes #19452.
2014-12-14 09:22:24 +00:00
Niko Matsakis
f6d60f3208 Stop using diagnostics to avoid merge conflicts. 2014-12-14 04:21:57 -05:00
Niko Matsakis
840ce00a9b Temporarily remove issue #14039; it is fixed and re-added by PR #19438 2014-12-14 04:21:57 -05:00
Niko Matsakis
9c9253e859 Add some tests for obsolete code, sugar used in appropriate ways. 2014-12-14 04:21:57 -05:00
Niko Matsakis
0fefd835f2 Update emacs and vi modes. 2014-12-14 04:21:57 -05:00
Niko Matsakis
112faabf94 Update guide/intro to take into account the removal of proc.
cc @steveklabnick
2014-12-14 04:21:57 -05:00
Niko Matsakis
27676d9aa9 Delete tests that are either no longer relevant or which have
duplicate tests around object types.
2014-12-14 04:21:56 -05:00
Niko Matsakis
5c3d398919 Mostly rote conversion of proc() to move|| (and occasionally Thunk::new) 2014-12-14 04:21:56 -05:00
Niko Matsakis
394f6846b8 Rewrite WorkItem not to use proc(). 2014-12-14 04:21:56 -05:00
Niko Matsakis
d8e51ea0e2 Patch rustdoc to include missing types, make the match exhaustive
to prevent such oversights in the future.
2014-12-14 04:21:56 -05:00
Niko Matsakis
d258d68db6 Remove proc types/expressions from the parser, compiler, and
language. Recommend `move||` instead.
2014-12-14 04:21:56 -05:00
Niko Matsakis
9cc8453a78 Adjust feature gates to allow for parenthetical notation to be used
with the fn traits
2014-12-14 04:21:56 -05:00
Niko Matsakis
698db04a8d Purge the hack that allows FnOnce to be used with a by-value self method. Besides being yucky, it will cause problems if we try to make all traits implement themselves, which would make a lot of things in life easier. Also, it was inextricably linked to Box, which was not the intention. We can work around its absence, so better to reimplement it later in a more thorough fashion. 2014-12-14 04:21:56 -05:00
Niko Matsakis
d61338172f Rewrite threading infrastructure, introducing Thunk to represent
boxed `FnOnce` closures.
2014-12-14 04:21:56 -05:00
bors
10ac5b72f1 auto merge of #19677 : japaric/rust/deprecate-tupleN, r=alexcrichton
r? @alexcrichton or anyone else
closes #18006
2014-12-14 07:07:31 +00:00
bors
f07526a999 auto merge of #19669 : alfie/rust/master, r=sanxiyn 2014-12-14 01:07:31 +00:00
Jorge Aparicio
029789b98c Get rid of all the remaining uses of refN/valN/mutN/TupleN 2014-12-13 20:04:41 -05:00