aboutsummaryrefslogtreecommitdiff
path: root/crates
diff options
context:
space:
mode:
Diffstat (limited to 'crates')
-rw-r--r--crates/ra_syntax/src/ast.rs2
-rw-r--r--crates/ra_syntax/src/ast/expr_extensions.rs2
-rw-r--r--crates/ra_syntax/src/ast/extensions.rs3
-rw-r--r--crates/ra_syntax/src/ast/tokens.rs2
-rw-r--r--crates/ra_syntax/src/ast/traits.rs4
5 files changed, 13 insertions, 0 deletions
diff --git a/crates/ra_syntax/src/ast.rs b/crates/ra_syntax/src/ast.rs
index dcc71eabe..9f5c41b0c 100644
--- a/crates/ra_syntax/src/ast.rs
+++ b/crates/ra_syntax/src/ast.rs
@@ -1,4 +1,5 @@
1//! Abstract Syntax Tree, layered on top of untyped `SyntaxNode`s 1//! Abstract Syntax Tree, layered on top of untyped `SyntaxNode`s
2
2mod generated; 3mod generated;
3mod traits; 4mod traits;
4mod tokens; 5mod tokens;
@@ -44,6 +45,7 @@ pub trait AstToken<'a> {
44 } 45 }
45} 46}
46 47
48/// An iterator over `SyntaxNode` children of a particular AST type.
47#[derive(Debug)] 49#[derive(Debug)]
48pub struct AstChildren<'a, N> { 50pub struct AstChildren<'a, N> {
49 inner: SyntaxNodeChildren<'a>, 51 inner: SyntaxNodeChildren<'a>,
diff --git a/crates/ra_syntax/src/ast/expr_extensions.rs b/crates/ra_syntax/src/ast/expr_extensions.rs
index b24f86cec..1d8313810 100644
--- a/crates/ra_syntax/src/ast/expr_extensions.rs
+++ b/crates/ra_syntax/src/ast/expr_extensions.rs
@@ -1,3 +1,5 @@
1//! Various extension methods to ast Expr Nodes, which are hard to code-generate.
2
1use crate::{ 3use crate::{
2 SyntaxToken, SyntaxElement, SmolStr, 4 SyntaxToken, SyntaxElement, SmolStr,
3 ast::{self, AstNode, AstChildren, children, child_opt}, 5 ast::{self, AstNode, AstChildren, children, child_opt},
diff --git a/crates/ra_syntax/src/ast/extensions.rs b/crates/ra_syntax/src/ast/extensions.rs
index 342581faf..aec57c380 100644
--- a/crates/ra_syntax/src/ast/extensions.rs
+++ b/crates/ra_syntax/src/ast/extensions.rs
@@ -1,3 +1,6 @@
1//! Various extension methods to ast Nodes, which are hard to code-generate.
2//! Extensions for various expressions live in a sibling `expr_extensions` module.
3
1use itertools::Itertools; 4use itertools::Itertools;
2 5
3use crate::{ 6use crate::{
diff --git a/crates/ra_syntax/src/ast/tokens.rs b/crates/ra_syntax/src/ast/tokens.rs
index 7c30ff15c..da7d507bf 100644
--- a/crates/ra_syntax/src/ast/tokens.rs
+++ b/crates/ra_syntax/src/ast/tokens.rs
@@ -1,3 +1,5 @@
1//! There are many AstNodes, but only a few tokens, so we hand-write them here.
2
1use crate::{ 3use crate::{
2 SyntaxToken, 4 SyntaxToken,
3 SyntaxKind::{COMMENT, WHITESPACE}, 5 SyntaxKind::{COMMENT, WHITESPACE},
diff --git a/crates/ra_syntax/src/ast/traits.rs b/crates/ra_syntax/src/ast/traits.rs
index 98aa22085..aaf07d731 100644
--- a/crates/ra_syntax/src/ast/traits.rs
+++ b/crates/ra_syntax/src/ast/traits.rs
@@ -1,3 +1,7 @@
1//! Various traits that are implemented by ast nodes.
2//!
3//! The implementations are usually trivial, and live in generated.rs
4
1use itertools::Itertools; 5use itertools::Itertools;
2 6
3use crate::{ 7use crate::{