diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2019-09-30 11:46:13 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2019-09-30 11:46:13 +0100 |
commit | ebfba461123928363da55e75195d76314c51fa7e (patch) | |
tree | a1eecf37856e82e6a858de330ffdec9e1a0327f5 /crates/ra_hir | |
parent | 733f1d8b709788225bd06f8c0aee1819db92620b (diff) | |
parent | a47bca636cec350cf29c296dafd0c1bec51cd654 (diff) |
Merge #1937
1937: Added test for check doc strings in directory crates/ r=andreevlex a=andreevlex
#1856
Co-authored-by: Alexander Andreev <[email protected]>
Diffstat (limited to 'crates/ra_hir')
27 files changed, 59 insertions, 9 deletions
diff --git a/crates/ra_hir/src/code_model.rs b/crates/ra_hir/src/code_model.rs index fd7afcbb6..e3a7e8e3c 100644 --- a/crates/ra_hir/src/code_model.rs +++ b/crates/ra_hir/src/code_model.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | pub(crate) mod src; | 3 | pub(crate) mod src; |
2 | pub(crate) mod docs; | 4 | pub(crate) mod docs; |
3 | 5 | ||
diff --git a/crates/ra_hir/src/code_model/docs.rs b/crates/ra_hir/src/code_model/docs.rs index 99edc5814..9675e397f 100644 --- a/crates/ra_hir/src/code_model/docs.rs +++ b/crates/ra_hir/src/code_model/docs.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use std::sync::Arc; | 3 | use std::sync::Arc; |
2 | 4 | ||
3 | use ra_syntax::ast; | 5 | use ra_syntax::ast; |
diff --git a/crates/ra_hir/src/code_model/src.rs b/crates/ra_hir/src/code_model/src.rs index dc964e156..fdae26906 100644 --- a/crates/ra_hir/src/code_model/src.rs +++ b/crates/ra_hir/src/code_model/src.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use ra_syntax::{ | 3 | use ra_syntax::{ |
2 | ast::{self, AstNode}, | 4 | ast::{self, AstNode}, |
3 | SyntaxNode, | 5 | SyntaxNode, |
diff --git a/crates/ra_hir/src/db.rs b/crates/ra_hir/src/db.rs index deed1c62f..73d7d6fb6 100644 --- a/crates/ra_hir/src/db.rs +++ b/crates/ra_hir/src/db.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use std::sync::Arc; | 3 | use std::sync::Arc; |
2 | 4 | ||
3 | use ra_db::{salsa, SourceDatabase}; | 5 | use ra_db::{salsa, SourceDatabase}; |
diff --git a/crates/ra_hir/src/diagnostics.rs b/crates/ra_hir/src/diagnostics.rs index 60da33695..9acdaf8ed 100644 --- a/crates/ra_hir/src/diagnostics.rs +++ b/crates/ra_hir/src/diagnostics.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use std::{any::Any, fmt}; | 3 | use std::{any::Any, fmt}; |
2 | 4 | ||
3 | use ra_syntax::{ast, AstNode, AstPtr, SyntaxNode, SyntaxNodePtr, TextRange}; | 5 | use ra_syntax::{ast, AstNode, AstPtr, SyntaxNode, SyntaxNodePtr, TextRange}; |
diff --git a/crates/ra_hir/src/either.rs b/crates/ra_hir/src/either.rs index 439e6ec87..83583ef8b 100644 --- a/crates/ra_hir/src/either.rs +++ b/crates/ra_hir/src/either.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | #[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)] | 3 | #[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)] |
2 | pub enum Either<A, B> { | 4 | pub enum Either<A, B> { |
3 | A(A), | 5 | A(A), |
diff --git a/crates/ra_hir/src/expr.rs b/crates/ra_hir/src/expr.rs index b1bec2a68..d238741ba 100644 --- a/crates/ra_hir/src/expr.rs +++ b/crates/ra_hir/src/expr.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | pub(crate) mod lower; | 3 | pub(crate) mod lower; |
2 | pub(crate) mod scope; | 4 | pub(crate) mod scope; |
3 | pub(crate) mod validation; | 5 | pub(crate) mod validation; |
diff --git a/crates/ra_hir/src/expr/lower.rs b/crates/ra_hir/src/expr/lower.rs index 6d6f60506..50ea429ea 100644 --- a/crates/ra_hir/src/expr/lower.rs +++ b/crates/ra_hir/src/expr/lower.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use ra_arena::Arena; | 3 | use ra_arena::Arena; |
2 | use ra_syntax::{ | 4 | use ra_syntax::{ |
3 | ast::{ | 5 | ast::{ |
diff --git a/crates/ra_hir/src/expr/scope.rs b/crates/ra_hir/src/expr/scope.rs index de0983a7e..5496822e7 100644 --- a/crates/ra_hir/src/expr/scope.rs +++ b/crates/ra_hir/src/expr/scope.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use std::sync::Arc; | 3 | use std::sync::Arc; |
2 | 4 | ||
3 | use ra_arena::{impl_arena_id, Arena, RawId}; | 5 | use ra_arena::{impl_arena_id, Arena, RawId}; |
diff --git a/crates/ra_hir/src/expr/validation.rs b/crates/ra_hir/src/expr/validation.rs index f06e5ec07..1aa853c3e 100644 --- a/crates/ra_hir/src/expr/validation.rs +++ b/crates/ra_hir/src/expr/validation.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use std::sync::Arc; | 3 | use std::sync::Arc; |
2 | 4 | ||
3 | use ra_syntax::ast; | 5 | use ra_syntax::ast; |
diff --git a/crates/ra_hir/src/from_source.rs b/crates/ra_hir/src/from_source.rs index 7b6d9b240..a012f33f7 100644 --- a/crates/ra_hir/src/from_source.rs +++ b/crates/ra_hir/src/from_source.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use ra_db::{FileId, FilePosition}; | 3 | use ra_db::{FileId, FilePosition}; |
2 | use ra_syntax::{ | 4 | use ra_syntax::{ |
3 | algo::find_node_at_offset, | 5 | algo::find_node_at_offset, |
diff --git a/crates/ra_hir/src/ids.rs b/crates/ra_hir/src/ids.rs index bcbcd3dd7..a3b65cc79 100644 --- a/crates/ra_hir/src/ids.rs +++ b/crates/ra_hir/src/ids.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use std::{ | 3 | use std::{ |
2 | hash::{Hash, Hasher}, | 4 | hash::{Hash, Hasher}, |
3 | sync::Arc, | 5 | sync::Arc, |
diff --git a/crates/ra_hir/src/impl_block.rs b/crates/ra_hir/src/impl_block.rs index c66a1c6a6..8cf74ddc7 100644 --- a/crates/ra_hir/src/impl_block.rs +++ b/crates/ra_hir/src/impl_block.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use rustc_hash::FxHashMap; | 3 | use rustc_hash::FxHashMap; |
2 | use std::sync::Arc; | 4 | use std::sync::Arc; |
3 | 5 | ||
diff --git a/crates/ra_hir/src/lang_item.rs b/crates/ra_hir/src/lang_item.rs index dbba433fe..6c4e8ffbd 100644 --- a/crates/ra_hir/src/lang_item.rs +++ b/crates/ra_hir/src/lang_item.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use rustc_hash::FxHashMap; | 3 | use rustc_hash::FxHashMap; |
2 | use std::sync::Arc; | 4 | use std::sync::Arc; |
3 | 5 | ||
diff --git a/crates/ra_hir/src/lib.rs b/crates/ra_hir/src/lib.rs index a9de9fb6b..00031deba 100644 --- a/crates/ra_hir/src/lib.rs +++ b/crates/ra_hir/src/lib.rs | |||
@@ -1,5 +1,3 @@ | |||
1 | #![recursion_limit = "512"] | ||
2 | |||
3 | //! HIR (previously known as descriptors) provides a high-level object oriented | 1 | //! HIR (previously known as descriptors) provides a high-level object oriented |
4 | //! access to Rust code. | 2 | //! access to Rust code. |
5 | //! | 3 | //! |
@@ -7,6 +5,8 @@ | |||
7 | //! to a particular crate instance. That is, it has cfg flags and features | 5 | //! to a particular crate instance. That is, it has cfg flags and features |
8 | //! applied. So, the relation between syntax and HIR is many-to-one. | 6 | //! applied. So, the relation between syntax and HIR is many-to-one. |
9 | 7 | ||
8 | #![recursion_limit = "512"] | ||
9 | |||
10 | macro_rules! impl_froms { | 10 | macro_rules! impl_froms { |
11 | ($e:ident: $($v:ident $(($($sv:ident),*))?),*) => { | 11 | ($e:ident: $($v:ident $(($($sv:ident),*))?),*) => { |
12 | $( | 12 | $( |
diff --git a/crates/ra_hir/src/marks.rs b/crates/ra_hir/src/marks.rs index 0fed46802..79af24b20 100644 --- a/crates/ra_hir/src/marks.rs +++ b/crates/ra_hir/src/marks.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! See test_utils/src/marks.rs | ||
2 | |||
1 | test_utils::marks!( | 3 | test_utils::marks!( |
2 | bogus_paths | 4 | bogus_paths |
3 | name_res_works_for_broken_modules | 5 | name_res_works_for_broken_modules |
diff --git a/crates/ra_hir/src/mock.rs b/crates/ra_hir/src/mock.rs index cb405091e..50feb98fb 100644 --- a/crates/ra_hir/src/mock.rs +++ b/crates/ra_hir/src/mock.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use std::{panic, sync::Arc}; | 3 | use std::{panic, sync::Arc}; |
2 | 4 | ||
3 | use parking_lot::Mutex; | 5 | use parking_lot::Mutex; |
diff --git a/crates/ra_hir/src/name.rs b/crates/ra_hir/src/name.rs index d50867f5d..1e0b8c350 100644 --- a/crates/ra_hir/src/name.rs +++ b/crates/ra_hir/src/name.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use std::fmt; | 3 | use std::fmt; |
2 | 4 | ||
3 | use ra_syntax::{ast, SmolStr}; | 5 | use ra_syntax::{ast, SmolStr}; |
diff --git a/crates/ra_hir/src/nameres/collector.rs b/crates/ra_hir/src/nameres/collector.rs index 65929c522..a568fdabd 100644 --- a/crates/ra_hir/src/nameres/collector.rs +++ b/crates/ra_hir/src/nameres/collector.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use ra_db::FileId; | 3 | use ra_db::FileId; |
2 | use ra_syntax::{ast, SmolStr}; | 4 | use ra_syntax::{ast, SmolStr}; |
3 | use rustc_hash::FxHashMap; | 5 | use rustc_hash::FxHashMap; |
diff --git a/crates/ra_hir/src/nameres/per_ns.rs b/crates/ra_hir/src/nameres/per_ns.rs index 964da2794..0da6789de 100644 --- a/crates/ra_hir/src/nameres/per_ns.rs +++ b/crates/ra_hir/src/nameres/per_ns.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use crate::{MacroDef, ModuleDef}; | 3 | use crate::{MacroDef, ModuleDef}; |
2 | 4 | ||
3 | #[derive(Clone, Copy, Debug, PartialEq, Eq, PartialOrd, Ord, Hash)] | 5 | #[derive(Clone, Copy, Debug, PartialEq, Eq, PartialOrd, Ord, Hash)] |
diff --git a/crates/ra_hir/src/nameres/raw.rs b/crates/ra_hir/src/nameres/raw.rs index 0e27dd2db..606bd1a95 100644 --- a/crates/ra_hir/src/nameres/raw.rs +++ b/crates/ra_hir/src/nameres/raw.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use std::{ops::Index, sync::Arc}; | 3 | use std::{ops::Index, sync::Arc}; |
2 | 4 | ||
3 | use ra_arena::{impl_arena_id, map::ArenaMap, Arena, RawId}; | 5 | use ra_arena::{impl_arena_id, map::ArenaMap, Arena, RawId}; |
diff --git a/crates/ra_hir/src/path.rs b/crates/ra_hir/src/path.rs index 158c853d4..394617e1a 100644 --- a/crates/ra_hir/src/path.rs +++ b/crates/ra_hir/src/path.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use std::{iter, sync::Arc}; | 3 | use std::{iter, sync::Arc}; |
2 | 4 | ||
3 | use ra_syntax::{ | 5 | use ra_syntax::{ |
diff --git a/crates/ra_hir/src/source_binder.rs b/crates/ra_hir/src/source_binder.rs index 6e89bfc76..088335e66 100644 --- a/crates/ra_hir/src/source_binder.rs +++ b/crates/ra_hir/src/source_binder.rs | |||
@@ -1,10 +1,10 @@ | |||
1 | /// Lookup hir elements using positions in the source code. This is a lossy | 1 | //! Lookup hir elements using positions in the source code. This is a lossy |
2 | /// transformation: in general, a single source might correspond to several | 2 | //! transformation: in general, a single source might correspond to several |
3 | /// modules, functions, etc, due to macros, cfgs and `#[path=]` attributes on | 3 | //! modules, functions, etc, due to macros, cfgs and `#[path=]` attributes on |
4 | /// modules. | 4 | //! modules. |
5 | /// | 5 | //! |
6 | /// So, this modules should not be used during hir construction, it exists | 6 | //! So, this modules should not be used during hir construction, it exists |
7 | /// purely for "IDE needs". | 7 | //! purely for "IDE needs". |
8 | use std::sync::Arc; | 8 | use std::sync::Arc; |
9 | 9 | ||
10 | use ra_db::FileId; | 10 | use ra_db::FileId; |
diff --git a/crates/ra_hir/src/source_id.rs b/crates/ra_hir/src/source_id.rs index 04574876d..a4dd99598 100644 --- a/crates/ra_hir/src/source_id.rs +++ b/crates/ra_hir/src/source_id.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use std::{ | 3 | use std::{ |
2 | hash::{Hash, Hasher}, | 4 | hash::{Hash, Hasher}, |
3 | marker::PhantomData, | 5 | marker::PhantomData, |
diff --git a/crates/ra_hir/src/ty/display.rs b/crates/ra_hir/src/ty/display.rs index 63ec9d7e1..7910429d7 100644 --- a/crates/ra_hir/src/ty/display.rs +++ b/crates/ra_hir/src/ty/display.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use std::fmt; | 3 | use std::fmt; |
2 | 4 | ||
3 | use crate::db::HirDatabase; | 5 | use crate::db::HirDatabase; |
diff --git a/crates/ra_hir/src/ty/op.rs b/crates/ra_hir/src/ty/op.rs index 1b30a5b9b..bcfa3a6a2 100644 --- a/crates/ra_hir/src/ty/op.rs +++ b/crates/ra_hir/src/ty/op.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use super::{InferTy, Ty, TypeCtor}; | 3 | use super::{InferTy, Ty, TypeCtor}; |
2 | use crate::{ | 4 | use crate::{ |
3 | expr::{BinaryOp, CmpOp}, | 5 | expr::{BinaryOp, CmpOp}, |
diff --git a/crates/ra_hir/src/ty/primitive.rs b/crates/ra_hir/src/ty/primitive.rs index 2c60fefd6..8966f9d1d 100644 --- a/crates/ra_hir/src/ty/primitive.rs +++ b/crates/ra_hir/src/ty/primitive.rs | |||
@@ -1,3 +1,5 @@ | |||
1 | //! FIXME: write short doc here | ||
2 | |||
1 | use std::fmt; | 3 | use std::fmt; |
2 | 4 | ||
3 | #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] | 5 | #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] |