Skip to content

Commit

Permalink
doc: feature-gate doctest that needs rand
Browse files Browse the repository at this point in the history
  • Loading branch information
FreezyLemon authored and YeungOnion committed Sep 13, 2024
1 parent 0c29b44 commit c866d42
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@
//!
//! # Sampling
//! The common use case is to set up the distributions and sample from them which depends on the `Rand` crate for random number generation.
//! ```
#![cfg_attr(feature = "rand", doc = "```")]
#![cfg_attr(not(feature = "rand"), doc = "```ignore")]
//! use statrs::distribution::Exp;
//! use rand::distributions::Distribution;
//! let mut r = rand::rngs::OsRng;
Expand Down

0 comments on commit c866d42

Please sign in to comment.