Skip to content

Commit

Permalink
Merge #37
Browse files Browse the repository at this point in the history
37: Add both variants of half open range patterns to the grammar r=lf- a=lf-

This is prompted by
rust-lang/rust-analyzer#9779, but it
is not actually a prerequisite of making that one happen as this commit
doesn't change the generated code on the r-a side.

Relevant PR (that does not require this one be merged immediately/a release made): rust-lang/rust-analyzer#9780

Co-authored-by: Jade <software@lfcode.ca>
  • Loading branch information
bors[bot] and lf- committed Aug 13, 2021
2 parents 074b255 + 1fec3b1 commit 1c7a5c8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
3 changes: 1 addition & 2 deletions Cargo.toml
@@ -1,10 +1,9 @@
[package]
name = "ungrammar"
description = "A DSL for describing concrete syntax trees"
version = "1.14.3"
version = "1.14.4"
license = "MIT OR Apache-2.0"
repository = "https://github.com/matklad/ungrammar"
authors = ["Aleksey Kladov <aleksey.kladov@gmail.com>"]
edition = "2018"

exclude = ["/bors.toml", "/.github"]
Expand Down
7 changes: 6 additions & 1 deletion rust.ungram
Expand Up @@ -603,7 +603,12 @@ WildcardPat =
'_'

RangePat =
start:Pat op:('..' | '..=') end:Pat
// 1..
start:Pat op:('..' | '..=')
// 1..2
| start:Pat op:('..' | '..=') end:Pat
// ..2
| op:('..' | '..=') end:Pat

RefPat =
'&' 'mut'? Pat
Expand Down

0 comments on commit 1c7a5c8

Please sign in to comment.