1
Fork 0

Require module documentation with missing_doc

Closes #9824
This commit is contained in:
Alex Crichton 2013-10-12 19:02:46 -07:00
parent 4d2a402555
commit a84c2999c9
18 changed files with 44 additions and 1 deletions

View file

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
//! Common functionality related to cryptographic digest functions
use std::vec; use std::vec;
use hex::ToHex; use hex::ToHex;

View file

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#[allow(missing_doc)];
use std::iter::range_step; use std::iter::range_step;
use cryptoutil::{write_u32_le, read_u32v_le, FixedBuffer, FixedBuffer64, StandardPadding}; use cryptoutil::{write_u32_le, read_u32v_le, FixedBuffer, FixedBuffer64, StandardPadding};

View file

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#[allow(missing_doc)];
use std::iter::range_step; use std::iter::range_step;
use cryptoutil::{write_u64_be, write_u32_be, read_u64v_be, read_u32v_be, add_bytes_to_bits, use cryptoutil::{write_u64_be, write_u32_be, read_u64v_be, read_u32v_be, add_bytes_to_bits,

View file

@ -8,6 +8,11 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
//! A structure for holding a set of enum variants
//!
//! This module defines a container which uses an efficient bit mask
//! representation to hold C-like enum variants.
#[deriving(Clone, Eq, IterBytes, ToStr)] #[deriving(Clone, Eq, IterBytes, ToStr)]
/// A specialized Set implementation to use enum types. /// A specialized Set implementation to use enum types.
pub struct EnumSet<E> { pub struct EnumSet<E> {

View file

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#[allow(missing_doc)];
use std::io::{Reader, BytesReader}; use std::io::{Reader, BytesReader};
use std::io; use std::io;
use std::cast; use std::cast;

View file

@ -8,6 +8,7 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#[allow(missing_doc)];
use std::vec; use std::vec;

View file

@ -8,12 +8,14 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
//! Bindings for the ability to read lines of input from the console
use std::c_str::ToCStr; use std::c_str::ToCStr;
use std::libc::{c_char, c_int}; use std::libc::{c_char, c_int};
use std::{local_data, str, rt}; use std::{local_data, str, rt};
use std::unstable::finally::Finally; use std::unstable::finally::Finally;
pub mod rustrt { mod rustrt {
use std::libc::{c_char, c_int}; use std::libc::{c_char, c_int};
externfn!(fn linenoise(prompt: *c_char) -> *c_char) externfn!(fn linenoise(prompt: *c_char) -> *c_char)

View file

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#[allow(missing_doc)];
use sort; use sort;
use std::cmp; use std::cmp;
use std::hashmap; use std::hashmap;

View file

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#[allow(missing_doc)];
/** /**
* The concurrency primitives you know and love. * The concurrency primitives you know and love.
* *

View file

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#[allow(missing_doc)];
use std::hashmap::HashMap; use std::hashmap::HashMap;
/// A parsed terminfo entry. /// A parsed terminfo entry.

View file

@ -955,6 +955,11 @@ impl Visitor<()> for MissingDocLintVisitor {
~"missing documentation for a function"); ~"missing documentation for a function");
} }
ast::item_mod(*) if it.vis == ast::public => {
self.check_attrs(it.attrs, it.id, it.span,
~"missing documentation for a module");
}
ast::item_enum(ref edef, _) if it.vis == ast::public => { ast::item_enum(ref edef, _) if it.vis == ast::public => {
self.check_attrs(it.attrs, it.id, it.span, self.check_attrs(it.attrs, it.id, it.span,
~"missing documentation for an enum"); ~"missing documentation for an enum");

View file

@ -135,6 +135,7 @@ impl<T> Clone for @[T] {
} }
#[cfg(not(test))] #[cfg(not(test))]
#[allow(missing_doc)]
pub mod traits { pub mod traits {
use at_vec::append; use at_vec::append;
use clone::Clone; use clone::Clone;
@ -152,6 +153,7 @@ pub mod traits {
#[cfg(test)] #[cfg(test)]
pub mod traits {} pub mod traits {}
#[allow(missing_doc)]
pub mod raw { pub mod raw {
use at_vec::capacity; use at_vec::capacity;
use cast; use cast;

View file

@ -8,6 +8,12 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
//! Parsing of format strings
//!
//! These structures are used when parsing format strings for the compiler.
//! Parsing does not currently happen at runtime (structures of std::fmt::rt are
//! generated instead).
use prelude::*; use prelude::*;
use char; use char;

View file

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#[allow(missing_doc)];
use cell::Cell; use cell::Cell;
use comm; use comm;
use container::Container; use container::Container;

View file

@ -1253,6 +1253,7 @@ Section: Trait implementations
*/ */
#[cfg(not(test))] #[cfg(not(test))]
#[allow(missing_doc)]
pub mod traits { pub mod traits {
use ops::Add; use ops::Add;
use cmp::{TotalOrd, Ordering, Less, Equal, Greater, Eq, Ord, Equiv, TotalEq}; use cmp::{TotalOrd, Ordering, Less, Equal, Greater, Eq, Ord, Equiv, TotalEq};

View file

@ -603,6 +603,7 @@ impl<'self, T> RandomAccessIterator<&'self [T]> for ChunkIter<'self, T> {
// Equality // Equality
#[cfg(not(test))] #[cfg(not(test))]
#[allow(missing_doc)]
pub mod traits { pub mod traits {
use super::*; use super::*;

View file

@ -991,6 +991,7 @@ pub fn std_macros() -> @str {
pub mod $c { pub mod $c {
#[allow(unused_imports)]; #[allow(unused_imports)];
#[allow(non_uppercase_statics)]; #[allow(non_uppercase_statics)];
#[allow(missing_doc)];
use super::*; use super::*;

View file

@ -29,6 +29,9 @@ pub struct PubFoo2 {
c: int, c: int,
} }
mod module_no_dox {}
pub mod pub_module_no_dox {} //~ ERROR: missing documentation
/// dox /// dox
pub fn foo() {} pub fn foo() {}
pub fn foo2() {} //~ ERROR: missing documentation pub fn foo2() {} //~ ERROR: missing documentation