Steve Klabnik
79ac8f5110
Rename fail! to panic!
...
https://github.com/rust-lang/rfcs/pull/221
The current terminology of "task failure" often causes problems when
writing or speaking about code. You often want to talk about the
possibility of an operation that returns a Result "failing", but cannot
because of the ambiguity with task failure. Instead, you have to speak
of "the failing case" or "when the operation does not succeed" or other
circumlocutions.
Likewise, we use a "Failure" header in rustdoc to describe when
operations may fail the task, but it would often be helpful to separate
out a section describing the "Err-producing" case.
We have been steadily moving away from task failure and toward Result as
an error-handling mechanism, so we should optimize our terminology
accordingly: Result-producing functions should be easy to describe.
To update your code, rename any call to `fail!` to `panic!` instead.
Assuming you have not created your own macro named `panic!`, this
will work on UNIX based systems:
grep -lZR 'fail!' . | xargs -0 -l sed -i -e 's/fail!/panic!/g'
You can of course also do this by hand.
[breaking-change]
2017-03-02 14:56:53 -08:00
Steve Klabnik
9e9a8b5237
update keyword list
...
Fixes #17969
2017-03-02 14:56:53 -08:00
Ivan Ukhov
50476bb14f
Fix the description of raw byte string literals
2017-03-02 14:56:53 -08:00
Luqman Aden
9cb350c4e8
librustc: Remove trans::reflect and the opaque and ty_visitor lang items.
2017-03-02 14:56:53 -08:00
Luqman Aden
df35475d92
Remove libdebug and update tests.
2017-03-02 14:56:53 -08:00
NODA, Kai
ba50ee1563
Fix HTML version of the keyword table.
...
This should really fix rust-lang/rust#17528 .
2017-03-02 14:56:53 -08:00
John Gallagher
29d41459ef
Add `while let` to the reference
...
Closes #17687
2017-03-02 14:56:53 -08:00
John Gallagher
fa558588a7
Move `while let` behind `while_let` feature gate
2017-03-02 14:56:53 -08:00
Steven Fackler
e77a8553d0
Continue cfg syntax transition
...
All deprecation warnings have been converted to errors. This includes
the warning for multiple cfgs on one item. We'll leave that as an error
for some period of time to ensure that all uses are updated before the
behavior changes from "or" to "and".
2017-03-02 14:56:53 -08:00
Jakub Wieczorek
179bd9327c
Remove `virtual` structs from the reference
2017-03-02 14:56:52 -08:00
Alex Crichton
d53cec1ebb
doc: Document constants in the reference
2017-03-02 14:56:52 -08:00
Steve Klabnik
149d3ab9e2
add mention of test attribute
...
Fixes #16413
2017-03-02 14:56:52 -08:00
Steve Klabnik
d0a374161e
remove crate_id attribute, add crate_name one
...
this is true as of https://github.com/rust-lang/rust/pull/15319
2017-03-02 14:56:52 -08:00
Steve Klabnik
7d3b9b0f92
Fix keyword table
...
Markdown tables require a header, and we don't want one.
Fixes #17528
2017-03-02 14:56:52 -08:00
Nick Cameron
714408be0f
Put slicing syntax behind a feature gate.
...
[breaking-change]
If you are using slicing syntax you will need to add #![feature(slicing_syntax)] to your crate.
2017-03-02 14:56:52 -08:00
Alex Crichton
274d527c45
Test fixes from the rollup
2017-03-02 14:56:52 -08:00
Keegan McAllister
5bf3c2b88b
Link plugins guide from elsewhere
2017-03-02 14:56:52 -08:00
Eduard Burtescu
f82f98c93e
docs: remove mentions of Gc.
2017-03-02 14:56:52 -08:00
Aaron Turon
566a0d6473
Revert "Put slicing syntax behind a feature gate."
...
This reverts commit 95cfc35607ccf5f02f02de56a35a9ef50fa23a82.
2017-03-02 14:56:52 -08:00
Nick Cameron
f12a8baf47
Put slicing syntax behind a feature gate.
...
[breaking-change]
If you are using slicing syntax you will need to add #![feature(slicing_syntax)] to your crate.
2017-03-02 14:56:51 -08:00
Patrick Walton
5c2a580183
librustc: Forbid `..` in range patterns.
...
This breaks code that looks like:
match foo {
1..3 => { ... }
}
Instead, write:
match foo {
1...3 => { ... }
}
Closes #17295 .
[breaking-change]
2017-03-02 14:56:51 -08:00
Jakub Wieczorek
93be85f7d9
Add `if let` to the reference
2017-03-02 14:56:51 -08:00
Kevin Ballard
b44f1f9bea
Update based on PR feedback
2017-03-02 14:56:51 -08:00
Kevin Ballard
7d2417054e
Move `if let` behind a feature gate
2017-03-02 14:56:51 -08:00
Steve Klabnik
b90733a9d0
clean up some references to 'owned'
2017-03-02 14:56:51 -08:00
Steve Klabnik
895b2a9489
vectors are not in the language
2017-03-02 14:56:51 -08:00
Steve Klabnik
7bab3aa486
die 'managed'
2017-03-02 14:56:51 -08:00
Steve Klabnik
15dfd6da1f
logging is an external crate
2017-03-02 14:56:51 -08:00
Steve Klabnik
ce2822109a
no it won't
2017-03-02 14:56:50 -08:00
Steve Klabnik
277d74b114
runtime has no C++
2017-03-02 14:56:50 -08:00
Steve Klabnik
2357a3f21e
Remove lies about task scheduling
...
it's 1:1 by default now, and N:M is on its way out
2017-03-02 14:56:50 -08:00
Steve Klabnik
64b7114645
Fix terminology around boxes
...
it's just 'box' not 'owned box'
2017-03-02 14:56:50 -08:00
Steve Klabnik
cd4b934993
fix example
2017-03-02 14:56:50 -08:00
Steve Klabnik
85f29fcd29
glob imports are an external crate
2017-03-02 14:56:50 -08:00
Steve Klabnik
d446b6684a
rust -> Rust
2017-03-02 14:56:50 -08:00
Steve Klabnik
52ca55a213
uhhh weird triple backticks
2017-03-02 14:56:50 -08:00
Steve Klabnik
e8a1627557
'merican English
2017-03-02 14:56:50 -08:00
Steve Klabnik
f708314faa
move keywords to table
2017-03-02 14:56:50 -08:00
Steve Klabnik
b1e97209fc
'. ' -> '. '
2017-03-02 14:56:49 -08:00
Steve Klabnik
34c2cbcb55
Remove disclaimer
...
This is just true of all of Rust, and doesn't make a lot of sense now.
Especially as we move towards finalizing things, I think it's time for
this to go.
2017-03-02 14:56:49 -08:00
Steve Klabnik
1d2cbad750
make note of language vs libraries
2017-03-02 14:56:49 -08:00
Steve Klabnik
721c7421ee
modernize code blocks
2017-03-02 14:56:49 -08:00
Steve Klabnik
fa5fd6c344
manual -> reference & formatting
...
'reference' sounds better than 'manual' to me here, and rust.html is
certainly wrong.
I also wrapped everything to 80 cols.
2017-03-02 14:56:49 -08:00