Commit Graph

47226 Commits

Author SHA1 Message Date
Ahmed Charles
5ea1f9ffed Run rustfmt on liballoc_jemalloc. 2015-10-11 22:18:51 -07:00
Ahmed Charles
5dcd406188 Run rustfmt on liballoc. 2015-10-11 22:11:59 -07:00
Ahmed Charles
21bb0dcc12 Run rustfmt on libarena. 2015-10-11 19:33:51 -07:00
bors
81b3b27cf5 Auto merge of #28969 - chrisccerami:link_to_ffi_in_concurrency_chapter, r=steveklabnik 2015-10-11 23:20:28 +00:00
bors
c413bb4fff Auto merge of #28973 - nrc:match-source, r=Manishearth
r? @Manishearth
2015-10-11 21:35:48 +00:00
Nick Cameron
254a10b318 Properly set the MatchSource for for loops 2015-10-12 09:49:29 +13:00
bors
8fbb35b835 Auto merge of #28960 - barosl:home-temp-dir-doc, r=alexcrichton
This concern was raised by #28940.
2015-10-11 19:51:22 +00:00
bors
9dafceb1f9 Auto merge of #28948 - steveklabnik:gh28944, r=alexcrichton
"Crate features" isn't a thing in Rust, but you do need to add this line
to your crate root.

Fixes #28944
2015-10-11 18:06:51 +00:00
Chris C Cerami
42e3f1dfae Link to FFI in Concurrency chapter 2015-10-11 13:23:57 -04:00
bors
603582776a Auto merge of #28966 - ykomatsu:trpl, r=steveklabnik 2015-10-11 16:20:13 +00:00
bors
84ff665558 Auto merge of #28964 - eminence:docfix, r=sfackler
r? @steveklabnik
2015-10-11 14:32:45 +00:00
Yoshito Komatsu
9652fc1d49 Fix some typos 2015-10-11 22:38:44 +09:00
bors
db6c7124b4 Auto merge of #28965 - bluss:ptr-write-doc, r=huonw
core: Update the safety docs for core::ptr::write

Updated to reflect that not dropping a value is safe (but discouraged).
2015-10-11 11:45:26 +00:00
Ulrik Sverdrup
4dee42fe58 core: Update the safety docs for core::ptr::write
Updated to reflect that not dropping a value is safe (but discouraged).
2015-10-11 13:40:47 +02:00
Andrew Chin
dce58baff0 Trivial typo fix: from_utrf8 should be from_utf8 2015-10-10 23:33:43 -04:00
Barosl Lee
8667aa207b Clarify the behavior of std::env::home_dir and std::env::temp_dir
This concern was raised by #28940.
2015-10-11 09:46:23 +09:00
bors
9d3e79ad37 Auto merge of #28941 - jcaudle:rustfmt/librand-distributions-normal, r=nrc
This is my first PR to rust and first collaboration on a rust project, but I think the formatting looked ok. If this works out, I hope to go through more of librand.
2015-10-10 22:39:35 +00:00
bors
f0ae44ab93 Auto merge of #28949 - iwillspeak:rustfmt-libflate, r=nrc
This commit updates the libflate crate with the formatting output of
`rustfmt`.

r? @nrc
2015-10-10 19:55:37 +00:00
Will Speak
e3af117f4d Update Libflate Formatting
This commit updates the libflate crate with the formatting output of
`rustfmt`.
2015-10-10 19:00:20 +01:00
Steve Klabnik
988ab562eb Diagnostic change: crate features -> crate root
"Crate features" isn't a thing in Rust, but you do need to add this line
to your crate root.

Fixes #28944
2015-10-10 13:35:40 -04:00
bors
1302187673 Auto merge of #28945 - shama:doc-typos, r=steveklabnik
Just a few typos found in the docs. Thanks!
2015-10-10 16:40:05 +00:00
Kyle Robinson Young
a6aa6456ee doc: fixing typos 2015-10-10 09:15:55 -07:00
bors
e3cd872418 Auto merge of #28922 - panicbit:trpl-missing-docs, r=steveklabnik 2015-10-10 14:51:42 +00:00
bors
e6abcbcb21 Auto merge of #28938 - GlenDC:master, r=Manishearth
Here is my attempt to resolve issue #28822, @Manishearth.
Please let me know if it's fine. And if not, what should I do instead?

This issue felt like quite a good start for some rust contributions. It allows me to get used to the workflow  and codebase of rust in an easy-to-swallow manner. Are there any other issues you would recommend me to look at? :) Would love to do some more stuff!
2015-10-10 12:02:24 +00:00
glendc
55546362d9 Whitelisting PatWild for E0022. Fix #28822 2015-10-10 09:27:24 +00:00
bors
8091cb139f Auto merge of #28930 - steveklabnik:update_pr, r=steveklabnik
https://github.com/rust-lang/rust/pull/27813#issuecomment-146842041
2015-10-10 07:56:49 +00:00
bors
39376de485 Auto merge of #28920 - dotdash:const_align, r=eddyb
For enum variants, the default alignment for a specific variant might be
lower than the alignment of the enum type itself. In such cases we, for
example, generate memcpy calls with an alignment that's higher than the
alignment of the constant we copy from.

To avoid that, we need to explicitly set the required alignment on
constants.

Fixes #28912.
2015-10-10 06:07:40 +00:00
bors
840d29eab6 Auto merge of #28928 - ykomatsu:trpl, r=Manishearth 2015-10-10 04:15:33 +00:00
Joseph Caudle
928e4b2541 Run rustfmt on librand/distributions/normal.rs 2015-10-10 00:01:57 -04:00
bors
b6fd615b8a Auto merge of #28932 - barosl:empty-comment, r=alexcrichton
Previously, `/**/` was incorrectly regarded as a doc comment because it starts with `/**` and ends with `*/`. However, this caused an ICE because some code assumed that the length of a doc comment is at least 5. This commit adds an additional check to `is_block_doc_comment` that tests the length of the input.

Fixes #28844.
2015-10-10 02:29:37 +00:00
bors
87cd2c0827 Auto merge of #28861 - pnkfelix:fsk-nonparam-dropck-issue28498, r=arielb1
implement RFC 1238: nonparametric dropck.

cc #28498 

cc @nikomatsakis
2015-10-10 00:39:29 +00:00
Björn Steinbrink
6ad079e341 Set proper alignment on constants
For enum variants, the default alignment for a specific variant might be
lower than the alignment of the enum type itself. In such cases we, for
example, generate memcpy calls with an alignment that's higher than the
alignment of the constant we copy from.

To avoid that, we need to explicitly set the required alignment on
constants.

Fixes #28912.
2015-10-10 01:15:36 +02:00
bors
439311d938 Auto merge of #28049 - steveklabnik:doc_write, r=alexcrichton 2015-10-09 22:15:24 +00:00
Björn Steinbrink
7ff4524e54 Use a proper C string for the gdb script section name 2015-10-09 23:25:57 +02:00
Barosl Lee
c7fa52df34 Prevent /**/ from being parsed as a doc comment
Previously, `/**/` was incorrectly regarded as a doc comment because it
starts with `/**` and ends with `*/`. However, this caused an ICE
because some code assumed that the length of a doc comment is at least
5. This commit adds an additional check to `is_block_doc_comment` that
tests the length of the input.

Fixes #28844.
2015-10-10 04:49:31 +09:00
bors
7dcc4d7dcb Auto merge of #28926 - DanielKeep:syntax-index, r=steveklabnik
The intent with this chapter is to have a central place where users can
go to find out what a random bit of syntax means, be it a keyword,
symbol, or some unusual bit of composite syntax (like `for <...>`).  This
should be useful both for new users (who may not know what to call this
weird `'blah` thing), and for experienced users (who may just wish to
link someone to the appropriate section on `Trait + Trait` bounds).

Where possible, entries have been linked to an appropriate section of
the book which explains the syntax.  This was not possible in all cases.
If an entry is missing links, that's because I was unable to *find*
anything appropriate to link to.

This commit should include all stable keywords, operators and symbols,
as well as a selection of potentially confusing or unusual syntax.
2015-10-09 19:28:43 +00:00
Steve Klabnik
ef9e542b45 Improve docs for write!/writeln! macros 2015-10-09 13:53:25 -04:00
bors
e3376d8a13 Auto merge of #28929 - pnkfelix:expand-legal-cycles-test, r=alexcrichton
Major revision to the dropck_legal_cycles test.

1. Added big comment block explaining the test framework.

2. Added tests exericising Rc and Arc. This was inspired by a comment
   from eefriedman on PR #28861.

3. Made the cycle-detection not issue false-positives on acyclic dags.

   Doing this efficiently required revising the framework; instead of
   visiting all children (i.e. doing a traversal), now each test is
   responsible for supplying the path that will act as a witness to
   the cycle.

   Luckily for me, all of the pre-existing tests worked with a trivial
   path built from "always tke your first left", but new tests I added
   did require other input paths (i.e., "first turn right, then left".

   (The path representation is a bit-string and its branches are
    n-ary, not word phrases and binary branches as you might think
    from the outline above.)

cc PR #27185
2015-10-09 17:07:48 +00:00
Felix S. Klock II
a445f234a6 review comment: further refinement of comment above fn is_adt_dtorck. 2015-10-09 18:42:14 +02:00
Felix S. Klock II
34076bc0c9 Added the param-blindness attribute to Rc and Arc.
This was proven necessary after I added `Rc` and `Arc` to the rpass
test `dropck_legal_cycles.rs`; see PR #28929.
2015-10-09 18:10:52 +02:00
Jonathan Hansford
22fbbd4b5c Some tidying up
Improving the use of 2nd and 3rd person
Adding a few contractions to make the text less formal
Tidying up some notes
Providing a little bit more clarification for Windows users
2015-10-09 12:06:51 -04:00
Jonathan Hansford
f116ab58b2 2nd to 3rd person
Replacing all references to the 2nd person with references to the 3rd
person (excluding `authors = [ "Your name <you@example.com>" ]` and
`file:///home/yourname/projects/hello_world` in `hello-cargo.md`)
2015-10-09 12:06:05 -04:00
Felix S. Klock II
098a7a07ee Major revision to the dropck_legal_cycles test.
1. Added big comment block explaining the test framework.

2. Added tests exericising Rc and Arc. This was inspired by a comment
   from eefriedman on PR #28861.

3. Made the cycle-detection not issue false-positives on acyclic dags.

   Doing this efficiently required revising the framework; instead of
   visiting all children (i.e. doing a traversal), now each test is
   responsible for supplying the path that will act as a witness to
   the cycle.

   Luckily for me, all of the pre-existing tests worked with a trivial
   path built from "always tke your first left", but new tests I added
   did require other input paths (i.e., "first turn right, then left".

   (The path representation is a bit-string and its branches are
    n-ary, not word phrases and binary branches as you might think
    from the outline above.)
2015-10-09 18:04:18 +02:00
bors
3034541129 Auto merge of #27897 - sfackler:cursor-box-slice, r=alexcrichton 2015-10-09 13:07:07 +00:00
Steven Fackler
6b244d54e6 Implement Read, BufRead, Write and Seek for Cursor<Box<[u8]>> 2015-10-09 14:06:36 +01:00
Yoshito Komatsu
440b3fb277 Fix GitHub 2015-10-09 22:03:02 +09:00
panicbit
cf785d1a9f trpl: mention doc(hidden) 2015-10-09 14:08:32 +02:00
Felix S. Klock II
e1aba75a97 review comment: point out that the dropck analysis is now trivial. 2015-10-09 14:08:06 +02:00
Daniel Keep
2b5983423d Corrections to syntax index.
* removed reference to struct fields from `mut` description.
* changed `..` pattern example to not be syntactically bogus.
* changed `@` pattern example for similar reasons.

(Thanks petrochenkov)
2015-10-09 23:06:20 +11:00
panicbit
8dfe0ec8a8 trpl: missing documentation wording 2015-10-09 14:04:45 +02:00