Added test for check doc strings in crates.

#1856
This commit is contained in:
Alexander Andreev 2019-09-30 11:58:53 +03:00
parent 2b69c84396
commit fdbd6bb11a
171 changed files with 419 additions and 29 deletions

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
pub(crate) mod src;
pub(crate) mod docs;

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use std::sync::Arc;
use ra_syntax::ast;

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use ra_syntax::{
ast::{self, AstNode},
SyntaxNode,

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use std::sync::Arc;
use ra_db::{salsa, SourceDatabase};

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use std::{any::Any, fmt};
use ra_syntax::{ast, AstNode, AstPtr, SyntaxNode, SyntaxNodePtr, TextRange};

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
#[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)]
pub enum Either<A, B> {
A(A),

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
pub(crate) mod lower;
pub(crate) mod scope;
pub(crate) mod validation;

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use ra_arena::Arena;
use ra_syntax::{
ast::{

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use std::sync::Arc;
use ra_arena::{impl_arena_id, Arena, RawId};

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use std::sync::Arc;
use ra_syntax::ast;

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use ra_db::{FileId, FilePosition};
use ra_syntax::{
algo::find_node_at_offset,

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use std::{
hash::{Hash, Hasher},
sync::Arc,

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use rustc_hash::FxHashMap;
use std::sync::Arc;

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use rustc_hash::FxHashMap;
use std::sync::Arc;

View file

@ -1,5 +1,3 @@
#![recursion_limit = "512"]
//! HIR (previously known as descriptors) provides a high-level object oriented
//! access to Rust code.
//!
@ -7,6 +5,8 @@
//! to a particular crate instance. That is, it has cfg flags and features
//! applied. So, the relation between syntax and HIR is many-to-one.
#![recursion_limit = "512"]
macro_rules! impl_froms {
($e:ident: $($v:ident $(($($sv:ident),*))?),*) => {
$(

View file

@ -1,3 +1,5 @@
//! See test_utils/src/marks.rs
test_utils::marks!(
bogus_paths
name_res_works_for_broken_modules

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use std::{panic, sync::Arc};
use parking_lot::Mutex;

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use std::fmt;
use ra_syntax::{ast, SmolStr};

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use ra_db::FileId;
use ra_syntax::{ast, SmolStr};
use rustc_hash::FxHashMap;

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use crate::{MacroDef, ModuleDef};
#[derive(Clone, Copy, Debug, PartialEq, Eq, PartialOrd, Ord, Hash)]

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use std::{ops::Index, sync::Arc};
use ra_arena::{impl_arena_id, map::ArenaMap, Arena, RawId};

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use std::{iter, sync::Arc};
use ra_syntax::{

View file

@ -1,10 +1,10 @@
/// Lookup hir elements using positions in the source code. This is a lossy
/// transformation: in general, a single source might correspond to several
/// modules, functions, etc, due to macros, cfgs and `#[path=]` attributes on
/// modules.
///
/// So, this modules should not be used during hir construction, it exists
/// purely for "IDE needs".
//! Lookup hir elements using positions in the source code. This is a lossy
//! transformation: in general, a single source might correspond to several
//! modules, functions, etc, due to macros, cfgs and `#[path=]` attributes on
//! modules.
//!
//! So, this modules should not be used during hir construction, it exists
//! purely for "IDE needs".
use std::sync::Arc;
use ra_db::FileId;

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use std::{
hash::{Hash, Hasher},
marker::PhantomData,

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use std::fmt;
use crate::db::HirDatabase;

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use super::{InferTy, Ty, TypeCtor};
use crate::{
expr::{BinaryOp, CmpOp},

View file

@ -1,3 +1,5 @@
//! FIXME: write short doc here
use std::fmt;
#[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)]