]> git.lizzy.rs Git - rust.git/commit
Teach parser to understand fake anonymous enum syntax
authorEsteban Küber <esteban@kuber.com.ar>
Sun, 15 Jan 2023 22:36:46 +0000 (22:36 +0000)
committerEsteban Küber <esteban@kuber.com.ar>
Tue, 17 Jan 2023 01:58:32 +0000 (01:58 +0000)
commit2d824206655bfb26cb5eed43490ee396542b153e
tree0b46bf3dc0a6684a48c025d8f0ff0c298a107204
parentae4d89dfb51535c1c43052ef848564bd2323c9ca
Teach parser to understand fake anonymous enum syntax

Parse `-> Ty | OtherTy`.
Parse type ascription in top level patterns.
13 files changed:
compiler/rustc_ast/src/ast.rs
compiler/rustc_ast/src/mut_visit.rs
compiler/rustc_ast/src/visit.rs
compiler/rustc_ast_lowering/src/lib.rs
compiler/rustc_ast_pretty/src/pprust/state.rs
compiler/rustc_parse/src/parser/diagnostics.rs
compiler/rustc_parse/src/parser/pat.rs
compiler/rustc_parse/src/parser/ty.rs
compiler/rustc_passes/src/hir_stats.rs
src/tools/rustfmt/src/types.rs
tests/ui/parser/anon-enums.rs [new file with mode: 0644]
tests/ui/parser/anon-enums.stderr [new file with mode: 0644]
tests/ui/parser/issues/issue-87086-colon-path-sep.stderr