aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_syntax/src/grammar.ron
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2019-12-22 07:56:33 +0000
committerGitHub <[email protected]>2019-12-22 07:56:33 +0000
commitd33493d779ba573403804b8d78e9b72fcf98f894 (patch)
treef6fe331d8fac08c821d0820e4c15410e1c9de66a /crates/ra_syntax/src/grammar.ron
parent000710bd089959796947b507d05a6426b7733b47 (diff)
parentb04d4a88d1ba7f04445e807b6a816930b1e9bbf2 (diff)
Merge #2641
2641: Parse const generics r=matklad a=roblabla Adds very primitive support for parsing const generics (`const IDENT: TY`) so that rust-analyzer stops complaining about the syntax being invalid. Fixes #1574 Fixes #2281 Co-authored-by: roblabla <[email protected]>
Diffstat (limited to 'crates/ra_syntax/src/grammar.ron')
-rw-r--r--crates/ra_syntax/src/grammar.ron5
1 files changed, 5 insertions, 0 deletions
diff --git a/crates/ra_syntax/src/grammar.ron b/crates/ra_syntax/src/grammar.ron
index 3f1cd0b90..08aafb610 100644
--- a/crates/ra_syntax/src/grammar.ron
+++ b/crates/ra_syntax/src/grammar.ron
@@ -245,6 +245,7 @@ Grammar(
245 "TYPE_PARAM_LIST", 245 "TYPE_PARAM_LIST",
246 "LIFETIME_PARAM", 246 "LIFETIME_PARAM",
247 "TYPE_PARAM", 247 "TYPE_PARAM",
248 "CONST_PARAM",
248 "TYPE_ARG_LIST", 249 "TYPE_ARG_LIST",
249 "LIFETIME_ARG", 250 "LIFETIME_ARG",
250 "TYPE_ARG", 251 "TYPE_ARG",
@@ -604,6 +605,10 @@ Grammar(
604 options: [("default_type", "TypeRef")], 605 options: [("default_type", "TypeRef")],
605 traits: ["NameOwner", "AttrsOwner", "TypeBoundsOwner"], 606 traits: ["NameOwner", "AttrsOwner", "TypeBoundsOwner"],
606 ), 607 ),
608 "ConstParam": (
609 options: [("default_val", "Expr")],
610 traits: ["NameOwner", "AttrsOwner", "TypeAscriptionOwner"],
611 ),
607 "LifetimeParam": ( 612 "LifetimeParam": (
608 traits: ["AttrsOwner"], 613 traits: ["AttrsOwner"],
609 ), 614 ),