Rename DotDotPat -> RestPat
This commit is contained in:
parent
215b9b9ccc
commit
22d295ceaa
14 changed files with 55 additions and 55 deletions
|
|
@ -293,15 +293,15 @@ impl ast::SlicePat {
|
|||
let mut args = self.args().peekable();
|
||||
let prefix = args
|
||||
.peeking_take_while(|p| match p {
|
||||
ast::Pat::DotDotPat(_) => false,
|
||||
ast::Pat::RestPat(_) => false,
|
||||
ast::Pat::IdentPat(bp) => match bp.pat() {
|
||||
Some(ast::Pat::DotDotPat(_)) => false,
|
||||
Some(ast::Pat::RestPat(_)) => false,
|
||||
_ => true,
|
||||
},
|
||||
ast::Pat::RefPat(rp) => match rp.pat() {
|
||||
Some(ast::Pat::DotDotPat(_)) => false,
|
||||
Some(ast::Pat::RestPat(_)) => false,
|
||||
Some(ast::Pat::IdentPat(bp)) => match bp.pat() {
|
||||
Some(ast::Pat::DotDotPat(_)) => false,
|
||||
Some(ast::Pat::RestPat(_)) => false,
|
||||
_ => true,
|
||||
},
|
||||
_ => true,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue