Uh oh!
There was an error while loading. Please reload this page.
Merge ObjectSum and PolyTraitRef in AST/HIR + some other refactoring - #39110
Conversation
eddyb
commented
Jan 16, 2017
This is getting awkward, I was trying to do this just today. Hopefully they're the same idea. |
eddyb
commented
Jan 16, 2017
I prefer |
eddyb
commented
Jan 16, 2017
Ah, you changed the parser, more elegant than my lowering hack, heh. I'm not super sure about the changes to |
petrochenkov
commented
Jan 17, 2017
I actually thought about renaming it to something, but decided to avoid extra churn. |
petrochenkov
commented
Jan 17, 2017
Renamed |
eddyb
commented
Jan 17, 2017
@bors r+ |
bors
commented
Jan 17, 2017
📌 Commit 66ef5f2 has been approved by |
bors
commented
Jan 17, 2017
Merge ObjectSum and PolyTraitRef in AST/HIR + some other refactoring `ObjectSum` and `PolyTraitRef` are the same thing (list of bounds), they exist separately only due to parser quirks. The second commit merges them. The first commit replaces `Path` with `Ty` in (not yet supported) equality predicates. They are parsed as types anyway and arbitrary types can always be disguised as paths using aliases, so this doesn't add any new functionality. The third commit uses `Vec` instead of `P<[T]>` in AST. AST is not immutable like HIR and `Vec`s are more convenient for it, unnecessary conversions are also avoided. The last commit renames `parse_ty_sum` (which is used for parsing types in general) into `parse_ty`, and renames `parse_ty` (which is used restricted contexts where `+` is not permitted due to operator priorities or other reasons) into `parse_ty_no_plus`. This is the first part of #39085 (comment) and #39080 focused on data changes and mechanical renaming, I'll submit a PR with parser changes a bit later. r? @eddyb
bors
commented
Jan 17, 2017
☀️ Test successful - status-appveyor, status-travis |
ObjectSumandPolyTraitRefare the same thing (list of bounds), they exist separately only due to parser quirks. The second commit merges them.The first commit replaces
PathwithTyin (not yet supported) equality predicates. They are parsed as types anyway and arbitrary types can always be disguised as paths using aliases, so this doesn't add any new functionality.The third commit uses
Vecinstead ofP<[T]>in AST. AST is not immutable like HIR andVecs are more convenient for it, unnecessary conversions are also avoided.The last commit renames
parse_ty_sum(which is used for parsing types in general) intoparse_ty, and renamesparse_ty(which is used restricted contexts where+is not permitted due to operator priorities or other reasons) intoparse_ty_no_plus.This is the first part of #39085 (comment) and #39080 focused on data changes and mechanical renaming, I'll submit a PR with parser changes a bit later.
r? @eddyb