Commit Graph

44144 Commits

Author SHA1 Message Date
Steve Klabnik
49d8573dd2 Re-enable html literals test
It's now passing again.

Fixes #20673
2015-06-12 14:19:47 -04:00
Steve Klabnik
13b9a725ea Update dead-code-closure-bang
This stdlib function went away, so update it to use current syntax.
2015-06-12 14:16:49 -04:00
Steve Klabnik
bba934f19a ignore-test cleanup
Most of these are old, but some specific messages for specific tests:

* trait-contravariant-self.rs: failed due to a soundess hole:
  05e3248a79

* process-detatch: 15966c3c1f
  says "this test is being ignored until signals are implemented" That's
  not happening for a long time, and when it is, we'll write tests for
  it.

* deep-vector{,2}.rs: "too big for our poor macro infrastructure", and has
  been ignored over a year.

* borrowck-nested-calls.rs's FIXME #6268 was closed in favor of
  rust-lang/rfcs#811

* issue-15167.rs works properly now
* issue-9737.rs works properly now
* match-var-hygiene.rs works properly now

Addresses a chunk of #3965
2015-06-12 14:16:16 -04:00
Eli Friedman
3c69db4c3c Cleanup: rename middle::ty::sty and its variants.
Use camel-case naming, and use names which actually make sense in modern Rust.
2015-06-12 11:07:16 -07:00
Steve Klabnik
5a5499b36c Remove old runtime panic test
This test has an interesting history, because of fail -> panic. It was
originally called extern-fail.rs:
https://github.com/rust-lang/rust/commits/master/src/test/run-fail/extern-fail.rs

It lived for a while, but was disabled in August 2013:
ce95b01014

As you can see, that failure was not specific to this test, however,
this code does stuff with the runtime, which was removed. Given that
it hasn't even been able to compile in a long time, we should just
remove it.
2015-06-12 13:11:17 -04:00
Steve Klabnik
106a40885d Remove ignored test for #2061
This test was added on Nov 1, 2012:
0069bd2f46 (diff-b516ff69faf8886c48e6f5e833c2548c)

and then ignored on the same day:
a90020fe8d (diff-b516ff69faf8886c48e6f5e833c2548c)

and never unignored again.
2015-06-12 13:02:50 -04:00
Steve Klabnik
cae1d67406 Remove ignore'd test for old ICE
This test originated from an ICE in Rust 0.4:
373504a7ac (diff-214656000770dff71c8165d051c3f027)

it was ignored one day later:
1fa2b9980f (diff-214656000770dff71c8165d051c3f027)

and then never enabled again. I think we're safe without it.
2015-06-12 12:44:25 -04:00
Markus Westerlind
219ddd1f61 Mention the short form pattern syntax in the book
Explains short form pattern syntax and then introduces the longer
pattern matching as a rebinding of the fields instead.

 #25779
2015-06-12 18:18:45 +02:00
bors
4cc87c8acb Auto merge of #26245 - mbrubeck:extern, r=steveklabnik
r? @steveklabnik
2015-06-12 15:15:11 +00:00
Matt Brubeck
334ce91443 [reference] Fix typo in extern fn section 2015-06-12 08:08:48 -07:00
Seo Sanghyeon
793d9fcb52 Add tests for tuple-like structs and dictionary-like enum variants 2015-06-12 21:09:17 +09:00
Seo Sanghyeon
16d5c83d5f Use more precise span when checking type definitions 2015-06-12 20:28:09 +09:00
bors
a2f2a64763 Auto merge of #26238 - Manishearth:rollup, r=Manishearth
- Successful merges: #24495, #26229, #26231
- Failed merges:
2015-06-12 06:25:49 +00:00
Manish Goregaokar
a9ea380523 Rollup merge of #26231 - reem:patch-2, r=Gankro
r? @steveklabnik
2015-06-12 11:55:37 +05:30
Manish Goregaokar
8f841b24ca Rollup merge of #26229 - Stebalien:versionless-book, r=steveklabnik
They're forever doomed to be out-of-date. Also, don't assume the user is
installing a particular version.

r? @steveklabnik
2015-06-12 11:55:37 +05:30
Manish Goregaokar
18f70e3498 Rollup merge of #24495 - nathanl:nathanl-explain-bin-flag, r=steveklabnik
Explain the --bin flag in terms of the difference
between shipping binary and library code

I'm not sure if my explanation is even quite correct, but as a newbie coming from Ruby, this is my best guess. (In Rubyland, libraries always ship with the source code because there's no other form you can ship. :) )
2015-06-12 11:55:37 +05:30
bors
69db64f304 Auto merge of #26224 - mcast:doc-travis2buildbot, r=steveklabnik
Suggesting this because I was confused by what is now visible from the Travis CI / buildbot split.

Found the hint  in bors comments on d911936d
Couldn't find anything on https://internals.rust-lang.org/
2015-06-12 04:38:02 +00:00
bors
0da58cc361 Auto merge of #26226 - alexcrichton:fix-msvc-dist, r=brson
Right now the distribution tarball for MSVC only includes the *.dll files for
the supporting libraries, but not the corresponding *.lib files which allow
actually linking to the dll. This means that the current MSVC nightlies cannot
produce dynamically linked binaries as the *.lib files are not available to link
against.

This commit modifies the `LIB_GLOB` used to copy the files around to include the
`lib` variant of the `dll`.
2015-06-12 01:36:55 +00:00
Alexis Beingessner
2962b2681f validate stability against deprecation version 2015-06-11 17:18:46 -07:00
bors
7648776503 Auto merge of #26225 - arielb1:raw-self, r=eddyb
This can't be made to work with the current setup.

Technically a [breaking-change], but a simple bug fix.

Fixes #26194.
2015-06-12 00:00:27 +00:00
Jonathan Reem
3c6dcea985 Add Terminal.com to the list of companies using rust in production. 2015-06-11 16:07:34 -07:00
bors
400e955d8b Auto merge of #26199 - swgillespie:issue-26092, r=alexcrichton
`driver::build_output_filenames` calls `file_stem` on a PathBuf obtained from the output file compiler flag. It's possible to pass the empty string to this compiler flag. When file_stem is called on an empty Path, it returns None, which is unwrapped and the compiler panics.

This change modifies the `unwrap` to an `unwrap_or` so that the empty string is passed through the compilation pipeline until it reaches `trans:🔙:write_output_file`, which will emit an appropriate error.

Instead of panicking, the error that is emitted now is:

```
$ rustc -o "" thing.rs
error: could not write output to : No such file or directory
```

The `:` is a little strange, but it /is/ reporting the filename (the empty string) correctly, I suppose. Both gcc and clang hand the output file to ld, which emits a similar error message when faced with the empty string as an output file:

```
$ clang -o "" thing.c
ld: can't open output file for writing: , errno=2 for architecture x86_64
```

This PR also adds a test for this, in `run-make`. This fixes issue #26092.
2015-06-11 21:35:10 +00:00
Steven Allen
e2e292cc00 Don't link to specific versions of rust in the book.
They're forever doomed to be out-of-date. Also, don't assume the user is
installing a particular version.
2015-06-11 17:33:18 -04:00
Alex Crichton
6fee2690cf mk: Tweak the LIB_GLOB for MSVC
Right now the distribution tarball for MSVC only includes the *.dll files for
the supporting libraries, but not the corresponding *.lib files which allow
actually linking to the dll. This means that the current MSVC nightlies cannot
produce dynamically linked binaries as the *.lib files are not available to link
against.

This commit modifies the `LIB_GLOB` used to copy the files around to include the
`lib` variant of the `dll`.
2015-06-11 14:15:36 -07:00
Ariel Ben-Yehuda
3be18f0edc Prevent raw pointers from being used as an explicit self
This can't be made to work with the current setup.

Fixes #26194.
2015-06-11 23:45:27 +03:00
Matthew Astley
512b105b15 point to buildbot
Since 7b6ecc00
2015-06-11 19:57:16 +01:00
bors
b5b3a99f84 Auto merge of #26190 - Veedrac:no-iter, r=alexcrichton
Pull request for #26188.
2015-06-11 18:10:08 +00:00
Alexis Beingessner
5779fff543 update stability compile-fail tests 2015-06-11 10:49:29 -07:00
Alexis Beingessner
836cdf0a02 WIP inherited deprecation fixes #26040 2015-06-11 10:49:28 -07:00
Joshua Landau
2148567821 Changed patch wording 2015-06-11 18:10:25 +01:00
bors
deff2f50a9 Auto merge of #26212 - Manishearth:rollup, r=Manishearth
- Successful merges: #26181, #26184, #26189, #26191, #26195, #26202
- Failed merges:
2015-06-11 16:33:53 +00:00
bors
c85f307369 Auto merge of #26197 - dhuseby:fixing_morestack_breakage, r=brson
Revision 021e483 broke the BSD builds.  This fixes it for Bitrig and probably the others.
2015-06-11 14:57:13 +00:00
Joshua Landau
b107af3ada Comment for #26196.
Fixes #26196.

Alternatively we could explicitly check and complain (eg. panic), but I don't see the value-add.
2015-06-11 14:23:51 +01:00
Nathan Long
a47d7a752e Explain the --bin flag more clearly 2015-06-11 09:20:14 -04:00
bors
acfcb15e09 Auto merge of #26184 - aepsil0n:error-desc-funcargs, r=alexcrichton
These errors all relate to type checking, specifically the number of function arguments, and occur in librustc_typeck::check::check_argument_types.

Resolves part of #24407.
2015-06-11 13:17:19 +00:00
Joshua Landau
d7f5fa4636 Conver reborrows to .iter() calls where appropriate 2015-06-11 13:56:07 +01:00
bors
7e9a8e322a Auto merge of #26177 - jooert:fix26169, r=alexcrichton
Closes #26169.

r? @steveklabnik
2015-06-11 11:41:24 +00:00
bors
fc9e424550 Auto merge of #26172 - nham:add_E0116, r=alexcrichton
Also improves the wording of the E0133 description.

cc #24407
2015-06-11 10:06:38 +00:00
bors
f6341a878e Auto merge of #26159 - alexcrichton:tweak-process-lowering-raising, r=brson
* Slate these features to be stable in 1.2 instead of 1.1 (not being backported)
* Have the `FromRawFd` implementations follow the contract of the `FromRawFd`
  trait by taking ownership of the primitive specified.
* Refactor the implementations slightly to remove the `unreachable!` blocks as
  well as separating the stdio representation of `std::process` from
  `std::sys::process`.

cc #25494
2015-06-11 08:22:39 +00:00
Manish Goregaokar
e50675d549 Rollup merge of #26202 - nham:revise_E0072, r=alexcrichton
Converts the size calculation in the explanation from a fenced code block to an indented one. I think it looks better when not rendered, and is the same rendered.
2015-06-11 12:50:54 +05:30
Manish Goregaokar
cf3e79d558 Rollup merge of #26195 - tshepang:patch-1, r=alexcrichton 2015-06-11 12:50:53 +05:30
Manish Goregaokar
95407cc627 Rollup merge of #26191 - jimblandy:master, r=steveklabnik
In the discussion of returning closures, it seems like the example code got simplified, but only the later copies got fixed. The final working code has `factory` returning `|x| x + num`, but the earlier code has `|x| vec.push(x)`.

The first form seemed to have more distracting characteristics, and the code wasn't right anyway, so I changed them to all use the second form, and updated the error messages.

r? @steveklabnik
2015-06-11 12:50:53 +05:30
Manish Goregaokar
ea4949d449 Rollup merge of #26189 - bluss:iter-once-clone, r=Gankro
core: impl Clone for option::IntoIter and iter::Once
2015-06-11 12:50:53 +05:30
Manish Goregaokar
cf685cb8f8 Rollup merge of #26184 - aepsil0n:error-desc-funcargs, r=alexcrichton
These errors all relate to type checking, specifically the number of function arguments, and occur in librustc_typeck::check::check_argument_types.

Resolves part of #24407.
2015-06-11 12:50:53 +05:30
Manish Goregaokar
bdebe94433 Rollup merge of #26181 - Stebalien:fix-26178, r=steveklabnik
The list of in-production users is probably incomplete. It's based on a [post](https://www.reddit.com/r/rust/comments/2x567m/who_is_using_rust_or_what_projects_that_are/cox7eby) by /u/mozilla_kmc

closes #26178
2015-06-11 12:50:52 +05:30
bors
cf0edd0ad9 Auto merge of #26155 - dhuseby:fixing_bitrig_net_tests, r=alexcrichton
… congruent due to rounding errors

@semarie this affected both openbsd and bitrig.  it seems the correct solution is to switch to fixed point arithmetic in the timeout code, the same as freebsd.
2015-06-11 06:46:25 +00:00
bors
37cf025f1c Auto merge of #26154 - pmarcelll:master, r=Gankro
Various methods in both libcore/char.rs and librustc_unicode/char.rs were previously marked with #[inline], now every method is marked in char's impl blocks.
Partially fixes #26124.
EDIT: I'm not familiar with pull reqests (yet), apparently Github added my second commit to thit PR...
Fixes #26124
2015-06-11 05:05:20 +00:00
bors
2fbbd54afe Auto merge of #26122 - bluss:borrow-box, r=alexcrichton
Implement Borrow<T> and BorrowMut<T> for Box<T: ?Sized>
2015-06-11 03:25:45 +00:00
Nick Hamann
a297651607 Revise the E0072 explanation. 2015-06-10 21:36:32 -05:00
swgillespie
91effb374c fix #26092 by returning an empty OS string when the output file path has no file_stem 2015-06-10 18:18:04 -07:00