diff options
| author | Mazdak Farrokhzad <twingoow@gmail.com> | 2019-12-20 17:22:19 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-12-20 17:22:19 +0100 |
| commit | ec82174fad385882798b6c223dc1b8ac44f58332 (patch) | |
| tree | 0602c23ea16b14f9f76377c3506143575df88c3c /src/rustllvm/RustWrapper.cpp | |
| parent | ba1a4882514c3262caff38deabc30b669c709b95 (diff) | |
| parent | 054458b48db87ce767d7cc3d2dd86846ada3e3da (diff) | |
| download | rust-ec82174fad385882798b6c223dc1b8ac44f58332.tar.gz rust-ec82174fad385882798b6c223dc1b8ac44f58332.zip | |
Rollup merge of #67131 - Centril:item-merge, r=petrochenkov
Merge `TraitItem` & `ImplItem into `AssocItem`
In this PR we:
- Merge `{Trait,Impl}Item{Kind?}` into `AssocItem{Kind?}` as discussed in https://github.com/rust-lang/rust/issues/65041#issuecomment-538105286.
- This is done by using the cover grammar of both forms.
- In particular, it requires that we syntactically allow (under `#[cfg(FALSE)]`):
- `default`ness on `trait` items,
- `impl` items without a body / definition (`const`, `type`, and `fn`),
- and associated `type`s in `impl`s with bounds, e.g., `type Foo: Ord;`.
- The syntactic restrictions are replaced by semantic ones in `ast_validation`.
- Move syntactic restrictions around C-variadic parameters from the parser into `ast_validation`:
- `fn`s in all contexts now syntactically allow `...`,
- `...` can occur anywhere in the list syntactically (`fn foo(..., x: usize) {}`),
- and `...` can be the sole parameter (`fn foo(...) {}`.
r? @petrochenkov
Diffstat (limited to 'src/rustllvm/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions
