Commit Graph

21 Commits

Author SHA1 Message Date
Mazdak Farrokhzad e233331a51 syntax::print -> new crate rustc_ast_pretty 2020-02-01 18:59:49 +01:00
Mazdak Farrokhzad de6046fa0f remove rustc_error_codes deps except in rustc_driver 2020-01-18 21:53:53 +01:00
varkor 3de9b8a3b7 Fix formatting ellipses at the end of some diagnostics 2020-01-12 15:37:50 +00:00
Mazdak Farrokhzad 883932c6ba Ban `...X` pats, harden tests, and improve diagnostics.
Also fix a bug with the span passed in `mk_range`.
2020-01-11 08:58:58 +01:00
Mazdak Farrokhzad d5598aa7a0 Introduce `#![feature(half_open_range_patterns)]`.
This feature adds `X..`, `..X`, and `..=X` patterns.
2020-01-10 07:29:04 +01:00
Vadim Petrochenkov 70f1d57048 Rename `syntax_pos` to `rustc_span` in source code 2020-01-01 09:15:18 +03:00
Mazdak Farrokhzad 2e812c1c5f parser::pat: remove .fatal calls 2019-12-31 04:33:34 +01:00
Mazdak Farrokhzad 5a64ba6386 parser: span_fatal -> struct_span_err 2019-12-31 04:33:34 +01:00
Mazdak Farrokhzad 2091062bf6 parser: call .struct_span_err directly 2019-12-31 04:33:34 +01:00
bors da3629b05f Auto merge of #67112 - Centril:expr-polish, r=estebank
Refactor expression parsing thoroughly

Based on https://github.com/rust-lang/rust/pull/66994 together with which this has refactored basically the entirety of `expr.rs`.

r? @estebank
2019-12-29 19:30:53 +00:00
Mazdak Farrokhzad 5f92a56ed6 Introduce `#![feature(bindings_after_at)]`.
Under the gate, `x @ Some(y)` is allowed.
This is subject to various restrictions for soundness.
2019-12-23 14:47:19 +01:00
Mazdak Farrokhzad 8456c403e1 extract parse_not_expr 2019-12-23 13:55:04 +01:00
Mark Rousskov a06baa56b9 Format the world 2019-12-22 17:42:47 -05:00
Mazdak Farrokhzad c0bf3afc96
Rollup merge of #67355 - Centril:merge-mut, r=oli-obk
Merge `ast::Mutability` and `mir::Mutability`

r? @oli-obk
2019-12-21 15:29:42 +01:00
Mazdak Farrokhzad a0d20935cc introduce 'type AttrVec' 2019-12-20 22:53:40 +01:00
Mazdak Farrokhzad a7aec3f207 1. ast::Mutability::{Mutable -> Mut, Immutable -> Not}.
2. mir::Mutability -> ast::Mutability.
2019-12-20 22:22:44 +01:00
Mazdak Farrokhzad 45c1e38147 parser: recover on `&'lifetime mut $pat`. 2019-12-13 02:36:25 +01:00
Mazdak Farrokhzad 74804fa3e7 rustc_parser: cleanup imports 2019-12-05 06:38:06 +01:00
Vadim Petrochenkov 0fac56717a syntax: Remove redundant span from `ast::Mac`
Also remove a couple of redundant `visit_mac` asserts
2019-12-02 21:56:34 +03:00
Vadim Petrochenkov a81804b4d5 syntax: Introduce a struct `MacArgs` for macro arguments 2019-12-02 21:56:34 +03:00
Mazdak Farrokhzad 4ae2728fa8 move syntax::parse -> librustc_parse
also move MACRO_ARGUMENTS -> librustc_parse
2019-11-10 03:57:18 +01:00