Commit Graph

39596 Commits

Author SHA1 Message Date
Manish Goregaokar
340d1cc7d7 Fix tag align tests for 32bit linux (fixes #7340) 2015-03-05 17:09:12 +05:30
Niko Matsakis
9b332ff2c7 Address nits by @nrc. 2015-03-05 05:46:12 -05:00
Valerii Hiora
3f4181a6e5 iOS: open file on aarch64 breaks permissions
According to Apple arm64 calling convention varargs always are passed
through stack. Since `open` is actually a vararg function on Darwin's,
it means that older declaration caused permissions to be taken from
stack, while passed through register => it set file permissions
to garbage and it was simply impossible to read/delete files after they
were created.

They way this commit handles it is to preserve compatibility with
existing code - it simply creates a shim unsafe function so all existing
callers continue work as nothing happened.
2015-03-05 12:41:59 +02:00
Kang Seonghoon
9e28156551 rustdoc: Move sidebar items into shared JavaScript.
It had been a source of huge bloat in rustdoc outputs. Of course,
we can simply disable compiler docs (as `rustc` generates over 90M
of HTML) but this approach fares better even after such decision.

Each directory now has `sidebar-items.js`, which immediately calls
`initSidebarItems` with a JSON sidebar data. This file is shared
throughout every item in the sidebar. The current item is
highlighted via a separate JS snippet (`window.sidebarCurrent`).
The JS file is designed to be loaded asynchronously, as the sidebar
is rendered before the content and slow sidebar loading blocks
the entire rendering. For the minimal accessibility without JS,
links to the parent items are left in HTML.

In the future, it might also be possible to integrate crates data
with the same fashion: `sidebar-items.js` at the root path will do
that. (Currently rustdoc skips writing JS in that case.)

This has a huge impact on the size of rustdoc outputs. Originally
it was 326MB uncompressed (37.7MB gzipped, 6.1MB xz compressed);
it is 169MB uncompressed (11.9MB gzipped, 5.9MB xz compressed) now.
The sidebar JS only takes 10MB uncompressed & 0.3MB gzipped.
2015-03-05 16:35:43 +09:00
Manish Goregaokar
455aa62e4d Rollup merge of #23033 - pelmers:patch-3, r=steveklabnik
I came across a couple of grammar mistakes when refreshing myself on enums.
2015-03-05 12:39:07 +05:30
Manish Goregaokar
8a55fce389 Rollup merge of #23029 - vhbit:ios-env-stab, r=alexcrichton
"body": null,
2015-03-05 12:39:07 +05:30
Manish Goregaokar
acd9554fd6 Rollup merge of #23027 - fenhl:patch-1, r=sfackler
The docs for `std::time::duration::Duration::weeks` were formatted incorrectly.
2015-03-05 12:39:06 +05:30
Manish Goregaokar
4c2bd63d17 Rollup merge of #23006 - dhuseby:master, r=alexcrichton
as the subject says.
2015-03-05 12:39:06 +05:30
Manish Goregaokar
44f8ac0b4d Rollup merge of #22947 - ic:master, r=steveklabnik
Changed guaranteed for \"quaranteed\", and
Made failing/working examples look alike.

r? @steveklabnik
2015-03-05 12:39:06 +05:30
Manish Goregaokar
eab5d0d0ae Rollup merge of #22937 - MDCox:str-docs, r=steveklabnik
Fixes #22902
r? @steveklabnik
2015-03-05 12:39:06 +05:30
Manish Goregaokar
faca553a01 Rollup merge of #22994 - eddyb:unsuffix-ints-good, r=alexcrichton
Automatic has-same-types testing methodology can be found in #22501.
Because most of them don't work with `--pretty=typed`, compile-fail tests were manually audited.

r? @aturon
2015-03-05 12:39:05 +05:30
Manish Goregaokar
931c55ab00 Move span in error (fixup #22764) 2015-03-05 12:38:36 +05:30
Manish Goregaokar
3d3ccfff9e Rollup merge of #23006 - dhuseby:master, r=alexcrichton
as the subject says.
2015-03-05 12:38:36 +05:30
Dave Huseby
13720b5571 updating llvm-auto-clean-trigger too 2015-03-05 12:38:35 +05:30
Dave Huseby
07e51ec7e0 adding bitrig snapshot to snapshots file 2015-03-05 12:38:35 +05:30
Dave Huseby
4ca07af526 bumping again to get the updated configure 2015-03-05 12:38:35 +05:30
Dave Huseby
a73fc0fe83 bumping the jemalloc revision to include the bitrig changes 2015-03-05 12:38:35 +05:30
Manish Goregaokar
ca13fd2a07 Rollup merge of #22973 - djmally:coll_docs, r=Gankro 2015-03-05 12:38:34 +05:30
Dave Huseby
5d003c6f79 updating llvm submodule to include bitrig support 2015-03-05 12:38:34 +05:30
Manish Goregaokar
145b83e633 Rollup merge of #22994 - eddyb:unsuffix-ints-good, r=alexcrichton
Automatic has-same-types testing methodology can be found in #22501.
Because most of them don't work with `--pretty=typed`, compile-fail tests were manually audited.

r? @aturon
2015-03-05 12:38:33 +05:30
Eduard Burtescu
34410ec748 Fix compile-fail error messages after integer suffix removal. 2015-03-05 12:38:33 +05:30
Eduard Burtescu
e64670888a Remove integer suffixes where the types in compiled code are identical. 2015-03-05 12:38:33 +05:30
Manish Goregaokar
c8c4d85b50 Rollup merge of #22764 - ivanradanov:fileline_help, r=huonw
When warnings and errors occur, the associated help message should not print the same code snippet.
https://github.com/rust-lang/rust/issues/21938
2015-03-05 12:38:32 +05:30
Manish Goregaokar
4de4234795 Rollup merge of #23018 - sanxiyn:quote-question, r=huonw
Fix #22957.
2015-03-05 12:38:32 +05:30
Seo Sanghyeon
951118b74f Fix quoting of ?Sized 2015-03-05 12:38:30 +05:30
Manish Goregaokar
71ef0734e7 Rollup merge of #23013 - nikomatsakis:syncbox, r=pnkfelix
When generating WF criteria, do not visit the same type more than once. Fixes an infinite stack overflow (#23003).

r? @aturon
2015-03-05 12:37:49 +05:30
Manish Goregaokar
bedfca0fb3 Rollup merge of #23004 - alexcrichton:libc-stable, r=brson
This same source is being built in the Cargo ecosystem and hence needs to build
on stable Rust as well. This commit places the `no_std` attribute along with the
`no_std` feature behind a `cfg_attr` flag so they are not processed when
compiled on crates.io
2015-03-05 12:37:49 +05:30
Manish Goregaokar
24f00eb2ae Rollup merge of #23001 - alexcrichton:index-output-stable, r=nikomatsakis
This stability attribute was left out by accident and the stability pass has
since picked up the ability to check for this. As a result, crates are currently
getting warnings for implementations of `Index`.
2015-03-05 12:37:49 +05:30
Manish Goregaokar
bb459bf95b Rollup merge of #23000 - Florob:unicode-FL, r=brson
This handles the ranges contained in UnicodeData.txt.
Counterintuitively this actually makes the tables shorter.
2015-03-05 12:37:48 +05:30
Manish Goregaokar
478c396b7a Rollup merge of #22939 - bleibig:grammar-updates, r=sanxiyn
Updates to the bison grammar to account for recent grammar additions and new tests. In particular:

* Support parsing `impl MyTrait for .. { }`
* Support parsing ExprQualifiedPaths without \"as TRAIT_REF\" such as `<Foo>::bar(&Foo)`
* Support parsing \"for\" clauses at the beginning of where clauses such as `where for<'a, 'b> &'a T: Bar<'b>`
2015-03-05 12:37:48 +05:30
Manish Goregaokar
d693ec17a5 Rollup merge of #22029 - iKevinY:tidy-changes, r=brson
Currently, the list of files linted in `tidy.py` is unordered. It seems more appropriate for more frequently appearing files (like `.rs`) to appear at the top of the list and for \"other files\" to appear at the very end. This PR also changes the wildcard import of `check_license()` into an explicit one.

```
Before:                     After:
* linted 4 .sh files        * linted 5034 .rs files
* linted 4 .h files         * linted 29 .c files
* linted 29 .c files        * linted 28 .py files
* linted 2 .js files        * linted 4 .sh files
* linted 0 other files      * linted 4 .h files
* linted 28 .py files       * linted 2 .js files
* linted 5034 .rs files     * linted 0 other files
```

r? @brson
2015-03-05 12:37:48 +05:30
bors
68740b4054 Auto merge of #22061 - pczarn:quote_matcher_and_attr, r=kmcallister
Fixes #19674
Fixes #17396 (already closed, yeah)

cc @kmcallister , @cmr
2015-03-05 04:32:51 +00:00
bors
cc722a4dd3 Auto merge of #22873 - alexcrichton:deprecate-fs, r=aturon
This commit deprecates the majority of std::old_io::fs in favor of std::fs and
its new functionality. Some functions remain non-deprecated but are now behind a
feature gate called `old_fs`. These functions will be deprecated once
suitable replacements have been implemented.

The compiler has been migrated to new `std::fs` and `std::path` APIs where
appropriate as part of this change.

[breaking-change]
2015-03-05 01:19:15 +00:00
Alex Crichton
0dfa9978cc std: Stabilize portions of the io module
The new `io` module has had some time to bake and this commit stabilizes some of
the utilities associated with it. This commit also deprecates a number of
`std::old_io::util` functions and structures.

These items are now `#[stable]`

* `Cursor`
* `Cursor::{new, into_inner, get_ref, get_mut, position, set_position}`
* Implementations of I/O traits for `Cursor<T>`
* Delegating implementations of I/O traits for references and `Box` pointers
* Implementations of I/O traits for primitives like slices and `Vec<T>`
* `ReadExt::bytes`
* `Bytes` (and impls)
* `ReadExt::chain`
* `Chain` (and impls)
* `ReadExt::take` (and impls)
* `BufReadExt::lines`
* `Lines` (and impls)
* `io::copy`
* `io::{empty, Empty}` (and impls)
* `io::{sink, Sink}` (and impls)
* `io::{repeat, Repeat}` (and impls)

These items remain `#[unstable]`

* Core I/O traits. These may want a little bit more time to bake along with the
  commonly used methods like `read_to_end`.
* `BufReadExt::split` - this function may be renamed to not conflict with
  `SliceExt::split`.
* `Error` - there are a number of questions about its representation,
  `ErrorKind`, and usability.

These items are now `#[deprecated]` in `old_io`

* `LimitReader` - use `take` instead
* `NullWriter` - use `io::sink` instead
* `ZeroReader` - use `io::repeat` instead
* `NullReader` - use `io::empty` instead
* `MultiWriter` - use `broadcast` instead
* `ChainedReader` - use `chain` instead
* `TeeReader` - use `tee` instead
* `copy` - use `io::copy` instead

[breaking-change]
2015-03-04 17:04:22 -08:00
Alex Crichton
95d904625b std: Deprecate std::old_io::fs
This commit deprecates the majority of std::old_io::fs in favor of std::fs and
its new functionality. Some functions remain non-deprecated but are now behind a
feature gate called `old_fs`. These functions will be deprecated once
suitable replacements have been implemented.

The compiler has been migrated to new `std::fs` and `std::path` APIs where
appropriate as part of this change.
2015-03-04 15:59:30 -08:00
David King
a037cdfcf1 Fix broken link in old rust guide
Having come back to rust recently after > 6months I was looking for docs
on tasks and stumbled upon this broken link.
2015-03-04 23:18:24 +00:00
Camille TJHOA
b1e0dfb25c docs(path.rs): fix ends_with method 2015-03-04 23:09:03 +01:00
Steve Klabnik
61a2766136 Note the alternate form of vec in trpl 2015-03-04 16:27:18 -05:00
Michał Krasnoborski
29938fff38 Fix struct stat on arm linux 2015-03-04 22:24:38 +01:00
Niko Matsakis
1d3de19e99 Add tests related to #20220. Fixes #20220. 2015-03-04 15:06:33 -05:00
Niko Matsakis
cd50b4e0b1 Generalize the code so we can handle multiple supertraits.
Fixes #10596. Fixes #22279.
2015-03-04 15:06:33 -05:00
Niko Matsakis
bc9ae36dba Separate supertrait collection from processing a TraitDef. This allows
us to construct trait-references and do other things without forcing a
full evaluation of the supertraits. One downside of this scheme is that
we must invoke `ensure_super_predicates` before using any construct that
might require knowing about the super-predicates.
2015-03-04 15:06:33 -05:00
Niko Matsakis
4ee002a17c Extract out trait_defines_associated_type_named into the AstConv
interface, so that we can perform this query without requiring a full
trait def or set of supertraits.
2015-03-04 15:05:52 -05:00
Niko Matsakis
ab8a769c57 Extend the "treat-err-as-bug" option to cover calls to fatal. 2015-03-04 15:05:52 -05:00
Niko Matsakis
4dfa81f6fa Extract out the filter_to_traits functionality 2015-03-04 15:05:52 -05:00
Niko Matsakis
ba1b5ee1d1 Simplify impl of Elaborator now that we don't need stack traces anymore. 2015-03-04 15:05:52 -05:00
Steve Klabnik
977d7897fe TRPL: Documentation
This chapter covers writing documentation in depth.

Fixes #4361
Fixes #12862
Fixes #14070
Fixes #14967
2015-03-04 13:32:43 -05:00
Peter Elmers
299b594fde Fix grammar nits in compound-data-types.md
I came across a couple of grammar mistakes when refreshing myself on enums.
2015-03-04 11:02:31 -06:00
Matt Cox
433392afd8 Reword str docs and include links to StrExt 2015-03-04 08:15:58 -08:00
Dave Huseby
e0a0b4683e updating llvm-auto-clean-trigger too 2015-03-04 07:50:34 -08:00