Commit Graph

41353 Commits

Author SHA1 Message Date
Alex Crichton
700e627cf7 test: Fixup many library unit tests 2015-04-14 10:14:19 -07:00
Alex Crichton
dddfbe0441 syntax: Remove derive(Rand) 2015-04-14 10:14:19 -07:00
Alex Crichton
adcd67272e test: Fix fallout in run-pass tests 2015-04-14 10:14:19 -07:00
Alex Crichton
84a89ed3ef compiletest: Re-add raise_fd_limit
This apparently fixes obscure bugs on OSX!
2015-04-14 10:14:11 -07:00
Alex Crichton
0516c4099e std: Reexport some unstable rand functionality for now
Needed to get modules like rustc_back::tempdir compiling.
2015-04-14 10:14:11 -07:00
Alex Crichton
359ab0b56b rustc_back: Rewrite realpath to not use old_io
Just bind the relevant platform-specific functions we should probably be calling
anyway.
2015-04-14 10:14:11 -07:00
Alex Crichton
bf4e77d4b5 std: Remove old_io/old_path/rand modules
This commit entirely removes the old I/O, path, and rand modules. All
functionality has been deprecated and unstable for quite some time now!
2015-04-14 10:14:11 -07:00
Felix S. Klock II
0610ee490e Regression tests for wrapping_* operations for integer types. 2015-04-14 18:44:42 +02:00
Felix S. Klock II
d8122ee87d Fix bug in wrapping_div
See discussion, albeit one-sided, in:

  https://github.com/rust-lang/rfcs/issues/964
2015-04-14 18:44:14 +02:00
Steve Klabnik
8b6987aced copyediting: structs 2015-04-14 11:25:38 -04:00
Aaron Turon
a9fd41e1f9 Fallout: move from scoped to spawn 2015-04-14 08:15:45 -07:00
bors
dabf0c6371 Auto merge of #24312 - rprichard:destabilize-format-args, r=alexcrichton
Fixes #22953.
2015-04-14 14:41:15 +00:00
Thomas Jespersen
bed2d33523 Add "run-make" test for trace-macros flag 2015-04-14 15:40:10 +02:00
Thomas Jespersen
d14109ec7e Add "trace-macros" as a compiler flag
Fixes #22619
2015-04-14 15:36:38 +02:00
Felix S. Klock II
4991c7acad Remaining API additions for int overflow:
`wrapping_div`, `wrapping_rem`, `wrapping_neg`,
  `wrapping_shl`, `wrapping_shr`.

All marked unstable under `core` feature for now (with expectation of
being marked as stable by 1.0 release).
2015-04-14 14:46:47 +02:00
Felix S. Klock II
d82f9123b2 Fallout from this change. 2015-04-14 14:23:02 +02:00
bors
47551b5745 Auto merge of #24261 - nrc:coerce-refactor, r=nikomatsakis
@eddyb's preparatory work for DST coercions

r? @nikomatsakis
2015-04-14 11:16:57 +00:00
Felix S. Klock II
58dc3bb575 Regression tests for issues that led me to revise typeck.
Close #23729
Close #23827
Close #24356
2015-04-14 12:49:26 +02:00
Nick Cameron
b35a587da1 Reviewer comments 2015-04-14 22:17:08 +12:00
Nick Cameron
4ad4363870 Better explanation of AutoDerefRef 2015-04-14 21:55:42 +12:00
Nick Cameron
73c2e768d6 Rebased 2015-04-14 21:55:42 +12:00
Eduard Burtescu
4e8e64140f eddyb's refactoring of coercions/adjustments 2015-04-14 21:55:42 +12:00
Felix S. Klock II
32d5f742cb typeck: Do high-level structural/signature checks before function body checks.
This avoids various ICEs, e.g. premature calls to cat_expr that yield
the dreaded "cat_expr Errd" ICE.
2015-04-14 11:20:21 +02:00
bors
a9d8065633 Auto merge of #24408 - richo:configure-optimize-default, r=pnkfelix
Optimization is now on by default. Closes #24405
2015-04-14 09:05:22 +00:00
Richo Healey
fd69ac160b configure: Turn optimization back on iff --enable-optimize 2015-04-14 00:58:57 -07:00
Richo Healey
87efd2cd74 configure: Set CFG_<FOO>_PROVIDED if it was supplied
This allows you to distinguish between an option that defaulted, and an
option selected by the user
2015-04-14 00:58:51 -07:00
Richo Healey
71a4ea56c2 configure: Don't disable optimizations when enabling debug
Optimization is now on by default. Closes #24405
2015-04-14 00:07:27 -07:00
bors
a4eb5a66a5 Auto merge of #24295 - contradictioned:master, r=alexcrichton
As i proposed in #24262 (and found acceptance in the IRC channel), added a compiler warning for wrong escaping of curly braces.
2015-04-14 06:54:20 +00:00
bors
5dc8060e3f Auto merge of #24287 - brson:beta, r=steveklabnik
r? @steveklabnik

Should land this, https://github.com/rust-lang/rust/pull/24270, and https://github.com/rust-lang/rust/pull/24245 before rolling another beta.
2015-04-14 04:42:06 +00:00
fenduru
ab93a51068 Point to From trait in error handling guide
Not sure if `From<Error>` is the correct way to reference that trait (maybe `From<E: Error>`?)
2015-04-13 22:01:20 -04:00
Brian Anderson
942c97bce5 Make use of the stability attributes issue a deprecation warning. #22830 2015-04-13 18:42:48 -07:00
Steve Klabnik
00867b312c Fix up nightly installation instructions.
The two-step command left off the nightly flag :frown:

Thanks @mdinger
2015-04-13 21:23:44 -04:00
bors
e6a8124028 Auto merge of #24251 - alexcrichton:unsafe-from-raw-fd, r=aturon
As pointed out in [RFC issue 1043][rfc] it is quite useful to have the standard
I/O types to provide the contract that they are the sole owner of the underlying
object they represent. This guarantee enables writing safe interfaces like the
`MemoryMap` API sketched out in that issue.

[rfc]: https://github.com/rust-lang/rfcs/issues/1043

As constructing objects from these raw handles may end up violating these
ownership gurantees, the functions for construction are now marked unsafe.

[breaking-change]
Closes rust-lang/rfcs#1043
2015-04-14 00:07:50 +00:00
Steve Klabnik
8a65029fac Link RBE more prominently
It's no longer a community based project.

Also, Rust for Rubyists is deprecated at this point, so we shouldn't
link to it anymore.
2015-04-13 18:33:37 -04:00
rundrop1
57e3475794 Update vectors.md
Feel silly because it's just one thing but it was bothering me that the documentation tells you what you're not going to learn now instead of linking to the item in question.  Am total noob pls assist, where is power button. :)
2015-04-13 17:14:53 -05:00
Nick Cameron
01678acf50 Expose visibility for fns in syntax::visit 2015-04-14 09:54:58 +12:00
Aaron Turon
6e0fb70ff6 Generalize spawn beyond unit closures
`thread::spawn` was previously restricted to closures that return `()`,
which limited the utility of joining on a spawned thread. However, there
is no reason for this restriction, and this commit allows arbitrary
return types.

Since it introduces a type parameter to `JoinHandle`, it's technically
a:

[breaking-change]

However, no code is actually expected to break.
2015-04-13 14:48:17 -07:00
Simonas Kazlauskas
32f7e673c8 Refine read_to_end documentation 2015-04-13 22:41:41 +03:00
Abhishek Chanda
f60f4b7d7c Fix check for globally routable IPv4 address
- Adds two more functions for broadcast address and special
  address classes reserved for documentation
- Modifies the globally routable IP check to include these
  new functions

Fixes #24314
2015-04-13 12:38:09 -07:00
Aaron Turon
6399bb425b De-stabilize thread::scoped and friends
Issue #24292 demonstrates that the `scoped` API as currently offered can
be memory-unsafe: the `JoinGuard` can be moved into a context that will
fail to execute destructors prior to the stack frame being popped (for
example, by creating an `Rc` cycle).

This commit reverts the APIs to `unstable` status while a long-term
solution is worked out.

(There are several possible ways to address this issue; it's not a
fundamental problem with the `scoped` idea, but rather an indication
that Rust doesn't currently provide a good way to ensure that
destructors are run within a particular stack frame.)

[breaking-change]
2015-04-13 12:15:28 -07:00
Andrew Paseltiner
6fa16d6a47 pluralize doc comment verbs and add missing periods 2015-04-13 13:57:51 -04:00
Erick Tryzelaar
951db77267 syntax: Publically expose printing where clauses, and add attr_to_string 2015-04-13 10:49:34 -07:00
bors
f55e66aaed Auto merge of #24198 - alexcrichton:windows-readlink, r=aturon
The current implementation of using GetFinalPathNameByHandle actually reads all
intermediate links instead of just looking at the current link. This commit
alters the behavior of the function to use a different API which correctly reads
only one level of the soft link.

[breaking-change]
2015-04-13 17:39:14 +00:00
Ariel Ben-Yehuda
39543e91f5 Don't try to suggest fields of an enum
Fixes #24365
2015-04-13 19:29:23 +03:00
bors
588d37c653 Auto merge of #24362 - alexcrichton:issue-24334, r=huonw
Make sure the unstable `scoped` modules isn't named the same as the `scoped`
function.

cc #24334
2015-04-13 14:57:13 +00:00
pez
883bb6568d remove duplicated linux sysconf mod 2015-04-13 15:17:45 +01:00
Manuel Hoffmann
4abade50d7 Added a help span which informs the user about the escaping of curly braces in a format string if a wrongly escaped one is detected in a string. 2015-04-13 15:56:10 +02:00
pez
6f54ce9aa5 added _SC_NPROCESSORS_ONLN constants for linux and macos for fix #24374 2015-04-13 14:24:47 +01:00
bors
b9ed9e2a32 Auto merge of #24351 - michaelwoerister:named-tuple-fields, r=alexcrichton
This PR makes `rustc` emit field names for tuple fields in DWARF. Formerly there was no way of directly accessing the fields of a tuple in GDB and LLDB since there is no C/C++ equivalent to this. Now, the debugger sees the name `__{field-index}` for tuple fields. So you can type for example `some_tuple_val.__2` to get the third tuple component.
When pretty printers are used (e.g. via `rust-gdb` or `rust-lldb`) these artificial field names will not clutter tuple rendering (which was the main motivation for not doing this in the past).

Solves #21948.
2015-04-13 12:39:49 +00:00
Björn Steinbrink
e891f29b95 Fix ICE when returning a variable whose declaration is unreachable
Fixes #24353
2015-04-13 13:07:41 +02:00