Skip to content
This repository was archived by the owner on Jul 30, 2025. It is now read-only.

Commit 0db2771

Browse files
committed
Improve docs.rs documentation
1 parent e4783ad commit 0db2771

File tree

3 files changed

+6
-0
lines changed

3 files changed

+6
-0
lines changed

Cargo.toml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,3 +44,7 @@ log_backend = ["dep:log"]
4444
# Bring logs into Rust via the tracing crate. *Warning*: not mutually exclusive with log_backend,
4545
# will result in duplicate logs if both are enabled and one consumes logs from the other.
4646
tracing_backend = ["dep:tracing"]
47+
48+
[package.metadata.docs.rs]
49+
all-features = true
50+
rustdoc-args = ["--cfg", "docsrs"]

src/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#![allow(clippy::uninlined_format_args)]
22
#![cfg_attr(test, feature(test))]
3+
#![cfg_attr(docsrs, feature(doc_cfg))]
34

45
mod common_logging;
56
mod error;

src/whisper_state.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ impl WhisperState {
6666
/// # C++ equivalent
6767
/// `int whisper_ctx_init_openvino_encoder(struct whisper_context * ctx, const char * model_path, const char * device, const char * cache_dir);`
6868
#[cfg(feature = "openvino")]
69+
#[cfg_attr(docsrs, doc(cfg(feature = "openvino")))]
6970
pub fn init_openvino_encoder(
7071
&mut self,
7172
model_path: Option<&str>,

0 commit comments

Comments
 (0)