rust/tests/rustdoc-ui/check-fail.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

24 lines
375 B
Rust
Raw Normal View History

2020-11-12 07:58:07 -06:00
// compile-flags: -Z unstable-options --check
#![feature(rustdoc_missing_doc_code_examples)]
2020-11-12 07:58:07 -06:00
#![deny(missing_docs)]
#![deny(rustdoc::missing_doc_code_examples)]
#![deny(rustdoc::all)]
2020-11-12 07:58:07 -06:00
//! ```rust,testharness
//~^ ERROR
//! let x = 12;
//! ```
2020-11-12 07:58:07 -06:00
pub fn foo() {}
//~^ ERROR
//~^^ ERROR
/// hello
//~^ ERROR
///
/// ```rust,testharness
/// let x = 12;
/// ```
pub fn bar() {}