Aaron Turon
9d919d2302
Second pass stabilization: vec
...
This commit takes a second pass through the `vec` module to
stabilize its API. The changes are as follows:
**Stable**:
* `dedup`
* `from_raw_parts`
* `insert`
* `into_iter`
* `is_empty`
* `remove`
* `reserve_exact`
* `reserve`
* `retain`
* `swap_remove`
* `truncate`
**Deprecated**:
* `from_fn`, `from_elem`, `grow_fn` and `grow`, all deprecated in
favor of iterators. See https://github.com/rust-lang/rfcs/pull/509
* `partition`, `partitioned`, deprecated in favor of a new, more
general iterator consumer called `partition`.
* `unzip`, deprecated in favor of a new, more general iterator
consumer called `unzip`.
A few remaining methods are left at experimental status.
[breaking-change]
2014-12-30 12:02:22 -08:00
Aaron Turon
8a5057af2e
std::iter: Add partition and unzip methods to iterators
2014-12-30 12:02:21 -08:00
Brian Anderson
1131acbc8e
mk: Append -src to source tarballs for easier identification
2014-12-30 11:47:12 -08:00
Corey Farwell
1d26fb9e07
Remove core::atomic::Ordering::* public reexport
...
Part of #19253
[breaking-change]
2014-12-30 11:43:51 -08:00
Jonathan S
c7a8240f02
Removed a bunch of unnecessary .clone()s from build_reduced_graph
2014-12-30 12:52:51 -06:00
Jonathan S
096df4e134
Purged ReducedGraphParent
2014-12-30 12:30:42 -06:00
Jonathan S
28659cf804
Cleanup unused imports resulting from move of reduced graph building
2014-12-30 12:19:24 -06:00
Brian Anderson
20fcece88b
mk: The alpha will not have a cycle number
2014-12-30 10:18:54 -08:00
Jonathan S
be00b9dc40
Moved ReducedGraphParent building to a new module
2014-12-30 12:16:42 -06:00
bors
84f5ad8679
auto merge of #20307 : nikomatsakis/rust/assoc-types-normalization-extend-bound, r=nrc
...
Rewrite associated types to use projection rather than dummy type parameters. This closes almost every (major) open issue, but I'm holding off on that until the code has landed and baked a bit. Probably it should have more tests, as well, but I wanted to get this landed as fast as possible so that we can collaborate on improving it.
The commit history is a little messy, particularly the merge commit at the end. If I get some time, I might just "reset" to the beginning and try to carve up the final state into logical pieces. Let me know if it seems hard to follow. By far the most crucial commit is "Implement associated type projection and normalization."
r? @nick29581
2014-12-30 17:51:21 +00:00
Niko Matsakis
e186accbc4
Fix rebase conflicts
2014-12-30 12:09:21 -05:00
Michael Woerister
91a0e18866
debuginfo: Add a rust-gdb shell script that will start GDB with Rust pretty printers enabled.
2014-12-30 17:26:13 +01:00
Florian Hahn
1e278c1cd1
Update src/grammar/README.md
2014-12-30 16:49:27 +01:00
Florian Hahn
f066acf645
src/grammar/check.sh now prints test summary
2014-12-30 16:46:07 +01:00
Niko Matsakis
919975d0a5
Address nits.
2014-12-30 09:36:23 -05:00
Niko Matsakis
518ec1259a
Normalize associated types in bounds too. Also, make the workaround
...
for lack of impl-trait-for-trait just a bit more targeted (don't
substitute err, just drop the troublesome bound for now) -- otherwise
substituting false types leads us into trouble when we normalize etc.
2014-12-30 09:36:23 -05:00
Niko Matsakis
cdd5ff842d
Add a test case using associated types cross crate. Fixes #18048 .
2014-12-30 09:36:23 -05:00
Niko Matsakis
208d32d192
Encode the TypeScheme for associated types
2014-12-30 09:36:23 -05:00
Niko Matsakis
de8e0ae22c
Remove the AssocSpace
2014-12-30 09:36:23 -05:00
Niko Matsakis
42e645ca9a
Patch more metadata decoding problems.
2014-12-30 09:36:23 -05:00
Niko Matsakis
30e8ab0182
Encode the name for associated items on a trait. Fixes #18048 .
2014-12-30 09:36:23 -05:00
Niko Matsakis
c1bc150bc4
Correct licenses.
2014-12-30 09:36:23 -05:00
Niko Matsakis
7ed0e23209
Resolve merge conflicts. This changes should really be integrated back to their respective
...
commits but oh dear what a pain.
2014-12-30 09:36:23 -05:00
Niko Matsakis
05eb2eeb61
Adjust tests for inferenceGet more conservative about inference for now. Seems better to err on the side of being more correct rather than less. Fix a bug in typing index expressions that was exposed as a result, and add one type annotation that is not required. Delete some random tests that were relying on old behavior and don't seem to add anything anymore.
2014-12-30 09:36:23 -05:00
Niko Matsakis
c197911c60
Add a FIXME relating to these type-testing traits
2014-12-30 09:36:23 -05:00
Niko Matsakis
f1c041a54d
Patch long line.
2014-12-30 09:36:23 -05:00
Niko Matsakis
00cf176a5e
Add FIXMEs relating to caching of projection results
2014-12-30 09:36:22 -05:00
Niko Matsakis
97d8a668f6
Add a FIXME relating to regions and projection types
2014-12-30 09:36:22 -05:00
Niko Matsakis
d62d4953d2
Add a FIXME to patch up rustdoc
2014-12-30 09:36:22 -05:00
Niko Matsakis
58467fab0f
File a FIXME relating to using where clauses, not bounds
2014-12-30 09:36:22 -05:00
Niko Matsakis
df967306e3
Add a FIXME relating to Copy<T> not being checked
2014-12-30 09:36:22 -05:00
Niko Matsakis
adca15a151
Add a FIXME relating to using ast::Name
2014-12-30 09:36:22 -05:00
Niko Matsakis
7836c72eba
Patch tests and create new tests related to projection from a HRTB.
2014-12-30 09:36:22 -05:00
Niko Matsakis
3657ae13f5
Don't normalize associated types when in region binders, wait until we instantiate
...
them. Also fix some assertions and handling of builtin bounds.
2014-12-30 09:36:22 -05:00
Niko Matsakis
2bbd2f9cea
Remove the def-id from type parameters. Having this def-id was bad for several reasons:
...
1. Produced more unique types than is necessary. This increases memory consumption.
2. Linking the type parameter to its definition *seems* like a good idea, but it
encourages reliance on the bounds listing.
3. It made pretty-printing harder and in particular was causing bad error messages
when errors occurred before the `TypeParameterDef` entries were fully stored.
2014-12-30 09:36:22 -05:00
Niko Matsakis
964a5fabb7
Update error messages in various compile-fail tests
2014-12-30 09:36:22 -05:00
Niko Matsakis
b7c6e317b0
Make projected types select out of the trait bounds.
2014-12-30 09:36:22 -05:00
Niko Matsakis
de806bc057
Teach project
to project associated types out of object types.
2014-12-30 09:36:22 -05:00
Niko Matsakis
5b53b11ad9
Allow object safe traits to access associated types.
2014-12-30 09:36:21 -05:00
Niko Matsakis
becbd81aaa
Integrate projection bounds to ExistentialBounds
but do not use them for anything.
2014-12-30 09:36:21 -05:00
Niko Matsakis
82787c2252
Convert to use Rc<TraitRef>
in object types (finally!).
2014-12-30 09:36:21 -05:00
Niko Matsakis
4404592f36
Implement associated type projection and normalization.
2014-12-30 09:36:21 -05:00
Niko Matsakis
f95bb55a1c
Move the scalar types out of static data so that we can put Rc
into sty.
2014-12-30 09:34:38 -05:00
Niko Matsakis
771dd54ea6
Rename Polytype
to TypeScheme
to differentiate type schemes (early bound) from higher-ranked things (late-bound), which also use the Poly
prefix.
2014-12-30 09:32:42 -05:00
Niko Matsakis
986f654f3b
Rename trait_ref
field to predicate
, since trait_ref
is really
...
overly general, and the value is always *some* sort of predicate.
2014-12-30 09:32:42 -05:00
Niko Matsakis
c5edd22646
Rewrite the intrinsicck to take the parameter environment into account. Also fixes #20116 .
2014-12-30 09:32:42 -05:00
Niko Matsakis
4946e1a463
Move the TypeContents-based "Sized" queries into trans, where the full
...
types are always known and hence the ParameterEnvironment is not
necessary. For other `Sized` queries, use the trait infrastructure
just like `Copy`.
2014-12-30 09:32:42 -05:00
Niko Matsakis
0b64e5796b
Make ExprUseVisitor<..> use inherited parameter environments.
2014-12-30 09:32:42 -05:00
Niko Matsakis
c08d004545
Refactor various queries out of ty
and into trans/common
2014-12-30 09:32:42 -05:00
JONNALAGADDA Srinivas
42ae6bb24d
Minor change to wording in Variables and Bindings
...
In the context of explaining the declaration of mutable bindings, using 'intended' probably conveys the meaning better than 'cared'.
2014-12-30 19:23:16 +05:30