From eedf11ae8897083ba4d5f64e6bce38f4e19cd8e2 Mon Sep 17 00:00:00 2001 From: veetaha Date: Sun, 10 May 2020 19:24:06 +0300 Subject: Add example with const in TypeBound as per flodiebold --- xtask/src/ast_src.rs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'xtask') diff --git a/xtask/src/ast_src.rs b/xtask/src/ast_src.rs index 16222b3c4..2a8a5378d 100644 --- a/xtask/src/ast_src.rs +++ b/xtask/src/ast_src.rs @@ -1640,8 +1640,6 @@ pub(crate) const AST_SRC: AstSrc = AstSrc { /// [Reference](https://doc.rust-lang.org/reference/items/generics.html) struct LifetimeParam: AttrsOwner { T![lifetime] } - // TODO: better clarify where is the colon token and what `const` pertains to. - // TODO: add example with `const` /// Type bound declaration clause. /// /// ``` @@ -1651,12 +1649,12 @@ pub(crate) const AST_SRC: AstSrc = AstSrc { /// where /// T: ❰ Send ❱ + ❰ Sync ❱ /// { - /// type Baz: ❰ !Sync ❱ + ❰ Debug ❱; + /// type Baz: ❰ !Sync ❱ + ❰ Debug ❱ + ❰ ?const Add ❱; /// } /// ``` /// /// [Reference](https://doc.rust-lang.org/reference/trait-bounds.html) - struct TypeBound { T![lifetime], /* Question, */ T![const], /* Question, */ TypeRef } + struct TypeBound { T![lifetime], /* Question, */ T![const], /* Question, */ TypeRef } /// Type bounds list. /// -- cgit v1.2.3