about summary refs log tree commit diff
path: root/compiler/rustc_ast/src/token.rs
AgeCommit message (Collapse)AuthorLines
2020-11-25Adjust pretty-print compat hack to work with item statementsAaron Hill-7/+14
2020-10-26Suggest expressions that look like const generic arguments should be ↵varkor-0/+7
enclosed in brackets Co-Authored-By: Esteban Kuber <github@kuber.com.ar>
2020-10-16Parse inline const expressionsSantiago Pastorino-0/+1
2020-10-15Rollup merge of #77739 - est31:remove_unused_code, r=petrochenkov,varkorYuki Okushi-10/+0
Remove unused code Rustc has a builtin lint for detecting unused code inside a crate, but when an item is marked `pub`, the code, even if unused inside the entire workspace, is never marked as such. Therefore, I've built [warnalyzer](https://github.com/est31/warnalyzer) to detect unused items in a cross-crate setting. Closes https://github.com/est31/warnalyzer/issues/2
2020-10-14Remove unused code from rustc_astest31-10/+0
2020-10-11Add hack to keep `actix-web` and `actori-web` compilingAaron Hill-5/+16
This extends the existing `ident_name_compatibility_hack` to handle the `tuple_from_req` macro defined in `actix-web` (and its fork `actori-web`).
2020-09-10Fully integrate token collection for additional AST structsAaron Hill-1/+1
This commit contains miscellaneous changes that don't fit into any of the other commits in this PR
2020-09-07Rollup merge of #76274 - scottmcm:fix-76271, r=petrochenkovDylan DPC-0/+1
Allow try blocks as the argument to return expressions Fixes #76271 I don't think this needs to be edition-aware (phew) since `return try` in 2015 is also the start of an expression, just with a struct literal instead of a block (`return try { x: 4, y: 5 }`).
2020-09-04Account for version number in NtIdent hackAaron Hill-3/+13
Issue #74616 tracks a backwards-compatibility hack for certain macros. This has is implemented by hard-coding the filenames and macro names of certain code that we want to continue to compile. However, the initial implementation of the hack was based on the directory structure when building the crate from its repository (e.g. `js-sys/src/lib.rs`). When the crate is build as a dependency, it will include a version number from the clone from the cargo registry (e.g. `js-sys-0.3.17/src/lib.rs`), which would fail the check. This commit modifies the backwards-compatibility hack to check that desired crate name (`js-sys` or `time-macros-impl`) is a prefix of the proper part of the path. See https://github.com/rust-lang/rust/issues/76070#issuecomment-687215646 for more details.
2020-09-02Allow try blocks as the argument to return expressionsScott McMurray-0/+1
Fixes 76271
2020-09-01Remove trivia tokensAleksey Kladov-15/+3
2020-08-30mv compiler to compiler/mark-0/+884